$ man eth-logs
/eth-logs
PRICE / CALL
$0.01
USDC · base mainnet · scheme: exact
METHOD
POST
CLUSTER
edgemarketCATEGORY
uncategorized
STATUS
● live
NAME
eth-logs — reads on-chain event logs with generic eth_getlogs queries across base, ethereum, arbitrum, optimism, polygon, and bsc via public no-auth…
SYNOPSIS
POST https://x402.agentutility.ai/eth-logs
Content-Type: application/json
X-PAYMENT: <signed-transferWithAuthorization>
{ ... }↳ first call →
402 Payment Required. Sign USDCtransferWithAuthorization, retry with theX-PAYMENT header.DESCRIPTION
Reads on-chain event logs with generic eth_getLogs queries across Base, Ethereum, Arbitrum, Optimism, Polygon, and BSC via public no-auth RPC. Supports address + up to 4 topics (with OR arrays), from/to block range, and a 'last_n_blocks' convenience param. Hard-capped at 5,000 logs and 10,000-block range per call. Use it as an EVM event reader, ERC20 Transfer log scanner, NFT mint log reader, DEX swap event feed, multi-chain log scanner, log indexer, or smart contract event reader.
INPUT — request schema
| property | type | description | req? |
|---|---|---|---|
| chain | any | Chain id or slug. Default 'base'. Supported: 8453|'base', 1|'ethereum', 42161|'arbitrum', 10|'optimism', 137|'polygon', 56|'bsc'. | optional |
| address | any | Contract address (0x..., string or array of strings). Optional. | optional |
| topics | array | Up to 4 topics. Each element: hex string (32 bytes), array of hex strings (OR-filter), or null (wildcard at that position). | optional |
| from_block | any | Hex string ('0x...'), decimal number, or 'latest'/'earliest'/'pending'/'safe'/'finalized'. | optional |
| to_block | any | Same shape as from_block. Default 'latest'. | optional |
| last_n_blocks | number | Convenience: query the last N blocks. Overrides from/to_block. | optional |
OUTPUT — response shape
| field | type | description |
|---|---|---|
| chain | string | Chain name queried (base, ethereum, arbitrum, optimism, polygon, or bsc). |
| chain_id | string | Numeric EVM chain ID corresponding to the chain that was queried. |
| from_block | string | Starting block number (inclusive) of the scanned range, as a decimal string. |
| to_block | string | Ending block number (inclusive) of the scanned range, as a decimal string. |
| count | string | Number of logs actually returned in this response after the 5,000-log cap. |
| total_count | string | Total logs matched by the filter before the 5,000-log cap was applied. |
| truncated | string | True if results hit the 5,000-log cap and more matching logs exist beyond what's returned. |
| logs | string | Array of raw eth_getLogs entries with address, topics, data, blockNumber, txHash, and logIndex. |
EXAMPLES — two ways to call
EXAMPLE 1 · curl
curl -X POST https://x402.agentutility.ai/eth-logs \
-H 'Content-Type: application/json' \
-d '{ }'first response =
402 Payment Required with payment requirements; sign + retry with X-PAYMENT.EXAMPLE 2 · mcp
# Install the MCP package for this endpoint's cluster npx -y @agentutility/mcp-<cluster> # Required: EVM private key with USDC on Base export X402_PRIVATE_KEY=0x... # Then call the eth-logs tool from your MCP-aware agent.
MCP server handles payment automatically — your coding agent just calls the tool by name.
METADATA
- tags
- edge-marketeth-getlogsevent-logsevm-rpcerc20-transfersmulti-chainlog-indexeronchain-events
- methods
- POST
- cluster
- edgemarket
- price
- $0.01 USDC per call
ADJACENT — other endpoints in edgemarket
| endpoint | description | price |
|---|---|---|
| contract-source | Returns verified source code and ABI for any deployed contract on Ethereum, Base, Optimism, Arbitrum, or Polygon. | $0.01 |
| contract-source-verified | Fetches verified contract source code and ABI for a deployed contract on Ethereum, Optimism, Polygon, Base, or Arbitrum. | $0.01 |
| dex-liquidity-depth | Measures DEX liquidity depth by summing TVL across every DefiLlama-tracked yield pool holding a given ERC-20 on Ethereum, Base, Polygon,… | $0.01 |
| lp-lock-check | Checks whether an LP token's liquidity is locked, useful for detecting rug-pull risk before swapping into a new pair. | $0.01 |
| nft-floor | Gets an NFT collection's floor price and recent sales via Reservoir. | $0.01 |
| agent-card-resolve | Resolves an ERC-8004 agentId to its on-chain owner, agentURI, and agent card JSON. | $0.005 |
| arbitrage-spread | Finds the cross-exchange arbitrage spread for any CoinGecko-listed coin. | $0.005 |
| basename-resolve | Resolves Coinbase Basenames (.base.eth) to Ethereum addresses and back, reading the Base mainnet L2 Resolver on-chain (no gas, no wallet). | $0.005 |
SEE ALSO