Starkscan
Getting started

Read a transaction

Fetch a transaction's full detail and its execution trace over REST or the TypeScript SDK.

Read a transaction

Resolve a transaction hash to its full detail (receipt, logs, token transfers) and, when you need execution context, its trace.

REST

# detail (includes inline tokenTransfers)
curl -H "X-Starkscan-Api-Key: $STARKSCAN_API_KEY" \
  "$STARKSCAN_BASE_URL/v1/$STARKSCAN_CHAIN/tx/<tx_hash>"

# execution trace
curl -H "X-Starkscan-Api-Key: $STARKSCAN_API_KEY" \
  "$STARKSCAN_BASE_URL/v1/$STARKSCAN_CHAIN/tx/<tx_hash>/trace"

Detail responses include inline tokenTransfers. Check logsTruncated before treating the logs array as exhaustive (tokenTransfersTruncated is only present on the batched txDetails response below, not on single-transaction detail).

TypeScript SDK

import { createStarkscanClient } from "@starkscan/sdk";

const starkscan = createStarkscanClient({
  apiKey: process.env.STARKSCAN_API_KEY!,
  baseUrl: process.env.STARKSCAN_BASE_URL!,
  chainId: "SN_MAIN",
});

const tx = await starkscan.transaction("0x...");
const trace = await starkscan.transactionTrace("0x...");

Install the client with npm install @starkscan/sdk@alpha (see the SDK guide — the untagged install resolves to a non-working placeholder). For many hashes at once, use starkscan.txDetails([...]) (batched, up to 32 hashes; again check logsTruncated / tokenTransfersTruncated).

Other surfaces

When a call fails

See Your first error for 401 / 403 / 404 / 429 and the exact fix for each.

On this page