Documentation ¶
Index ¶
- func CancelOrder(rw http.ResponseWriter, req *http.Request, params denco.Params)
- func CreateOrder(rw http.ResponseWriter, req *http.Request, params denco.Params)
- func CreatePet(w http.ResponseWriter, r *http.Request, params denco.Params)
- func CreateUser(w http.ResponseWriter, r *http.Request, params denco.Params)
- func DeletePet(w http.ResponseWriter, r *http.Request, params denco.Params)
- func DeleteUser(w http.ResponseWriter, r *http.Request, params denco.Params)
- func GetOrderDetails(rw http.ResponseWriter, req *http.Request, params denco.Params)
- func GetPetByID(w http.ResponseWriter, r *http.Request, params denco.Params)
- func GetPets(w http.ResponseWriter, r *http.Request, params denco.Params)
- func GetUserByID(w http.ResponseWriter, r *http.Request, params denco.Params)
- func GetUsers(w http.ResponseWriter, r *http.Request, params denco.Params)
- func UpdateOrder(rw http.ResponseWriter, req *http.Request, params denco.Params)
- func UpdatePet(w http.ResponseWriter, r *http.Request, params denco.Params)
- func UpdateUser(w http.ResponseWriter, r *http.Request, params denco.Params)
- type GenericError
- type OrderBodyParams
- type OrderID
- type OrderResponse
- type PetBodyParams
- type PetID
- type PetQueryFlags
- type ValidationError
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CancelOrder ¶
CancelOrder swagger:route DELETE /orders/{id} orders cancelOrder
Deletes an order.
Responses:
default: genericError 204:
func CreateOrder ¶
CreateOrder swagger:route POST /orders orders createOrder
Creates an order.
Responses:
default: genericError 200: orderResponse 422: validationError
func CreatePet ¶
CreatePet swagger:route POST /pets pets createPet
Creates a new pet in the store.
Responses:
default: genericError 200: pet 422: validationError
func CreateUser ¶
CreateUser creates a user
func DeletePet ¶
DeletePet swagger:route DELETE /pets/{id} pets deletePet
Deletes a pet from the store.
Responses:
default: genericError 204:
func DeleteUser ¶
DeleteUser deletes a user from the store
func GetOrderDetails ¶
GetOrderDetails swagger:route GET /orders/{id} orders getOrderDetails
Gets the details for an order.
Responses:
default: genericError 200: orderResponse
func GetPetByID ¶
GetPetByID swagger:route GET /pets/{id} pets getPetById
Gets the details for a pet.
Responses:
default: genericError 200: pet
func GetPets ¶
GetPets swagger:route GET /pets pets listPets
Lists the pets known to the store.
By default it will only lists pets that are available for sale. This can be changed with the status flag.
Responses:
default: genericError 200: []pet
func GetUserByID ¶
GetUserByID gets a user by id
func UpdateOrder ¶
UpdateOrder swagger:route PUT /orders/{id} orders updateOrder
Updates an order.
Responses:
default: genericError 200: order 422: validationError
func UpdatePet ¶
UpdatePet swagger:route PUT /pets/{id} pets updatePet
Updates the details for a pet.
Responses:
default: genericError 200: pet 422: validationError
func UpdateUser ¶
UpdateUser updates a user
Types ¶
type GenericError ¶
type GenericError struct { // in: body Body struct { Code int32 `json:"code"` Message string `json:"message"` } `json:"body"` }
A GenericError is the default error message that is generated. For certain status codes there are more appropriate error structures.
swagger:response genericError
type OrderBodyParams ¶
type OrderBodyParams struct { // The order to submit // // required: true // in: body Order *models.Order `json:"order"` }
An OrderBodyParams model.
This is used for operations that want an Order as body of the request swagger:parameters updateOrder createOrder
type OrderID ¶
type OrderID struct { // The ID of the order // // in: path // required: true ID int64 `json:"id"` }
An OrderID parameter model.
This is used for operations that want the ID of an order in the path swagger:parameters getOrderDetails cancelOrder updateOrder
type OrderResponse ¶
An OrderResponse response model
This is used for returning a response with a single order as body ¶
swagger:response orderResponse
type PetBodyParams ¶
type PetBodyParams struct { // The pet to submit. // // in: body // required: true Pet *models.Pet `json:"pet"` }
A PetBodyParams model.
This is used for operations that want an Order as body of the request swagger:parameters updatePet createPet
type PetID ¶
type PetID struct { // The ID of the pet // // in: path // required: true ID int64 `json:"id"` }
A PetID parameter model.
This is used for operations that want the ID of an pet in the path swagger:parameters getPetById deletePet updatePet
type PetQueryFlags ¶
type PetQueryFlags struct {
Status string `json:"status"`
}
A PetQueryFlags contains the query flags for things that list pets. swagger:parameters listPets
type ValidationError ¶
type ValidationError struct { // in: body Body struct { Code int32 `json:"code"` Message string `json:"message"` Field string `json:"field"` } `json:"body"` }
A ValidationError is an that is generated for validation failures. It has the same fields as a generic error but adds a Field property.
swagger:response validationError