GET /api/explorer/v1/{chain}/transactions/{txHash}/logs

Auth X-Hub-Key from API_HUB_KEYExecute GET /run/oklink/api/explorer/v1/{chain}/transactions/{txHash}/logsCache cached 1s, never served stale past that windowCost free · weight 0 · standard rate classSource billing free

Transaction event logs

Parameters

nameintypedescription
chainpathstr
btc | eth | x1 | xlayer | sol | solana | tron | bsc | base | sui | apt | aptos | arbitrum | optimism | polygon | avax | avalanche | zksync | ton | gravity
requiredWeb chain slug (eth, bsc, sol, …)
example: eth
txHashpathstrrequiredTransaction hash
example: 0x5c504ed432cb51138bcf09aa5e8a410dd4a1e204ef84bfed1be16dfba1b22060
limitqueryintoptionalPage size
default: 20
example: 5
offsetqueryintoptionalPage offset
default: 0
example: 0

Response

type: object
data key: data
pagination: none
sample: {
  "code": "int",
  "data": "array[0]",
  "detailMsg": "str",
  "msg": "str"
}

Safe request

Reads the credential from API_HUB_KEY; it never appears in the URL.

curl -sH "X-Hub-Key: $API_HUB_KEY" "https://openapihub.dev/run/oklink/api/explorer/v1/eth/transactions/0x5c504ed432cb51138bcf09aa5e8a410dd4a1e204ef84bfed1be16dfba1b22060/logs?limit=5&offset=0"