TheGraph exposes a GraphQL endpoint to query the events and entities within the Fantom Opera Chain and PaintSwap ecosystem.
Currently, there are multiple subgraphs, but additional subgraphs can be added to this repo:
- Exchange: Tracks all PaintSwap Exchange data with price, volume, liquidity, ...
- Brush: Tracks data about the brush token
For any of the subgraph: blocks
as [subgraph]
-
Run the
yarn run codegen:[subgraph]
command to prepare the TypeScript sources for the GraphQL (generated/*). -
Run the
yarn run build:[subgraph]
command to build the subgraph, and check compilation errors before deploying. -
Run
graph auth https://api.thegraph.com/deploy/ '<ACCESS_TOKEN>'
-
Deploy via
yarn run deploy:[subgraph]
.