| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
SwaggerPetstore.API
Contents
Description
- testSpecialTags :: (Consumes TestSpecialTags contentType, MimeRender contentType Client) => contentType -> Client -> SwaggerPetstoreRequest TestSpecialTags contentType Client
- data TestSpecialTags
- fakeOuterBooleanSerialize :: Consumes FakeOuterBooleanSerialize contentType => contentType -> SwaggerPetstoreRequest FakeOuterBooleanSerialize contentType OuterBoolean
- data FakeOuterBooleanSerialize
- fakeOuterCompositeSerialize :: Consumes FakeOuterCompositeSerialize contentType => contentType -> SwaggerPetstoreRequest FakeOuterCompositeSerialize contentType OuterComposite
- data FakeOuterCompositeSerialize
- fakeOuterNumberSerialize :: Consumes FakeOuterNumberSerialize contentType => contentType -> SwaggerPetstoreRequest FakeOuterNumberSerialize contentType OuterNumber
- data FakeOuterNumberSerialize
- fakeOuterStringSerialize :: Consumes FakeOuterStringSerialize contentType => contentType -> SwaggerPetstoreRequest FakeOuterStringSerialize contentType OuterString
- data FakeOuterStringSerialize
- testClientModel :: (Consumes TestClientModel contentType, MimeRender contentType Client) => contentType -> Client -> SwaggerPetstoreRequest TestClientModel contentType Client
- data TestClientModel
- testEndpointParameters :: Consumes TestEndpointParameters contentType => contentType -> Number -> ParamDouble -> PatternWithoutDelimiter -> Byte -> SwaggerPetstoreRequest TestEndpointParameters contentType res
- data TestEndpointParameters
- testEnumParameters :: Consumes TestEnumParameters contentType => contentType -> SwaggerPetstoreRequest TestEnumParameters contentType res
- data TestEnumParameters
- testJsonFormData :: Consumes TestJsonFormData contentType => contentType -> Param -> Param2 -> SwaggerPetstoreRequest TestJsonFormData contentType NoContent
- data TestJsonFormData
- testClassname :: (Consumes TestClassname contentType, MimeRender contentType Client) => contentType -> Client -> SwaggerPetstoreRequest TestClassname contentType Client
- data TestClassname
- addPet :: (Consumes AddPet contentType, MimeRender contentType Pet) => contentType -> Pet -> SwaggerPetstoreRequest AddPet contentType res
- data AddPet
- deletePet :: PetId -> SwaggerPetstoreRequest DeletePet MimeNoContent res
- data DeletePet
- findPetsByStatus :: Status -> SwaggerPetstoreRequest FindPetsByStatus MimeNoContent [Pet]
- data FindPetsByStatus
- findPetsByTags :: Tags -> SwaggerPetstoreRequest FindPetsByTags MimeNoContent [Pet]
- data FindPetsByTags
- getPetById :: PetId -> SwaggerPetstoreRequest GetPetById MimeNoContent Pet
- data GetPetById
- updatePet :: (Consumes UpdatePet contentType, MimeRender contentType Pet) => contentType -> Pet -> SwaggerPetstoreRequest UpdatePet contentType res
- data UpdatePet
- updatePetWithForm :: Consumes UpdatePetWithForm contentType => contentType -> PetId -> SwaggerPetstoreRequest UpdatePetWithForm contentType res
- data UpdatePetWithForm
- uploadFile :: Consumes UploadFile contentType => contentType -> PetId -> SwaggerPetstoreRequest UploadFile contentType ApiResponse
- data UploadFile
- deleteOrder :: OrderIdText -> SwaggerPetstoreRequest DeleteOrder MimeNoContent res
- data DeleteOrder
- getInventory :: SwaggerPetstoreRequest GetInventory MimeNoContent (Map String Int)
- data GetInventory
- getOrderById :: OrderId -> SwaggerPetstoreRequest GetOrderById MimeNoContent Order
- data GetOrderById
- placeOrder :: (Consumes PlaceOrder contentType, MimeRender contentType Order) => contentType -> Order -> SwaggerPetstoreRequest PlaceOrder contentType Order
- data PlaceOrder
- createUser :: (Consumes CreateUser contentType, MimeRender contentType User) => contentType -> User -> SwaggerPetstoreRequest CreateUser contentType res
- data CreateUser
- createUsersWithArrayInput :: (Consumes CreateUsersWithArrayInput contentType, MimeRender contentType Body) => contentType -> Body -> SwaggerPetstoreRequest CreateUsersWithArrayInput contentType res
- data CreateUsersWithArrayInput
- createUsersWithListInput :: (Consumes CreateUsersWithListInput contentType, MimeRender contentType Body) => contentType -> Body -> SwaggerPetstoreRequest CreateUsersWithListInput contentType res
- data CreateUsersWithListInput
- deleteUser :: Username -> SwaggerPetstoreRequest DeleteUser MimeNoContent res
- data DeleteUser
- getUserByName :: Username -> SwaggerPetstoreRequest GetUserByName MimeNoContent User
- data GetUserByName
- loginUser :: Username -> Password -> SwaggerPetstoreRequest LoginUser MimeNoContent Text
- data LoginUser
- logoutUser :: SwaggerPetstoreRequest LogoutUser MimeNoContent res
- data LogoutUser
- updateUser :: (Consumes UpdateUser contentType, MimeRender contentType User) => contentType -> Username -> User -> SwaggerPetstoreRequest UpdateUser contentType res
- data UpdateUser
- class HasBodyParam req param where
- class HasOptionalParam req param where
- data SwaggerPetstoreRequest req contentType res = SwaggerPetstoreRequest {
- rMethod :: Method
- rUrlPath :: [ByteString]
- rParams :: Params
- rAuthTypes :: [TypeRep]
- rMethodL :: Lens_' (SwaggerPetstoreRequest req contentType res) Method
- rUrlPathL :: Lens_' (SwaggerPetstoreRequest req contentType res) [ByteString]
- rParamsL :: Lens_' (SwaggerPetstoreRequest req contentType res) Params
- rAuthTypesL :: Lens_' (SwaggerPetstoreRequest req contentType res) [TypeRep]
- data Params = Params {}
- paramsQueryL :: Lens_' Params Query
- paramsHeadersL :: Lens_' Params RequestHeaders
- paramsBodyL :: Lens_' Params ParamBody
- data ParamBody
- _mkRequest :: Method -> [ByteString] -> SwaggerPetstoreRequest req contentType res
- _mkParams :: Params
- setHeader :: SwaggerPetstoreRequest req contentType res -> [Header] -> SwaggerPetstoreRequest req contentType res
- removeHeader :: SwaggerPetstoreRequest req contentType res -> [HeaderName] -> SwaggerPetstoreRequest req contentType res
- _setContentTypeHeader :: forall req contentType res. MimeType contentType => SwaggerPetstoreRequest req contentType res -> SwaggerPetstoreRequest req contentType res
- _setAcceptHeader :: forall req contentType res accept. MimeType accept => SwaggerPetstoreRequest req contentType res -> accept -> SwaggerPetstoreRequest req contentType res
- setQuery :: SwaggerPetstoreRequest req contentType res -> [QueryItem] -> SwaggerPetstoreRequest req contentType res
- addForm :: SwaggerPetstoreRequest req contentType res -> Form -> SwaggerPetstoreRequest req contentType res
- _addMultiFormPart :: SwaggerPetstoreRequest req contentType res -> Part -> SwaggerPetstoreRequest req contentType res
- _setBodyBS :: SwaggerPetstoreRequest req contentType res -> ByteString -> SwaggerPetstoreRequest req contentType res
- _setBodyLBS :: SwaggerPetstoreRequest req contentType res -> ByteString -> SwaggerPetstoreRequest req contentType res
- _hasAuthType :: AuthMethod authMethod => SwaggerPetstoreRequest req contentType res -> Proxy authMethod -> SwaggerPetstoreRequest req contentType res
- toPath :: ToHttpApiData a => a -> ByteString
- toHeader :: ToHttpApiData a => (HeaderName, a) -> [Header]
- toForm :: ToHttpApiData v => (ByteString, v) -> Form
- toQuery :: ToHttpApiData a => (ByteString, Maybe a) -> [QueryItem]
- data CollectionFormat
- toHeaderColl :: ToHttpApiData a => CollectionFormat -> (HeaderName, [a]) -> [Header]
- toFormColl :: ToHttpApiData v => CollectionFormat -> (ByteString, [v]) -> Form
- toQueryColl :: ToHttpApiData a => CollectionFormat -> (ByteString, Maybe [a]) -> Query
- _toColl :: Traversable f => CollectionFormat -> (f a -> [(b, ByteString)]) -> f [a] -> [(b, ByteString)]
- _toCollA :: (Traversable f, Traversable t, Alternative t) => CollectionFormat -> (f (t a) -> [(b, t ByteString)]) -> f (t [a]) -> [(b, t ByteString)]
- _toCollA' :: (Monoid c, Traversable f, Traversable t, Alternative t) => CollectionFormat -> (f (t a) -> [(b, t c)]) -> (Char -> c) -> f (t [a]) -> [(b, t c)]
- class Typeable a => AuthMethod a where
- data AnyAuthMethod = AuthMethod a => AnyAuthMethod a
- data AuthApiKeyApiKey = AuthApiKeyApiKey Text
- data AuthApiKeyApiKeyQuery = AuthApiKeyApiKeyQuery Text
- data AuthBasicHttpBasicTest = AuthBasicHttpBasicTest ByteString ByteString
- data AuthOAuthPetstoreAuth = AuthOAuthPetstoreAuth Text
Operations
AnotherFake
testSpecialTags
Arguments
| :: (Consumes TestSpecialTags contentType, MimeRender contentType Client) | |
| => contentType | request content-type ( |
| -> Client | "body" - client model |
| -> SwaggerPetstoreRequest TestSpecialTags contentType Client |
PATCH /another-fake/dummy
To test special tags
To test special tags
data TestSpecialTags Source #
Instances
| Produces TestSpecialTags MimeJSON Source # | application/json |
| Consumes TestSpecialTags MimeJSON Source # | application/json |
| HasBodyParam TestSpecialTags Client Source # | Body Param "body" - client model |
Fake
fakeOuterBooleanSerialize
fakeOuterBooleanSerialize Source #
Arguments
| :: Consumes FakeOuterBooleanSerialize contentType | |
| => contentType | request content-type ( |
| -> SwaggerPetstoreRequest FakeOuterBooleanSerialize contentType OuterBoolean |
POST /fake/outer/boolean
Test serialization of outer boolean types
data FakeOuterBooleanSerialize Source #
Instances
| HasBodyParam FakeOuterBooleanSerialize OuterBoolean Source # | Body Param "body" - Input boolean as post body |
fakeOuterCompositeSerialize
fakeOuterCompositeSerialize Source #
Arguments
| :: Consumes FakeOuterCompositeSerialize contentType | |
| => contentType | request content-type ( |
| -> SwaggerPetstoreRequest FakeOuterCompositeSerialize contentType OuterComposite |
POST /fake/outer/composite
Test serialization of object with outer number type
data FakeOuterCompositeSerialize Source #
Instances
| HasBodyParam FakeOuterCompositeSerialize OuterComposite Source # | Body Param "body" - Input composite as post body |
fakeOuterNumberSerialize
fakeOuterNumberSerialize Source #
Arguments
| :: Consumes FakeOuterNumberSerialize contentType | |
| => contentType | request content-type ( |
| -> SwaggerPetstoreRequest FakeOuterNumberSerialize contentType OuterNumber |
POST /fake/outer/number
Test serialization of outer number types
data FakeOuterNumberSerialize Source #
Instances
| HasBodyParam FakeOuterNumberSerialize OuterNumber Source # | Body Param "body" - Input number as post body |
fakeOuterStringSerialize
fakeOuterStringSerialize Source #
Arguments
| :: Consumes FakeOuterStringSerialize contentType | |
| => contentType | request content-type ( |
| -> SwaggerPetstoreRequest FakeOuterStringSerialize contentType OuterString |
POST /fake/outer/string
Test serialization of outer string types
data FakeOuterStringSerialize Source #
Instances
| HasBodyParam FakeOuterStringSerialize OuterString Source # | Body Param "body" - Input string as post body |
testClientModel
Arguments
| :: (Consumes TestClientModel contentType, MimeRender contentType Client) | |
| => contentType | request content-type ( |
| -> Client | "body" - client model |
| -> SwaggerPetstoreRequest TestClientModel contentType Client |
PATCH /fake
To test "client" model
To test "client" model
data TestClientModel Source #
Instances
| Produces TestClientModel MimeJSON Source # | application/json |
| Consumes TestClientModel MimeJSON Source # | application/json |
| HasBodyParam TestClientModel Client Source # | Body Param "body" - client model |
testEndpointParameters
testEndpointParameters Source #
Arguments
| :: Consumes TestEndpointParameters contentType | |
| => contentType | request content-type ( |
| -> Number | "number" - None |
| -> ParamDouble | "double" - None |
| -> PatternWithoutDelimiter | "patternWithoutDelimiter" - None |
| -> Byte | "byte" - None |
| -> SwaggerPetstoreRequest TestEndpointParameters contentType res |
POST /fake
Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
AuthMethod: AuthBasicHttpBasicTest
Note: Has Produces instances, but no response schema
data TestEndpointParameters Source #
Instances
testEnumParameters
Arguments
| :: Consumes TestEnumParameters contentType | |
| => contentType | request content-type ( |
| -> SwaggerPetstoreRequest TestEnumParameters contentType res |
GET /fake
To test enum parameters
To test enum parameters
Note: Has Produces instances, but no response schema
data TestEnumParameters Source #
Instances
| Produces TestEnumParameters MimeAny Source # | */* |
| Consumes TestEnumParameters MimeAny Source # | */* |
| HasOptionalParam TestEnumParameters EnumQueryStringArray Source # | Optional Param "enum_query_string_array" - Query parameter enum test (string array) |
| HasOptionalParam TestEnumParameters EnumQueryString Source # | Optional Param "enum_query_string" - Query parameter enum test (string) |
| HasOptionalParam TestEnumParameters EnumQueryInteger Source # | Optional Param "enum_query_integer" - Query parameter enum test (double) |
| HasOptionalParam TestEnumParameters EnumQueryDouble Source # | Optional Param "enum_query_double" - Query parameter enum test (double) |
| HasOptionalParam TestEnumParameters EnumHeaderStringArray Source # | Optional Param "enum_header_string_array" - Header parameter enum test (string array) |
| HasOptionalParam TestEnumParameters EnumHeaderString Source # | Optional Param "enum_header_string" - Header parameter enum test (string) |
| HasOptionalParam TestEnumParameters EnumFormStringArray Source # | Optional Param "enum_form_string_array" - Form parameter enum test (string array) |
| HasOptionalParam TestEnumParameters EnumFormString Source # | Optional Param "enum_form_string" - Form parameter enum test (string) |
testJsonFormData
Arguments
| :: Consumes TestJsonFormData contentType | |
| => contentType | request content-type ( |
| -> Param | "param" - field1 |
| -> Param2 | "param2" - field2 |
| -> SwaggerPetstoreRequest TestJsonFormData contentType NoContent |
GET /fake/jsonFormData
test json serialization of form data
data TestJsonFormData Source #
Instances
| Consumes TestJsonFormData MimeJSON Source # | application/json |
FakeClassnameTags123
testClassname
Arguments
| :: (Consumes TestClassname contentType, MimeRender contentType Client) | |
| => contentType | request content-type ( |
| -> Client | "body" - client model |
| -> SwaggerPetstoreRequest TestClassname contentType Client |
data TestClassname Source #
Instances
| Produces TestClassname MimeJSON Source # | application/json |
| Consumes TestClassname MimeJSON Source # | application/json |
| HasBodyParam TestClassname Client Source # | Body Param "body" - client model |
Pet
addPet
Arguments
| :: (Consumes AddPet contentType, MimeRender contentType Pet) | |
| => contentType | request content-type ( |
| -> Pet | "body" - Pet object that needs to be added to the store |
| -> SwaggerPetstoreRequest AddPet contentType res |
POST /pet
Add a new pet to the store
AuthMethod: AuthOAuthPetstoreAuth
Note: Has Produces instances, but no response schema
Instances
deletePet
Arguments
| :: PetId | "petId" - Pet id to delete |
| -> SwaggerPetstoreRequest DeletePet MimeNoContent res |
DELETE /pet/{petId}Deletes a pet
AuthMethod: AuthOAuthPetstoreAuth
Note: Has Produces instances, but no response schema
findPetsByStatus
Arguments
| :: Status | "status" - Status values that need to be considered for filter |
| -> SwaggerPetstoreRequest FindPetsByStatus MimeNoContent [Pet] |
GET /pet/findByStatus
Finds Pets by status
Multiple status values can be provided with comma separated strings
AuthMethod: AuthOAuthPetstoreAuth
data FindPetsByStatus Source #
Instances
| Produces FindPetsByStatus MimeXML Source # | application/xml |
| Produces FindPetsByStatus MimeJSON Source # | application/json |
findPetsByTags
Arguments
| :: Tags | "tags" - Tags to filter by |
| -> SwaggerPetstoreRequest FindPetsByTags MimeNoContent [Pet] |
Deprecated:
GET /pet/findByTags
Finds Pets by tags
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
AuthMethod: AuthOAuthPetstoreAuth
data FindPetsByTags Source #
Instances
| Produces FindPetsByTags MimeXML Source # | application/xml |
| Produces FindPetsByTags MimeJSON Source # | application/json |
getPetById
Arguments
| :: PetId | "petId" - ID of pet to return |
| -> SwaggerPetstoreRequest GetPetById MimeNoContent Pet |
data GetPetById Source #
Instances
| Produces GetPetById MimeXML Source # | application/xml |
| Produces GetPetById MimeJSON Source # | application/json |
updatePet
Arguments
| :: (Consumes UpdatePet contentType, MimeRender contentType Pet) | |
| => contentType | request content-type ( |
| -> Pet | "body" - Pet object that needs to be added to the store |
| -> SwaggerPetstoreRequest UpdatePet contentType res |
PUT /pet
Update an existing pet
AuthMethod: AuthOAuthPetstoreAuth
Note: Has Produces instances, but no response schema
Instances
| Produces UpdatePet MimeXML Source # | application/xml |
| Produces UpdatePet MimeJSON Source # | application/json |
| Consumes UpdatePet MimeXML Source # | application/xml |
| Consumes UpdatePet MimeJSON Source # | application/json |
| HasBodyParam UpdatePet Pet Source # | Body Param "body" - Pet object that needs to be added to the store |
updatePetWithForm
Arguments
| :: Consumes UpdatePetWithForm contentType | |
| => contentType | request content-type ( |
| -> PetId | "petId" - ID of pet that needs to be updated |
| -> SwaggerPetstoreRequest UpdatePetWithForm contentType res |
POST /pet/{petId}Updates a pet in the store with form data
AuthMethod: AuthOAuthPetstoreAuth
Note: Has Produces instances, but no response schema
data UpdatePetWithForm Source #
Instances
| Produces UpdatePetWithForm MimeXML Source # | application/xml |
| Produces UpdatePetWithForm MimeJSON Source # | application/json |
| Consumes UpdatePetWithForm MimeFormUrlEncoded Source # | application/x-www-form-urlencoded |
| HasOptionalParam UpdatePetWithForm StatusText Source # | Optional Param "status" - Updated status of the pet |
| HasOptionalParam UpdatePetWithForm Name2 Source # | Optional Param "name" - Updated name of the pet |
uploadFile
Arguments
| :: Consumes UploadFile contentType | |
| => contentType | request content-type ( |
| -> PetId | "petId" - ID of pet to update |
| -> SwaggerPetstoreRequest UploadFile contentType ApiResponse |
data UploadFile Source #
Instances
| Produces UploadFile MimeJSON Source # | application/json |
| Consumes UploadFile MimeMultipartFormData Source # | multipart/form-data |
| HasOptionalParam UploadFile File Source # | Optional Param "file" - file to upload |
| HasOptionalParam UploadFile AdditionalMetadata Source # | Optional Param "additionalMetadata" - Additional data to pass to server |
Store
deleteOrder
Arguments
| :: OrderIdText | "orderId" - ID of the order that needs to be deleted |
| -> SwaggerPetstoreRequest DeleteOrder MimeNoContent res |
DELETE /store/order/{order_id}Delete purchase order by ID
For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors
Note: Has Produces instances, but no response schema
data DeleteOrder Source #
Instances
| Produces DeleteOrder MimeXML Source # | application/xml |
| Produces DeleteOrder MimeJSON Source # | application/json |
getInventory
getInventory :: SwaggerPetstoreRequest GetInventory MimeNoContent (Map String Int) Source #
GET /store/inventory
Returns pet inventories by status
Returns a map of status codes to quantities
AuthMethod: AuthApiKeyApiKey
data GetInventory Source #
Instances
| Produces GetInventory MimeJSON Source # | application/json |
getOrderById
Arguments
| :: OrderId | "orderId" - ID of pet that needs to be fetched |
| -> SwaggerPetstoreRequest GetOrderById MimeNoContent Order |
GET /store/order/{order_id}Find purchase order by ID
For valid response try integer IDs with value 5 or 10. Other values will generated exceptions
data GetOrderById Source #
Instances
| Produces GetOrderById MimeXML Source # | application/xml |
| Produces GetOrderById MimeJSON Source # | application/json |
placeOrder
Arguments
| :: (Consumes PlaceOrder contentType, MimeRender contentType Order) | |
| => contentType | request content-type ( |
| -> Order | "body" - order placed for purchasing the pet |
| -> SwaggerPetstoreRequest PlaceOrder contentType Order |
POST /store/order
Place an order for a pet
data PlaceOrder Source #
Instances
| Produces PlaceOrder MimeXML Source # | application/xml |
| Produces PlaceOrder MimeJSON Source # | application/json |
| HasBodyParam PlaceOrder Order Source # | Body Param "body" - order placed for purchasing the pet |
User
createUser
Arguments
| :: (Consumes CreateUser contentType, MimeRender contentType User) | |
| => contentType | request content-type ( |
| -> User | "body" - Created user object |
| -> SwaggerPetstoreRequest CreateUser contentType res |
POST /user
Create user
This can only be done by the logged in user.
Note: Has Produces instances, but no response schema
data CreateUser Source #
Instances
| Produces CreateUser MimeXML Source # | application/xml |
| Produces CreateUser MimeJSON Source # | application/json |
| HasBodyParam CreateUser User Source # | Body Param "body" - Created user object |
createUsersWithArrayInput
createUsersWithArrayInput Source #
Arguments
| :: (Consumes CreateUsersWithArrayInput contentType, MimeRender contentType Body) | |
| => contentType | request content-type ( |
| -> Body | "body" - List of user object |
| -> SwaggerPetstoreRequest CreateUsersWithArrayInput contentType res |
POST /user/createWithArray
Creates list of users with given input array
Note: Has Produces instances, but no response schema
data CreateUsersWithArrayInput Source #
Instances
| Produces CreateUsersWithArrayInput MimeXML Source # | application/xml |
| Produces CreateUsersWithArrayInput MimeJSON Source # | application/json |
| HasBodyParam CreateUsersWithArrayInput Body Source # | Body Param "body" - List of user object |
createUsersWithListInput
createUsersWithListInput Source #
Arguments
| :: (Consumes CreateUsersWithListInput contentType, MimeRender contentType Body) | |
| => contentType | request content-type ( |
| -> Body | "body" - List of user object |
| -> SwaggerPetstoreRequest CreateUsersWithListInput contentType res |
POST /user/createWithList
Creates list of users with given input array
Note: Has Produces instances, but no response schema
data CreateUsersWithListInput Source #
Instances
| Produces CreateUsersWithListInput MimeXML Source # | application/xml |
| Produces CreateUsersWithListInput MimeJSON Source # | application/json |
| HasBodyParam CreateUsersWithListInput Body Source # | Body Param "body" - List of user object |
deleteUser
Arguments
| :: Username | "username" - The name that needs to be deleted |
| -> SwaggerPetstoreRequest DeleteUser MimeNoContent res |
DELETE /user/{username}Delete user
This can only be done by the logged in user.
Note: Has Produces instances, but no response schema
data DeleteUser Source #
Instances
| Produces DeleteUser MimeXML Source # | application/xml |
| Produces DeleteUser MimeJSON Source # | application/json |
getUserByName
Arguments
| :: Username | "username" - The name that needs to be fetched. Use user1 for testing. |
| -> SwaggerPetstoreRequest GetUserByName MimeNoContent User |
GET /user/{username}Get user by user name
data GetUserByName Source #
Instances
| Produces GetUserByName MimeXML Source # | application/xml |
| Produces GetUserByName MimeJSON Source # | application/json |
loginUser
Arguments
| :: Username | "username" - The user name for login |
| -> Password | "password" - The password for login in clear text |
| -> SwaggerPetstoreRequest LoginUser MimeNoContent Text |
GET /user/login
Logs user into the system
logoutUser
logoutUser :: SwaggerPetstoreRequest LogoutUser MimeNoContent res Source #
GET /user/logout
Logs out current logged in user session
Note: Has Produces instances, but no response schema
data LogoutUser Source #
Instances
| Produces LogoutUser MimeXML Source # | application/xml |
| Produces LogoutUser MimeJSON Source # | application/json |
updateUser
Arguments
| :: (Consumes UpdateUser contentType, MimeRender contentType User) | |
| => contentType | request content-type ( |
| -> Username | "username" - name that need to be deleted |
| -> User | "body" - Updated user object |
| -> SwaggerPetstoreRequest UpdateUser contentType res |
PUT /user/{username}Updated user
This can only be done by the logged in user.
Note: Has Produces instances, but no response schema
data UpdateUser Source #
Instances
| Produces UpdateUser MimeXML Source # | application/xml |
| Produces UpdateUser MimeJSON Source # | application/json |
| HasBodyParam UpdateUser User Source # | Body Param "body" - Updated user object |
HasBodyParam
class HasBodyParam req param where Source #
Designates the body parameter of a request
Methods
setBodyParam :: forall contentType res. (Consumes req contentType, MimeRender contentType param) => SwaggerPetstoreRequest req contentType res -> param -> SwaggerPetstoreRequest req contentType res Source #
Instances
| HasBodyParam UpdateUser User Source # | Body Param "body" - Updated user object |
| HasBodyParam CreateUsersWithListInput Body Source # | Body Param "body" - List of user object |
| HasBodyParam CreateUsersWithArrayInput Body Source # | Body Param "body" - List of user object |
| HasBodyParam CreateUser User Source # | Body Param "body" - Created user object |
| HasBodyParam PlaceOrder Order Source # | Body Param "body" - order placed for purchasing the pet |
| HasBodyParam UpdatePet Pet Source # | Body Param "body" - Pet object that needs to be added to the store |
| HasBodyParam AddPet Pet Source # | Body Param "body" - Pet object that needs to be added to the store |
| HasBodyParam TestClassname Client Source # | Body Param "body" - client model |
| HasBodyParam TestClientModel Client Source # | Body Param "body" - client model |
| HasBodyParam FakeOuterStringSerialize OuterString Source # | Body Param "body" - Input string as post body |
| HasBodyParam FakeOuterNumberSerialize OuterNumber Source # | Body Param "body" - Input number as post body |
| HasBodyParam FakeOuterCompositeSerialize OuterComposite Source # | Body Param "body" - Input composite as post body |
| HasBodyParam FakeOuterBooleanSerialize OuterBoolean Source # | Body Param "body" - Input boolean as post body |
| HasBodyParam TestSpecialTags Client Source # | Body Param "body" - client model |
HasOptionalParam
class HasOptionalParam req param where Source #
Designates the optional parameters of a request
Minimal complete definition
Methods
applyOptionalParam :: SwaggerPetstoreRequest req contentType res -> param -> SwaggerPetstoreRequest req contentType res Source #
Apply an optional parameter to a request
(-&-) :: SwaggerPetstoreRequest req contentType res -> param -> SwaggerPetstoreRequest req contentType res infixl 2 Source #
infix operator / alias for addOptionalParam
Instances
| HasOptionalParam UploadFile File Source # | Optional Param "file" - file to upload |
| HasOptionalParam UploadFile AdditionalMetadata Source # | Optional Param "additionalMetadata" - Additional data to pass to server |
| HasOptionalParam UpdatePetWithForm StatusText Source # | Optional Param "status" - Updated status of the pet |
| HasOptionalParam UpdatePetWithForm Name2 Source # | Optional Param "name" - Updated name of the pet |
| HasOptionalParam DeletePet ApiKey Source # | |
| HasOptionalParam TestEnumParameters EnumQueryStringArray Source # | Optional Param "enum_query_string_array" - Query parameter enum test (string array) |
| HasOptionalParam TestEnumParameters EnumQueryString Source # | Optional Param "enum_query_string" - Query parameter enum test (string) |
| HasOptionalParam TestEnumParameters EnumQueryInteger Source # | Optional Param "enum_query_integer" - Query parameter enum test (double) |
| HasOptionalParam TestEnumParameters EnumQueryDouble Source # | Optional Param "enum_query_double" - Query parameter enum test (double) |
| HasOptionalParam TestEnumParameters EnumHeaderStringArray Source # | Optional Param "enum_header_string_array" - Header parameter enum test (string array) |
| HasOptionalParam TestEnumParameters EnumHeaderString Source # | Optional Param "enum_header_string" - Header parameter enum test (string) |
| HasOptionalParam TestEnumParameters EnumFormStringArray Source # | Optional Param "enum_form_string_array" - Form parameter enum test (string array) |
| HasOptionalParam TestEnumParameters EnumFormString Source # | Optional Param "enum_form_string" - Form parameter enum test (string) |
| HasOptionalParam TestEndpointParameters Password Source # | Optional Param "password" - None |
| HasOptionalParam TestEndpointParameters ParamString Source # | Optional Param "string" - None |
| HasOptionalParam TestEndpointParameters ParamInteger Source # | Optional Param "integer" - None |
| HasOptionalParam TestEndpointParameters ParamFloat Source # | Optional Param "float" - None |
| HasOptionalParam TestEndpointParameters ParamDateTime Source # | Optional Param "dateTime" - None |
| HasOptionalParam TestEndpointParameters ParamDate Source # | Optional Param "date" - None |
| HasOptionalParam TestEndpointParameters ParamBinary Source # | Optional Param "binary" - None |
| HasOptionalParam TestEndpointParameters Int64 Source # | Optional Param "int64" - None |
| HasOptionalParam TestEndpointParameters Int32 Source # | Optional Param "int32" - None |
| HasOptionalParam TestEndpointParameters Callback Source # | Optional Param "callback" - None |
SwaggerPetstoreRequest
data SwaggerPetstoreRequest req contentType res Source #
Represents a request. The "req" type variable is the request type. The "res" type variable is the response type.
Constructors
| SwaggerPetstoreRequest | |
Fields
| |
Instances
| Show (SwaggerPetstoreRequest req contentType res) Source # | |
rUrlPathL :: Lens_' (SwaggerPetstoreRequest req contentType res) [ByteString] Source #
rUrlPath Lens
rAuthTypesL :: Lens_' (SwaggerPetstoreRequest req contentType res) [TypeRep] Source #
rParams Lens
Request Params
Constructors
| Params | |
Fields | |
paramsQueryL :: Lens_' Params Query Source #
paramsQuery Lens
paramsBodyL :: Lens_' Params ParamBody Source #
paramsBody Lens
Request Body
SwaggerPetstoreRequest Utils
Arguments
| :: Method | Method |
| -> [ByteString] | Endpoint |
| -> SwaggerPetstoreRequest req contentType res | req: Request Type, res: Response Type |
setHeader :: SwaggerPetstoreRequest req contentType res -> [Header] -> SwaggerPetstoreRequest req contentType res Source #
removeHeader :: SwaggerPetstoreRequest req contentType res -> [HeaderName] -> SwaggerPetstoreRequest req contentType res Source #
_setContentTypeHeader :: forall req contentType res. MimeType contentType => SwaggerPetstoreRequest req contentType res -> SwaggerPetstoreRequest req contentType res Source #
_setAcceptHeader :: forall req contentType res accept. MimeType accept => SwaggerPetstoreRequest req contentType res -> accept -> SwaggerPetstoreRequest req contentType res Source #
setQuery :: SwaggerPetstoreRequest req contentType res -> [QueryItem] -> SwaggerPetstoreRequest req contentType res Source #
addForm :: SwaggerPetstoreRequest req contentType res -> Form -> SwaggerPetstoreRequest req contentType res Source #
_addMultiFormPart :: SwaggerPetstoreRequest req contentType res -> Part -> SwaggerPetstoreRequest req contentType res Source #
_setBodyBS :: SwaggerPetstoreRequest req contentType res -> ByteString -> SwaggerPetstoreRequest req contentType res Source #
_setBodyLBS :: SwaggerPetstoreRequest req contentType res -> ByteString -> SwaggerPetstoreRequest req contentType res Source #
_hasAuthType :: AuthMethod authMethod => SwaggerPetstoreRequest req contentType res -> Proxy authMethod -> SwaggerPetstoreRequest req contentType res Source #
Params Utils
toPath :: ToHttpApiData a => a -> ByteString Source #
toHeader :: ToHttpApiData a => (HeaderName, a) -> [Header] Source #
toForm :: ToHttpApiData v => (ByteString, v) -> Form Source #
toQuery :: ToHttpApiData a => (ByteString, Maybe a) -> [QueryItem] Source #
Swagger CollectionFormat Utils
data CollectionFormat Source #
Determines the format of the array if type array is used.
Constructors
| CommaSeparated | CSV format for multiple parameters. |
| SpaceSeparated | Also called SSV |
| TabSeparated | Also called TSV |
| PipeSeparated | `value1|value2|value2` |
| MultiParamArray | Using multiple GET parameters, e.g. `foo=bar&foo=baz`. This is valid only for parameters in "query" ( |
toHeaderColl :: ToHttpApiData a => CollectionFormat -> (HeaderName, [a]) -> [Header] Source #
toFormColl :: ToHttpApiData v => CollectionFormat -> (ByteString, [v]) -> Form Source #
toQueryColl :: ToHttpApiData a => CollectionFormat -> (ByteString, Maybe [a]) -> Query Source #
_toColl :: Traversable f => CollectionFormat -> (f a -> [(b, ByteString)]) -> f [a] -> [(b, ByteString)] Source #
_toCollA :: (Traversable f, Traversable t, Alternative t) => CollectionFormat -> (f (t a) -> [(b, t ByteString)]) -> f (t [a]) -> [(b, t ByteString)] Source #
_toCollA' :: (Monoid c, Traversable f, Traversable t, Alternative t) => CollectionFormat -> (f (t a) -> [(b, t c)]) -> (Char -> c) -> f (t [a]) -> [(b, t c)] Source #
AuthMethods
class Typeable a => AuthMethod a where Source #
Provides a method to apply auth methods to requests
Minimal complete definition
Methods
applyAuthMethod :: SwaggerPetstoreRequest req contentType res -> a -> SwaggerPetstoreRequest req contentType res Source #
data AnyAuthMethod Source #
An existential wrapper for any AuthMethod
Constructors
| AuthMethod a => AnyAuthMethod a |
Instances
AuthApiKeyApiKey
data AuthApiKeyApiKey Source #
Constructors
| AuthApiKeyApiKey Text | secret |
AuthApiKeyApiKeyQuery
data AuthApiKeyApiKeyQuery Source #
Constructors
| AuthApiKeyApiKeyQuery Text | secret |
AuthBasicHttpBasicTest
data AuthBasicHttpBasicTest Source #
Constructors
| AuthBasicHttpBasicTest ByteString ByteString | username password |
AuthOAuthPetstoreAuth
data AuthOAuthPetstoreAuth Source #
Constructors
| AuthOAuthPetstoreAuth Text | secret |