Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type APIClient ¶
type APIClient interface { // MessageType retrieves the type of messages sent and received over the API MessageType() MessageType // Host retrieves the API host server Host() *url.URL // Call will send the message to the API host, and expect a response message in return Call(path string, request *Message, response *Message) (err error) }
type Message ¶
type Message struct { // Method tells which method to use when sending request Method string // Status is a representation of eg. http status code in responses Status int // Header is a map of Message headers Header http.Header // Body is the message body object // the message body is de-serialized at retrieval and serialized before sending request Body interface{} }
type MessageType ¶
type MessageType interface { // ContentType retrieves the MIME-type of the message body ContentType() string // Serializer retrieves the message serializer to use Serializer() Serializer }
Click to show internal directories.
Click to hide internal directories.