RPC method

eth_getTransactionByHash on Unichain

Supported on SwiftNodes

Everything below was measured on 2026-10-13 by calling eth_getTransactionByHash on Unichain through the same endpoint customers use, and is re-measured weekly.

What eth_getTransactionByHash does

Returns a transaction by its hash: sender, recipient, value, input data, gas fields and signature, plus the block it was included in. It returns null for a hash the node does not know, and a transaction still in the mempool has a null blockNumber.

Transaction types on Unichain

Types of the 40 transactions in five consecutive blocks when we measured. Decoders that reject unknown types will fail on Unichain if any of these is missing from their list.

0x2 EIP-155935 (88%)
0x7e L1-to-L2 deposit (OP Stack)5 (13%)

Fields beyond Ethereum's

Type 0x7e (L1-to-L2 deposit (OP Stack)) transactions carry extra fields. depositReceiptVersion: the version of the deposit receipt format; mint: the amount of ETH minted on L2 by a deposit; sourceHash: the unique ID of an L1-to-L2 deposit, derived from its L1 origin.

Transactions include blockTimestamp, so you get the block time without a second call for the block.

A real Unichain transaction

A type 0x2 transaction from one of the latest blocks, as our endpoint returned it (long hex values shortened).

{
  "type": "0x2",
  "chainId": "0x82",
  "nonce": "0xbf64136",
  "gas": "0x5578",
  "maxFeePerGas": "0x7a120",
  "maxPriorityFeePerGas": "0x0",
  "to": "0x0000000000000000000000000000000000000000",
  "value": "0x0",
  "accessList": [],
  "input": "0x426c6f636b204e756d6265723a203631313436363734",
  "r": "0xdb9b0e0be7fd0c6fd99ae4b51229dfd2f1eadba0fc2073ebbcbd8dd3975e3eba",
  "s": "0x4ccec54b6be1f3371fbad5fca18b0a24c636e228972d5b60cd1f0bdfa5419491",
  "yParity": "0x0",
  "v": "0x0",
  "hash": "0x6bafe5aa328446d76c18c6b002ed8ea0951cc6779abfdee93c545787f2350374",
  "blockHash": "0x05ff42d32ed7f5c2b0c4b3e02d0b6ff7184382825cd160b3fbe14a428b974b36",
  "blockNumber": "0x3a50632",
  "transactionIndex": "0x1",
  "blockTimestamp": "0x6ace25f9",
  "from": "0xcabba9e7f4b3a885c5aa069f88469ac711dd4acc",
  "gasPrice": "0x7a120"
}

Example request

curl -s https://rpc.swiftnodes.io/rpc/unichain?key=YOUR_API_KEY \
  -X POST -H "Content-Type: application/json" \
  -d '{"jsonrpc":"2.0","id":1,"method":"eth_getTransactionByHash","params":["0x6bafe5aa328446d76c18c6b002ed8ea0951cc6779abfdee93c545787f2350374"]}'
import { createPublicClient, http } from "viem";

const client = createPublicClient({
  transport: http("https://rpc.swiftnodes.io/rpc/unichain?key=YOUR_API_KEY"),
});

const tx = await client.getTransaction({ hash: "0x6bafe5aa328446d76c18c6b002ed8ea0951cc6779abfdee93c545787f2350374" });
if (tx.blockNumber === null) console.log("still pending");
console.log(tx.type, tx.from, tx.to, tx.value);

Other methods on Unichain

eth_getTransactionByHash on other chains

Frequently asked questions

Does Unichain support eth_getTransactionByHash?

Yes. eth_getTransactionByHash answered on the SwiftNodes Unichain endpoint when our weekly probe called it through the customer path (2026-10-13).

Which transaction types does Unichain use?

In five recent blocks: 5 × 0x7e (L1-to-L2 deposit (OP Stack)), 35 × 0x2 (EIP-1559).

Why does eth_getTransactionByHash return null on Unichain?

The node does not know the hash: it was never broadcast, it was dropped from the mempool, or it was sent to another chain. Check the hash and the chain ID before retrying.

Unichain endpoints, live block height and WebSocket status are on the Unichain RPC page.

One key covers every chain we serve, and SwiftNodes has a free tier.