Documentation
¶
Overview ¶
Package api provides primitives to interact with the openapi HTTP API.
Code generated by github.com/deepmap/oapi-codegen version v1.16.2 DO NOT EDIT.
Index ¶
- func NewDeleteUserRequest(server string, params *DeleteUserParams) (*http.Request, error)
- func NewGetUserRequest(server string, params *GetUserParams) (*http.Request, error)
- func NewPutUserCredentialsRequest(server string, params *PutUserCredentialsParams) (*http.Request, error)
- func NewPutUserRequest(server string, body PutUserJSONRequestBody) (*http.Request, error)
- func NewPutUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
- type Client
- func (c *Client) DeleteUser(ctx context.Context, params *DeleteUserParams, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) GetUser(ctx context.Context, params *GetUserParams, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) PutUser(ctx context.Context, body PutUserJSONRequestBody, ...) (*http.Response, error)
- func (c *Client) PutUserCredentials(ctx context.Context, params *PutUserCredentialsParams, ...) (*http.Response, error)
- func (c *Client) PutUserWithBody(ctx context.Context, contentType string, body io.Reader, ...) (*http.Response, error)
- type ClientInterface
- type ClientOption
- type ClientWithResponses
- func (c *ClientWithResponses) DeleteUserWithResponse(ctx context.Context, params *DeleteUserParams, reqEditors ...RequestEditorFn) (*DeleteUserResponse, error)
- func (c *ClientWithResponses) GetUserWithResponse(ctx context.Context, params *GetUserParams, reqEditors ...RequestEditorFn) (*GetUserResponse, error)
- func (c *ClientWithResponses) PutUserCredentialsWithResponse(ctx context.Context, params *PutUserCredentialsParams, ...) (*PutUserCredentialsResponse, error)
- func (c *ClientWithResponses) PutUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, ...) (*PutUserResponse, error)
- func (c *ClientWithResponses) PutUserWithResponse(ctx context.Context, body PutUserJSONRequestBody, ...) (*PutUserResponse, error)
- type ClientWithResponsesInterface
- type DeleteUserParams
- type DeleteUserResponse
- type GetUserParams
- type GetUserResponse
- type HttpRequestDoer
- type PutUserCredentialsParams
- type PutUserCredentialsResponse
- type PutUserJSONRequestBody
- type PutUserResponse
- type RequestEditorFn
- type SecurityInfo
- type UserInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewDeleteUserRequest ¶
func NewDeleteUserRequest(server string, params *DeleteUserParams) (*http.Request, error)
NewDeleteUserRequest generates requests for DeleteUser
func NewGetUserRequest ¶
func NewGetUserRequest(server string, params *GetUserParams) (*http.Request, error)
NewGetUserRequest generates requests for GetUser
func NewPutUserCredentialsRequest ¶
func NewPutUserCredentialsRequest(server string, params *PutUserCredentialsParams) (*http.Request, error)
NewPutUserCredentialsRequest generates requests for PutUserCredentials
func NewPutUserRequest ¶
func NewPutUserRequest(server string, body PutUserJSONRequestBody) (*http.Request, error)
NewPutUserRequest calls the generic PutUser builder with application/json body
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) DeleteUser ¶
func (c *Client) DeleteUser(ctx context.Context, params *DeleteUserParams, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) GetUser ¶
func (c *Client) GetUser(ctx context.Context, params *GetUserParams, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) PutUser ¶
func (c *Client) PutUser(ctx context.Context, body PutUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) PutUserCredentials ¶
func (c *Client) PutUserCredentials(ctx context.Context, params *PutUserCredentialsParams, reqEditors ...RequestEditorFn) (*http.Response, error)
type ClientInterface ¶
type ClientInterface interface {
// DeleteUser request
DeleteUser(ctx context.Context, params *DeleteUserParams, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetUser request
GetUser(ctx context.Context, params *GetUserParams, reqEditors ...RequestEditorFn) (*http.Response, error)
// PutUserWithBody request with any body
PutUserWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
PutUser(ctx context.Context, body PutUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
// PutUserCredentials request
PutUserCredentials(ctx context.Context, params *PutUserCredentialsParams, 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) DeleteUserWithResponse ¶
func (c *ClientWithResponses) DeleteUserWithResponse(ctx context.Context, params *DeleteUserParams, reqEditors ...RequestEditorFn) (*DeleteUserResponse, error)
DeleteUserWithResponse request returning *DeleteUserResponse
func (*ClientWithResponses) GetUserWithResponse ¶
func (c *ClientWithResponses) GetUserWithResponse(ctx context.Context, params *GetUserParams, reqEditors ...RequestEditorFn) (*GetUserResponse, error)
GetUserWithResponse request returning *GetUserResponse
func (*ClientWithResponses) PutUserCredentialsWithResponse ¶
func (c *ClientWithResponses) PutUserCredentialsWithResponse(ctx context.Context, params *PutUserCredentialsParams, reqEditors ...RequestEditorFn) (*PutUserCredentialsResponse, error)
PutUserCredentialsWithResponse request returning *PutUserCredentialsResponse
func (*ClientWithResponses) PutUserWithBodyWithResponse ¶
func (c *ClientWithResponses) PutUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutUserResponse, error)
PutUserWithBodyWithResponse request with arbitrary body returning *PutUserResponse
func (*ClientWithResponses) PutUserWithResponse ¶
func (c *ClientWithResponses) PutUserWithResponse(ctx context.Context, body PutUserJSONRequestBody, reqEditors ...RequestEditorFn) (*PutUserResponse, error)
type ClientWithResponsesInterface ¶
type ClientWithResponsesInterface interface {
// DeleteUserWithResponse request
DeleteUserWithResponse(ctx context.Context, params *DeleteUserParams, reqEditors ...RequestEditorFn) (*DeleteUserResponse, error)
// GetUserWithResponse request
GetUserWithResponse(ctx context.Context, params *GetUserParams, reqEditors ...RequestEditorFn) (*GetUserResponse, error)
// PutUserWithBodyWithResponse request with any body
PutUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutUserResponse, error)
PutUserWithResponse(ctx context.Context, body PutUserJSONRequestBody, reqEditors ...RequestEditorFn) (*PutUserResponse, error)
// PutUserCredentialsWithResponse request
PutUserCredentialsWithResponse(ctx context.Context, params *PutUserCredentialsParams, reqEditors ...RequestEditorFn) (*PutUserCredentialsResponse, error)
}
ClientWithResponsesInterface is the interface specification for the client with responses above.
type DeleteUserParams ¶
type DeleteUserParams struct {
UserId string `form:"userId" json:"userId"`
GroupId string `form:"groupId" json:"groupId"`
}
DeleteUserParams defines parameters for DeleteUser.
type DeleteUserResponse ¶
func ParseDeleteUserResponse ¶
func ParseDeleteUserResponse(rsp *http.Response) (*DeleteUserResponse, error)
ParseDeleteUserResponse parses an HTTP response from a DeleteUserWithResponse call
func (DeleteUserResponse) Status ¶
func (r DeleteUserResponse) Status() string
Status returns HTTPResponse.Status
func (DeleteUserResponse) StatusCode ¶
func (r DeleteUserResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetUserParams ¶
type GetUserParams struct {
UserId string `form:"userId" json:"userId"`
GroupId string `form:"groupId" json:"groupId"`
}
GetUserParams defines parameters for GetUser.
type GetUserResponse ¶
func ParseGetUserResponse ¶
func ParseGetUserResponse(rsp *http.Response) (*GetUserResponse, error)
ParseGetUserResponse parses an HTTP response from a GetUserWithResponse call
func (GetUserResponse) Status ¶
func (r GetUserResponse) Status() string
Status returns HTTPResponse.Status
func (GetUserResponse) StatusCode ¶
func (r GetUserResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type HttpRequestDoer ¶
Doer performs HTTP requests.
The standard http.Client implements this interface.
type PutUserCredentialsParams ¶
type PutUserCredentialsParams struct {
UserId string `form:"userId" json:"userId"`
GroupId string `form:"groupId" json:"groupId"`
}
PutUserCredentialsParams defines parameters for PutUserCredentials.
type PutUserCredentialsResponse ¶
type PutUserCredentialsResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *SecurityInfo
}
func ParsePutUserCredentialsResponse ¶
func ParsePutUserCredentialsResponse(rsp *http.Response) (*PutUserCredentialsResponse, error)
ParsePutUserCredentialsResponse parses an HTTP response from a PutUserCredentialsWithResponse call
func (PutUserCredentialsResponse) Status ¶
func (r PutUserCredentialsResponse) Status() string
Status returns HTTPResponse.Status
func (PutUserCredentialsResponse) StatusCode ¶
func (r PutUserCredentialsResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type PutUserJSONRequestBody ¶
type PutUserJSONRequestBody = UserInfo
PutUserJSONRequestBody defines body for PutUser for application/json ContentType.
type PutUserResponse ¶
func ParsePutUserResponse ¶
func ParsePutUserResponse(rsp *http.Response) (*PutUserResponse, error)
ParsePutUserResponse parses an HTTP response from a PutUserWithResponse call
func (PutUserResponse) Status ¶
func (r PutUserResponse) Status() string
Status returns HTTPResponse.Status
func (PutUserResponse) StatusCode ¶
func (r PutUserResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type RequestEditorFn ¶
RequestEditorFn is the function signature for the RequestEditor callback function
type SecurityInfo ¶
type SecurityInfo struct {
AccessKey string `json:"accessKey"`
Active bool `json:"active"`
CreateDate int `json:"createDate"`
ExpireDate *int `json:"expireDate,omitempty"`
SecretKey string `json:"secretKey"`
}
SecurityInfo defines model for SecurityInfo.
type UserInfo ¶
type UserInfo struct {
Active string `json:"active"`
Address1 string `json:"address1"`
Address2 string `json:"address2"`
CanonicalUserId string `json:"canonicalUserId"`
City string `json:"city"`
Country string `json:"country"`
EmailAddr string `json:"emailAddr"`
FileEndpoints *string `json:"fileEndpoints,omitempty"`
FullName string `json:"fullName"`
GroupId string `json:"groupId"`
Groupuser string `json:"groupuser"`
LdapEnabled bool `json:"ldapEnabled"`
Phone string `json:"phone"`
State string `json:"state"`
UserId string `json:"userId"`
UserType string `json:"userType"`
Website string `json:"website"`
Zip string `json:"zip"`
}
UserInfo defines model for UserInfo.