File tree Expand file tree Collapse file tree 1 file changed +39
-0
lines changed
src/routes/changelog/(entries) Expand file tree Collapse file tree 1 file changed +39
-0
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ layout: changelog
3+ title: "GraphQL schema is now public"
4+ date: 2026-02-02
5+ ---
6+
7+ You can now run introspection queries on Appwrite's GraphQL API. With introspection enabled, you get:
8+
9+ - **IDE autocomplete** for queries, mutations, and fields
10+ - **Schema exploration** using tools like GraphQL Playground, Insomnia, or Postman
11+ - **Type generation** for strongly-typed clients in your preferred language
12+
13+ Here's how to fetch the schema using the Appwrite SDK:
14+
15+ ```client-web
16+ import { Client, Graphql } from "appwrite";
17+
18+ const client = new Client()
19+ .setEndpoint('https://<REGION>.cloud.appwrite.io/v1')
20+ .setProject('<PROJECT_ID>');
21+
22+ const graphql = new Graphql(client);
23+
24+ const schema = await graphql.query({
25+ query: `{
26+ __schema {
27+ types { name }
28+ queryType { fields { name } }
29+ mutationType { fields { name } }
30+ }
31+ }`
32+ });
33+
34+ console.log(schema.data);
35+ ```
36+
37+ {% arrow_link href="/docs/apis/graphql" %}
38+ Learn more about Appwrite's GraphQL API
39+ {% /arrow_link %}
You can’t perform that action at this time.
0 commit comments