Documentation
¶
Overview ¶
Package oapi provides primitives to interact with the openapi HTTP API.
Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.4.0 DO NOT EDIT.
Index ¶
- func NewConfirmMessagesRequest(server string, params *ConfirmMessagesParams, ...) (*http.Request, error)
- func NewConfirmMessagesRequestWithBody(server string, params *ConfirmMessagesParams, contentType string, ...) (*http.Request, error)
- func NewDeleteEndpointRequest(server string, externalId ExternalId, params *DeleteEndpointParams) (*http.Request, error)
- func NewListAuthorizedTenantsRequest(server string) (*http.Request, error)
- func NewListTenantEndpointsRequest(server string, tenantId TenantId) (*http.Request, error)
- func NewPutEndpointRequest(server string, externalId ExternalId, params *PutEndpointParams, ...) (*http.Request, error)
- func NewPutEndpointRequestWithBody(server string, externalId ExternalId, params *PutEndpointParams, ...) (*http.Request, error)
- func NewReceiveEventsRequest(server string, params *ReceiveEventsParams) (*http.Request, error)
- func NewSendMessagesRequestWithBody(server string, params *SendMessagesParams, contentType string, body io.Reader) (*http.Request, error)
- type Client
- func (c *Client) ConfirmMessages(ctx context.Context, params *ConfirmMessagesParams, ...) (*http.Response, error)
- func (c *Client) ConfirmMessagesWithBody(ctx context.Context, params *ConfirmMessagesParams, contentType string, ...) (*http.Response, error)
- func (c *Client) DeleteEndpoint(ctx context.Context, externalId ExternalId, params *DeleteEndpointParams, ...) (*http.Response, error)
- func (c *Client) ListAuthorizedTenants(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) ListTenantEndpoints(ctx context.Context, tenantId TenantId, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) PutEndpoint(ctx context.Context, externalId ExternalId, params *PutEndpointParams, ...) (*http.Response, error)
- func (c *Client) PutEndpointWithBody(ctx context.Context, externalId ExternalId, params *PutEndpointParams, ...) (*http.Response, error)
- func (c *Client) ReceiveEvents(ctx context.Context, params *ReceiveEventsParams, ...) (*http.Response, error)
- func (c *Client) SendMessagesWithBody(ctx context.Context, params *SendMessagesParams, contentType string, ...) (*http.Response, error)
- type ClientInterface
- type ClientOption
- type ClientWithResponses
- func (c *ClientWithResponses) ConfirmMessagesWithBodyWithResponse(ctx context.Context, params *ConfirmMessagesParams, contentType string, ...) (*ConfirmMessagesResponse, error)
- func (c *ClientWithResponses) ConfirmMessagesWithResponse(ctx context.Context, params *ConfirmMessagesParams, ...) (*ConfirmMessagesResponse, error)
- func (c *ClientWithResponses) DeleteEndpointWithResponse(ctx context.Context, externalId ExternalId, params *DeleteEndpointParams, ...) (*DeleteEndpointResponse, error)
- func (c *ClientWithResponses) ListAuthorizedTenantsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ListAuthorizedTenantsResponse, error)
- func (c *ClientWithResponses) ListTenantEndpointsWithResponse(ctx context.Context, tenantId TenantId, reqEditors ...RequestEditorFn) (*ListTenantEndpointsResponse, error)
- func (c *ClientWithResponses) PutEndpointWithBodyWithResponse(ctx context.Context, externalId ExternalId, params *PutEndpointParams, ...) (*PutEndpointResponse, error)
- func (c *ClientWithResponses) PutEndpointWithResponse(ctx context.Context, externalId ExternalId, params *PutEndpointParams, ...) (*PutEndpointResponse, error)
- func (c *ClientWithResponses) ReceiveEventsWithResponse(ctx context.Context, params *ReceiveEventsParams, ...) (*ReceiveEventsResponse, error)
- func (c *ClientWithResponses) SendMessagesWithBodyWithResponse(ctx context.Context, params *SendMessagesParams, contentType string, ...) (*SendMessagesResponse, error)
- type ClientWithResponsesInterface
- type ConfirmMessagesResponse
- type DeleteEndpointResponse
- type HttpRequestDoer
- type ListAuthorizedTenantsResponse
- type ListTenantEndpointsResponse
- type PutEndpointResponse
- type ReceiveEventsResponse
- type RequestEditorFn
- type SendMessagesResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewConfirmMessagesRequest ¶ added in v0.4.0
func NewConfirmMessagesRequest(server string, params *ConfirmMessagesParams, body ConfirmMessagesJSONRequestBody) (*http.Request, error)
NewConfirmMessagesRequest calls the generic ConfirmMessages builder with application/json body
func NewConfirmMessagesRequestWithBody ¶ added in v0.4.0
func NewConfirmMessagesRequestWithBody(server string, params *ConfirmMessagesParams, contentType string, body io.Reader) (*http.Request, error)
NewConfirmMessagesRequestWithBody generates requests for ConfirmMessages with any type of body
func NewDeleteEndpointRequest ¶ added in v0.6.0
func NewDeleteEndpointRequest(server string, externalId ExternalId, params *DeleteEndpointParams) (*http.Request, error)
NewDeleteEndpointRequest generates requests for DeleteEndpoint
func NewListAuthorizedTenantsRequest ¶ added in v0.8.0
NewListAuthorizedTenantsRequest generates requests for ListAuthorizedTenants
func NewListTenantEndpointsRequest ¶ added in v0.8.0
NewListTenantEndpointsRequest generates requests for ListTenantEndpoints
func NewPutEndpointRequest ¶
func NewPutEndpointRequest(server string, externalId ExternalId, params *PutEndpointParams, body PutEndpointJSONRequestBody) (*http.Request, error)
NewPutEndpointRequest calls the generic PutEndpoint builder with application/json body
func NewPutEndpointRequestWithBody ¶
func NewPutEndpointRequestWithBody(server string, externalId ExternalId, params *PutEndpointParams, contentType string, body io.Reader) (*http.Request, error)
NewPutEndpointRequestWithBody generates requests for PutEndpoint with any type of body
func NewReceiveEventsRequest ¶ added in v0.2.0
NewReceiveEventsRequest generates requests for ReceiveEvents
Types ¶
type Client ¶
type Client struct {
// The endpoint of the server conforming to this interface, with scheme,
// https://api.deepmap.com for example. This can contain a path relative
// to the server, such as https://api.deepmap.com/dev-test, and all the
// paths in the swagger spec will be appended to the server.
Server string
// Doer for performing requests, typically a *http.Client with any
// customized settings, such as certificate chains.
Client HttpRequestDoer
// A list of callbacks for modifying requests which are generated before sending over
// the network.
RequestEditors []RequestEditorFn
}
Client which conforms to the OpenAPI3 specification for this service.
func NewClient ¶
func NewClient(server string, opts ...ClientOption) (*Client, error)
Creates a new Client, with reasonable defaults
func (*Client) ConfirmMessages ¶ added in v0.4.0
func (*Client) ConfirmMessagesWithBody ¶ added in v0.4.0
func (*Client) DeleteEndpoint ¶ added in v0.6.0
func (*Client) ListAuthorizedTenants ¶ added in v0.8.0
func (*Client) ListTenantEndpoints ¶ added in v0.8.0
func (*Client) PutEndpoint ¶
func (*Client) PutEndpointWithBody ¶
func (*Client) ReceiveEvents ¶ added in v0.2.0
type ClientInterface ¶
type ClientInterface interface {
// ConfirmMessagesWithBody request with any body
ConfirmMessagesWithBody(ctx context.Context, params *ConfirmMessagesParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
ConfirmMessages(ctx context.Context, params *ConfirmMessagesParams, body ConfirmMessagesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
// DeleteEndpoint request
DeleteEndpoint(ctx context.Context, externalId ExternalId, params *DeleteEndpointParams, reqEditors ...RequestEditorFn) (*http.Response, error)
// PutEndpointWithBody request with any body
PutEndpointWithBody(ctx context.Context, externalId ExternalId, params *PutEndpointParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
PutEndpoint(ctx context.Context, externalId ExternalId, params *PutEndpointParams, body PutEndpointJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
// ReceiveEvents request
ReceiveEvents(ctx context.Context, params *ReceiveEventsParams, reqEditors ...RequestEditorFn) (*http.Response, error)
// SendMessagesWithBody request with any body
SendMessagesWithBody(ctx context.Context, params *SendMessagesParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
// ListAuthorizedTenants request
ListAuthorizedTenants(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
// ListTenantEndpoints request
ListTenantEndpoints(ctx context.Context, tenantId TenantId, reqEditors ...RequestEditorFn) (*http.Response, error)
}
The interface specification for the client above.
type ClientOption ¶
ClientOption allows setting custom parameters during construction
func WithHTTPClient ¶
func WithHTTPClient(doer HttpRequestDoer) ClientOption
WithHTTPClient allows overriding the default Doer, which is automatically created using http.Client. This is useful for tests.
func WithRequestEditorFn ¶
func WithRequestEditorFn(fn RequestEditorFn) ClientOption
WithRequestEditorFn allows setting up a callback function, which will be called right before sending the request. This can be used to mutate the request.
type ClientWithResponses ¶
type ClientWithResponses struct {
ClientInterface
}
ClientWithResponses builds on ClientInterface to offer response payloads
func NewClientWithResponses ¶
func NewClientWithResponses(server string, opts ...ClientOption) (*ClientWithResponses, error)
NewClientWithResponses creates a new ClientWithResponses, which wraps Client with return type handling
func (*ClientWithResponses) ConfirmMessagesWithBodyWithResponse ¶ added in v0.4.0
func (c *ClientWithResponses) ConfirmMessagesWithBodyWithResponse(ctx context.Context, params *ConfirmMessagesParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ConfirmMessagesResponse, error)
ConfirmMessagesWithBodyWithResponse request with arbitrary body returning *ConfirmMessagesResponse
func (*ClientWithResponses) ConfirmMessagesWithResponse ¶ added in v0.4.0
func (c *ClientWithResponses) ConfirmMessagesWithResponse(ctx context.Context, params *ConfirmMessagesParams, body ConfirmMessagesJSONRequestBody, reqEditors ...RequestEditorFn) (*ConfirmMessagesResponse, error)
func (*ClientWithResponses) DeleteEndpointWithResponse ¶ added in v0.6.0
func (c *ClientWithResponses) DeleteEndpointWithResponse(ctx context.Context, externalId ExternalId, params *DeleteEndpointParams, reqEditors ...RequestEditorFn) (*DeleteEndpointResponse, error)
DeleteEndpointWithResponse request returning *DeleteEndpointResponse
func (*ClientWithResponses) ListAuthorizedTenantsWithResponse ¶ added in v0.8.0
func (c *ClientWithResponses) ListAuthorizedTenantsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ListAuthorizedTenantsResponse, error)
ListAuthorizedTenantsWithResponse request returning *ListAuthorizedTenantsResponse
func (*ClientWithResponses) ListTenantEndpointsWithResponse ¶ added in v0.8.0
func (c *ClientWithResponses) ListTenantEndpointsWithResponse(ctx context.Context, tenantId TenantId, reqEditors ...RequestEditorFn) (*ListTenantEndpointsResponse, error)
ListTenantEndpointsWithResponse request returning *ListTenantEndpointsResponse
func (*ClientWithResponses) PutEndpointWithBodyWithResponse ¶
func (c *ClientWithResponses) PutEndpointWithBodyWithResponse(ctx context.Context, externalId ExternalId, params *PutEndpointParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutEndpointResponse, error)
PutEndpointWithBodyWithResponse request with arbitrary body returning *PutEndpointResponse
func (*ClientWithResponses) PutEndpointWithResponse ¶
func (c *ClientWithResponses) PutEndpointWithResponse(ctx context.Context, externalId ExternalId, params *PutEndpointParams, body PutEndpointJSONRequestBody, reqEditors ...RequestEditorFn) (*PutEndpointResponse, error)
func (*ClientWithResponses) ReceiveEventsWithResponse ¶ added in v0.2.0
func (c *ClientWithResponses) ReceiveEventsWithResponse(ctx context.Context, params *ReceiveEventsParams, reqEditors ...RequestEditorFn) (*ReceiveEventsResponse, error)
ReceiveEventsWithResponse request returning *ReceiveEventsResponse
func (*ClientWithResponses) SendMessagesWithBodyWithResponse ¶
func (c *ClientWithResponses) SendMessagesWithBodyWithResponse(ctx context.Context, params *SendMessagesParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendMessagesResponse, error)
SendMessagesWithBodyWithResponse request with arbitrary body returning *SendMessagesResponse
type ClientWithResponsesInterface ¶
type ClientWithResponsesInterface interface {
// ConfirmMessagesWithBodyWithResponse request with any body
ConfirmMessagesWithBodyWithResponse(ctx context.Context, params *ConfirmMessagesParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ConfirmMessagesResponse, error)
ConfirmMessagesWithResponse(ctx context.Context, params *ConfirmMessagesParams, body ConfirmMessagesJSONRequestBody, reqEditors ...RequestEditorFn) (*ConfirmMessagesResponse, error)
// DeleteEndpointWithResponse request
DeleteEndpointWithResponse(ctx context.Context, externalId ExternalId, params *DeleteEndpointParams, reqEditors ...RequestEditorFn) (*DeleteEndpointResponse, error)
// PutEndpointWithBodyWithResponse request with any body
PutEndpointWithBodyWithResponse(ctx context.Context, externalId ExternalId, params *PutEndpointParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutEndpointResponse, error)
PutEndpointWithResponse(ctx context.Context, externalId ExternalId, params *PutEndpointParams, body PutEndpointJSONRequestBody, reqEditors ...RequestEditorFn) (*PutEndpointResponse, error)
// ReceiveEventsWithResponse request
ReceiveEventsWithResponse(ctx context.Context, params *ReceiveEventsParams, reqEditors ...RequestEditorFn) (*ReceiveEventsResponse, error)
// SendMessagesWithBodyWithResponse request with any body
SendMessagesWithBodyWithResponse(ctx context.Context, params *SendMessagesParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendMessagesResponse, error)
// ListAuthorizedTenantsWithResponse request
ListAuthorizedTenantsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ListAuthorizedTenantsResponse, error)
// ListTenantEndpointsWithResponse request
ListTenantEndpointsWithResponse(ctx context.Context, tenantId TenantId, reqEditors ...RequestEditorFn) (*ListTenantEndpointsResponse, error)
}
ClientWithResponsesInterface is the interface specification for the client with responses above.
type ConfirmMessagesResponse ¶ added in v0.4.0
type ConfirmMessagesResponse struct {
Body []byte
HTTPResponse *http.Response
JSON400 *ErrorResponse
JSON401 *ErrorResponse
JSON403 *ErrorResponse
}
func ParseConfirmMessagesResponse ¶ added in v0.4.0
func ParseConfirmMessagesResponse(rsp *http.Response) (*ConfirmMessagesResponse, error)
ParseConfirmMessagesResponse parses an HTTP response from a ConfirmMessagesWithResponse call
func (ConfirmMessagesResponse) Status ¶ added in v0.4.0
func (r ConfirmMessagesResponse) Status() string
Status returns HTTPResponse.Status
func (ConfirmMessagesResponse) StatusCode ¶ added in v0.4.0
func (r ConfirmMessagesResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type DeleteEndpointResponse ¶ added in v0.6.0
type DeleteEndpointResponse struct {
Body []byte
HTTPResponse *http.Response
JSON400 *ErrorResponse
JSON401 *ErrorResponse
JSON403 *ErrorResponse
JSON404 *ErrorResponse
}
func ParseDeleteEndpointResponse ¶ added in v0.6.0
func ParseDeleteEndpointResponse(rsp *http.Response) (*DeleteEndpointResponse, error)
ParseDeleteEndpointResponse parses an HTTP response from a DeleteEndpointWithResponse call
func (DeleteEndpointResponse) Status ¶ added in v0.6.0
func (r DeleteEndpointResponse) Status() string
Status returns HTTPResponse.Status
func (DeleteEndpointResponse) StatusCode ¶ added in v0.6.0
func (r DeleteEndpointResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type HttpRequestDoer ¶
Doer performs HTTP requests.
The standard http.Client implements this interface.
type ListAuthorizedTenantsResponse ¶ added in v0.8.0
type ListAuthorizedTenantsResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *TenantsListResponse
JSON400 *ErrorResponse
JSON401 *ErrorResponse
JSON403 *ErrorResponse
}
func ParseListAuthorizedTenantsResponse ¶ added in v0.8.0
func ParseListAuthorizedTenantsResponse(rsp *http.Response) (*ListAuthorizedTenantsResponse, error)
ParseListAuthorizedTenantsResponse parses an HTTP response from a ListAuthorizedTenantsWithResponse call
func (ListAuthorizedTenantsResponse) Status ¶ added in v0.8.0
func (r ListAuthorizedTenantsResponse) Status() string
Status returns HTTPResponse.Status
func (ListAuthorizedTenantsResponse) StatusCode ¶ added in v0.8.0
func (r ListAuthorizedTenantsResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type ListTenantEndpointsResponse ¶ added in v0.8.0
type ListTenantEndpointsResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *EndpointsListResponse
JSON400 *ErrorResponse
JSON401 *ErrorResponse
JSON403 *ErrorResponse
}
func ParseListTenantEndpointsResponse ¶ added in v0.8.0
func ParseListTenantEndpointsResponse(rsp *http.Response) (*ListTenantEndpointsResponse, error)
ParseListTenantEndpointsResponse parses an HTTP response from a ListTenantEndpointsWithResponse call
func (ListTenantEndpointsResponse) Status ¶ added in v0.8.0
func (r ListTenantEndpointsResponse) Status() string
Status returns HTTPResponse.Status
func (ListTenantEndpointsResponse) StatusCode ¶ added in v0.8.0
func (r ListTenantEndpointsResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type PutEndpointResponse ¶
type PutEndpointResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *Endpoint
JSON201 *Endpoint
JSON400 *ErrorResponse
JSON401 *ErrorResponse
JSON403 *ErrorResponse
JSON413 *ErrorResponse
}
func ParsePutEndpointResponse ¶
func ParsePutEndpointResponse(rsp *http.Response) (*PutEndpointResponse, error)
ParsePutEndpointResponse parses an HTTP response from a PutEndpointWithResponse call
func (PutEndpointResponse) Status ¶
func (r PutEndpointResponse) Status() string
Status returns HTTPResponse.Status
func (PutEndpointResponse) StatusCode ¶
func (r PutEndpointResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type ReceiveEventsResponse ¶ added in v0.2.0
func ParseReceiveEventsResponse ¶ added in v0.2.0
func ParseReceiveEventsResponse(rsp *http.Response) (*ReceiveEventsResponse, error)
ParseReceiveEventsResponse parses an HTTP response from a ReceiveEventsWithResponse call
func (ReceiveEventsResponse) Status ¶ added in v0.2.0
func (r ReceiveEventsResponse) Status() string
Status returns HTTPResponse.Status
func (ReceiveEventsResponse) StatusCode ¶ added in v0.2.0
func (r ReceiveEventsResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type RequestEditorFn ¶
RequestEditorFn is the function signature for the RequestEditor callback function
type SendMessagesResponse ¶
type SendMessagesResponse struct {
Body []byte
HTTPResponse *http.Response
JSON400 *ErrorResponse
JSON401 *ErrorResponse
JSON403 *ErrorResponse
JSON413 *ErrorResponse
}
func ParseSendMessagesResponse ¶
func ParseSendMessagesResponse(rsp *http.Response) (*SendMessagesResponse, error)
ParseSendMessagesResponse parses an HTTP response from a SendMessagesWithResponse call
func (SendMessagesResponse) Status ¶
func (r SendMessagesResponse) Status() string
Status returns HTTPResponse.Status
func (SendMessagesResponse) StatusCode ¶
func (r SendMessagesResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode