Indexing Frameworks
Background
Smart contract indexers are off-chain calculators that compute additional metrics specific to one smart contract. Calculators can be thought of as extensions to a smart contract that do additional off-chain computation and maintain additional off-chain state.
Simple example: the UniswapV2Pair contract maintains minimal state for the pool and emits Mint, Burn, and Swap events. If we wanted to know the cumulative number and volume of swaps on the pair, we could write and deploy a custom indexer instead of adding additional state variables and computation to the contract.
Smart contract indexers typically produce object schemas using the GraphQL schema language.
Smart contract indexing services usually provide a hosted service so that users can deploy their indexers without having to run their own infrastructure.
Provider Summary
- Mainnet
- Testnet
| Provider | Docs | Status | Language | Framework | Known for | Hosted service | Decen- tralized hosted service | Onchain & offchain data | Web- socket subscr- iptions | Query layer |
|---|---|---|---|---|---|---|---|---|---|---|
| Alchemy | Docs | ⌛️ | Assembly-Script | subgraph | Uptime guarantee | ✅ | ❌ | ❌ | ❌ | GraphQL |
| DipDup | Docs | ❓ | Python | dipdup | Python development | ❌ | ❌ | ✅ | ✅ | GraphQL |
| Envio | Docs | ✅ | JavaScript, TypeScript, Rescript | HyperIndex | Performance and scale | ✅ | ❌ | ✅ | ✅ | GraphQL |
| Ghost | Docs | ❓ | Solidity | GhostGraph | Solidity development | ✅ | ❌ | ❌ | ❌ | GraphQL |
| Goldsky | Docs | ⌛️ | Assembly- Script | subgraph | ✅ | ❌ | ❌ | ❌ | Custom GraphQL | |
| Sentio | Docs | ❓ | JavaScript, TypeScript | sentio-sdk | Performance; integrated alerting and visualization | ✅ | ❌ | ✅ | ❌ | GraphQL & SQL |
| SQD | Docs | ❓ | TypeScript | squid-sdk | Performance, decentralization | ✅ | Partial1 | ✅ | ✅ | GraphQL |
| SubQuery | Docs | ❓ | TypeScript | subql | Decentral- ization | ✅ | ✅ | ✅ | ❌ | GraphQL |
| The Graph | Docs | ✅ | Assembly- Script | subgraph | The original indexer | ✅ | ✅ | ❌ | ❌ | Custom GraphQL |
✅ = supported, ⌛️ = in progress, ❓ = unknown, ❌ = won't support