{"uid":"cap_6khC6vWxPFZIN82FToeP6","slug":"agent-data-tools-evm-contract-event-logs-reader-19583a3e","name":"Agent Data Tools: EVM Contract Event Logs Reader","description":"Recent contract event logs on Optimism (eth_getLogs): the events a contract emitted over the last N blocks (1-1,000, default 50), optionally filtered by topic0 (the 0x 32-byte event signature hash). Returns up to 100 logs with block, transaction hash and topics. Use to watch transfers or contract events; for one transaction's outcome use op_receipt.","url":"https://agent-data-tools.revmesh2074.workers.dev/op/logs?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","required":["address"],"properties":{"blocks":{"type":"integer","description":"How many recent blocks to scan (1-1000, default 50)"},"topic0":{"type":"string","description":"Optional 0x event signature hash to filter by"},"address":{"type":"string","description":"0x contract address"}}},"responseSchema":{"type":"object","properties":{"logs":{"type":"array","items":{"type":"object","properties":{"tx":{"type":"string"},"data":{"type":"string"},"block":{"type":"number"},"topics":{"type":"array","items":{"type":"string"}},"logIndex":{"type":"number"}}}},"chain":{"type":"string"},"count":{"type":"number"},"address":{"type":"string"},"chainId":{"type":"number"},"toBlock":{"type":"number"},"fromBlock":{"type":"number"},"truncated":{"type":"boolean"}}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.01","displayCostAsset":"USD","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.01/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_j2mx3wrRAINGAQ8zRG3gO","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.01","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Fetches recent event logs emitted by a smart contract on an EVM-compatible chain, optionally filtered by event signature hash","exampleAgentPrompt":"Pull the last 100 blocks of event logs for the contract at 0x0b2C639c533813f4Aa9D7837CAf62653d097Ff85 on Optimism, and filter for Transfer events using topic0 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef.","exampleUseCases":[{"title":"DeFi contract activity audit","prompt":"Fetch the most recent 200 blocks of event logs for the USDC contract at 0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48 on Ethereum so I can see what events it's been emitting lately."},{"title":"DEX swap event monitoring","prompt":"Scan the last 50 blocks of logs for the Uniswap pool at 0x8ad599c3A0ff1De082011EFDDc58f1908eb6e6D8 and filter by the Swap event signature 0xc42079f94a6350d7e6235f29174924f928cc2ac818eb64fed8004e115fbcca67."},{"title":"NFT transfer history retrieval","prompt":"Get the last 500 blocks of on-chain logs for the NFT contract at 0xBC4CA0EdA7647A8aB7C2061c2E118A18a936f13D filtered to topic0 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef so I can see all Transfer events."}],"resultDescription":"Returns a JSON object containing an array of event logs (each with tx hash, data, block number, topics array, and log index), along with the chain name, chain ID, contract address, fromBlock, toBlock, total count, and a truncated flag indicating if results were cut off.","failureModes":["Invalid or malformed contract address returns an error","Block range exceeding 1000 returns a validation error","Contract with no events in the scanned range returns an empty logs array","Unsupported chain or network unavailability returns an error","Result set too large causes truncated=true with partial data"],"whenToPreferThis":"Use this endpoint when you need raw on-chain event logs for a specific EVM smart contract across Base, Ethereum, Arbitrum, Optimism, or Polygon. It requires no API key or account setup and charges only $0.001 per successful call via x402 USDC micropayments, making it ideal for lightweight agent workflows. Prefer this over heavier blockchain indexers when you only need recent logs (up to 1000 blocks) and want a pay-per-call model with zero subscription overhead.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-30T12:35:25.388Z","isFirstParty":false,"canonicalSlug":"agent-data-tools-evm-contract-event-logs-reader-19583a3e"}