{"uid":"cap__-DFD2IS1V6XqDzWaL2v3","slug":"getlogs-ethereum-event-logs-by-address-and-topics-2638f741","name":"GetLogs - Ethereum Event Logs by Address and Topics","description":"Pay-per-request access to CoinGecko, DefiLlama, Alchemy, and Etherscan APIs. No auth, no subscriptions.","url":"https://stablecrypto.dev/api/etherscan/logs/getLogs","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"page":{"type":"number"},"offset":{"type":"number"},"topic0":{"type":"string","description":"Event topic 0"},"topic1":{"type":"string"},"topic2":{"type":"string"},"topic3":{"type":"string"},"address":{"type":"string","description":"Contract address"},"chainid":{"type":"number","description":"EVM chain ID (1=Ethereum, 137=Polygon, 8453=Base, etc.)"},"toBlock":{"type":"number"},"fromBlock":{"type":"number"},"topic0_1_opr":{"enum":["and","or"],"type":"string"},"topic0_2_opr":{"enum":["and","or"],"type":"string"},"topic0_3_opr":{"enum":["and","or"],"type":"string"},"topic1_2_opr":{"enum":["and","or"],"type":"string"},"topic1_3_opr":{"enum":["and","or"],"type":"string"},"topic2_3_opr":{"enum":["and","or"],"type":"string"}}},"responseSchema":null,"example":{"request":{"page":1,"offset":10,"topic0":"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef","address":"0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48","chainid":1,"toBlock":19000100,"fromBlock":19000000},"response":[{"data":"0x000000000000000000000000000000000000000000000000000000001dcd6500","topics":["0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef","0x000000000000000000000000bd098c9b3b2cffee0083725f3545e604dd9d8de7","0x0000000000000000000000002fc617e933a52713247ce25730f6695920b3befe"],"address":"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48","gasUsed":"0x9d9c","gasPrice":"0x55ecfe6bd","logIndex":"0x74","blockHash":"0xcf384012b91b081230cdf17a3f7dd370d8e67056058af6b272b3d54aa2714fac","timeStamp":"0x65a2e1c3","blockNumber":"0x121eac0","transactionHash":"0x0ea4a96a24aca17cf18c2ebc9ba7d5f5a2738dc8eae83bac9b07ccea74010249","transactionIndex":"0x1a"},{"data":"0x0000000000000000000000000000000000000000000000000000000002a007ce","topics":["0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef","0x000000000000000000000000b9254341a08da44f31b60851f038192140365e00","0x0000000000000000000000001ac1a8feaaea1900c4166deeed0c11cc10669d36"],"address":"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48","gasUsed":"0x7bdd6","gasPrice":"0x4b1f569bc","logIndex":"0xdd","blockHash":"0xcf384012b91b081230cdf17a3f7dd370d8e67056058af6b272b3d54aa2714fac","timeStamp":"0x65a2e1c3","blockNumber":"0x121eac0","transactionHash":"0x3e1b0fd0cb1bfa787f5b674a37574eb87bb74c632fd4894baec1ad2b9b7fb103","transactionIndex":"0x6b"},{"data":"0x000000000000000000000000000000000000000000000000000000175ebb5e91","topics":["0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef","0x00000000000000000000000088e6a0c2ddd26feeb64f039a2c41296fcb3f5640","0x0000000000000000000000005050e08626c499411b5d0e0b5af0e83d3fd82edf"],"address":"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48","gasUsed":"0x1d646","gasPrice":"0x4764f75b8","logIndex":"0xd","blockHash":"0x858f71b82284841eedd8c4ca4855345ddf728ae034ebe03e21d5f30fb88c0f4d","timeStamp":"0x65a2e1cf","blockNumber":"0x121eac1","transactionHash":"0xda9c61259d360f1158ca3fc80f670a15da8e1c39debff3c0c7dbc6e55591be82","transactionIndex":"0x4"},{"data":"0x0000000000000000000000000000000000000000000000000000000011e1a300","topics":["0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef","0x000000000000000000000000f89d7b9c864f589bbf53a82105107622b35eaa40","0x000000000000000000000000fd1e8681918c5d99c588483cbcd4703f94e753ee"],"address":"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48","gasUsed":"0xf328","gasPrice":"0x4ed8509b8","logIndex":"0x57","blockHash":"0x858f71b82284841eedd8c4ca4855345ddf728ae034ebe03e21d5f30fb88c0f4d","timeStamp":"0x65a2e1cf","blockNumber":"0x121eac1","transactionHash":"0x1f0cba4fd4e277130dc0cc6887a67cd105885a8b427959bf5449330d4dae7089","transactionIndex":"0x26"},{"data":"0x0000000000000000000000000000000000000000000000000000000218711a00","topics":["0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef","0x000000000000000000000000f89d7b9c864f589bbf53a82105107622b35eaa40","0x00000000000000000000000018c0da141472d5db1d561851dce5d4a7754992d7"],"address":"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48","gasUsed":"0xb068","gasPrice":"0x4ed8509b8","logIndex":"0x58","blockHash":"0x858f71b82284841eedd8c4ca4855345ddf728ae034ebe03e21d5f30fb88c0f4d","timeStamp":"0x65a2e1cf","blockNumber":"0x121eac1","transactionHash":"0xcd109a5ea4aacee11b091829e6d0406cb96b2f54361903abcb368d7b02010bef","transactionIndex":"0x27"},{"data":"0x000000000000000000000000000000000000000000000000000000000b23dd93","topics":["0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef","0x000000000000000000000000cfc0f98f30742b6d880f90155d4ebb885e55ab33","0x00000000000000000000000073fd554ac128ed32b66ed7f070590b8fe6b6b162"],"address":"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48","gasUsed":"0xb068","gasPrice":"0x4c2b93a38","logIndex":"0x62","blockHash":"0x858f71b82284841eedd8c4ca4855345ddf728ae034ebe03e21d5f30fb88c0f4d","timeStamp":"0x65a2e1cf","blockNumber":"0x121eac1","transactionHash":"0x8e634ff16fda2144b12beeb393a34017d5b5e02b1f2232a158fff306c2e4552a","transactionIndex":"0x39"},{"data":"0x000000000000000000000000000000000000000000000000000000012a05f200","topics":["0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef","0x0000000000000000000000004b95d2b0ae104fa87f2816b77a4a50cd2a33e794","0x000000000000000000000000ad00a21b37e785becbff33f68cda896d5f5e53b1"],"address":"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48","gasUsed":"0xb05c","gasPrice":"0x48ad5ab23","logIndex":"0x86","blockHash":"0x858f71b82284841eedd8c4ca4855345ddf728ae034ebe03e21d5f30fb88c0f4d","timeStamp":"0x65a2e1cf","blockNumber":"0x121eac1","transactionHash":"0xd778347963930a7e3b29808d2ff761c6b9f9bf9fccdf52f23d02ec182ff265b9","transactionIndex":"0x56"},{"data":"0x000000000000000000000000000000000000000000000000000000000ee650da","topics":["0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef","0x000000000000000000000000787b8840100d9baadd7463f4a73b5ba73b00c6ca","0x000000000000000000000000aeb414cee5ce2804f9e4947dce25e2633279fb1d"],"address":"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48","gasUsed":"0xf334","gasPrice":"0x4a4d43c47","logIndex":"0xef","blockHash":"0x858f71b82284841eedd8c4ca4855345ddf728ae034ebe03e21d5f30fb88c0f4d","timeStamp":"0x65a2e1cf","blockNumber":"0x121eac1","transactionHash":"0x93482dcce372c4d92ab10b80f1c9392252fa3d32d13216373f3a4f9fb78252c5","transactionIndex":"0x8a"},{"data":"0x00000000000000000000000000000000000000000000000000000000014db97d","topics":["0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef","0x0000000000000000000000003af5a04ac0c8ecc6bf285d99a5da19e0ee8af9b1","0x000000000000000000000000b4e16d0168e52d35cacd2c6185b44281ec28c9dc"],"address":"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48","gasUsed":"0x3781f","gasPrice":"0x4794a6638","logIndex":"0xfe","blockHash":"0x858f71b82284841eedd8c4ca4855345ddf728ae034ebe03e21d5f30fb88c0f4d","timeStamp":"0x65a2e1cf","blockNumber":"0x121eac1","transactionHash":"0xcc4161d15e823d287bbcf80ebcb38ca9ebedbb0c3c64f187c8a93d5f0f356533","transactionIndex":"0x91"},{"data":"0x00000000000000000000000000000000000000000000000000000000078d22cc","topics":["0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef","0x0000000000000000000000001002d483fe780f8dd15650adbce5555087bd67cb","0x000000000000000000000000397ff1542f962076d0bfe58ea045ffa2d347aca0"],"address":"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48","gasUsed":"0x2e751","gasPrice":"0x4794a6638","logIndex":"0x108","blockHash":"0x858f71b82284841eedd8c4ca4855345ddf728ae034ebe03e21d5f30fb88c0f4d","timeStamp":"0x65a2e1cf","blockNumber":"0x121eac1","transactionHash":"0xc95cd2b1837d860570537b56e26798f49d046fe9b93083556817b7be9757fd3b","transactionIndex":"0x93"}]},"exampleRequest":{"page":1,"offset":10,"topic0":"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef","address":"0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48","chainid":1,"toBlock":19000100,"fromBlock":19000000},"tags":["x402"],"displayCostAmount":"0.01","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"settled","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_Wsh4TR4r3UqUg0UBOB06K","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 on-chain event logs for a contract address filtered by topics and block range across EVM-compatible chains","exampleAgentPrompt":"Pull all Transfer event logs for the USDC contract at 0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48 on Ethereum mainnet (chain ID 1) from block 19000000 to 19100000, filtering by topic0 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef.","exampleUseCases":null,"resultDescription":"An array of event log entries for the specified contract, each containing the transaction hash, block number, log index, contract address, raw data field, and indexed topic values (topic0–topic3), paginated according to the page and offset parameters.","failureModes":["Invalid or unsupported chain ID returns an error","Malformed contract address (non-checksummed or wrong length) causes rejection","Block range too large may return truncated or paginated results","Invalid topic hex string format causes query failure","No logs found for the given filters returns an empty array","Network congestion or upstream Etherscan API throttling may cause timeouts"],"whenToPreferThis":"Use this endpoint when you need filtered on-chain event logs for a specific contract address on any supported EVM chain, especially when you want to narrow results by event signature (topic0) and additional indexed parameters. Prefer this over a generic RPC call when you want structured, paginated log results without managing raw JSON-RPC complexity. Ideal for DeFi analytics, contract debugging, and event-driven workflows.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T00:50:51.444Z","isFirstParty":false}