The subgraph for BadToken on blockchain XinFin and Apothem
- Linux:
/etc/hosts
- Windows:
C:\Windows\System32\drivers\etc\hosts
test:
ping graph-node
Suggest to use node v18, the package.json requires:
- node: >=18.0.0
- yarn: >=8.6.0
git clone https://github.com/gzliudan/bad-token-subgraph
cd bad-token-subgraph
yarn
yarn make:apothem && yarn create:apothem && yarn deploy:apothem
yarn make:xinfin && yarn create:xinfin && yarn deploy:xinfin
Endpoints:
- apothem network: http://graph-node:8000/subgraphs/name/gzliudan/bad-token-subgraph-apothem
- xinfin network: http://graph-node:8000/subgraphs/name/gzliudan/bad-token-subgraph-xinfin
Query statement:
{
erc20Contracts(first: 5) {
id
name
symbol
decimals
totalSupply {
value
valueExact
}
}
blackLists(first: 5) {
id
members {
account {
id
}
}
}
accounts(first: 5) {
id
isErc20
blackLists {
id
}
Erc20balances {
id
value
valueExact
}
}
}