Every block is handled by one mapping handleBlock
The contract
ConverterRegistryContract
found in ABIs and subgraph.yaml is just a dummy contract used to pass formatting checks. Each block is handled automatically regardless of the logic in this contract.
npm install
npm run codegen -- --chain-id 1
npm run build
⚠️ For deployment the subgraph to hosted service you need the access token (deployment key). See: Store the Access Token
npm run deploy -- --name <subgraph-name> --token 5ec79a32a3d2cdc497eddfdcdac5ad44
or
npm run deploy -- -n <subgraph-name> -t 5ec79a32a3d2cdc497eddfdcdac5ad44
Token 5ec79a32a3d2cdc497eddfdcdac5ad44
is example, you need insert your access token for hosted service or studio.
--name
: Subgraph name. Hosted service should contain '/'.
--token
: Access token.
--version
: Version label for studio project. Default v0.0.1
You can delete all generated files with the command:
npm run clean
Also, the cleanup is started before each code generation.