Hi! I'd like to add here the servant-queryparam (ex - named-servant) family of libraries.
These libraries add support for QueryParams as records or named parameters.
What I changed:
added a type family for modification of fields of query parameter records. Here's an example.
renamed the packages: named-servant -> servant-queryparam-core, etc.
I first used a modified version of the symbols package that I provided using a Nix flake.
I later moved the type family from https://github.com/kcsongor/symbols/pull/4 to servant-named-core.
So, technically, a flake is not necessary to build servant-named, but it can improve the build time.
Example
servant-named-server provides an example of constructing an OpenAPI3 specification for an API with query parameters.
To run the example, run nix develop -c cabal run servant-named-server:exe:example.
Hi! I'd like to add here the
servant-queryparam
(ex - named-servant) family of libraries. These libraries add support forQueryParam
s as records or named parameters.What I changed:
named-servant
->servant-queryparam-core
, etc.I first used a modified version of the
symbols
package that I provided using a Nix flake. I later moved the type family from https://github.com/kcsongor/symbols/pull/4 toservant-named-core
. So, technically, a flake is not necessary to buildservant-named
, but it can improve the build time.Example
servant-named-server
provides an example of constructing an OpenAPI3 specification for an API with query parameters.To run the example, run
nix develop -c cabal run servant-named-server:exe:example
.The output should look like