servant-kotlin-0.1.1.0: Automatically derive Kotlin class to query servant webservices

Safe HaskellNone
LanguageHaskell2010

Servant.Kotlin.Internal.Generate

Synopsis

Documentation

generateKotlinForAPI :: (HasForeign LangKotlin KotlinClass api, GenerateList KotlinClass (Foreign KotlinClass api)) => Proxy api -> [Text] Source #

Generate Kotlin code for the API with default options. Returns a list of Kotlin functions to query your Servant API from Kotlin.

generateKotlinForAPIWith :: (HasForeign LangKotlin KotlinClass api, GenerateList KotlinClass (Foreign KotlinClass api)) => KotlinOptions -> Proxy api -> [Text] Source #

Generate Kotlin code for the API with custom options.

data KotlinOptions Source #

Options to configure how code is generated.

Constructors

KotlinOptions 

Fields

defKotlinOptions :: KotlinOptions Source #

Default options for generating Kotlin code. The default options are: > { urlPrefix = Static "" > , emptyResponseKotlinTypes = [ toKotlinType NoContent ] > , stringKotlinTypes = [ toKotlinType "" ] > }

data UrlPrefix Source #

Constructors

Static Text 
Dynamic