GraphQL has enabled thousands of users to take advantage of Fauna's globally distributed, ACID compliant database using a query language that is familiar to them. To help more users adopt Fauna quickly we’re releasing two resources to help our users on-board with Fauna using GraphQL: our new GraphQL workshop
and an update to our GraphQL documentation
based on user feedback.
How customers reduce time to market using Fauna + GraphQL
We’ve seen customers use Fauna purely via GraphQL or combine GraphQL and Fauna Query Language (FQL) to perform complex business logic in their data layers. Customers that are familiar with GraphQL can quickly execute CRUD functions by importing their GraphQL schema to Fauna out-of-the-box. If they’re familiar with GraphQL but need to execute business logic more complex than CRUD on their data, they can create user-defined functions
(UDFs) with FQL and still call those functions using GraphQL.
Increased development velocity at ZXDigital
ZXDigital is a digital publisher based out of the UK that uses Fauna via our GraphQL API. Their primary application NetVoucherCodes
collects discount codes from online retailers and makes them available to their customers. During a recent digital transformation effort, ZXDigital chose Fauna because they needed a document database that could provide access to data via an API and integrate well with Next.js and Vercel. ZXDigital increased their development velocity by adopting technologies across their stack that didn’t require administration of servers – like Fauna. They also benefited from being able to upload their GraphQL schemas to Fauna and see that Fauna not only imported the schema’s mutations, queries, and collections but gave them the ability to perform CRUD operations on this data out-of-the-box.
Complex data manipulation with simple GraphQL calls at Dhamira
We have also seen developers interface with Fauna via our GraphQL API to tackle use cases we never expected. Digitalax is a digital fashion NFT marketplace that leverages technologies
like Ethereum, Polygon, and The Graph alongside Fauna. They use Fauna as their off-chain datastore
to store any sensitive user data that shouldn’t be on a public ledger like Ethereum, along with other metadata. Developer tools in the blockchain ecosystem heavily leverage GraphQL to query data – Fauna’s GraphQL API has made it a popular choice
for decentralized applications (dApps) looking for an off-chain datastore.
Users familiar with GraphQL can use our GraphQL API to interface directly with Fauna’s Databases. They can build functions in Fauna using FQL, and call them using resolvers in GraphQL. Users comfortable with FQL can create all their functions using FQL and call them using Fauna’s language specific drivers.
What’s next for our GraphQL API?
We released our GraphQL API
in 2019. The motivations to do so were two-fold:
our users were using GraphQL in their architectures, and because GraphQL combined with Fauna brought our users powerful new functionality. We are committed to continuing to build functionality into our GraphQL API and make it easier for teams of developers to use GraphQL and FQL together when working with Fauna. Together they enable customers to encode their business logic, separate their application front ends from their back ends and ultimately iterate and release their applications to market even quicker with more confidence.
We're excited to soon GA Partial Update Mutations
in our GraphQL API, so you can confidently use it in production. Soon after, we’ll release the ability to persist autoresolvers to UDFs – enabling you to save FQL translations our GraphQL API uses to then automatically turn your GraphQL queries into Fauna UDFs. This feature continues our effort in enabling any user who comes to Fauna that is familiar with GraphQL to take full advantage of Fauna’s features.
As we continue to build features into our GraphQL API to make it easier and more powerful for you to interact with Fauna, we’re also looking at partnering with GraphQL middleware providers (i.e. Apollo and Hasura) in the future to provide out-of-the-box integrations. Fauna’s GraphQL API will be an interface to Fauna, and Fauna alone – we are not trying to provide a GraphQL abstraction across multiple DBs, APIs, SaaS services like Apollo and Hasura.
If you haven’t used Fauna before, signup here
to create a database
, import your GraphQL schema and integrate Fauna into your applications! If you have any feedback on features you’d like to see in our GraphQL API or middleware partners you’d like to see us partner with please drop us a line on our Discord community