An example to help you get started with The Graph. For more information see the docs on https://thegraph.com/docs/. Demo https://thegraph.com/explorer/subgraph/tercel/clover-example-subgraph
- Register an account in https://thegraph.com/explorer/
- Install Graph CLI globally on your machine
yarn global add @graphprotocol/graph-cli
- Init Subgraph
yarn install
yarn codegen
- Deploy Subgraph
graph deploy --access-token <ACCESS_TOKEN> \
--debug \
--node https://api.thegraph.com/deploy/ \
--ipfs https://api.thegraph.com/ipfs/ \
<GITHUB_USERNAME>/<SUBGRAPH_NAME>