Documentation ¶
Index ¶
- func GetErrorFromResponse(res *http.Response) error
- func Min(a int, b int) int
- func UnmarshalResponse(res *http.Response, dst interface{}) error
- type APIStatus
- type ApiError
- type ErrorResponse
- type HttpClient
- func (c *HttpClient) FetchWithGet(path string, queryValues interface{}, responseModel interface{}, ...) error
- func (c *HttpClient) PatchJSON(path string, queryValues interface{}, body interface{}, ...) error
- func (c *HttpClient) PostFile(path string, queryValues interface{}, file io.Reader, ...) error
- func (c *HttpClient) PostJSON(path string, queryValues interface{}, body interface{}, ...) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetErrorFromResponse ¶
func UnmarshalResponse ¶
Types ¶
type ApiError ¶
type ErrorResponse ¶
type ErrorResponse struct {
Error ApiError `json:"error"`
}
type HttpClient ¶
type HttpClient struct {
// contains filtered or unexported fields
}
func NewHttpClient ¶
func NewHttpClient(c *http.Client) *HttpClient
func (*HttpClient) FetchWithGet ¶
Click to show internal directories.
Click to hide internal directories.