Documentation ¶
Index ¶
- type ClientConfig
- type HTTPClient
- func (client *HTTPClient) CreateRequest(method, path string, body []byte) (*http.Request, error)
- func (client *HTTPClient) Delete(path string) (int, error)
- func (client *HTTPClient) Do(req *http.Request) (*http.Response, error)
- func (client *HTTPClient) Get(path string) (int, []byte, error)
- func (client *HTTPClient) Post(path string, jsonBody []byte) (int, []byte, error)
- type Queries
- type Query
- type Reference
- type SessionID
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ClientConfig ¶
ClientConfig encapsulate the data needed to configure the HTTPClient
type HTTPClient ¶
type HTTPClient struct {
// contains filtered or unexported fields
}
HTTPClient provides a implementation of the Client interface
func NewHTTPClient ¶
func (*HTTPClient) CreateRequest ¶
CreateRequest builds a new request from the given parameters
func (*HTTPClient) Delete ¶
func (client *HTTPClient) Delete(path string) (int, error)
Delete perform HTTP DELETE on path
type Reference ¶
type Reference struct {
ID string `json:"id"`
}
Reference represents an ID to another REST resource
type SessionID ¶
type SessionID string
SessionID represents a session ID. For proper validation use NewSession() func to initialize sessionID's.
func NewSession ¶
NewSession validates and initializes a new session ID from a string.
Click to show internal directories.
Click to hide internal directories.