matic

Polygon (MATIC)

Method: POST eth_getLogs

dropdown
POST

eth_getLogs

Returns an array of all logs matching a given filter object.

Parameters

Object - object

The filter options

Request

curl --location --request POST 'https://matic.getblock.io/mainnet/' 
--header 'x-api-key: YOUR-API-KEY' 
--header 'Content-Type: application/json' 
--data-raw '{"jsonrpc": "2.0",
"method": "eth_getLogs",
"params": [{"topics": []}],
"id": "getblock.io"}'


Response

{
    "id": "getblock.io",
    "jsonrpc": "2.0",
    "result": [
        {
            "address": "0xc2132d05d31c914a87c6611c10748aeb04b58e8f",
            "blockHash": "0x9081f91d0bc5fab3bb4819e0646fb629fbfe140a8948347529498b289d9a39a9",
            "blockNumber": "0x123e3f5",
            "data": "0x000000000000000000000000000000000000000000000000000000003beb2885",
            "logIndex": "0x0",
            "removed": false,
            "topics": [
                "0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
                "0x00000000000000000000000046ce2931140bf124fcf605192327b55b11b0a506",
                "0x000000000000000000000000604229c960e5cacf2aaeac8be68ac07ba9df81c3"
            ],
            "transactionHash": "0xe87bd4b07bcb0f423ebf2de2dcff7c67e4feecd379814113ba87d921675bd8bf",
            "transactionIndex": "0x0"
        },
        {
            "address": "0xc2132d05d31c914a87c6611c10748aeb04b58e8f",
            "blockHash": "0x9081f91d0bc5fab3bb4819e0646fb629fbfe140a8948347529498b289d9a39a9",
            "blockNumber": "0x123e3f5",
            "data": "0xfffffffffffffffffffffffffffffffffffffffffffffffffffffb921f1d77b7",
            "logIndex": "0x1",
            "removed": false,
            "topics": [
                "0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925",
                "0x00000000000000000000000046ce2931140bf124fcf605192327b55b11b0a506",
                "0x000000000000000000000000a5e0829caced8ffdd4de3c43696c57f7d7a678ff"
            ],
            "transactionHash": "0xe87bd4b07bcb0f423ebf2de2dcff7c67e4feecd379814113ba87d921675bd8bf",
            "transactionIndex": "0x0"
        }
    ]
}