Table of Contents
- Clone URL: git://caraus.tech/pub/graphql.git
GraphQL implementation in Haskell
This is the core library that provides:
- Parser for the query and schema languages, as well as a printer for the query language (minimizer and pretty-printer).
- Data structures to define a type system.
- Executor (queries, mutations and subscriptions are supported).
- Validation.
- Introspection is work in progress.
For a more precise list of currently missing features and known limitations see issues.
GHC 9 and Aeson 2
Since JSON serialization support is not mandatory for GraphQL itself, current version optionally supports only Aeson 1. Aeson 2 support is provided by a companion library, graphql-spice. Aeson 1 build supports GHC 8, Aeson 2 build - GHC 9. The default build currently uses GHC 8 and Aeson 1, this will change soon, so GHC9 and Aeson 2 (with graphql-spice) build will be the default.
The version built can be changed with json
flag passed to cabal. Run cabal build --flag=+json
to build the old verison, or --flag=-json
for the new one. --flag
also works with other cabal commands like test
. To choose the appropriate build in a project, cabal.project
with the following contents can be used:
packages: .
constraints: graphql -jso
Documentation
API documentation is available through Hackage.
Further documentation will be made available in the Wiki.