Skip to content

Importing a GraphQL schema

Restorm imports a GraphQL schema in SDL — the text format, the one in .graphql and .gql files.

File ▸ Import (Ctrl+I) then the schema file. Pasted content works too: Restorm recognises an SDL by the presence of type Query, type Mutation or schema {.

The tree produced by importing a GraphQL schema: a "GraphQL API" environment folder, a Queries folder and a Mutations folder, with one GQL request per root field

ElementWhat Restorm makes of it
Root typesOne folder per operation type (Query, Mutation, Subscription)
Each root fieldA GraphQL request with its operationType
ArgumentsOperation variables pre-filled with placeholder values
Descriptions and typesThe API documentation
enumEnumerations reusable as a value type

GraphQL is one of the re-syncable formats (if the schema was imported from a URL): the folder’s Refresh button fetches the source and Restorm applies the delta. See Updating from the source.