Skip to main content

Schema

API reference

A GraphQL introspection schema that can be inspected and merged.

Implements Node

contents: JSON!

Serialize the schema back to introspection JSON.

id: ID!

A unique identifier for this Schema.

merge(moduleTypes: JSON!, moduleName: String!): Schema!

Merge a module's introspection-shaped type definitions into the schema, returning the combined schema.

moduleTypes: JSON!

Introspection JSON describing the types the module defines. Object, interface and enum types are appended to the schema, and a constructor field for the module is added to the Query type.

moduleName: String!

The name of the module whose types are being merged. Used to stamp the @sourceMap directive and to derive the module's constructor field.

References

Returned by

Accepted as an argument by