Wix GraphQL API

 

Developer Preview - This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.
 

The Wix GraphQL API exposes Wix REST APIs as a single unified GraphQL schema, allowing you to query and mutate data from the Wix Platform with all the benefits of GraphQL.

🐣 New to GraphQL? Check out the GraphQL Documentation to learn more.

The Wix SDK allows you to consume the Wix GraphQL API easily, with built-in support for authentication, type inference and more.

Usage

📚 For the full documentation and API reference for the Wix GraphQL API, visit the Wix GraphQL API Documentation.

An initialized WixClient exposes a graphql function that can be used to query and mutate data from the Wix GraphQL API. The graphql function accepts a GraphQL query or mutation and returns a Promise that resolves to the result of the query or mutation.

Copy
1

Type Inference

The graphql function also supports type inference for the result and variables of a GrahphQL query. If you are using a solution for type inference in your project (such as GraphQL Code Generator) you can pass the inferred types to the graphql function and it will use them to type the result and variables of the query.

Copy
1
Was this helpful?
Yes
No