Documentation ¶
Overview ¶
Package api provides primitives to interact with the openapi HTTP API.
Code generated by github.com/deepmap/oapi-codegen/v2 version v2.1.0 DO NOT EDIT.
Index ¶
- func NewGetV1ConfigNamespaceNameRequest(server string, namespace string, name string, ...) (*http.Request, error)
- func NewListV1ConfigsNamespaceRequest(server string, namespace string, params *ListV1ConfigsNamespaceParams) (*http.Request, error)
- func NewListV1ConfigsRequest(server string, params *ListV1ConfigsParams) (*http.Request, error)
- type Client
- func (c *Client) GetV1ConfigNamespaceName(ctx context.Context, namespace string, name string, ...) (*http.Response, error)
- func (c *Client) ListV1Configs(ctx context.Context, params *ListV1ConfigsParams, ...) (*http.Response, error)
- func (c *Client) ListV1ConfigsNamespace(ctx context.Context, namespace string, params *ListV1ConfigsNamespaceParams, ...) (*http.Response, error)
- type ClientInterface
- type ClientOption
- type ClientWithResponses
- func (c *ClientWithResponses) GetV1ConfigNamespaceNameWithResponse(ctx context.Context, namespace string, name string, ...) (*GetV1ConfigNamespaceNameResponse, error)
- func (c *ClientWithResponses) ListV1ConfigsNamespaceWithResponse(ctx context.Context, namespace string, params *ListV1ConfigsNamespaceParams, ...) (*ListV1ConfigsNamespaceResponse, error)
- func (c *ClientWithResponses) ListV1ConfigsWithResponse(ctx context.Context, params *ListV1ConfigsParams, ...) (*ListV1ConfigsResponse, error)
- type ClientWithResponsesInterface
- type GetV1ConfigNamespaceNameParams
- type GetV1ConfigNamespaceNameResponse
- type HttpRequestDoer
- type ListV1ConfigsNamespaceParams
- type ListV1ConfigsNamespaceResponse
- type ListV1ConfigsParams
- type ListV1ConfigsResponse
- type RequestEditorFn
- type V1Config
- type V1ConfigList
- type V1Error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewGetV1ConfigNamespaceNameRequest ¶
func NewGetV1ConfigNamespaceNameRequest(server string, namespace string, name string, params *GetV1ConfigNamespaceNameParams) (*http.Request, error)
NewGetV1ConfigNamespaceNameRequest generates requests for GetV1ConfigNamespaceName
func NewListV1ConfigsNamespaceRequest ¶
func NewListV1ConfigsNamespaceRequest(server string, namespace string, params *ListV1ConfigsNamespaceParams) (*http.Request, error)
NewListV1ConfigsNamespaceRequest generates requests for ListV1ConfigsNamespace
func NewListV1ConfigsRequest ¶
func NewListV1ConfigsRequest(server string, params *ListV1ConfigsParams) (*http.Request, error)
NewListV1ConfigsRequest generates requests for ListV1Configs
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) GetV1ConfigNamespaceName ¶
func (c *Client) GetV1ConfigNamespaceName(ctx context.Context, namespace string, name string, params *GetV1ConfigNamespaceNameParams, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) ListV1Configs ¶
func (c *Client) ListV1Configs(ctx context.Context, params *ListV1ConfigsParams, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) ListV1ConfigsNamespace ¶
func (c *Client) ListV1ConfigsNamespace(ctx context.Context, namespace string, params *ListV1ConfigsNamespaceParams, reqEditors ...RequestEditorFn) (*http.Response, error)
type ClientInterface ¶
type ClientInterface interface { // ListV1Configs request ListV1Configs(ctx context.Context, params *ListV1ConfigsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // ListV1ConfigsNamespace request ListV1ConfigsNamespace(ctx context.Context, namespace string, params *ListV1ConfigsNamespaceParams, reqEditors ...RequestEditorFn) (*http.Response, error) // GetV1ConfigNamespaceName request GetV1ConfigNamespaceName(ctx context.Context, namespace string, name string, params *GetV1ConfigNamespaceNameParams, 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) GetV1ConfigNamespaceNameWithResponse ¶
func (c *ClientWithResponses) GetV1ConfigNamespaceNameWithResponse(ctx context.Context, namespace string, name string, params *GetV1ConfigNamespaceNameParams, reqEditors ...RequestEditorFn) (*GetV1ConfigNamespaceNameResponse, error)
GetV1ConfigNamespaceNameWithResponse request returning *GetV1ConfigNamespaceNameResponse
func (*ClientWithResponses) ListV1ConfigsNamespaceWithResponse ¶
func (c *ClientWithResponses) ListV1ConfigsNamespaceWithResponse(ctx context.Context, namespace string, params *ListV1ConfigsNamespaceParams, reqEditors ...RequestEditorFn) (*ListV1ConfigsNamespaceResponse, error)
ListV1ConfigsNamespaceWithResponse request returning *ListV1ConfigsNamespaceResponse
func (*ClientWithResponses) ListV1ConfigsWithResponse ¶
func (c *ClientWithResponses) ListV1ConfigsWithResponse(ctx context.Context, params *ListV1ConfigsParams, reqEditors ...RequestEditorFn) (*ListV1ConfigsResponse, error)
ListV1ConfigsWithResponse request returning *ListV1ConfigsResponse
type ClientWithResponsesInterface ¶
type ClientWithResponsesInterface interface { // ListV1ConfigsWithResponse request ListV1ConfigsWithResponse(ctx context.Context, params *ListV1ConfigsParams, reqEditors ...RequestEditorFn) (*ListV1ConfigsResponse, error) // ListV1ConfigsNamespaceWithResponse request ListV1ConfigsNamespaceWithResponse(ctx context.Context, namespace string, params *ListV1ConfigsNamespaceParams, reqEditors ...RequestEditorFn) (*ListV1ConfigsNamespaceResponse, error) // GetV1ConfigNamespaceNameWithResponse request GetV1ConfigNamespaceNameWithResponse(ctx context.Context, namespace string, name string, params *GetV1ConfigNamespaceNameParams, reqEditors ...RequestEditorFn) (*GetV1ConfigNamespaceNameResponse, error) }
ClientWithResponsesInterface is the interface specification for the client with responses above.
type GetV1ConfigNamespaceNameParams ¶
type GetV1ConfigNamespaceNameParams struct { // Watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Watch *bool `form:"watch,omitempty" json:"watch,omitempty"` // Node Name of the node the client runs on. Node *string `form:"node,omitempty" json:"node,omitempty"` }
GetV1ConfigNamespaceNameParams defines parameters for GetV1ConfigNamespaceName.
type GetV1ConfigNamespaceNameResponse ¶
type GetV1ConfigNamespaceNameResponse struct { Body []byte HTTPResponse *http.Response JSON200 *V1Config JSON404 *V1Error JSON500 *V1Error JSONDefault *V1Error }
func ParseGetV1ConfigNamespaceNameResponse ¶
func ParseGetV1ConfigNamespaceNameResponse(rsp *http.Response) (*GetV1ConfigNamespaceNameResponse, error)
ParseGetV1ConfigNamespaceNameResponse parses an HTTP response from a GetV1ConfigNamespaceNameWithResponse call
func (GetV1ConfigNamespaceNameResponse) Status ¶
func (r GetV1ConfigNamespaceNameResponse) Status() string
Status returns HTTPResponse.Status
func (GetV1ConfigNamespaceNameResponse) StatusCode ¶
func (r GetV1ConfigNamespaceNameResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type HttpRequestDoer ¶
Doer performs HTTP requests.
The standard http.Client implements this interface.
type ListV1ConfigsNamespaceParams ¶
type ListV1ConfigsNamespaceParams struct { // Watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Watch *bool `form:"watch,omitempty" json:"watch,omitempty"` }
ListV1ConfigsNamespaceParams defines parameters for ListV1ConfigsNamespace.
type ListV1ConfigsNamespaceResponse ¶
type ListV1ConfigsNamespaceResponse struct { Body []byte HTTPResponse *http.Response JSON200 *V1ConfigList JSONDefault *V1Error }
func ParseListV1ConfigsNamespaceResponse ¶
func ParseListV1ConfigsNamespaceResponse(rsp *http.Response) (*ListV1ConfigsNamespaceResponse, error)
ParseListV1ConfigsNamespaceResponse parses an HTTP response from a ListV1ConfigsNamespaceWithResponse call
func (ListV1ConfigsNamespaceResponse) Status ¶
func (r ListV1ConfigsNamespaceResponse) Status() string
Status returns HTTPResponse.Status
func (ListV1ConfigsNamespaceResponse) StatusCode ¶
func (r ListV1ConfigsNamespaceResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type ListV1ConfigsParams ¶
type ListV1ConfigsParams struct { // Watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Watch *bool `form:"watch,omitempty" json:"watch,omitempty"` }
ListV1ConfigsParams defines parameters for ListV1Configs.
type ListV1ConfigsResponse ¶
type ListV1ConfigsResponse struct { Body []byte HTTPResponse *http.Response JSON200 *V1ConfigList JSONDefault *V1Error }
func ParseListV1ConfigsResponse ¶
func ParseListV1ConfigsResponse(rsp *http.Response) (*ListV1ConfigsResponse, error)
ParseListV1ConfigsResponse parses an HTTP response from a ListV1ConfigsWithResponse call
func (ListV1ConfigsResponse) Status ¶
func (r ListV1ConfigsResponse) Status() string
Status returns HTTPResponse.Status
func (ListV1ConfigsResponse) StatusCode ¶
func (r ListV1ConfigsResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type RequestEditorFn ¶
RequestEditorFn is the function signature for the RequestEditor callback function
type V1Config ¶
type V1Config = stunnerv1.StunnerConfig
V1Config Config provides a STUNner config. Schema is defined in https://github.com/l7mp/stunner/tree/main/pkg/apis/v1
type V1ConfigList ¶ added in v0.17.1
type V1ConfigList struct { // Items Items is the list of Config objects in the list. Items []V1Config `json:"items"` // Version version defines the versioned schema of this object. Version string `json:"version"` }
V1ConfigList ConfigList is a list of Configs.