Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type APIError ¶
type APIError struct { ExpectedStatusCodes []int // Resp HTTP response Resp *http.Response // Err is either error body or error from io.Copy. // TODO: be more specific? Err error }
APIError REST API error
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client the REST API client
func NewClient ¶
NewClient returns REST API Client. Use https://github.com/cristalhq/hedgedhttp for retries. Check https://github.com/vtopc/restclient/tree/master/interceptors for middlewares/interceptors. TODO: switch to HTTPClient interface?
type HTTPClient ¶
HTTPClient a HTTP client
Click to show internal directories.
Click to hide internal directories.