Polygon
هل أنت مستعد لاستدعاء هذا في الإنتاج؟
الخطة المجانية تغطي المشاريع الشخصية. الدفع حسب الاستخدام يتوسع دون بطاقة.
Polygon
الخطة المجانية تغطي المشاريع الشخصية. الدفع حسب الاستخدام يتوسع دون بطاقة.
eth_getTransactionByBlockNumberAndIndex returns one transaction from Polygon PoS (chain ID 137) addressed by a block — given as a height or a tag like latest or pending — plus the zero-based index of the transaction within it. Polygon's MATIC-fee, EVM-equivalent design and ~2-second Bor blocks make this handy for sequential scanning when you are iterating by block number rather than resolving block hashes first. Point the request at https://polygon.therpc.io/YOUR_API_KEY and it returns the same transaction object as eth_getTransactionByHash, or null if the block or index is out of range.
0x0) of each Polygon block for MEV and ordering research.pending tag while Bor is still assembling it.| # | الاسم | النوع | مطلوب | الوصف |
|---|---|---|---|---|
| 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 Polygon 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 are not stable: which transactions appear and in what order depends on the node's current Bor mempool view and can differ between clients and between calls.المعاملات
hex block number or "latest"/"earliest"/"pending"/"safe"/"finalized"
0x-prefixed hex integer (e.g. "0x0" for the first transaction)