Indexing Status
Performing SQL queries on the ENS Unigraph requires that you have the unigraph plugin activated in your ENSNode instance. Learn more
Read the indexing status snapshot for an ENSIndexer instance from the shared ensnode.metadata table. See Connect for setup.
An ENSIndexer Schema is a
database schema within an ENSDb instance, used to store indexed ENS data from a given ENSIndexer instance. We use ensindexer_0 as the ENSIndexer Schema Name in examples on this page, but your ENSIndexer instance may be configured to use a different schema name based on how you configured its `ENSINDEXER_SCHEMA_NAME`
environment variable. Make sure to replace ensindexer_0 with the actual schema
name used by your ENSIndexer instance when querying the ENSDb instance directly.
-- Indexing status snapshot for the `ensindexer_0` ENSIndexer SchemaSELECT value -> 'indexingStatus' as indexing_status_snapshotFROM "ensnode"."metadata"WHERE ens_indexer_schema_name = 'ensindexer_0'AND key = 'indexing_metadata_context';| # | indexing_status_snapshot |
|---|---|
| 1 |
|
Output matches a SQL response snapshot; live output depends on your ENSNode instance.
ensDb query builder and ensIndexerSchema
schema definition in the Connect section if you haven't
already.
import { IndexingMetadataContextStatusCodes } from "@ensnode/ensdb-sdk";
const indexingMetadataContext = await ensDbReader.getIndexingMetadataContext();if (indexingMetadataContext.statusCode === IndexingMetadataContextStatusCodes.Initialized) { const indexingStatusSnapshot = indexingMetadataContext.indexingStatus; console.log(indexingStatusSnapshot);}| # | strategy | snapshotTime | omnichainSnapshot | slowestChainIndexingCursor |
|---|---|---|---|---|
| 1 | omnichain | 1779795066 |
| 1732054983 |
Output matches a SQL response snapshot; live output depends on your ENSNode instance.