Connecting backends with custom directives
Create a GraphQL API for any backend in a few lines of code using the
@rest
, @dbquery
, and @graphql
custom directives.
Start with an application view of the API, and use the API Connect for GraphQL custom GraphQL directives
(@rest
, @dbquery
, and @graphql
) to connect and
configure the backend. With a few lines of declarative code, you have a working schema.
Tip: An alternative method of creating the schema is to use the
stepzen
import
CLI command as explained in the "Generate a GraphQL schema with the CLI" section in
Creating a
schema.Use the custom GraphQL directives to connect the following backend data sources:
- REST
- SOAP/XML
- GraphQL API
- MySQL database
- PostgreSQL database
- MSSQL database
- Snowflake database
- Multiple backends of the same type
In addition, you can build a graph of graphs
with the @materializer
directive, and manage backend connections.