Skip to content
Back to Changelog

GraphQL schema is now public

You can now run introspection queries on Appwrite's GraphQL API. With introspection enabled, you get:

  • IDE autocomplete for queries, mutations, and fields
  • Schema exploration using tools like GraphQL Playground, Insomnia, or Postman
  • Type generation for strongly-typed clients in your preferred language

Here's how to fetch the schema using the Appwrite SDK:

Web
import { Client, Graphql } from "appwrite";

const client = new Client()
    .setEndpoint('https://<REGION>.cloud.appwrite.io/v1')
    .setProject('<PROJECT_ID>');

const graphql = new Graphql(client);

const schema = await graphql.query({
    query: `{
        __schema {
            types { name }
            queryType { fields { name } }
            mutationType { fields { name } }
        }
    }`
});

console.log(schema.data);

Learn more about Appwrite's GraphQL API

Start building with Appwrite today

Get started

Our plans

  • Free

    $0

    A great fit for passion projects and small applications.

    Get started
  • Pro

    Most popular
    From
    $25
    /month

    For production applications that need powerful functionality and resources to scale.

    Start building
  • Enterprise

    Custom

    For enterprises that need more power and premium support.

    Contact us