Documentation ¶
Index ¶
- func IsAdminError(err error) bool
- type Client
- func (c *Client) Delete(endpoint string) error
- func (c *Client) DeleteWithQueryParams(endpoint string, params map[string]string) error
- func (c *Client) Get(endpoint string, obj interface{}) error
- func (c *Client) GetWithOptions(endpoint string, obj interface{}, params map[string]string, decode bool, ...) ([]byte, error)
- func (c *Client) GetWithQueryParams(endpoint string, obj interface{}, params map[string]string, decode bool) ([]byte, error)
- func (c *Client) MakeRequest(method, endpoint string) (*http.Response, error)
- func (c *Client) MakeRequestWithURL(method string, urlOpt *url.URL) (*http.Response, error)
- func (c *Client) Post(endpoint string, in interface{}) error
- func (c *Client) PostWithMultiPart(endpoint string, in interface{}, body io.Reader, contentType string) error
- func (c *Client) PostWithObj(endpoint string, in, obj interface{}) error
- func (c *Client) PostWithQueryParams(endpoint string, in interface{}, params map[string]string) error
- func (c *Client) Put(endpoint string, in interface{}) error
- func (c *Client) PutWithCustomMediaType(endpoint string, in, obj interface{}, params map[string]string, ...) error
- func (c *Client) PutWithMultiPart(endpoint string, body io.Reader, contentType string) error
- func (c *Client) PutWithQueryParams(endpoint string, in, obj interface{}, params map[string]string) error
- type Error
- type MediaType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsAdminError ¶
Types ¶
type Client ¶
Client is a base client that is used to make http request to the ServiceURL
func (*Client) DeleteWithQueryParams ¶
func (*Client) GetWithOptions ¶
func (*Client) GetWithQueryParams ¶
func (*Client) MakeRequest ¶
MakeRequest can make a simple request and handle the response by yourself
func (*Client) MakeRequestWithURL ¶ added in v0.13.0
func (*Client) PostWithMultiPart ¶
func (*Client) PostWithObj ¶
func (*Client) PostWithQueryParams ¶
func (*Client) PutWithCustomMediaType ¶ added in v0.13.0
func (*Client) PutWithMultiPart ¶
Click to show internal directories.
Click to hide internal directories.