Haskell GraphQL implementation

Latest on Hackage:0.3

This package is not currently in any snapshots. If you're interested in using it, we recommend adding it to Stackage Nightly. Doing so will make builds more reliable, and allow to host generated Haddocks.

BSD3 licensed by Danny Navarro
Maintained by

Haskell GraphQL

Hackage Version Build Status

For now this only provides the data types to represent the GraphQL AST, but the idea is to be a Haskell port of graphql-js. Next releases should include:

  • [x] GraphQL AST
  • [x] Parser for the GraphQL language. See TODO for limitations.
  • [x] Printer for GraphQL. This is not pretty yet.
  • [ ] GraphQL Schema AST.
  • [ ] Parser for the GraphQL Schema language.
  • [ ] Printer for the GraphQL Schema language.
  • [ ] Interpreter of GraphQL requests.
  • [ ] Utilities to define GraphQL types and schema.

See the TODO file for more concrete tasks.


Suggestions, contributions and bug reports are welcome.

Feel free to contact on Slack in #haskell on GraphQL. You can obtain an invitation here.


Change Log

All notable changes to this project will be documented in this file.

0.3 - 2015-09-22


  • Exact match numeric types to spec.
  • Names follow now the spec.
  • AST slightly different for better readability or easier parsing.
  • Replace golden test for test to validate parsing/encoding.


  • Parsing errors in all cases where Alternative is used.
  • GraphQL encoder.


  • Expect braces inputValueDefinitions instead of parens when parsing.

0.2.1 - 2015-09-16


  • Include data files for golden tests in Cabal package.
  • Support for ghc-7.8.

0.2 - 2015-09-14


  • Rudimentary parser for GraphQL which successfully parses the sample file kitchen-sink.graphql from graphql-js tests.
  • Golden test for kitchen-sink.grahql parsing.


  • Many optional data types in GraphQl didn't need to be wrapped in a Maybe.
  • Some newtypes became type synonyms for easier parsing.

0.1 - 2015-09-12


  • Data types for the GraphQL language.

Depends on 3 packages:
Used by 1 package:
comments powered byDisqus