Documentation Index
Fetch the complete documentation index at: https://docs.geode.ag/llms.txt
Use this file to discover all available pages before exploring further.
What is the Indexer?
The Geode Indexer is a lightweight service that scans Ethereum for Geode protocol events and stores them in a persistent database. It serves as the single source of truth for:- Launched tokens — every coin deployed via the Geocurve
- Batch settlements — clearing prices, matched volumes, and settler fees
- Graduations — when a curve transitions to a full Uniswap v4 AMM
The indexer replaces the settler’s volatile in-memory token registry. Tokens persist across restarts, and the settler bot automatically syncs its pool list from the indexer every 30 seconds.
Architecture
- Ethereum → polls for on-chain events and writes them to the database
- Frontend → reads token lists, writes new launches via POST
- Settler → syncs pool registrations so every token is automatically settleable
Hosted Instance
Geode runs a public indexer at:Self-Hosting
Configure
FACTORY_ADDRESS— GeodeFactory contract addressHOOK_ADDRESS— GeodeHook contract addressRPC_URL— your Ethereum JSON-RPC endpoint
Configuration
| Variable | Required | Default | Description |
|---|---|---|---|
RPC_URL | No | https://ethereum-rpc.publicnode.com | Ethereum JSON-RPC endpoint |
FACTORY_ADDRESS | ⚠️ | — | GeodeFactory contract address |
HOOK_ADDRESS | ⚠️ | — | GeodeHook contract address |
START_BLOCK | No | current | Block number to start indexing from |
POLL_INTERVAL_MS | No | 5000 | How often to scan for new blocks (ms) |
PORT | No | 3004 | HTTP API port |
DATA_DIR | No | ./data | Directory for the SQLite database file |
If neither
FACTORY_ADDRESS nor HOOK_ADDRESS is set, the indexer runs in API-only mode — it accepts token registrations via POST /tokens but does not poll for on-chain events.API Reference
List All Tokens
Get Token by Address
404 if not found.
Register a Token
Duplicate registrations (same
tokenAddress) are safely ignored with status: "already_registered". The indexer also discovers tokens from on-chain TokenLaunched events, so manual registration is a belt-and-suspenders approach.List Settlements
Statistics
Health Check
Indexed Events
The indexer watches for these on-chain events:TokenLaunched
Emitted by GeodeFactory when a new Geocurve token is deployed. Captures name, symbol, deployer, reserves, and graduation threshold.
GeodeBatchSettled
Emitted by GeodeHook after each successful settlement. Records clearing price, matched volume, fees, and settler address.
GeodeGraduated
Emitted when a Geocurve reaches its ETH threshold and transitions to a full Uniswap v4 AMM. Updates the token’s
graduated status.GeodeLaunched
Backup event from GeodeHook (fewer fields than Factory’s TokenLaunched). Ensures tokens are captured even if the Factory event is missed.
Persistence
The indexer uses SQLite with WAL mode for the database. Key tables:| Table | Contents |
|---|---|
tokens | All launched tokens with metadata, graduation status |
settlements | Every batch settlement with clearing price, fees, settler |
indexer_state | Tracks last_indexed_block for resumption after restart |
$DATA_DIR/geode.db. On Railway, this is mounted to a persistent volume at /data so data survives redeployments.
Deploying to Railway
The indexer is deployed to Railway with a persistent volume for the SQLite database:Settler Integration
The settler bot automatically syncs its pool list from the indexer:GET /tokens from the indexer and registers any new pools. This means every token launched on Geode is automatically available for settlement — no manual pool registration required.
See the Settler documentation for details on running a settlement service.