    {-
       OpenAPI Petstore

       This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\

       OpenAPI Version: 3.0.1
       OpenAPI Petstore API version: 1.0.0
       Generated by OpenAPI Generator (https://openapi-generator.tech)
    -}

    {-|
    Module : OpenAPIPetstore.API.Fake
    -}

    {-# LANGUAGE FlexibleContexts #-}
    {-# LANGUAGE FlexibleInstances #-}
    {-# LANGUAGE MonoLocalBinds #-}
    {-# LANGUAGE MultiParamTypeClasses #-}
    {-# LANGUAGE OverloadedStrings #-}
    {-# OPTIONS_GHC -fno-warn-name-shadowing -fno-warn-unused-binds -fno-warn-unused-imports #-}

    module OpenAPIPetstore.API.Fake where

    import OpenAPIPetstore.Core
    import OpenAPIPetstore.MimeTypes
    import OpenAPIPetstore.Model as M

    import qualified Data.Aeson as A
    import qualified Data.ByteString as B
    import qualified Data.ByteString.Lazy as BL
    import qualified Data.Data as P (Typeable, TypeRep, typeOf, typeRep)
    import qualified Data.Foldable as P
    import qualified Data.Map as Map
    import qualified Data.Maybe as P
    import qualified Data.Proxy as P (Proxy(..))
    import qualified Data.Set as Set
    import qualified Data.String as P
    import qualified Data.Text as T
    import qualified Data.Text.Encoding as T
    import qualified Data.Text.Lazy as TL
    import qualified Data.Text.Lazy.Encoding as TL
    import qualified Data.Time as TI
    import qualified Network.HTTP.Client.MultipartFormData as NH
    import qualified Network.HTTP.Media as ME
    import qualified Network.HTTP.Types as NH
    import qualified Web.FormUrlEncoded as WH
    import qualified Web.HttpApiData as WH

    import Data.Text (Text)
    import GHC.Base ((<|>))

    import Prelude ((==),(/=),($), (.),(<$>),(<*>),(>>=),Maybe(..),Bool(..),Char,Double,FilePath,Float,Int,Integer,String,fmap,undefined,mempty,maybe,pure,Monad,Applicative,Functor)
    import qualified Prelude as P

    -- * Operations

    -- ** Fake

    -- *** createXmlItem

    -- | @POST \/fake\/create_xml_item@
    --
    -- creates an XmlItem
    --
    -- this route creates an XmlItem
    --
    createXmlItem
      :: (Consumes CreateXmlItem contentType, MimeRender contentType XmlItem)
      => ContentType contentType -- ^ request content-type ('MimeType')
      -> XmlItem -- ^ "xmlItem" -  XmlItem Body
      -> OpenAPIPetstoreRequest CreateXmlItem contentType NoContent MimeNoContent
    createXmlItem :: forall contentType.
    (Consumes CreateXmlItem contentType,
     MimeRender contentType XmlItem) =>
    ContentType contentType
    -> XmlItem
    -> OpenAPIPetstoreRequest
         CreateXmlItem contentType NoContent MimeNoContent
    createXmlItem ContentType contentType
    _ XmlItem
    xmlItem =
      Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest
         CreateXmlItem contentType NoContent MimeNoContent
    forall req contentType res accept.
    Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest req contentType res accept
    _mkRequest Method
    "POST" [ByteString
    "/fake/create_xml_item"]
        OpenAPIPetstoreRequest
      CreateXmlItem contentType NoContent MimeNoContent
    -> XmlItem
    -> OpenAPIPetstoreRequest
         CreateXmlItem contentType NoContent MimeNoContent
    forall req param contentType res accept.
    (HasBodyParam req param, Consumes req contentType,
     MimeRender contentType param) =>
    OpenAPIPetstoreRequest req contentType res accept
    -> param -> OpenAPIPetstoreRequest req contentType res accept
    forall contentType res accept.
    (Consumes CreateXmlItem contentType,
     MimeRender contentType XmlItem) =>
    OpenAPIPetstoreRequest CreateXmlItem contentType res accept
    -> XmlItem
    -> OpenAPIPetstoreRequest CreateXmlItem contentType res accept
    `setBodyParam` XmlItem
    xmlItem

    data CreateXmlItem

    -- | /Body Param/ "XmlItem" - XmlItem Body
    instance HasBodyParam CreateXmlItem XmlItem

    -- | @application/xml@
    instance Consumes CreateXmlItem MimeXML
    -- | @text/xml@
    instance Consumes CreateXmlItem MimeTextXml
    -- | @text/xml; charset=utf-8@
    instance Consumes CreateXmlItem MimeTextXmlCharsetutf8
    -- | @text/xml; charset=utf-16@
    instance Consumes CreateXmlItem MimeTextXmlCharsetutf16
    -- | @application/xml; charset=utf-8@
    instance Consumes CreateXmlItem MimeXmlCharsetutf8
    -- | @application/xml; charset=utf-16@
    instance Consumes CreateXmlItem MimeXmlCharsetutf16

    instance Produces CreateXmlItem MimeNoContent

    -- *** fakeOuterBooleanSerialize

    -- | @POST \/fake\/outer\/boolean@
    --
    -- Test serialization of outer boolean types
    --
    fakeOuterBooleanSerialize
      :: (Consumes FakeOuterBooleanSerialize contentType)
      => ContentType contentType -- ^ request content-type ('MimeType')
      -> Accept accept -- ^ request accept ('MimeType')
      -> OpenAPIPetstoreRequest FakeOuterBooleanSerialize contentType Bool accept
    fakeOuterBooleanSerialize :: forall contentType accept.
    Consumes FakeOuterBooleanSerialize contentType =>
    ContentType contentType
    -> Accept accept
    -> OpenAPIPetstoreRequest
         FakeOuterBooleanSerialize contentType Bool accept
    fakeOuterBooleanSerialize ContentType contentType
    _  Accept accept
    _ =
      Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest
         FakeOuterBooleanSerialize contentType Bool accept
    forall req contentType res accept.
    Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest req contentType res accept
    _mkRequest Method
    "POST" [ByteString
    "/fake/outer/boolean"]

    data FakeOuterBooleanSerialize

    -- | /Body Param/ "body" - Input boolean as post body
    instance HasBodyParam FakeOuterBooleanSerialize BodyBool

    -- | @*/*@
    instance MimeType mtype => Consumes FakeOuterBooleanSerialize mtype

    -- | @*/*@
    instance MimeType mtype => Produces FakeOuterBooleanSerialize mtype

    -- *** fakeOuterCompositeSerialize

    -- | @POST \/fake\/outer\/composite@
    --
    -- Test serialization of object with outer number type
    --
    fakeOuterCompositeSerialize
      :: (Consumes FakeOuterCompositeSerialize contentType)
      => ContentType contentType -- ^ request content-type ('MimeType')
      -> Accept accept -- ^ request accept ('MimeType')
      -> OpenAPIPetstoreRequest FakeOuterCompositeSerialize contentType OuterComposite accept
    fakeOuterCompositeSerialize :: forall contentType accept.
    Consumes FakeOuterCompositeSerialize contentType =>
    ContentType contentType
    -> Accept accept
    -> OpenAPIPetstoreRequest
         FakeOuterCompositeSerialize contentType OuterComposite accept
    fakeOuterCompositeSerialize ContentType contentType
    _  Accept accept
    _ =
      Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest
         FakeOuterCompositeSerialize contentType OuterComposite accept
    forall req contentType res accept.
    Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest req contentType res accept
    _mkRequest Method
    "POST" [ByteString
    "/fake/outer/composite"]

    data FakeOuterCompositeSerialize

    -- | /Body Param/ "body" - Input composite as post body
    instance HasBodyParam FakeOuterCompositeSerialize OuterComposite

    -- | @*/*@
    instance MimeType mtype => Consumes FakeOuterCompositeSerialize mtype

    -- | @*/*@
    instance MimeType mtype => Produces FakeOuterCompositeSerialize mtype

    -- *** fakeOuterNumberSerialize

    -- | @POST \/fake\/outer\/number@
    --
    -- Test serialization of outer number types
    --
    fakeOuterNumberSerialize
      :: (Consumes FakeOuterNumberSerialize contentType)
      => ContentType contentType -- ^ request content-type ('MimeType')
      -> Accept accept -- ^ request accept ('MimeType')
      -> OpenAPIPetstoreRequest FakeOuterNumberSerialize contentType Double accept
    fakeOuterNumberSerialize :: forall contentType accept.
    Consumes FakeOuterNumberSerialize contentType =>
    ContentType contentType
    -> Accept accept
    -> OpenAPIPetstoreRequest
         FakeOuterNumberSerialize contentType Double accept
    fakeOuterNumberSerialize ContentType contentType
    _  Accept accept
    _ =
      Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest
         FakeOuterNumberSerialize contentType Double accept
    forall req contentType res accept.
    Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest req contentType res accept
    _mkRequest Method
    "POST" [ByteString
    "/fake/outer/number"]

    data FakeOuterNumberSerialize

    -- | /Body Param/ "body" - Input number as post body
    instance HasBodyParam FakeOuterNumberSerialize BodyDouble

    -- | @*/*@
    instance MimeType mtype => Consumes FakeOuterNumberSerialize mtype

    -- | @*/*@
    instance MimeType mtype => Produces FakeOuterNumberSerialize mtype

    -- *** fakeOuterStringSerialize

    -- | @POST \/fake\/outer\/string@
    --
    -- Test serialization of outer string types
    --
    fakeOuterStringSerialize
      :: (Consumes FakeOuterStringSerialize contentType)
      => ContentType contentType -- ^ request content-type ('MimeType')
      -> Accept accept -- ^ request accept ('MimeType')
      -> OpenAPIPetstoreRequest FakeOuterStringSerialize contentType Text accept
    fakeOuterStringSerialize :: forall contentType accept.
    Consumes FakeOuterStringSerialize contentType =>
    ContentType contentType
    -> Accept accept
    -> OpenAPIPetstoreRequest
         FakeOuterStringSerialize contentType Text accept
    fakeOuterStringSerialize ContentType contentType
    _  Accept accept
    _ =
      Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest
         FakeOuterStringSerialize contentType Text accept
    forall req contentType res accept.
    Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest req contentType res accept
    _mkRequest Method
    "POST" [ByteString
    "/fake/outer/string"]

    data FakeOuterStringSerialize

    -- | /Body Param/ "body" - Input string as post body
    instance HasBodyParam FakeOuterStringSerialize BodyText

    -- | @*/*@
    instance MimeType mtype => Consumes FakeOuterStringSerialize mtype

    -- | @*/*@
    instance MimeType mtype => Produces FakeOuterStringSerialize mtype

    -- *** testBodyWithFileSchema

    -- | @PUT \/fake\/body-with-file-schema@
    --
    -- For this test, the body for this request much reference a schema named `File`.
    --
    testBodyWithFileSchema
      :: (Consumes TestBodyWithFileSchema MimeJSON, MimeRender MimeJSON FileSchemaTestClass)
      => FileSchemaTestClass -- ^ "body"
      -> OpenAPIPetstoreRequest TestBodyWithFileSchema MimeJSON NoContent MimeNoContent
    testBodyWithFileSchema :: (Consumes TestBodyWithFileSchema MimeJSON,
     MimeRender MimeJSON FileSchemaTestClass) =>
    FileSchemaTestClass
    -> OpenAPIPetstoreRequest
         TestBodyWithFileSchema MimeJSON NoContent MimeNoContent
    testBodyWithFileSchema FileSchemaTestClass
    body =
      Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest
         TestBodyWithFileSchema MimeJSON NoContent MimeNoContent
    forall req contentType res accept.
    Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest req contentType res accept
    _mkRequest Method
    "PUT" [ByteString
    "/fake/body-with-file-schema"]
        OpenAPIPetstoreRequest
      TestBodyWithFileSchema MimeJSON NoContent MimeNoContent
    -> FileSchemaTestClass
    -> OpenAPIPetstoreRequest
         TestBodyWithFileSchema MimeJSON NoContent MimeNoContent
    forall req param contentType res accept.
    (HasBodyParam req param, Consumes req contentType,
     MimeRender contentType param) =>
    OpenAPIPetstoreRequest req contentType res accept
    -> param -> OpenAPIPetstoreRequest req contentType res accept
    forall contentType res accept.
    (Consumes TestBodyWithFileSchema contentType,
     MimeRender contentType FileSchemaTestClass) =>
    OpenAPIPetstoreRequest
      TestBodyWithFileSchema contentType res accept
    -> FileSchemaTestClass
    -> OpenAPIPetstoreRequest
         TestBodyWithFileSchema contentType res accept
    `setBodyParam` FileSchemaTestClass
    body

    data TestBodyWithFileSchema
    instance HasBodyParam TestBodyWithFileSchema FileSchemaTestClass

    -- | @application/json@
    instance Consumes TestBodyWithFileSchema MimeJSON

    instance Produces TestBodyWithFileSchema MimeNoContent

    -- *** testBodyWithQueryParams

    -- | @PUT \/fake\/body-with-query-params@
    --
    testBodyWithQueryParams
      :: (Consumes TestBodyWithQueryParams MimeJSON, MimeRender MimeJSON User)
      => User -- ^ "body"
      -> Query -- ^ "query"
      -> OpenAPIPetstoreRequest TestBodyWithQueryParams MimeJSON NoContent MimeNoContent
    testBodyWithQueryParams :: (Consumes TestBodyWithQueryParams MimeJSON,
     MimeRender MimeJSON User) =>
    User
    -> Query
    -> OpenAPIPetstoreRequest
         TestBodyWithQueryParams MimeJSON NoContent MimeNoContent
    testBodyWithQueryParams User
    body (Query Text
    query) =
      Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest
         TestBodyWithQueryParams MimeJSON NoContent MimeNoContent
    forall req contentType res accept.
    Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest req contentType res accept
    _mkRequest Method
    "PUT" [ByteString
    "/fake/body-with-query-params"]
        OpenAPIPetstoreRequest
      TestBodyWithQueryParams MimeJSON NoContent MimeNoContent
    -> User
    -> OpenAPIPetstoreRequest
         TestBodyWithQueryParams MimeJSON NoContent MimeNoContent
    forall req param contentType res accept.
    (HasBodyParam req param, Consumes req contentType,
     MimeRender contentType param) =>
    OpenAPIPetstoreRequest req contentType res accept
    -> param -> OpenAPIPetstoreRequest req contentType res accept
    forall contentType res accept.
    (Consumes TestBodyWithQueryParams contentType,
     MimeRender contentType User) =>
    OpenAPIPetstoreRequest
      TestBodyWithQueryParams contentType res accept
    -> User
    -> OpenAPIPetstoreRequest
         TestBodyWithQueryParams contentType res accept
    `setBodyParam` User
    body
        OpenAPIPetstoreRequest
      TestBodyWithQueryParams MimeJSON NoContent MimeNoContent
    -> [QueryItem]
    -> OpenAPIPetstoreRequest
         TestBodyWithQueryParams MimeJSON NoContent MimeNoContent
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [QueryItem] -> OpenAPIPetstoreRequest req contentType res accept
    `addQuery` (Method, Maybe Text) -> [QueryItem]
    forall a. ToHttpApiData a => (Method, Maybe a) -> [QueryItem]
    toQuery (Method
    "query", Text -> Maybe Text
    forall a. a -> Maybe a
    Just Text
    query)

    data TestBodyWithQueryParams
    instance HasBodyParam TestBodyWithQueryParams User

    -- | @application/json@
    instance Consumes TestBodyWithQueryParams MimeJSON

    instance Produces TestBodyWithQueryParams MimeNoContent

    -- *** testClientModel

    -- | @PATCH \/fake@
    --
    -- To test \"client\" model
    --
    -- To test \"client\" model
    --
    testClientModel
      :: (Consumes TestClientModel MimeJSON, MimeRender MimeJSON Client)
      => Client -- ^ "body" -  client model
      -> OpenAPIPetstoreRequest TestClientModel MimeJSON Client MimeJSON
    testClientModel :: (Consumes TestClientModel MimeJSON, MimeRender MimeJSON Client) =>
    Client
    -> OpenAPIPetstoreRequest TestClientModel MimeJSON Client MimeJSON
    testClientModel Client
    body =
      Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest TestClientModel MimeJSON Client MimeJSON
    forall req contentType res accept.
    Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest req contentType res accept
    _mkRequest Method
    "PATCH" [ByteString
    "/fake"]
        OpenAPIPetstoreRequest TestClientModel MimeJSON Client MimeJSON
    -> Client
    -> OpenAPIPetstoreRequest TestClientModel MimeJSON Client MimeJSON
    forall req param contentType res accept.
    (HasBodyParam req param, Consumes req contentType,
     MimeRender contentType param) =>
    OpenAPIPetstoreRequest req contentType res accept
    -> param -> OpenAPIPetstoreRequest req contentType res accept
    forall contentType res accept.
    (Consumes TestClientModel contentType,
     MimeRender contentType Client) =>
    OpenAPIPetstoreRequest TestClientModel contentType res accept
    -> Client
    -> OpenAPIPetstoreRequest TestClientModel contentType res accept
    `setBodyParam` Client
    body

    data TestClientModel

    -- | /Body Param/ "body" - client model
    instance HasBodyParam TestClientModel Client

    -- | @application/json@
    instance Consumes TestClientModel MimeJSON

    -- | @application/json@
    instance Produces TestClientModel MimeJSON

    -- *** testEndpointParameters

    -- | @POST \/fake@
    --
    -- Fake endpoint for testing various parameters  假端點  偽のエンドポイント  가짜 엔드 포인트
    --
    -- Fake endpoint for testing various parameters  假端點  偽のエンドポイント  가짜 엔드 포인트
    --
    -- AuthMethod: 'AuthBasicHttpBasicTest'
    --
    testEndpointParameters
      :: (Consumes TestEndpointParameters MimeFormUrlEncoded)
      => Number -- ^ "number" -  None
      -> ParamDouble -- ^ "double" -  None
      -> PatternWithoutDelimiter -- ^ "patternWithoutDelimiter" -  None
      -> Byte -- ^ "byte" -  None
      -> OpenAPIPetstoreRequest TestEndpointParameters MimeFormUrlEncoded NoContent MimeNoContent
    testEndpointParameters :: Consumes TestEndpointParameters MimeFormUrlEncoded =>
    Number
    -> ParamDouble
    -> PatternWithoutDelimiter
    -> Byte
    -> OpenAPIPetstoreRequest
         TestEndpointParameters MimeFormUrlEncoded NoContent MimeNoContent
    testEndpointParameters (Number Double
    number) (ParamDouble Double
    double) (PatternWithoutDelimiter Text
    patternWithoutDelimiter) (Byte ByteArray
    byte) =
      Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest
         TestEndpointParameters MimeFormUrlEncoded NoContent MimeNoContent
    forall req contentType res accept.
    Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest req contentType res accept
    _mkRequest Method
    "POST" [ByteString
    "/fake"]
        OpenAPIPetstoreRequest
      TestEndpointParameters MimeFormUrlEncoded NoContent MimeNoContent
    -> Proxy AuthBasicHttpBasicTest
    -> OpenAPIPetstoreRequest
         TestEndpointParameters MimeFormUrlEncoded NoContent MimeNoContent
    forall authMethod req contentType res accept.
    AuthMethod authMethod =>
    OpenAPIPetstoreRequest req contentType res accept
    -> Proxy authMethod
    -> OpenAPIPetstoreRequest req contentType res accept
    `_hasAuthType` (Proxy AuthBasicHttpBasicTest
    forall {k} (t :: k). Proxy t
    P.Proxy :: P.Proxy AuthBasicHttpBasicTest)
        OpenAPIPetstoreRequest
      TestEndpointParameters MimeFormUrlEncoded NoContent MimeNoContent
    -> Form
    -> OpenAPIPetstoreRequest
         TestEndpointParameters MimeFormUrlEncoded NoContent MimeNoContent
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, Double) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "number", Double
    number)
        OpenAPIPetstoreRequest
      TestEndpointParameters MimeFormUrlEncoded NoContent MimeNoContent
    -> Form
    -> OpenAPIPetstoreRequest
         TestEndpointParameters MimeFormUrlEncoded NoContent MimeNoContent
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, Double) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "double", Double
    double)
        OpenAPIPetstoreRequest
      TestEndpointParameters MimeFormUrlEncoded NoContent MimeNoContent
    -> Form
    -> OpenAPIPetstoreRequest
         TestEndpointParameters MimeFormUrlEncoded NoContent MimeNoContent
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, Text) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "pattern_without_delimiter", Text
    patternWithoutDelimiter)
        OpenAPIPetstoreRequest
      TestEndpointParameters MimeFormUrlEncoded NoContent MimeNoContent
    -> Form
    -> OpenAPIPetstoreRequest
         TestEndpointParameters MimeFormUrlEncoded NoContent MimeNoContent
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, ByteArray) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "byte", ByteArray
    byte)

    data TestEndpointParameters

    -- | /Optional Param/ "integer" - None
    instance HasOptionalParam TestEndpointParameters ParamInteger where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> ParamInteger
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req (ParamInteger Int
    xs) =
        OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> Form
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, Int) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "integer", Int
    xs)

    -- | /Optional Param/ "int32" - None
    instance HasOptionalParam TestEndpointParameters Int32 where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> Int32
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req (Int32 Int
    xs) =
        OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> Form
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, Int) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "int32", Int
    xs)

    -- | /Optional Param/ "int64" - None
    instance HasOptionalParam TestEndpointParameters Int64 where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> Int64
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req (Int64 Integer
    xs) =
        OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> Form
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, Integer) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "int64", Integer
    xs)

    -- | /Optional Param/ "float" - None
    instance HasOptionalParam TestEndpointParameters ParamFloat where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> ParamFloat
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req (ParamFloat Float
    xs) =
        OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> Form
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, Float) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "float", Float
    xs)

    -- | /Optional Param/ "string" - None
    instance HasOptionalParam TestEndpointParameters ParamString where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> ParamString
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req (ParamString Text
    xs) =
        OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> Form
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, Text) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "string", Text
    xs)

    -- | /Optional Param/ "binary" - None
    instance HasOptionalParam TestEndpointParameters ParamBinary where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> ParamBinary
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req (ParamBinary FilePath
    xs) =
        OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> Part
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Part -> OpenAPIPetstoreRequest req contentType res accept
    `_addMultiFormPart` Text -> FilePath -> Part
    NH.partFileSource Text
    "binary" FilePath
    xs

    -- | /Optional Param/ "date" - None
    instance HasOptionalParam TestEndpointParameters ParamDate where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> ParamDate
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req (ParamDate Date
    xs) =
        OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> Form
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, Date) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "date", Date
    xs)

    -- | /Optional Param/ "dateTime" - None
    instance HasOptionalParam TestEndpointParameters ParamDateTime where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> ParamDateTime
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req (ParamDateTime DateTime
    xs) =
        OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> Form
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, DateTime) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "dateTime", DateTime
    xs)

    -- | /Optional Param/ "password" - None
    instance HasOptionalParam TestEndpointParameters Password where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> Password
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req (Password Text
    xs) =
        OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> Form
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, Text) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "password", Text
    xs)

    -- | /Optional Param/ "callback" - None
    instance HasOptionalParam TestEndpointParameters Callback where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> Callback
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req (Callback Text
    xs) =
        OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    req OpenAPIPetstoreRequest
      TestEndpointParameters contentType res accept
    -> Form
    -> OpenAPIPetstoreRequest
         TestEndpointParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, Text) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "callback", Text
    xs)

    -- | @application/x-www-form-urlencoded@
    instance Consumes TestEndpointParameters MimeFormUrlEncoded

    instance Produces TestEndpointParameters MimeNoContent

    -- *** testEnumParameters

    -- | @GET \/fake@
    --
    -- To test enum parameters
    --
    -- To test enum parameters
    --
    testEnumParameters
      :: (Consumes TestEnumParameters MimeFormUrlEncoded)
      => OpenAPIPetstoreRequest TestEnumParameters MimeFormUrlEncoded NoContent MimeNoContent
    testEnumParameters :: Consumes TestEnumParameters MimeFormUrlEncoded =>
    OpenAPIPetstoreRequest
      TestEnumParameters MimeFormUrlEncoded NoContent MimeNoContent
    testEnumParameters =
      Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest
         TestEnumParameters MimeFormUrlEncoded NoContent MimeNoContent
    forall req contentType res accept.
    Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest req contentType res accept
    _mkRequest Method
    "GET" [ByteString
    "/fake"]

    data TestEnumParameters

    -- | /Optional Param/ "enum_form_string_array" - Form parameter enum test (string array)
    instance HasOptionalParam TestEnumParameters EnumFormStringArray where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> EnumFormStringArray
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req (EnumFormStringArray [E'EnumFormStringArray]
    xs) =
        OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> Form
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` CollectionFormat -> (Method, [E'EnumFormStringArray]) -> Form
    forall v.
    ToHttpApiData v =>
    CollectionFormat -> (Method, [v]) -> Form
    toFormColl CollectionFormat
    CommaSeparated (Method
    "enum_form_string_array", [E'EnumFormStringArray]
    xs)

    -- | /Optional Param/ "enum_form_string" - Form parameter enum test (string)
    instance HasOptionalParam TestEnumParameters EnumFormString where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> EnumFormString
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req (EnumFormString E'EnumFormString
    xs) =
        OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> Form
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, E'EnumFormString) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "enum_form_string", E'EnumFormString
    xs)

    -- | /Optional Param/ "enum_header_string_array" - Header parameter enum test (string array)
    instance HasOptionalParam TestEnumParameters EnumHeaderStringArray where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> EnumHeaderStringArray
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req (EnumHeaderStringArray [E'EnumFormStringArray]
    xs) =
        OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> [Header]
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [Header] -> OpenAPIPetstoreRequest req contentType res accept
    `addHeader` CollectionFormat
    -> (HeaderName, [E'EnumFormStringArray]) -> [Header]
    forall a.
    ToHttpApiData a =>
    CollectionFormat -> (HeaderName, [a]) -> [Header]
    toHeaderColl CollectionFormat
    CommaSeparated (HeaderName
    "enum_header_string_array", [E'EnumFormStringArray]
    xs)

    -- | /Optional Param/ "enum_header_string" - Header parameter enum test (string)
    instance HasOptionalParam TestEnumParameters EnumHeaderString where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> EnumHeaderString
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req (EnumHeaderString E'EnumFormString
    xs) =
        OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> [Header]
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [Header] -> OpenAPIPetstoreRequest req contentType res accept
    `addHeader` (HeaderName, E'EnumFormString) -> [Header]
    forall a. ToHttpApiData a => (HeaderName, a) -> [Header]
    toHeader (HeaderName
    "enum_header_string", E'EnumFormString
    xs)

    -- | /Optional Param/ "enum_query_string_array" - Query parameter enum test (string array)
    instance HasOptionalParam TestEnumParameters EnumQueryStringArray where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> EnumQueryStringArray
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req (EnumQueryStringArray [E'EnumFormStringArray]
    xs) =
        OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> [QueryItem]
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [QueryItem] -> OpenAPIPetstoreRequest req contentType res accept
    `addQuery` CollectionFormat
    -> (Method, Maybe [E'EnumFormStringArray]) -> [QueryItem]
    forall a.
    ToHttpApiData a =>
    CollectionFormat -> (Method, Maybe [a]) -> [QueryItem]
    toQueryColl CollectionFormat
    CommaSeparated (Method
    "enum_query_string_array", [E'EnumFormStringArray] -> Maybe [E'EnumFormStringArray]
    forall a. a -> Maybe a
    Just [E'EnumFormStringArray]
    xs)

    -- | /Optional Param/ "enum_query_string" - Query parameter enum test (string)
    instance HasOptionalParam TestEnumParameters EnumQueryString where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> EnumQueryString
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req (EnumQueryString E'EnumFormString
    xs) =
        OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> [QueryItem]
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [QueryItem] -> OpenAPIPetstoreRequest req contentType res accept
    `addQuery` (Method, Maybe E'EnumFormString) -> [QueryItem]
    forall a. ToHttpApiData a => (Method, Maybe a) -> [QueryItem]
    toQuery (Method
    "enum_query_string", E'EnumFormString -> Maybe E'EnumFormString
    forall a. a -> Maybe a
    Just E'EnumFormString
    xs)

    -- | /Optional Param/ "enum_query_integer" - Query parameter enum test (double)
    instance HasOptionalParam TestEnumParameters EnumQueryInteger where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> EnumQueryInteger
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req (EnumQueryInteger E'EnumQueryInteger
    xs) =
        OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> [QueryItem]
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [QueryItem] -> OpenAPIPetstoreRequest req contentType res accept
    `addQuery` (Method, Maybe E'EnumQueryInteger) -> [QueryItem]
    forall a. ToHttpApiData a => (Method, Maybe a) -> [QueryItem]
    toQuery (Method
    "enum_query_integer", E'EnumQueryInteger -> Maybe E'EnumQueryInteger
    forall a. a -> Maybe a
    Just E'EnumQueryInteger
    xs)

    -- | /Optional Param/ "enum_query_double" - Query parameter enum test (double)
    instance HasOptionalParam TestEnumParameters EnumQueryDouble where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> EnumQueryDouble
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req (EnumQueryDouble E'EnumNumber
    xs) =
        OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    req OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    -> [QueryItem]
    -> OpenAPIPetstoreRequest TestEnumParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [QueryItem] -> OpenAPIPetstoreRequest req contentType res accept
    `addQuery` (Method, Maybe E'EnumNumber) -> [QueryItem]
    forall a. ToHttpApiData a => (Method, Maybe a) -> [QueryItem]
    toQuery (Method
    "enum_query_double", E'EnumNumber -> Maybe E'EnumNumber
    forall a. a -> Maybe a
    Just E'EnumNumber
    xs)

    -- | @application/x-www-form-urlencoded@
    instance Consumes TestEnumParameters MimeFormUrlEncoded

    instance Produces TestEnumParameters MimeNoContent

    -- *** testGroupParameters

    -- | @DELETE \/fake@
    --
    -- Fake endpoint to test group parameters (optional)
    --
    -- Fake endpoint to test group parameters (optional)
    --
    testGroupParameters
      :: RequiredStringGroup -- ^ "requiredStringGroup" -  Required String in group parameters
      -> RequiredBooleanGroup -- ^ "requiredBooleanGroup" -  Required Boolean in group parameters
      -> RequiredInt64Group -- ^ "requiredInt64Group" -  Required Integer in group parameters
      -> OpenAPIPetstoreRequest TestGroupParameters MimeNoContent NoContent MimeNoContent
    testGroupParameters :: RequiredStringGroup
    -> RequiredBooleanGroup
    -> RequiredInt64Group
    -> OpenAPIPetstoreRequest
         TestGroupParameters MimeNoContent NoContent MimeNoContent
    testGroupParameters (RequiredStringGroup Int
    requiredStringGroup) (RequiredBooleanGroup Bool
    requiredBooleanGroup) (RequiredInt64Group Integer
    requiredInt64Group) =
      Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest
         TestGroupParameters MimeNoContent NoContent MimeNoContent
    forall req contentType res accept.
    Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest req contentType res accept
    _mkRequest Method
    "DELETE" [ByteString
    "/fake"]
        OpenAPIPetstoreRequest
      TestGroupParameters MimeNoContent NoContent MimeNoContent
    -> [QueryItem]
    -> OpenAPIPetstoreRequest
         TestGroupParameters MimeNoContent NoContent MimeNoContent
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [QueryItem] -> OpenAPIPetstoreRequest req contentType res accept
    `addQuery` (Method, Maybe Int) -> [QueryItem]
    forall a. ToHttpApiData a => (Method, Maybe a) -> [QueryItem]
    toQuery (Method
    "required_string_group", Int -> Maybe Int
    forall a. a -> Maybe a
    Just Int
    requiredStringGroup)
        OpenAPIPetstoreRequest
      TestGroupParameters MimeNoContent NoContent MimeNoContent
    -> [Header]
    -> OpenAPIPetstoreRequest
         TestGroupParameters MimeNoContent NoContent MimeNoContent
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [Header] -> OpenAPIPetstoreRequest req contentType res accept
    `addHeader` (HeaderName, Bool) -> [Header]
    forall a. ToHttpApiData a => (HeaderName, a) -> [Header]
    toHeader (HeaderName
    "required_boolean_group", Bool
    requiredBooleanGroup)
        OpenAPIPetstoreRequest
      TestGroupParameters MimeNoContent NoContent MimeNoContent
    -> [QueryItem]
    -> OpenAPIPetstoreRequest
         TestGroupParameters MimeNoContent NoContent MimeNoContent
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [QueryItem] -> OpenAPIPetstoreRequest req contentType res accept
    `addQuery` (Method, Maybe Integer) -> [QueryItem]
    forall a. ToHttpApiData a => (Method, Maybe a) -> [QueryItem]
    toQuery (Method
    "required_int64_group", Integer -> Maybe Integer
    forall a. a -> Maybe a
    Just Integer
    requiredInt64Group)

    data TestGroupParameters

    -- | /Optional Param/ "string_group" - String in group parameters
    instance HasOptionalParam TestGroupParameters StringGroup where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest TestGroupParameters contentType res accept
    -> StringGroup
    -> OpenAPIPetstoreRequest
         TestGroupParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest TestGroupParameters contentType res accept
    req (StringGroup Int
    xs) =
        OpenAPIPetstoreRequest TestGroupParameters contentType res accept
    req OpenAPIPetstoreRequest TestGroupParameters contentType res accept
    -> [QueryItem]
    -> OpenAPIPetstoreRequest
         TestGroupParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [QueryItem] -> OpenAPIPetstoreRequest req contentType res accept
    `addQuery` (Method, Maybe Int) -> [QueryItem]
    forall a. ToHttpApiData a => (Method, Maybe a) -> [QueryItem]
    toQuery (Method
    "string_group", Int -> Maybe Int
    forall a. a -> Maybe a
    Just Int
    xs)

    -- | /Optional Param/ "boolean_group" - Boolean in group parameters
    instance HasOptionalParam TestGroupParameters BooleanGroup where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest TestGroupParameters contentType res accept
    -> BooleanGroup
    -> OpenAPIPetstoreRequest
         TestGroupParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest TestGroupParameters contentType res accept
    req (BooleanGroup Bool
    xs) =
        OpenAPIPetstoreRequest TestGroupParameters contentType res accept
    req OpenAPIPetstoreRequest TestGroupParameters contentType res accept
    -> [Header]
    -> OpenAPIPetstoreRequest
         TestGroupParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [Header] -> OpenAPIPetstoreRequest req contentType res accept
    `addHeader` (HeaderName, Bool) -> [Header]
    forall a. ToHttpApiData a => (HeaderName, a) -> [Header]
    toHeader (HeaderName
    "boolean_group", Bool
    xs)

    -- | /Optional Param/ "int64_group" - Integer in group parameters
    instance HasOptionalParam TestGroupParameters Int64Group where
      applyOptionalParam :: forall contentType res accept.
    OpenAPIPetstoreRequest TestGroupParameters contentType res accept
    -> Int64Group
    -> OpenAPIPetstoreRequest
         TestGroupParameters contentType res accept
    applyOptionalParam OpenAPIPetstoreRequest TestGroupParameters contentType res accept
    req (Int64Group Integer
    xs) =
        OpenAPIPetstoreRequest TestGroupParameters contentType res accept
    req OpenAPIPetstoreRequest TestGroupParameters contentType res accept
    -> [QueryItem]
    -> OpenAPIPetstoreRequest
         TestGroupParameters contentType res accept
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [QueryItem] -> OpenAPIPetstoreRequest req contentType res accept
    `addQuery` (Method, Maybe Integer) -> [QueryItem]
    forall a. ToHttpApiData a => (Method, Maybe a) -> [QueryItem]
    toQuery (Method
    "int64_group", Integer -> Maybe Integer
    forall a. a -> Maybe a
    Just Integer
    xs)
    instance Produces TestGroupParameters MimeNoContent

    -- *** testInlineAdditionalProperties

    -- | @POST \/fake\/inline-additionalProperties@
    --
    -- test inline additionalProperties
    --
    testInlineAdditionalProperties
      :: (Consumes TestInlineAdditionalProperties MimeJSON, MimeRender MimeJSON ParamMapMapStringText)
      => ParamMapMapStringText -- ^ "param" -  request body
      -> OpenAPIPetstoreRequest TestInlineAdditionalProperties MimeJSON NoContent MimeNoContent
    testInlineAdditionalProperties :: (Consumes TestInlineAdditionalProperties MimeJSON,
     MimeRender MimeJSON ParamMapMapStringText) =>
    ParamMapMapStringText
    -> OpenAPIPetstoreRequest
         TestInlineAdditionalProperties MimeJSON NoContent MimeNoContent
    testInlineAdditionalProperties ParamMapMapStringText
    param =
      Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest
         TestInlineAdditionalProperties MimeJSON NoContent MimeNoContent
    forall req contentType res accept.
    Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest req contentType res accept
    _mkRequest Method
    "POST" [ByteString
    "/fake/inline-additionalProperties"]
        OpenAPIPetstoreRequest
      TestInlineAdditionalProperties MimeJSON NoContent MimeNoContent
    -> ParamMapMapStringText
    -> OpenAPIPetstoreRequest
         TestInlineAdditionalProperties MimeJSON NoContent MimeNoContent
    forall req param contentType res accept.
    (HasBodyParam req param, Consumes req contentType,
     MimeRender contentType param) =>
    OpenAPIPetstoreRequest req contentType res accept
    -> param -> OpenAPIPetstoreRequest req contentType res accept
    forall contentType res accept.
    (Consumes TestInlineAdditionalProperties contentType,
     MimeRender contentType ParamMapMapStringText) =>
    OpenAPIPetstoreRequest
      TestInlineAdditionalProperties contentType res accept
    -> ParamMapMapStringText
    -> OpenAPIPetstoreRequest
         TestInlineAdditionalProperties contentType res accept
    `setBodyParam` ParamMapMapStringText
    param

    data TestInlineAdditionalProperties

    -- | /Body Param/ "param" - request body
    instance HasBodyParam TestInlineAdditionalProperties ParamMapMapStringText

    -- | @application/json@
    instance Consumes TestInlineAdditionalProperties MimeJSON

    instance Produces TestInlineAdditionalProperties MimeNoContent

    -- *** testJsonFormData

    -- | @GET \/fake\/jsonFormData@
    --
    -- test json serialization of form data
    --
    testJsonFormData
      :: (Consumes TestJsonFormData MimeFormUrlEncoded)
      => Param -- ^ "param" -  field1
      -> Param2 -- ^ "param2" -  field2
      -> OpenAPIPetstoreRequest TestJsonFormData MimeFormUrlEncoded NoContent MimeNoContent
    testJsonFormData :: Consumes TestJsonFormData MimeFormUrlEncoded =>
    Param
    -> Param2
    -> OpenAPIPetstoreRequest
         TestJsonFormData MimeFormUrlEncoded NoContent MimeNoContent
    testJsonFormData (Param Text
    param) (Param2 Text
    param2) =
      Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest
         TestJsonFormData MimeFormUrlEncoded NoContent MimeNoContent
    forall req contentType res accept.
    Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest req contentType res accept
    _mkRequest Method
    "GET" [ByteString
    "/fake/jsonFormData"]
        OpenAPIPetstoreRequest
      TestJsonFormData MimeFormUrlEncoded NoContent MimeNoContent
    -> Form
    -> OpenAPIPetstoreRequest
         TestJsonFormData MimeFormUrlEncoded NoContent MimeNoContent
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, Text) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "param", Text
    param)
        OpenAPIPetstoreRequest
      TestJsonFormData MimeFormUrlEncoded NoContent MimeNoContent
    -> Form
    -> OpenAPIPetstoreRequest
         TestJsonFormData MimeFormUrlEncoded NoContent MimeNoContent
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> Form -> OpenAPIPetstoreRequest req contentType res accept
    `addForm` (Method, Text) -> Form
    forall v. ToHttpApiData v => (Method, v) -> Form
    toForm (Method
    "param2", Text
    param2)

    data TestJsonFormData

    -- | @application/x-www-form-urlencoded@
    instance Consumes TestJsonFormData MimeFormUrlEncoded

    instance Produces TestJsonFormData MimeNoContent

    -- *** testQueryParameterCollectionFormat

    -- | @PUT \/fake\/test-query-parameters@
    --
    -- To test the collection format in query parameters
    --
    testQueryParameterCollectionFormat
      :: Pipe -- ^ "pipe"
      -> Ioutil -- ^ "ioutil"
      -> Http -- ^ "http"
      -> Url -- ^ "url"
      -> Context -- ^ "context"
      -> OpenAPIPetstoreRequest TestQueryParameterCollectionFormat MimeNoContent NoContent MimeNoContent
    testQueryParameterCollectionFormat :: Pipe
    -> Ioutil
    -> Http
    -> Url
    -> Context
    -> OpenAPIPetstoreRequest
         TestQueryParameterCollectionFormat
         MimeNoContent
         NoContent
         MimeNoContent
    testQueryParameterCollectionFormat (Pipe [Text]
    pipe) (Ioutil [Text]
    ioutil) (Http [Text]
    http) (Url [Text]
    url) (Context [Text]
    context) =
      Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest
         TestQueryParameterCollectionFormat
         MimeNoContent
         NoContent
         MimeNoContent
    forall req contentType res accept.
    Method
    -> [ByteString]
    -> OpenAPIPetstoreRequest req contentType res accept
    _mkRequest Method
    "PUT" [ByteString
    "/fake/test-query-parameters"]
        OpenAPIPetstoreRequest
      TestQueryParameterCollectionFormat
      MimeNoContent
      NoContent
      MimeNoContent
    -> [QueryItem]
    -> OpenAPIPetstoreRequest
         TestQueryParameterCollectionFormat
         MimeNoContent
         NoContent
         MimeNoContent
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [QueryItem] -> OpenAPIPetstoreRequest req contentType res accept
    `addQuery` CollectionFormat -> (Method, Maybe [Text]) -> [QueryItem]
    forall a.
    ToHttpApiData a =>
    CollectionFormat -> (Method, Maybe [a]) -> [QueryItem]
    toQueryColl CollectionFormat
    CommaSeparated (Method
    "pipe", [Text] -> Maybe [Text]
    forall a. a -> Maybe a
    Just [Text]
    pipe)
        OpenAPIPetstoreRequest
      TestQueryParameterCollectionFormat
      MimeNoContent
      NoContent
      MimeNoContent
    -> [QueryItem]
    -> OpenAPIPetstoreRequest
         TestQueryParameterCollectionFormat
         MimeNoContent
         NoContent
         MimeNoContent
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [QueryItem] -> OpenAPIPetstoreRequest req contentType res accept
    `addQuery` CollectionFormat -> (Method, Maybe [Text]) -> [QueryItem]
    forall a.
    ToHttpApiData a =>
    CollectionFormat -> (Method, Maybe [a]) -> [QueryItem]
    toQueryColl CollectionFormat
    CommaSeparated (Method
    "ioutil", [Text] -> Maybe [Text]
    forall a. a -> Maybe a
    Just [Text]
    ioutil)
        OpenAPIPetstoreRequest
      TestQueryParameterCollectionFormat
      MimeNoContent
      NoContent
      MimeNoContent
    -> [QueryItem]
    -> OpenAPIPetstoreRequest
         TestQueryParameterCollectionFormat
         MimeNoContent
         NoContent
         MimeNoContent
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [QueryItem] -> OpenAPIPetstoreRequest req contentType res accept
    `addQuery` CollectionFormat -> (Method, Maybe [Text]) -> [QueryItem]
    forall a.
    ToHttpApiData a =>
    CollectionFormat -> (Method, Maybe [a]) -> [QueryItem]
    toQueryColl CollectionFormat
    SpaceSeparated (Method
    "http", [Text] -> Maybe [Text]
    forall a. a -> Maybe a
    Just [Text]
    http)
        OpenAPIPetstoreRequest
      TestQueryParameterCollectionFormat
      MimeNoContent
      NoContent
      MimeNoContent
    -> [QueryItem]
    -> OpenAPIPetstoreRequest
         TestQueryParameterCollectionFormat
         MimeNoContent
         NoContent
         MimeNoContent
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [QueryItem] -> OpenAPIPetstoreRequest req contentType res accept
    `addQuery` CollectionFormat -> (Method, Maybe [Text]) -> [QueryItem]
    forall a.
    ToHttpApiData a =>
    CollectionFormat -> (Method, Maybe [a]) -> [QueryItem]
    toQueryColl CollectionFormat
    CommaSeparated (Method
    "url", [Text] -> Maybe [Text]
    forall a. a -> Maybe a
    Just [Text]
    url)
        OpenAPIPetstoreRequest
      TestQueryParameterCollectionFormat
      MimeNoContent
      NoContent
      MimeNoContent
    -> [QueryItem]
    -> OpenAPIPetstoreRequest
         TestQueryParameterCollectionFormat
         MimeNoContent
         NoContent
         MimeNoContent
    forall req contentType res accept.
    OpenAPIPetstoreRequest req contentType res accept
    -> [QueryItem] -> OpenAPIPetstoreRequest req contentType res accept
    `addQuery` CollectionFormat -> (Method, Maybe [Text]) -> [QueryItem]
    forall a.
    ToHttpApiData a =>
    CollectionFormat -> (Method, Maybe [a]) -> [QueryItem]
    toQueryColl CollectionFormat
    MultiParamArray (Method
    "context", [Text] -> Maybe [Text]
    forall a. a -> Maybe a
    Just [Text]
    context)

    data TestQueryParameterCollectionFormat
    instance Produces TestQueryParameterCollectionFormat MimeNoContent