Introspection in GraphQL

Introspection is the ability to query which resources are available in the current API schema. Given the API, via introspection, we can see the queries, types, fields, and directives it supports.

__Schema

Schema type definition

__type

GraphiQL querying the type of the User using Github API v4 (Try it!)

__typename

GraphQL supports type name introspection at any point within a query by using the meta‐field __typename: String! when querying against any Object, Interface, or Union. It returns the name of the object type currently being queried.

Deprecations

GraphiQL querying the type of the Organization using Github API v4 (Try it!)
GraphQL Voyager using Shopify Storefront API

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store