func (views *Views) Add(body []byte) (ViewResp, error) {
	body = patchMetadataType(body, "SP.View")
	client := NewHTTPClient(views.client)
	return client.Post(views.endpoint, bytes.NewBuffer(body), views.config)
}
Add adds view with properties provided in `body` parameter
where `body` is byte array representation of JSON string payload relevant to SP.View object
package api
import (
	"bytes"
	"fmt"
	"github.com/koltyakov/gosip"
)
type Views struct {
	client    *gosip.SPClient
	config    *RequestConfig
	endpoint  string
	modifiers *ODataMods
}
type ViewsResp []byte
func NewViews(client *gosip.SPClient, endpoint string, config *RequestConfig) *Views {
	return &Views{
		client:    client,
		endpoint:  endpoint,
		config:    config,
		modifiers: NewODataMods(),
	}
}
func (views *Views) ToURL() string {
	return toURL(views.endpoint, views.modifiers)
}
func (views *Views) Get() (ViewsResp, error) {
	client := NewHTTPClient(views.client)
	return client.Get(views.ToURL(), views.config)
}