06 / 10

What are object types?

The most basic components of a GraphQL schema are object types, which just represent a kind of object you can fetch from your service, and what fields it has.

  1. 1

    Most of the types you define in a GraphQL schema are object types.

  2. 2

    An object type contains a collection of fields, each of which has its own type.

Two object types can include each other as fields, as is the case in our example schema from earlier: