Skip to main content

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
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

The indexer connects three systems:
  1. Ethereum → polls for on-chain events and writes them to the database
  2. Frontend → reads token lists, writes new launches via POST
  3. Settler → syncs pool registrations so every token is automatically settleable

Hosted Instance

Geode runs a public indexer at:
Try it now:

Self-Hosting

1

Clone and install

2

Configure

Set at minimum:
  • FACTORY_ADDRESS — GeodeFactory contract address
  • HOOK_ADDRESS — GeodeHook contract address
  • RPC_URL — your Ethereum JSON-RPC endpoint
3

Start

The indexer will begin polling for events and serving data on port 3004.

Configuration

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

Returns all launched tokens, newest first. Response format:

Get Token by Address

Returns a single token by its contract address. Returns 404 if not found.

Register a Token

Register a newly launched token. Called by the frontend after a successful Geocurve deployment.
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

Returns recent batch settlement events. Both query parameters are optional.

Statistics

Returns aggregate indexer 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 royalty configuration.

GeodeBatchSettled

Emitted by GeodeHook after each successful settlement. Records clearing price, matched volume, fees, and settler address.

GeodeCurveSwap

Emitted on every direct bonding curve swap. Tracks input/output amounts, fees, reserve fee, and updated ETH reserve.

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: The database file lives at $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:
On startup and every 30 seconds, the settler fetches 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.