Skip to content
docs

EtherscanSourceOptions

Defined in: protocol-approvals-evm/src/sources/etherscan.ts:7

optional apiKey?: string

Defined in: protocol-approvals-evm/src/sources/etherscan.ts:11

Sent as apikey (omit when a proxy adds it).


optional baseUrl?: string

Defined in: protocol-approvals-evm/src/sources/etherscan.ts:13

Endpoint (default ETHERSCAN_V2_URL); a proxy that forwards the same query works.


optional chainId?: number

Defined in: protocol-approvals-evm/src/sources/etherscan.ts:9

Etherscan chainid.


optional concurrency?: number

Defined in: protocol-approvals-evm/src/sources/indexer-logs.ts:27

Parallel requests (default 1).

IndexerSourceOptions.concurrency


optional fetch?: FetchLike

Defined in: protocol-approvals-evm/src/sources/indexer-logs.ts:23

Fetch implementation (default global).

IndexerSourceOptions.fetch


optional headers?: Record<string, string>

Defined in: protocol-approvals-evm/src/sources/indexer-logs.ts:25

Extra request headers (an auth token for a proxy, say).

IndexerSourceOptions.headers


optional maxRetryWait?: number

Defined in: protocol-approvals-evm/src/sources/indexer-logs.ts:33

A 429 whose reset is further away than this fails at once with the wait in the message (default 20 000 ms).

IndexerSourceOptions.maxRetryWait


optional perTopic?: boolean

Defined in: protocol-approvals-evm/src/sources/indexer-logs.ts:21

One request per event signature instead of one per range (default false).

IndexerSourceOptions.perTopic


optional retries?: number

Defined in: protocol-approvals-evm/src/sources/indexer-logs.ts:29

Retries for transient errors and 429s (default 3).

IndexerSourceOptions.retries


optional retryDelay?: number

Defined in: protocol-approvals-evm/src/sources/indexer-logs.ts:31

Base delay between retries, doubled each time; a 429’s reset hint wins when longer (default 1000 ms).

IndexerSourceOptions.retryDelay