Documentation ¶ Index ¶ type Api func Create(config config.Config) (Api, error) func (self *Api) DoCall(request *Request) error func (self *Api) DoLogin() func (self *Api) LoadToken() (oauth2.Token, error) func (self *Api) PrepareClient() error func (self *Api) UpdateAuth(token *oauth2.Token) error type Request Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ This section is empty. Types ¶ type Api ¶ type Api struct { Auth config.Auth AuthFile string BaseHost string Endpoint oauth2.Endpoint Config oauth2.Config Client *http.Client } func Create ¶ func Create(config config.Config) (Api, error) func (*Api) DoCall ¶ func (self *Api) DoCall(request *Request) error func (*Api) DoLogin ¶ func (self *Api) DoLogin() func (*Api) LoadToken ¶ func (self *Api) LoadToken() (oauth2.Token, error) func (*Api) PrepareClient ¶ func (self *Api) PrepareClient() error func (*Api) UpdateAuth ¶ func (self *Api) UpdateAuth(token *oauth2.Token) error type Request ¶ type Request struct { Method string Path string Params url.Values Response http.Response Data map[string]interface{} } Source Files ¶ View all Source files api.go Click to show internal directories. Click to hide internal directories.