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.5.1 DO NOT EDIT.
Index ¶
- Constants
- func NewAddPetRequest(server string, body AddPetJSONRequestBody) (*http.Request, error)
- func NewAddPetRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
- func NewAddPetRequestWithFormdataBody(server string, body AddPetFormdataRequestBody) (*http.Request, error)
- func NewCreateUserRequest(server string, body CreateUserJSONRequestBody) (*http.Request, error)
- func NewCreateUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
- func NewCreateUserRequestWithFormdataBody(server string, body CreateUserFormdataRequestBody) (*http.Request, error)
- func NewCreateUsersWithListInputRequest(server string, body CreateUsersWithListInputJSONRequestBody) (*http.Request, error)
- func NewCreateUsersWithListInputRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
- func NewDeleteOrderRequest(server string, orderId int64) (*http.Request, error)
- func NewDeletePetRequest(server string, petId int64, params *DeletePetParams) (*http.Request, error)
- func NewDeleteUserRequest(server string, username string) (*http.Request, error)
- func NewFindPetsByStatusRequest(server string, params *FindPetsByStatusParams) (*http.Request, error)
- func NewFindPetsByTagsRequest(server string, params *FindPetsByTagsParams) (*http.Request, error)
- func NewGetOrderByIdRequest(server string, orderId int64) (*http.Request, error)
- func NewGetPetByIdRequest(server string, petId int64) (*http.Request, error)
- func NewGetPetMetadataRequest(server string, petId int64, params *GetPetMetadataParams) (*http.Request, error)
- func NewGetPetPhotoByIdRequest(server string, petId int64, photoId int64) (*http.Request, error)
- func NewGetPetRegistrationRequest(server string, petId int64) (*http.Request, error)
- func NewGetStoreInventoryRequest(server string) (*http.Request, error)
- func NewGetUserByNameRequest(server string, username string) (*http.Request, error)
- func NewLoginUserRequest(server string, params *LoginUserParams) (*http.Request, error)
- func NewLogoutUserRequest(server string) (*http.Request, error)
- func NewPostStoreOrderRequest(server string, body PostStoreOrderJSONRequestBody) (*http.Request, error)
- func NewPostStoreOrderRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
- func NewPostStoreOrderRequestWithFormdataBody(server string, body PostStoreOrderFormdataRequestBody) (*http.Request, error)
- func NewUpdatePetRequest(server string, body UpdatePetJSONRequestBody) (*http.Request, error)
- func NewUpdatePetRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
- func NewUpdatePetRequestWithFormdataBody(server string, body UpdatePetFormdataRequestBody) (*http.Request, error)
- func NewUpdatePetWithFormRequest(server string, petId int64, params *UpdatePetWithFormParams) (*http.Request, error)
- func NewUpdateUserRequest(server string, username string, body UpdateUserJSONRequestBody) (*http.Request, error)
- func NewUpdateUserRequestWithBody(server string, username string, contentType string, body io.Reader) (*http.Request, error)
- func NewUpdateUserRequestWithFormdataBody(server string, username string, body UpdateUserFormdataRequestBody) (*http.Request, error)
- func NewUploadFileRequestWithBody(server string, petId int64, params *UploadFileParams, contentType string, ...) (*http.Request, error)
- type AddPetFormdataRequestBody
- type AddPetJSONRequestBody
- type AddPetResponse
- type ApiResponse
- type BasePhoto
- type Category
- type Client
- func (c *Client) AddPet(ctx context.Context, body AddPetJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) AddPetWithBody(ctx context.Context, contentType string, body io.Reader, ...) (*http.Response, error)
- func (c *Client) AddPetWithFormdataBody(ctx context.Context, body AddPetFormdataRequestBody, ...) (*http.Response, error)
- func (c *Client) CreateUser(ctx context.Context, body CreateUserJSONRequestBody, ...) (*http.Response, error)
- func (c *Client) CreateUserWithBody(ctx context.Context, contentType string, body io.Reader, ...) (*http.Response, error)
- func (c *Client) CreateUserWithFormdataBody(ctx context.Context, body CreateUserFormdataRequestBody, ...) (*http.Response, error)
- func (c *Client) CreateUsersWithListInput(ctx context.Context, body CreateUsersWithListInputJSONRequestBody, ...) (*http.Response, error)
- func (c *Client) CreateUsersWithListInputWithBody(ctx context.Context, contentType string, body io.Reader, ...) (*http.Response, error)
- func (c *Client) DeleteOrder(ctx context.Context, orderId int64, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) DeletePet(ctx context.Context, petId int64, params *DeletePetParams, ...) (*http.Response, error)
- func (c *Client) DeleteUser(ctx context.Context, username string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) FindPetsByStatus(ctx context.Context, params *FindPetsByStatusParams, ...) (*http.Response, error)
- func (c *Client) FindPetsByTags(ctx context.Context, params *FindPetsByTagsParams, ...) (*http.Response, error)
- func (c *Client) GetOrderById(ctx context.Context, orderId int64, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) GetPetById(ctx context.Context, petId int64, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) GetPetMetadata(ctx context.Context, petId int64, params *GetPetMetadataParams, ...) (*http.Response, error)
- func (c *Client) GetPetPhotoById(ctx context.Context, petId int64, photoId int64, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) GetPetRegistration(ctx context.Context, petId int64, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) GetStoreInventory(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) GetUserByName(ctx context.Context, username string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) LoginUser(ctx context.Context, params *LoginUserParams, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) LogoutUser(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) PostStoreOrder(ctx context.Context, body PostStoreOrderJSONRequestBody, ...) (*http.Response, error)
- func (c *Client) PostStoreOrderWithBody(ctx context.Context, contentType string, body io.Reader, ...) (*http.Response, error)
- func (c *Client) PostStoreOrderWithFormdataBody(ctx context.Context, body PostStoreOrderFormdataRequestBody, ...) (*http.Response, error)
- func (c *Client) UpdatePet(ctx context.Context, body UpdatePetJSONRequestBody, ...) (*http.Response, error)
- func (c *Client) UpdatePetWithBody(ctx context.Context, contentType string, body io.Reader, ...) (*http.Response, error)
- func (c *Client) UpdatePetWithForm(ctx context.Context, petId int64, params *UpdatePetWithFormParams, ...) (*http.Response, error)
- func (c *Client) UpdatePetWithFormdataBody(ctx context.Context, body UpdatePetFormdataRequestBody, ...) (*http.Response, error)
- func (c *Client) UpdateUser(ctx context.Context, username string, body UpdateUserJSONRequestBody, ...) (*http.Response, error)
- func (c *Client) UpdateUserWithBody(ctx context.Context, username string, contentType string, body io.Reader, ...) (*http.Response, error)
- func (c *Client) UpdateUserWithFormdataBody(ctx context.Context, username string, body UpdateUserFormdataRequestBody, ...) (*http.Response, error)
- func (c *Client) UploadFileWithBody(ctx context.Context, petId int64, params *UploadFileParams, contentType string, ...) (*http.Response, error)
- type ClientInterface
- type ClientOption
- type ClientWithResponses
- func (c *ClientWithResponses) AddPetWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, ...) (*AddPetResponse, error)
- func (c *ClientWithResponses) AddPetWithFormdataBodyWithResponse(ctx context.Context, body AddPetFormdataRequestBody, ...) (*AddPetResponse, error)
- func (c *ClientWithResponses) AddPetWithResponse(ctx context.Context, body AddPetJSONRequestBody, reqEditors ...RequestEditorFn) (*AddPetResponse, error)
- func (c *ClientWithResponses) CreateUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, ...) (*CreateUserResponse, error)
- func (c *ClientWithResponses) CreateUserWithFormdataBodyWithResponse(ctx context.Context, body CreateUserFormdataRequestBody, ...) (*CreateUserResponse, error)
- func (c *ClientWithResponses) CreateUserWithResponse(ctx context.Context, body CreateUserJSONRequestBody, ...) (*CreateUserResponse, error)
- func (c *ClientWithResponses) CreateUsersWithListInputWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, ...) (*CreateUsersWithListInputResponse, error)
- func (c *ClientWithResponses) CreateUsersWithListInputWithResponse(ctx context.Context, body CreateUsersWithListInputJSONRequestBody, ...) (*CreateUsersWithListInputResponse, error)
- func (c *ClientWithResponses) DeleteOrderWithResponse(ctx context.Context, orderId int64, reqEditors ...RequestEditorFn) (*DeleteOrderResponse, error)
- func (c *ClientWithResponses) DeletePetWithResponse(ctx context.Context, petId int64, params *DeletePetParams, ...) (*DeletePetResponse, error)
- func (c *ClientWithResponses) DeleteUserWithResponse(ctx context.Context, username string, reqEditors ...RequestEditorFn) (*DeleteUserResponse, error)
- func (c *ClientWithResponses) FindPetsByStatusWithResponse(ctx context.Context, params *FindPetsByStatusParams, ...) (*FindPetsByStatusResponse, error)
- func (c *ClientWithResponses) FindPetsByTagsWithResponse(ctx context.Context, params *FindPetsByTagsParams, ...) (*FindPetsByTagsResponse, error)
- func (c *ClientWithResponses) GetOrderByIdWithResponse(ctx context.Context, orderId int64, reqEditors ...RequestEditorFn) (*GetOrderByIdResponse, error)
- func (c *ClientWithResponses) GetPetByIdWithResponse(ctx context.Context, petId int64, reqEditors ...RequestEditorFn) (*GetPetByIdResponse, error)
- func (c *ClientWithResponses) GetPetMetadataWithResponse(ctx context.Context, petId int64, params *GetPetMetadataParams, ...) (*GetPetMetadataResponse, error)
- func (c *ClientWithResponses) GetPetPhotoByIdWithResponse(ctx context.Context, petId int64, photoId int64, reqEditors ...RequestEditorFn) (*GetPetPhotoByIdResponse, error)
- func (c *ClientWithResponses) GetPetRegistrationWithResponse(ctx context.Context, petId int64, reqEditors ...RequestEditorFn) (*GetPetRegistrationResponse, error)
- func (c *ClientWithResponses) GetStoreInventoryWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetStoreInventoryResponse, error)
- func (c *ClientWithResponses) GetUserByNameWithResponse(ctx context.Context, username string, reqEditors ...RequestEditorFn) (*GetUserByNameResponse, error)
- func (c *ClientWithResponses) LoginUserWithResponse(ctx context.Context, params *LoginUserParams, reqEditors ...RequestEditorFn) (*LoginUserResponse, error)
- func (c *ClientWithResponses) LogoutUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*LogoutUserResponse, error)
- func (c *ClientWithResponses) PostStoreOrderWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, ...) (*PostStoreOrderResponse, error)
- func (c *ClientWithResponses) PostStoreOrderWithFormdataBodyWithResponse(ctx context.Context, body PostStoreOrderFormdataRequestBody, ...) (*PostStoreOrderResponse, error)
- func (c *ClientWithResponses) PostStoreOrderWithResponse(ctx context.Context, body PostStoreOrderJSONRequestBody, ...) (*PostStoreOrderResponse, error)
- func (c *ClientWithResponses) UpdatePetWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, ...) (*UpdatePetResponse, error)
- func (c *ClientWithResponses) UpdatePetWithFormWithResponse(ctx context.Context, petId int64, params *UpdatePetWithFormParams, ...) (*UpdatePetWithFormResponse, error)
- func (c *ClientWithResponses) UpdatePetWithFormdataBodyWithResponse(ctx context.Context, body UpdatePetFormdataRequestBody, ...) (*UpdatePetResponse, error)
- func (c *ClientWithResponses) UpdatePetWithResponse(ctx context.Context, body UpdatePetJSONRequestBody, ...) (*UpdatePetResponse, error)
- func (c *ClientWithResponses) UpdateUserWithBodyWithResponse(ctx context.Context, username string, contentType string, body io.Reader, ...) (*UpdateUserResponse, error)
- func (c *ClientWithResponses) UpdateUserWithFormdataBodyWithResponse(ctx context.Context, username string, body UpdateUserFormdataRequestBody, ...) (*UpdateUserResponse, error)
- func (c *ClientWithResponses) UpdateUserWithResponse(ctx context.Context, username string, body UpdateUserJSONRequestBody, ...) (*UpdateUserResponse, error)
- func (c *ClientWithResponses) UploadFileWithBodyWithResponse(ctx context.Context, petId int64, params *UploadFileParams, contentType string, ...) (*UploadFileResponse, error)
- type ClientWithResponsesInterface
- type CreateUserFormdataRequestBody
- type CreateUserJSONRequestBody
- type CreateUserResponse
- type CreateUsersWithListInputJSONBody
- type CreateUsersWithListInputJSONRequestBody
- type CreateUsersWithListInputResponse
- type DeleteOrderResponse
- type DeletePetParams
- type DeletePetResponse
- type DeleteUserResponse
- type Error
- type FindPetsByStatusParams
- type FindPetsByStatusParamsStatus
- type FindPetsByStatusResponse
- type FindPetsByTagsParams
- type FindPetsByTagsResponse
- type GetOrderByIdResponse
- type GetPetByIdResponse
- type GetPetMetadataParams
- type GetPetMetadataResponse
- type GetPetPhotoByIdResponse
- type GetPetRegistrationResponse
- type GetStoreInventoryResponse
- type GetUserByNameResponse
- type HttpRequestDoer
- type LoginUserParams
- type LoginUserResponse
- type LogoutUserResponse
- type Order
- type OrderStatus
- type Pet
- type PetPhoto
- type PetStatus
- type PetWithCustomTypes
- type PostStoreOrderFormdataRequestBody
- type PostStoreOrderJSONRequestBody
- type PostStoreOrderResponse
- type RequestEditorFn
- type Tag
- type Timestamp
- type UUID
- type UpdatePetFormdataRequestBody
- type UpdatePetJSONRequestBody
- type UpdatePetResponse
- type UpdatePetWithFormParams
- type UpdatePetWithFormResponse
- type UpdateUserFormdataRequestBody
- type UpdateUserJSONRequestBody
- type UpdateUserResponse
- type UploadFileParams
- type UploadFileResponse
Constants ¶
const ( Api_keyScopes = "api_key.Scopes" Petstore_authScopes = "petstore_auth.Scopes" )
Variables ¶
This section is empty.
Functions ¶
func NewAddPetRequest ¶
func NewAddPetRequest(server string, body AddPetJSONRequestBody) (*http.Request, error)
NewAddPetRequest calls the generic AddPet builder with application/json body
func NewAddPetRequestWithBody ¶
func NewAddPetRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
NewAddPetRequestWithBody generates requests for AddPet with any type of body
func NewAddPetRequestWithFormdataBody ¶
func NewAddPetRequestWithFormdataBody(server string, body AddPetFormdataRequestBody) (*http.Request, error)
NewAddPetRequestWithFormdataBody calls the generic AddPet builder with application/x-www-form-urlencoded body
func NewCreateUserRequest ¶
func NewCreateUserRequest(server string, body CreateUserJSONRequestBody) (*http.Request, error)
NewCreateUserRequest calls the generic CreateUser builder with application/json body
func NewCreateUserRequestWithBody ¶
func NewCreateUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
NewCreateUserRequestWithBody generates requests for CreateUser with any type of body
func NewCreateUserRequestWithFormdataBody ¶
func NewCreateUserRequestWithFormdataBody(server string, body CreateUserFormdataRequestBody) (*http.Request, error)
NewCreateUserRequestWithFormdataBody calls the generic CreateUser builder with application/x-www-form-urlencoded body
func NewCreateUsersWithListInputRequest ¶
func NewCreateUsersWithListInputRequest(server string, body CreateUsersWithListInputJSONRequestBody) (*http.Request, error)
NewCreateUsersWithListInputRequest calls the generic CreateUsersWithListInput builder with application/json body
func NewCreateUsersWithListInputRequestWithBody ¶
func NewCreateUsersWithListInputRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
NewCreateUsersWithListInputRequestWithBody generates requests for CreateUsersWithListInput with any type of body
func NewDeleteOrderRequest ¶
NewDeleteOrderRequest generates requests for DeleteOrder
func NewDeletePetRequest ¶
func NewDeletePetRequest(server string, petId int64, params *DeletePetParams) (*http.Request, error)
NewDeletePetRequest generates requests for DeletePet
func NewDeleteUserRequest ¶
NewDeleteUserRequest generates requests for DeleteUser
func NewFindPetsByStatusRequest ¶
func NewFindPetsByStatusRequest(server string, params *FindPetsByStatusParams) (*http.Request, error)
NewFindPetsByStatusRequest generates requests for FindPetsByStatus
func NewFindPetsByTagsRequest ¶
func NewFindPetsByTagsRequest(server string, params *FindPetsByTagsParams) (*http.Request, error)
NewFindPetsByTagsRequest generates requests for FindPetsByTags
func NewGetOrderByIdRequest ¶
NewGetOrderByIdRequest generates requests for GetOrderById
func NewGetPetByIdRequest ¶
NewGetPetByIdRequest generates requests for GetPetById
func NewGetPetMetadataRequest ¶
func NewGetPetMetadataRequest(server string, petId int64, params *GetPetMetadataParams) (*http.Request, error)
NewGetPetMetadataRequest generates requests for GetPetMetadata
func NewGetPetPhotoByIdRequest ¶
NewGetPetPhotoByIdRequest generates requests for GetPetPhotoById
func NewGetPetRegistrationRequest ¶
NewGetPetRegistrationRequest generates requests for GetPetRegistration
func NewGetStoreInventoryRequest ¶
NewGetStoreInventoryRequest generates requests for GetStoreInventory
func NewGetUserByNameRequest ¶
NewGetUserByNameRequest generates requests for GetUserByName
func NewLoginUserRequest ¶
func NewLoginUserRequest(server string, params *LoginUserParams) (*http.Request, error)
NewLoginUserRequest generates requests for LoginUser
func NewLogoutUserRequest ¶
NewLogoutUserRequest generates requests for LogoutUser
func NewPostStoreOrderRequest ¶
func NewPostStoreOrderRequest(server string, body PostStoreOrderJSONRequestBody) (*http.Request, error)
NewPostStoreOrderRequest calls the generic PostStoreOrder builder with application/json body
func NewPostStoreOrderRequestWithBody ¶
func NewPostStoreOrderRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
NewPostStoreOrderRequestWithBody generates requests for PostStoreOrder with any type of body
func NewPostStoreOrderRequestWithFormdataBody ¶
func NewPostStoreOrderRequestWithFormdataBody(server string, body PostStoreOrderFormdataRequestBody) (*http.Request, error)
NewPostStoreOrderRequestWithFormdataBody calls the generic PostStoreOrder builder with application/x-www-form-urlencoded body
func NewUpdatePetRequest ¶
func NewUpdatePetRequest(server string, body UpdatePetJSONRequestBody) (*http.Request, error)
NewUpdatePetRequest calls the generic UpdatePet builder with application/json body
func NewUpdatePetRequestWithBody ¶
func NewUpdatePetRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
NewUpdatePetRequestWithBody generates requests for UpdatePet with any type of body
func NewUpdatePetRequestWithFormdataBody ¶
func NewUpdatePetRequestWithFormdataBody(server string, body UpdatePetFormdataRequestBody) (*http.Request, error)
NewUpdatePetRequestWithFormdataBody calls the generic UpdatePet builder with application/x-www-form-urlencoded body
func NewUpdatePetWithFormRequest ¶
func NewUpdatePetWithFormRequest(server string, petId int64, params *UpdatePetWithFormParams) (*http.Request, error)
NewUpdatePetWithFormRequest generates requests for UpdatePetWithForm
func NewUpdateUserRequest ¶
func NewUpdateUserRequest(server string, username string, body UpdateUserJSONRequestBody) (*http.Request, error)
NewUpdateUserRequest calls the generic UpdateUser builder with application/json body
func NewUpdateUserRequestWithBody ¶
func NewUpdateUserRequestWithBody(server string, username string, contentType string, body io.Reader) (*http.Request, error)
NewUpdateUserRequestWithBody generates requests for UpdateUser with any type of body
func NewUpdateUserRequestWithFormdataBody ¶
func NewUpdateUserRequestWithFormdataBody(server string, username string, body UpdateUserFormdataRequestBody) (*http.Request, error)
NewUpdateUserRequestWithFormdataBody calls the generic UpdateUser builder with application/x-www-form-urlencoded body
Types ¶
type AddPetFormdataRequestBody ¶
type AddPetFormdataRequestBody = Pet
AddPetFormdataRequestBody defines body for AddPet for application/x-www-form-urlencoded ContentType.
type AddPetJSONRequestBody ¶
type AddPetJSONRequestBody = Pet
AddPetJSONRequestBody defines body for AddPet for application/json ContentType.
type AddPetResponse ¶
func ParseAddPetResponse ¶
func ParseAddPetResponse(rsp *http.Response) (*AddPetResponse, error)
ParseAddPetResponse parses an HTTP response from a AddPetWithResponse call
func (AddPetResponse) Status ¶
func (r AddPetResponse) Status() string
Status returns HTTPResponse.Status
func (AddPetResponse) StatusCode ¶
func (r AddPetResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type ApiResponse ¶
type ApiResponse struct {
Code *int32 `json:"code,omitempty"`
Message *string `json:"message,omitempty"`
Type *string `json:"type,omitempty"`
}
ApiResponse defines model for ApiResponse.
type BasePhoto ¶
type BasePhoto struct {
CreatedAt *time.Time `json:"createdAt,omitempty"`
Id *int64 `json:"id,omitempty"`
Url *string `json:"url,omitempty"`
}
BasePhoto Base schema for photos (tests allOf composition)
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) AddPet ¶
func (c *Client) AddPet(ctx context.Context, body AddPetJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) AddPetWithBody ¶
func (*Client) AddPetWithFormdataBody ¶
func (c *Client) AddPetWithFormdataBody(ctx context.Context, body AddPetFormdataRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) CreateUser ¶
func (c *Client) CreateUser(ctx context.Context, body CreateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) CreateUserWithBody ¶
func (*Client) CreateUserWithFormdataBody ¶
func (c *Client) CreateUserWithFormdataBody(ctx context.Context, body CreateUserFormdataRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) CreateUsersWithListInput ¶
func (c *Client) CreateUsersWithListInput(ctx context.Context, body CreateUsersWithListInputJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) CreateUsersWithListInputWithBody ¶
func (*Client) DeleteOrder ¶
func (*Client) DeletePet ¶
func (c *Client) DeletePet(ctx context.Context, petId int64, params *DeletePetParams, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) DeleteUser ¶
func (*Client) FindPetsByStatus ¶
func (c *Client) FindPetsByStatus(ctx context.Context, params *FindPetsByStatusParams, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) FindPetsByTags ¶
func (c *Client) FindPetsByTags(ctx context.Context, params *FindPetsByTagsParams, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) GetOrderById ¶
func (*Client) GetPetById ¶
func (*Client) GetPetMetadata ¶
func (c *Client) GetPetMetadata(ctx context.Context, petId int64, params *GetPetMetadataParams, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) GetPetPhotoById ¶
func (*Client) GetPetRegistration ¶
func (*Client) GetStoreInventory ¶
func (*Client) GetUserByName ¶
func (*Client) LoginUser ¶
func (c *Client) LoginUser(ctx context.Context, params *LoginUserParams, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) LogoutUser ¶
func (*Client) PostStoreOrder ¶
func (c *Client) PostStoreOrder(ctx context.Context, body PostStoreOrderJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) PostStoreOrderWithBody ¶
func (*Client) PostStoreOrderWithFormdataBody ¶
func (c *Client) PostStoreOrderWithFormdataBody(ctx context.Context, body PostStoreOrderFormdataRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) UpdatePet ¶
func (c *Client) UpdatePet(ctx context.Context, body UpdatePetJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) UpdatePetWithBody ¶
func (*Client) UpdatePetWithForm ¶
func (c *Client) UpdatePetWithForm(ctx context.Context, petId int64, params *UpdatePetWithFormParams, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) UpdatePetWithFormdataBody ¶
func (c *Client) UpdatePetWithFormdataBody(ctx context.Context, body UpdatePetFormdataRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) UpdateUser ¶
func (c *Client) UpdateUser(ctx context.Context, username string, body UpdateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) UpdateUserWithBody ¶
func (*Client) UpdateUserWithFormdataBody ¶
func (c *Client) UpdateUserWithFormdataBody(ctx context.Context, username string, body UpdateUserFormdataRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) UploadFileWithBody ¶
type ClientInterface ¶
type ClientInterface interface {
// AddPetWithBody request with any body
AddPetWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
AddPet(ctx context.Context, body AddPetJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
AddPetWithFormdataBody(ctx context.Context, body AddPetFormdataRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
// UpdatePetWithBody request with any body
UpdatePetWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
UpdatePet(ctx context.Context, body UpdatePetJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
UpdatePetWithFormdataBody(ctx context.Context, body UpdatePetFormdataRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
// FindPetsByStatus request
FindPetsByStatus(ctx context.Context, params *FindPetsByStatusParams, reqEditors ...RequestEditorFn) (*http.Response, error)
// FindPetsByTags request
FindPetsByTags(ctx context.Context, params *FindPetsByTagsParams, reqEditors ...RequestEditorFn) (*http.Response, error)
// DeletePet request
DeletePet(ctx context.Context, petId int64, params *DeletePetParams, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetPetById request
GetPetById(ctx context.Context, petId int64, reqEditors ...RequestEditorFn) (*http.Response, error)
// UpdatePetWithForm request
UpdatePetWithForm(ctx context.Context, petId int64, params *UpdatePetWithFormParams, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetPetMetadata request
GetPetMetadata(ctx context.Context, petId int64, params *GetPetMetadataParams, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetPetPhotoById request
GetPetPhotoById(ctx context.Context, petId int64, photoId int64, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetPetRegistration request
GetPetRegistration(ctx context.Context, petId int64, reqEditors ...RequestEditorFn) (*http.Response, error)
// UploadFileWithBody request with any body
UploadFileWithBody(ctx context.Context, petId int64, params *UploadFileParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetStoreInventory request
GetStoreInventory(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
// PostStoreOrderWithBody request with any body
PostStoreOrderWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
PostStoreOrder(ctx context.Context, body PostStoreOrderJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
PostStoreOrderWithFormdataBody(ctx context.Context, body PostStoreOrderFormdataRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
// DeleteOrder request
DeleteOrder(ctx context.Context, orderId int64, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetOrderById request
GetOrderById(ctx context.Context, orderId int64, reqEditors ...RequestEditorFn) (*http.Response, error)
// CreateUserWithBody request with any body
CreateUserWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
CreateUser(ctx context.Context, body CreateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
CreateUserWithFormdataBody(ctx context.Context, body CreateUserFormdataRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
// CreateUsersWithListInputWithBody request with any body
CreateUsersWithListInputWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
CreateUsersWithListInput(ctx context.Context, body CreateUsersWithListInputJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
// LoginUser request
LoginUser(ctx context.Context, params *LoginUserParams, reqEditors ...RequestEditorFn) (*http.Response, error)
// LogoutUser request
LogoutUser(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
// DeleteUser request
DeleteUser(ctx context.Context, username string, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetUserByName request
GetUserByName(ctx context.Context, username string, reqEditors ...RequestEditorFn) (*http.Response, error)
// UpdateUserWithBody request with any body
UpdateUserWithBody(ctx context.Context, username string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
UpdateUser(ctx context.Context, username string, body UpdateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
UpdateUserWithFormdataBody(ctx context.Context, username string, body UpdateUserFormdataRequestBody, 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) AddPetWithBodyWithResponse ¶
func (c *ClientWithResponses) AddPetWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AddPetResponse, error)
AddPetWithBodyWithResponse request with arbitrary body returning *AddPetResponse
func (*ClientWithResponses) AddPetWithFormdataBodyWithResponse ¶
func (c *ClientWithResponses) AddPetWithFormdataBodyWithResponse(ctx context.Context, body AddPetFormdataRequestBody, reqEditors ...RequestEditorFn) (*AddPetResponse, error)
func (*ClientWithResponses) AddPetWithResponse ¶
func (c *ClientWithResponses) AddPetWithResponse(ctx context.Context, body AddPetJSONRequestBody, reqEditors ...RequestEditorFn) (*AddPetResponse, error)
func (*ClientWithResponses) CreateUserWithBodyWithResponse ¶
func (c *ClientWithResponses) CreateUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateUserResponse, error)
CreateUserWithBodyWithResponse request with arbitrary body returning *CreateUserResponse
func (*ClientWithResponses) CreateUserWithFormdataBodyWithResponse ¶
func (c *ClientWithResponses) CreateUserWithFormdataBodyWithResponse(ctx context.Context, body CreateUserFormdataRequestBody, reqEditors ...RequestEditorFn) (*CreateUserResponse, error)
func (*ClientWithResponses) CreateUserWithResponse ¶
func (c *ClientWithResponses) CreateUserWithResponse(ctx context.Context, body CreateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateUserResponse, error)
func (*ClientWithResponses) CreateUsersWithListInputWithBodyWithResponse ¶
func (c *ClientWithResponses) CreateUsersWithListInputWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateUsersWithListInputResponse, error)
CreateUsersWithListInputWithBodyWithResponse request with arbitrary body returning *CreateUsersWithListInputResponse
func (*ClientWithResponses) CreateUsersWithListInputWithResponse ¶
func (c *ClientWithResponses) CreateUsersWithListInputWithResponse(ctx context.Context, body CreateUsersWithListInputJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateUsersWithListInputResponse, error)
func (*ClientWithResponses) DeleteOrderWithResponse ¶
func (c *ClientWithResponses) DeleteOrderWithResponse(ctx context.Context, orderId int64, reqEditors ...RequestEditorFn) (*DeleteOrderResponse, error)
DeleteOrderWithResponse request returning *DeleteOrderResponse
func (*ClientWithResponses) DeletePetWithResponse ¶
func (c *ClientWithResponses) DeletePetWithResponse(ctx context.Context, petId int64, params *DeletePetParams, reqEditors ...RequestEditorFn) (*DeletePetResponse, error)
DeletePetWithResponse request returning *DeletePetResponse
func (*ClientWithResponses) DeleteUserWithResponse ¶
func (c *ClientWithResponses) DeleteUserWithResponse(ctx context.Context, username string, reqEditors ...RequestEditorFn) (*DeleteUserResponse, error)
DeleteUserWithResponse request returning *DeleteUserResponse
func (*ClientWithResponses) FindPetsByStatusWithResponse ¶
func (c *ClientWithResponses) FindPetsByStatusWithResponse(ctx context.Context, params *FindPetsByStatusParams, reqEditors ...RequestEditorFn) (*FindPetsByStatusResponse, error)
FindPetsByStatusWithResponse request returning *FindPetsByStatusResponse
func (*ClientWithResponses) FindPetsByTagsWithResponse ¶
func (c *ClientWithResponses) FindPetsByTagsWithResponse(ctx context.Context, params *FindPetsByTagsParams, reqEditors ...RequestEditorFn) (*FindPetsByTagsResponse, error)
FindPetsByTagsWithResponse request returning *FindPetsByTagsResponse
func (*ClientWithResponses) GetOrderByIdWithResponse ¶
func (c *ClientWithResponses) GetOrderByIdWithResponse(ctx context.Context, orderId int64, reqEditors ...RequestEditorFn) (*GetOrderByIdResponse, error)
GetOrderByIdWithResponse request returning *GetOrderByIdResponse
func (*ClientWithResponses) GetPetByIdWithResponse ¶
func (c *ClientWithResponses) GetPetByIdWithResponse(ctx context.Context, petId int64, reqEditors ...RequestEditorFn) (*GetPetByIdResponse, error)
GetPetByIdWithResponse request returning *GetPetByIdResponse
func (*ClientWithResponses) GetPetMetadataWithResponse ¶
func (c *ClientWithResponses) GetPetMetadataWithResponse(ctx context.Context, petId int64, params *GetPetMetadataParams, reqEditors ...RequestEditorFn) (*GetPetMetadataResponse, error)
GetPetMetadataWithResponse request returning *GetPetMetadataResponse
func (*ClientWithResponses) GetPetPhotoByIdWithResponse ¶
func (c *ClientWithResponses) GetPetPhotoByIdWithResponse(ctx context.Context, petId int64, photoId int64, reqEditors ...RequestEditorFn) (*GetPetPhotoByIdResponse, error)
GetPetPhotoByIdWithResponse request returning *GetPetPhotoByIdResponse
func (*ClientWithResponses) GetPetRegistrationWithResponse ¶
func (c *ClientWithResponses) GetPetRegistrationWithResponse(ctx context.Context, petId int64, reqEditors ...RequestEditorFn) (*GetPetRegistrationResponse, error)
GetPetRegistrationWithResponse request returning *GetPetRegistrationResponse
func (*ClientWithResponses) GetStoreInventoryWithResponse ¶
func (c *ClientWithResponses) GetStoreInventoryWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetStoreInventoryResponse, error)
GetStoreInventoryWithResponse request returning *GetStoreInventoryResponse
func (*ClientWithResponses) GetUserByNameWithResponse ¶
func (c *ClientWithResponses) GetUserByNameWithResponse(ctx context.Context, username string, reqEditors ...RequestEditorFn) (*GetUserByNameResponse, error)
GetUserByNameWithResponse request returning *GetUserByNameResponse
func (*ClientWithResponses) LoginUserWithResponse ¶
func (c *ClientWithResponses) LoginUserWithResponse(ctx context.Context, params *LoginUserParams, reqEditors ...RequestEditorFn) (*LoginUserResponse, error)
LoginUserWithResponse request returning *LoginUserResponse
func (*ClientWithResponses) LogoutUserWithResponse ¶
func (c *ClientWithResponses) LogoutUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*LogoutUserResponse, error)
LogoutUserWithResponse request returning *LogoutUserResponse
func (*ClientWithResponses) PostStoreOrderWithBodyWithResponse ¶
func (c *ClientWithResponses) PostStoreOrderWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostStoreOrderResponse, error)
PostStoreOrderWithBodyWithResponse request with arbitrary body returning *PostStoreOrderResponse
func (*ClientWithResponses) PostStoreOrderWithFormdataBodyWithResponse ¶
func (c *ClientWithResponses) PostStoreOrderWithFormdataBodyWithResponse(ctx context.Context, body PostStoreOrderFormdataRequestBody, reqEditors ...RequestEditorFn) (*PostStoreOrderResponse, error)
func (*ClientWithResponses) PostStoreOrderWithResponse ¶
func (c *ClientWithResponses) PostStoreOrderWithResponse(ctx context.Context, body PostStoreOrderJSONRequestBody, reqEditors ...RequestEditorFn) (*PostStoreOrderResponse, error)
func (*ClientWithResponses) UpdatePetWithBodyWithResponse ¶
func (c *ClientWithResponses) UpdatePetWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePetResponse, error)
UpdatePetWithBodyWithResponse request with arbitrary body returning *UpdatePetResponse
func (*ClientWithResponses) UpdatePetWithFormWithResponse ¶
func (c *ClientWithResponses) UpdatePetWithFormWithResponse(ctx context.Context, petId int64, params *UpdatePetWithFormParams, reqEditors ...RequestEditorFn) (*UpdatePetWithFormResponse, error)
UpdatePetWithFormWithResponse request returning *UpdatePetWithFormResponse
func (*ClientWithResponses) UpdatePetWithFormdataBodyWithResponse ¶
func (c *ClientWithResponses) UpdatePetWithFormdataBodyWithResponse(ctx context.Context, body UpdatePetFormdataRequestBody, reqEditors ...RequestEditorFn) (*UpdatePetResponse, error)
func (*ClientWithResponses) UpdatePetWithResponse ¶
func (c *ClientWithResponses) UpdatePetWithResponse(ctx context.Context, body UpdatePetJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePetResponse, error)
func (*ClientWithResponses) UpdateUserWithBodyWithResponse ¶
func (c *ClientWithResponses) UpdateUserWithBodyWithResponse(ctx context.Context, username string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error)
UpdateUserWithBodyWithResponse request with arbitrary body returning *UpdateUserResponse
func (*ClientWithResponses) UpdateUserWithFormdataBodyWithResponse ¶
func (c *ClientWithResponses) UpdateUserWithFormdataBodyWithResponse(ctx context.Context, username string, body UpdateUserFormdataRequestBody, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error)
func (*ClientWithResponses) UpdateUserWithResponse ¶
func (c *ClientWithResponses) UpdateUserWithResponse(ctx context.Context, username string, body UpdateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error)
func (*ClientWithResponses) UploadFileWithBodyWithResponse ¶
func (c *ClientWithResponses) UploadFileWithBodyWithResponse(ctx context.Context, petId int64, params *UploadFileParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UploadFileResponse, error)
UploadFileWithBodyWithResponse request with arbitrary body returning *UploadFileResponse
type ClientWithResponsesInterface ¶
type ClientWithResponsesInterface interface {
// AddPetWithBodyWithResponse request with any body
AddPetWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AddPetResponse, error)
AddPetWithResponse(ctx context.Context, body AddPetJSONRequestBody, reqEditors ...RequestEditorFn) (*AddPetResponse, error)
AddPetWithFormdataBodyWithResponse(ctx context.Context, body AddPetFormdataRequestBody, reqEditors ...RequestEditorFn) (*AddPetResponse, error)
// UpdatePetWithBodyWithResponse request with any body
UpdatePetWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePetResponse, error)
UpdatePetWithResponse(ctx context.Context, body UpdatePetJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePetResponse, error)
UpdatePetWithFormdataBodyWithResponse(ctx context.Context, body UpdatePetFormdataRequestBody, reqEditors ...RequestEditorFn) (*UpdatePetResponse, error)
// FindPetsByStatusWithResponse request
FindPetsByStatusWithResponse(ctx context.Context, params *FindPetsByStatusParams, reqEditors ...RequestEditorFn) (*FindPetsByStatusResponse, error)
// FindPetsByTagsWithResponse request
FindPetsByTagsWithResponse(ctx context.Context, params *FindPetsByTagsParams, reqEditors ...RequestEditorFn) (*FindPetsByTagsResponse, error)
// DeletePetWithResponse request
DeletePetWithResponse(ctx context.Context, petId int64, params *DeletePetParams, reqEditors ...RequestEditorFn) (*DeletePetResponse, error)
// GetPetByIdWithResponse request
GetPetByIdWithResponse(ctx context.Context, petId int64, reqEditors ...RequestEditorFn) (*GetPetByIdResponse, error)
// UpdatePetWithFormWithResponse request
UpdatePetWithFormWithResponse(ctx context.Context, petId int64, params *UpdatePetWithFormParams, reqEditors ...RequestEditorFn) (*UpdatePetWithFormResponse, error)
// GetPetMetadataWithResponse request
GetPetMetadataWithResponse(ctx context.Context, petId int64, params *GetPetMetadataParams, reqEditors ...RequestEditorFn) (*GetPetMetadataResponse, error)
// GetPetPhotoByIdWithResponse request
GetPetPhotoByIdWithResponse(ctx context.Context, petId int64, photoId int64, reqEditors ...RequestEditorFn) (*GetPetPhotoByIdResponse, error)
// GetPetRegistrationWithResponse request
GetPetRegistrationWithResponse(ctx context.Context, petId int64, reqEditors ...RequestEditorFn) (*GetPetRegistrationResponse, error)
// UploadFileWithBodyWithResponse request with any body
UploadFileWithBodyWithResponse(ctx context.Context, petId int64, params *UploadFileParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UploadFileResponse, error)
// GetStoreInventoryWithResponse request
GetStoreInventoryWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetStoreInventoryResponse, error)
// PostStoreOrderWithBodyWithResponse request with any body
PostStoreOrderWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostStoreOrderResponse, error)
PostStoreOrderWithResponse(ctx context.Context, body PostStoreOrderJSONRequestBody, reqEditors ...RequestEditorFn) (*PostStoreOrderResponse, error)
PostStoreOrderWithFormdataBodyWithResponse(ctx context.Context, body PostStoreOrderFormdataRequestBody, reqEditors ...RequestEditorFn) (*PostStoreOrderResponse, error)
// DeleteOrderWithResponse request
DeleteOrderWithResponse(ctx context.Context, orderId int64, reqEditors ...RequestEditorFn) (*DeleteOrderResponse, error)
// GetOrderByIdWithResponse request
GetOrderByIdWithResponse(ctx context.Context, orderId int64, reqEditors ...RequestEditorFn) (*GetOrderByIdResponse, error)
// CreateUserWithBodyWithResponse request with any body
CreateUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateUserResponse, error)
CreateUserWithResponse(ctx context.Context, body CreateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateUserResponse, error)
CreateUserWithFormdataBodyWithResponse(ctx context.Context, body CreateUserFormdataRequestBody, reqEditors ...RequestEditorFn) (*CreateUserResponse, error)
// CreateUsersWithListInputWithBodyWithResponse request with any body
CreateUsersWithListInputWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateUsersWithListInputResponse, error)
CreateUsersWithListInputWithResponse(ctx context.Context, body CreateUsersWithListInputJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateUsersWithListInputResponse, error)
// LoginUserWithResponse request
LoginUserWithResponse(ctx context.Context, params *LoginUserParams, reqEditors ...RequestEditorFn) (*LoginUserResponse, error)
// LogoutUserWithResponse request
LogoutUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*LogoutUserResponse, error)
// DeleteUserWithResponse request
DeleteUserWithResponse(ctx context.Context, username string, reqEditors ...RequestEditorFn) (*DeleteUserResponse, error)
// GetUserByNameWithResponse request
GetUserByNameWithResponse(ctx context.Context, username string, reqEditors ...RequestEditorFn) (*GetUserByNameResponse, error)
// UpdateUserWithBodyWithResponse request with any body
UpdateUserWithBodyWithResponse(ctx context.Context, username string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error)
UpdateUserWithResponse(ctx context.Context, username string, body UpdateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error)
UpdateUserWithFormdataBodyWithResponse(ctx context.Context, username string, body UpdateUserFormdataRequestBody, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error)
}
ClientWithResponsesInterface is the interface specification for the client with responses above.
type CreateUserFormdataRequestBody ¶
type CreateUserFormdataRequestBody = externalRef0.User
CreateUserFormdataRequestBody defines body for CreateUser for application/x-www-form-urlencoded ContentType.
type CreateUserJSONRequestBody ¶
type CreateUserJSONRequestBody = externalRef0.User
CreateUserJSONRequestBody defines body for CreateUser for application/json ContentType.
type CreateUserResponse ¶
type CreateUserResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *externalRef0.User
XML200 *externalRef0.User
}
func ParseCreateUserResponse ¶
func ParseCreateUserResponse(rsp *http.Response) (*CreateUserResponse, error)
ParseCreateUserResponse parses an HTTP response from a CreateUserWithResponse call
func (CreateUserResponse) Status ¶
func (r CreateUserResponse) Status() string
Status returns HTTPResponse.Status
func (CreateUserResponse) StatusCode ¶
func (r CreateUserResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type CreateUsersWithListInputJSONBody ¶
type CreateUsersWithListInputJSONBody = []externalRef0.User
CreateUsersWithListInputJSONBody defines parameters for CreateUsersWithListInput.
type CreateUsersWithListInputJSONRequestBody ¶
type CreateUsersWithListInputJSONRequestBody = CreateUsersWithListInputJSONBody
CreateUsersWithListInputJSONRequestBody defines body for CreateUsersWithListInput for application/json ContentType.
type CreateUsersWithListInputResponse ¶
type CreateUsersWithListInputResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *externalRef0.User
XML200 *externalRef0.User
}
func ParseCreateUsersWithListInputResponse ¶
func ParseCreateUsersWithListInputResponse(rsp *http.Response) (*CreateUsersWithListInputResponse, error)
ParseCreateUsersWithListInputResponse parses an HTTP response from a CreateUsersWithListInputWithResponse call
func (CreateUsersWithListInputResponse) Status ¶
func (r CreateUsersWithListInputResponse) Status() string
Status returns HTTPResponse.Status
func (CreateUsersWithListInputResponse) StatusCode ¶
func (r CreateUsersWithListInputResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type DeleteOrderResponse ¶
func ParseDeleteOrderResponse ¶
func ParseDeleteOrderResponse(rsp *http.Response) (*DeleteOrderResponse, error)
ParseDeleteOrderResponse parses an HTTP response from a DeleteOrderWithResponse call
func (DeleteOrderResponse) Status ¶
func (r DeleteOrderResponse) Status() string
Status returns HTTPResponse.Status
func (DeleteOrderResponse) StatusCode ¶
func (r DeleteOrderResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type DeletePetParams ¶
type DeletePetParams struct {
ApiKey *string `json:"api_key,omitempty"`
}
DeletePetParams defines parameters for DeletePet.
type DeletePetResponse ¶
type DeletePetResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *struct {
Message *string `json:"message,omitempty"`
}
JSON400 *struct {
Error *string `json:"error,omitempty"`
}
JSON404 *struct {
Error *string `json:"error,omitempty"`
}
}
func ParseDeletePetResponse ¶
func ParseDeletePetResponse(rsp *http.Response) (*DeletePetResponse, error)
ParseDeletePetResponse parses an HTTP response from a DeletePetWithResponse call
func (DeletePetResponse) Status ¶
func (r DeletePetResponse) Status() string
Status returns HTTPResponse.Status
func (DeletePetResponse) StatusCode ¶
func (r DeletePetResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
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 Error ¶
type Error struct {
// Message Message is a human-readable description of the error.
Message *string `json:"message,omitempty"`
}
Error defines model for error.
type FindPetsByStatusParams ¶
type FindPetsByStatusParams struct {
// Status Status values that need to be considered for filter
Status FindPetsByStatusParamsStatus `form:"status" json:"status"`
}
FindPetsByStatusParams defines parameters for FindPetsByStatus.
type FindPetsByStatusParamsStatus ¶
type FindPetsByStatusParamsStatus string
FindPetsByStatusParamsStatus defines parameters for FindPetsByStatus.
const ( FindPetsByStatusParamsStatusAvailable FindPetsByStatusParamsStatus = "available" FindPetsByStatusParamsStatusPending FindPetsByStatusParamsStatus = "pending" FindPetsByStatusParamsStatusSold FindPetsByStatusParamsStatus = "sold" )
Defines values for FindPetsByStatusParamsStatus.
type FindPetsByStatusResponse ¶
type FindPetsByStatusResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *[]Pet
XML200 *[]Pet
}
func ParseFindPetsByStatusResponse ¶
func ParseFindPetsByStatusResponse(rsp *http.Response) (*FindPetsByStatusResponse, error)
ParseFindPetsByStatusResponse parses an HTTP response from a FindPetsByStatusWithResponse call
func (FindPetsByStatusResponse) Status ¶
func (r FindPetsByStatusResponse) Status() string
Status returns HTTPResponse.Status
func (FindPetsByStatusResponse) StatusCode ¶
func (r FindPetsByStatusResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type FindPetsByTagsParams ¶
type FindPetsByTagsParams struct {
// Tags Tags to filter by
Tags []string `form:"tags" json:"tags"`
}
FindPetsByTagsParams defines parameters for FindPetsByTags.
type FindPetsByTagsResponse ¶
type FindPetsByTagsResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *[]Pet
XML200 *[]Pet
}
func ParseFindPetsByTagsResponse ¶
func ParseFindPetsByTagsResponse(rsp *http.Response) (*FindPetsByTagsResponse, error)
ParseFindPetsByTagsResponse parses an HTTP response from a FindPetsByTagsWithResponse call
func (FindPetsByTagsResponse) Status ¶
func (r FindPetsByTagsResponse) Status() string
Status returns HTTPResponse.Status
func (FindPetsByTagsResponse) StatusCode ¶
func (r FindPetsByTagsResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetOrderByIdResponse ¶
type GetOrderByIdResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *Order
XML200 *Order
}
func ParseGetOrderByIdResponse ¶
func ParseGetOrderByIdResponse(rsp *http.Response) (*GetOrderByIdResponse, error)
ParseGetOrderByIdResponse parses an HTTP response from a GetOrderByIdWithResponse call
func (GetOrderByIdResponse) Status ¶
func (r GetOrderByIdResponse) Status() string
Status returns HTTPResponse.Status
func (GetOrderByIdResponse) StatusCode ¶
func (r GetOrderByIdResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetPetByIdResponse ¶
type GetPetByIdResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *Pet
ApplicationvndPetstoreJSON200 *Pet
XML200 *Pet
JSON400 *Error
XML400 *Error
JSON404 *Error
XML404 *Error
}
func ParseGetPetByIdResponse ¶
func ParseGetPetByIdResponse(rsp *http.Response) (*GetPetByIdResponse, error)
ParseGetPetByIdResponse parses an HTTP response from a GetPetByIdWithResponse call
func (GetPetByIdResponse) Status ¶
func (r GetPetByIdResponse) Status() string
Status returns HTTPResponse.Status
func (GetPetByIdResponse) StatusCode ¶
func (r GetPetByIdResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetPetMetadataParams ¶
type GetPetMetadataParams struct {
// IncludeHistory Include historical metadata
IncludeHistory *bool `form:"includeHistory,omitempty" json:"includeHistory,omitempty"`
}
GetPetMetadataParams defines parameters for GetPetMetadata.
type GetPetMetadataResponse ¶
type GetPetMetadataResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *map[string]string
JSON404 *Error
XML404 *Error
}
func ParseGetPetMetadataResponse ¶
func ParseGetPetMetadataResponse(rsp *http.Response) (*GetPetMetadataResponse, error)
ParseGetPetMetadataResponse parses an HTTP response from a GetPetMetadataWithResponse call
func (GetPetMetadataResponse) Status ¶
func (r GetPetMetadataResponse) Status() string
Status returns HTTPResponse.Status
func (GetPetMetadataResponse) StatusCode ¶
func (r GetPetMetadataResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetPetPhotoByIdResponse ¶
type GetPetPhotoByIdResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *PetPhoto
JSON404 *Error
XML404 *Error
}
func ParseGetPetPhotoByIdResponse ¶
func ParseGetPetPhotoByIdResponse(rsp *http.Response) (*GetPetPhotoByIdResponse, error)
ParseGetPetPhotoByIdResponse parses an HTTP response from a GetPetPhotoByIdWithResponse call
func (GetPetPhotoByIdResponse) Status ¶
func (r GetPetPhotoByIdResponse) Status() string
Status returns HTTPResponse.Status
func (GetPetPhotoByIdResponse) StatusCode ¶
func (r GetPetPhotoByIdResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetPetRegistrationResponse ¶
type GetPetRegistrationResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *PetWithCustomTypes
JSON404 *Error
}
func ParseGetPetRegistrationResponse ¶
func ParseGetPetRegistrationResponse(rsp *http.Response) (*GetPetRegistrationResponse, error)
ParseGetPetRegistrationResponse parses an HTTP response from a GetPetRegistrationWithResponse call
func (GetPetRegistrationResponse) Status ¶
func (r GetPetRegistrationResponse) Status() string
Status returns HTTPResponse.Status
func (GetPetRegistrationResponse) StatusCode ¶
func (r GetPetRegistrationResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetStoreInventoryResponse ¶
type GetStoreInventoryResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *map[string]int32
}
func ParseGetStoreInventoryResponse ¶
func ParseGetStoreInventoryResponse(rsp *http.Response) (*GetStoreInventoryResponse, error)
ParseGetStoreInventoryResponse parses an HTTP response from a GetStoreInventoryWithResponse call
func (GetStoreInventoryResponse) Status ¶
func (r GetStoreInventoryResponse) Status() string
Status returns HTTPResponse.Status
func (GetStoreInventoryResponse) StatusCode ¶
func (r GetStoreInventoryResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetUserByNameResponse ¶
type GetUserByNameResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *externalRef0.User
XML200 *externalRef0.User
}
func ParseGetUserByNameResponse ¶
func ParseGetUserByNameResponse(rsp *http.Response) (*GetUserByNameResponse, error)
ParseGetUserByNameResponse parses an HTTP response from a GetUserByNameWithResponse call
func (GetUserByNameResponse) Status ¶
func (r GetUserByNameResponse) Status() string
Status returns HTTPResponse.Status
func (GetUserByNameResponse) StatusCode ¶
func (r GetUserByNameResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type HttpRequestDoer ¶
Doer performs HTTP requests.
The standard http.Client implements this interface.
type LoginUserParams ¶
type LoginUserParams struct {
// Username The user name for login
Username *string `form:"username,omitempty" json:"username,omitempty"`
// Password The password for login in clear text
Password *string `form:"password,omitempty" json:"password,omitempty"`
}
LoginUserParams defines parameters for LoginUser.
type LoginUserResponse ¶
type LoginUserResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *string
XML200 *string
}
func ParseLoginUserResponse ¶
func ParseLoginUserResponse(rsp *http.Response) (*LoginUserResponse, error)
ParseLoginUserResponse parses an HTTP response from a LoginUserWithResponse call
func (LoginUserResponse) Status ¶
func (r LoginUserResponse) Status() string
Status returns HTTPResponse.Status
func (LoginUserResponse) StatusCode ¶
func (r LoginUserResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type LogoutUserResponse ¶
func ParseLogoutUserResponse ¶
func ParseLogoutUserResponse(rsp *http.Response) (*LogoutUserResponse, error)
ParseLogoutUserResponse parses an HTTP response from a LogoutUserWithResponse call
func (LogoutUserResponse) Status ¶
func (r LogoutUserResponse) Status() string
Status returns HTTPResponse.Status
func (LogoutUserResponse) StatusCode ¶
func (r LogoutUserResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type Order ¶
type Order struct {
Complete *bool `json:"complete,omitempty"`
Id *int64 `json:"id,omitempty"`
PetId *int64 `json:"petId,omitempty"`
Quantity *int32 `json:"quantity,omitempty"`
ShipDate *time.Time `json:"shipDate,omitempty"`
// Status Order Status
Status *OrderStatus `json:"status,omitempty"`
}
Order defines model for Order.
type OrderStatus ¶
type OrderStatus string
OrderStatus Order Status
const ( OrderStatusApproved OrderStatus = "approved" OrderStatusDelivered OrderStatus = "delivered" OrderStatusPlaced OrderStatus = "placed" )
Defines values for OrderStatus.
type Pet ¶
type Pet struct {
Category *Category `json:"category,omitempty"`
Id *int32 `json:"id,omitempty"`
Name string `json:"name"`
PhotoUrls []string `json:"photoUrls"`
// Status pet status in the store
Status *PetStatus `json:"status,omitempty"`
Tags *[]Tag `json:"tags,omitempty"`
}
Pet defines model for Pet.
type PetPhoto ¶
type PetPhoto struct {
Caption *string `json:"caption,omitempty"`
CreatedAt *time.Time `json:"createdAt,omitempty"`
Id *int64 `json:"id,omitempty"`
// Metadata Tests additionalProperties with typed values
Metadata *map[string]string `json:"metadata,omitempty"`
PetId *int64 `json:"petId,omitempty"`
Tags *[]string `json:"tags,omitempty"`
Url *string `json:"url,omitempty"`
}
PetPhoto defines model for PetPhoto.
type PetWithCustomTypes ¶
type PetWithCustomTypes struct {
CreatedAt *Timestamp `json:"createdAt,omitempty"`
Id *int64 `json:"id,omitempty"`
Name *string `json:"name,omitempty"`
RegistrationId *UUID `json:"registrationId,omitempty"`
UpdatedAt *time.Time `json:"updatedAt,omitempty"`
}
PetWithCustomTypes defines model for PetWithCustomTypes.
type PostStoreOrderFormdataRequestBody ¶
type PostStoreOrderFormdataRequestBody = Order
PostStoreOrderFormdataRequestBody defines body for PostStoreOrder for application/x-www-form-urlencoded ContentType.
type PostStoreOrderJSONRequestBody ¶
type PostStoreOrderJSONRequestBody = Order
PostStoreOrderJSONRequestBody defines body for PostStoreOrder for application/json ContentType.
type PostStoreOrderResponse ¶
func ParsePostStoreOrderResponse ¶
func ParsePostStoreOrderResponse(rsp *http.Response) (*PostStoreOrderResponse, error)
ParsePostStoreOrderResponse parses an HTTP response from a PostStoreOrderWithResponse call
func (PostStoreOrderResponse) Status ¶
func (r PostStoreOrderResponse) Status() string
Status returns HTTPResponse.Status
func (PostStoreOrderResponse) StatusCode ¶
func (r PostStoreOrderResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type RequestEditorFn ¶
RequestEditorFn is the function signature for the RequestEditor callback function
type UpdatePetFormdataRequestBody ¶
type UpdatePetFormdataRequestBody = Pet
UpdatePetFormdataRequestBody defines body for UpdatePet for application/x-www-form-urlencoded ContentType.
type UpdatePetJSONRequestBody ¶
type UpdatePetJSONRequestBody = Pet
UpdatePetJSONRequestBody defines body for UpdatePet for application/json ContentType.
type UpdatePetResponse ¶
type UpdatePetResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *Pet
XML200 *Pet
JSON400 *Error
XML400 *Error
JSON404 *Error
XML404 *Error
JSON422 *Error
XML422 *Error
}
func ParseUpdatePetResponse ¶
func ParseUpdatePetResponse(rsp *http.Response) (*UpdatePetResponse, error)
ParseUpdatePetResponse parses an HTTP response from a UpdatePetWithResponse call
func (UpdatePetResponse) Status ¶
func (r UpdatePetResponse) Status() string
Status returns HTTPResponse.Status
func (UpdatePetResponse) StatusCode ¶
func (r UpdatePetResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type UpdatePetWithFormParams ¶
type UpdatePetWithFormParams struct {
// Name Name of pet that needs to be updated
Name *string `form:"name,omitempty" json:"name,omitempty"`
// Status Status of pet that needs to be updated
Status *string `form:"status,omitempty" json:"status,omitempty"`
}
UpdatePetWithFormParams defines parameters for UpdatePetWithForm.
type UpdatePetWithFormResponse ¶
type UpdatePetWithFormResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *Pet
XML200 *Pet
}
func ParseUpdatePetWithFormResponse ¶
func ParseUpdatePetWithFormResponse(rsp *http.Response) (*UpdatePetWithFormResponse, error)
ParseUpdatePetWithFormResponse parses an HTTP response from a UpdatePetWithFormWithResponse call
func (UpdatePetWithFormResponse) Status ¶
func (r UpdatePetWithFormResponse) Status() string
Status returns HTTPResponse.Status
func (UpdatePetWithFormResponse) StatusCode ¶
func (r UpdatePetWithFormResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type UpdateUserFormdataRequestBody ¶
type UpdateUserFormdataRequestBody = externalRef0.User
UpdateUserFormdataRequestBody defines body for UpdateUser for application/x-www-form-urlencoded ContentType.
type UpdateUserJSONRequestBody ¶
type UpdateUserJSONRequestBody = externalRef0.User
UpdateUserJSONRequestBody defines body for UpdateUser for application/json ContentType.
type UpdateUserResponse ¶
func ParseUpdateUserResponse ¶
func ParseUpdateUserResponse(rsp *http.Response) (*UpdateUserResponse, error)
ParseUpdateUserResponse parses an HTTP response from a UpdateUserWithResponse call
func (UpdateUserResponse) Status ¶
func (r UpdateUserResponse) Status() string
Status returns HTTPResponse.Status
func (UpdateUserResponse) StatusCode ¶
func (r UpdateUserResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type UploadFileParams ¶
type UploadFileParams struct {
// AdditionalMetadata Additional Metadata
AdditionalMetadata *string `form:"additionalMetadata,omitempty" json:"additionalMetadata,omitempty"`
}
UploadFileParams defines parameters for UploadFile.
type UploadFileResponse ¶
type UploadFileResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *ApiResponse
}
func ParseUploadFileResponse ¶
func ParseUploadFileResponse(rsp *http.Response) (*UploadFileResponse, error)
ParseUploadFileResponse parses an HTTP response from a UploadFileWithResponse call
func (UploadFileResponse) Status ¶
func (r UploadFileResponse) Status() string
Status returns HTTPResponse.Status
func (UploadFileResponse) StatusCode ¶
func (r UploadFileResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode