acolyte-codegen
Safe HaskellNone
LanguageGHC2024

Acolyte.Codegen.Emit

Description

Haskell code generation from the API IR.

Produces a complete Haskell module with: * Path types using GHC.TypeLits * Requestresponse data types with FromJSONToJSON * The API type as a promoted list * Requires Auth on secured endpoints

Synopsis

Documentation

emitModule :: EmitConfig -> ApiIR -> Text Source #

Generate a complete Haskell module from an API IR.

data EmitConfig Source #

Configuration for code emission.

Constructors

EmitConfig 

Fields

Instances

Instances details
Show EmitConfig Source # 
Instance details

Defined in Acolyte.Codegen.Emit

defaultEmitConfig :: EmitConfig Source #

Default emit configuration: module name Generated.API with handler stubs enabled.