EdgeDB supports GraphQL queries natively out of the box. Not everything that can be expressed in EdgeQL can easily be queried using GraphQL, but generally setting up aliases for complex expressions makes it possible to then use use GraphQL to query them.
EdgeDB exposes the Types and Aliases for GraphQL
querying. Types and expression aliases from the
default module are
exposed using their short names, whereas items from another module use
the module name as a prefix.
In order to set up GraphQL access to the database add the following to the schema:
using extension graphql;
expose GraphQL API. Check the credentials file for your instance at
<edgedb_config_dir>/credentials to find out which port the instance is
edgedb info to see the path to
<edgedb_config_dir> on your
will bring up a GraphiQL interface to EdgeDB. This interface can be
used to try out queries and explore the GraphQL capabilities.