Documentation ¶
Overview ¶
Package httpapi provides a client and server for a remote http api.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct { Endpoint string HTTPClient HTTPClient }
A Client marshals requests to send over the wire to a remote http server.
func (*Client) Apply ¶
func (c *Client) Apply(ctx context.Context, req *api.ApplyRequest) (*api.ApplyResponse, error)
Apply marshals an ApplyRequest and sends it over the wire.
The type of req.Config must be *hclpack.Body.
type Error ¶
type Error struct {
Msg string `json:"message"`
}
An Error is a json encoded error message from the api.
type HTTPClient ¶
HTTPClient is the client to use for communication.
Click to show internal directories.
Click to hide internal directories.