Arbitrum One
Arbitrum One
准备好在生产环境中调用了吗?
免费套餐涵盖个人项目。按量付费,无需绑卡即可扩展。
Arbitrum One
免费套餐涵盖个人项目。按量付费,无需绑卡即可扩展。
eth_getTransactionByBlockNumberAndIndex returns one transaction by its position inside a block, where the block is named by its number or by a tag like latest. On Arbitrum One (chain ID 42161), an Optimistic Rollup paying gas in ETH and settling to Ethereum L1, this is convenient when you are scanning forward by block height rather than tracking hashes. Send a block tag and a hex index to https://arbitrum.therpc.io/YOUR_API_KEY and it returns the transaction at that index position within the block, or null if the block or index is not found.
pending tag with a position index.| # | 名称 | 类型 | 必填 | 描述 |
|---|---|---|---|---|
| 1 | blockTag | string | 是 | The block containing the transaction. |
| 2 | transactionIndex | string (hex) | 是 | Zero-based position of the transaction within the block. |
| 类型 | 描述 |
|---|---|
| object | null | Same transaction object as eth_getTransactionByHash. Returns null if block or index not found. |
Try it live in the Arbitrum One playground.
| 错误码 | 错误信息 | 原因 |
|---|---|---|
-32602 | Invalid params | Block tag is malformed or transaction index is not a valid hex integer. |
"0x0", not the integer 0, for the first transaction.pending tag depend on the sequencer's current view; ordering and availability of pending transactions can differ between calls and node clients, so do not treat them as final.参数
hex block number or "latest"/"earliest"/"pending"/"safe"/"finalized"
0x-prefixed hex integer (e.g. "0x0" for the first transaction)