Skip to main content

Schema

Relations Overview

The schema above highlights the relations between the different objects. To learn about how to query this data, see the individual object references: Assets, Providers, Validators, Reward Options and Metrics.

Relations

Reward Options

Reward Options are the core and center of the API.
Each Reward Option is related to an Asset Validator Chain and Provider
The mental model is to start the queries with Reward Options and try to get the data via those.

Each Reward Option has a list of Assets that can be a direct input for that Reward Option or an output as a kind of "certificate"

Examples:

  • you deposit ETH into Lido, you get stETH
  • you deposit stETH into Curve and you get CRV
  • you send ETH to the WETH contract and you get WETH

Assets are only connected to Reward Options and not to Validators, Chains, or Providers.

For more information, see the Reward Options reference.

Metrics

Metrics are connected to Assets, Reward Options, Providers and Validators.
They are being used to store individual data about these Objects.

For more information, see the Metrics reference.

Assets

Assets are only connected to Reward Options, Metrics, and other Assets - not to Validators or Providers.
This is because Assets are only relevant for the Reward Options and Metrics, and not for the Validators** or Provider.

To get information about Providers or Validators related to an Asset, you need to query the Reward Options first.

For more information, see the Assets reference.

Validators

Validators are only connected to Reward Options and Metrics.
This is because the individual nodes are only relevant for the Reward Options as these are connected to a Provider.
If you want to get information about the Provider running a Validator you need to query the connected Providers.

For more information, see the Validators reference.

Providers

Providers are only connected to Reward Options, it's own Reward Option Type and Metrics.


Get Schema through a client

You can use a GraphQL Playground and its built-in introspection capabilities to retrieve the automatically generated API documentation. Navigate to the Docs or Schema tab in the playground, which displays the schema documentation in a user-friendly format. The documentation includes information on the available types, fields, and their arguments. You can also use the search bar to find the information you need quickly. The internal API documentation, in combination with our API docs, can be helpful for quickly understanding the capabilities of our API and constructing valid queries.