Contract Intelligence

Per-Transaction Attribution

Public API: Classifies a single transaction against the attribution engine.

Given a transaction hash, this fetches the transaction and its receipt from Alchemy and applies the same four vectors used in our aggregate attribution (calldata-suffix, proxy-router, fee-recipient, aggregator) to tell you which frontend/router originated the trade and how we know — plus the pools touched, fee recipients, and whether the tx was sandwiched.

Results are cached permanently (mined transactions are immutable). Fee amounts are exact raw token units. With price=true, an APPROXIMATE USD trade size is added (best-effort spot price, dominant leg) — never treat it as a settlement figure.

get/api/v1/tx/{tx_hash}

Request

  • Base URL: https://cleartracedata.com (the document declares no server; this is the origin it was published from)
  • URL: https://cleartracedata.com/api/v1/tx/{tx_hash}
  • Auth: none declared

Path parameters

tx_hashstring required

Query parameters

chain'ethereum' | 'base' | 'arbitrum' | 'optimism'

Blockchain to query.

deepboolean

Use internal call traces to refine the classification (catches aggregators that sit as intermediates, e.g. a router reached through a separate settlement contract, and runs the calldata-suffix test per sub-call). Costs more Alchemy CU; trace support is strongest on Ethereum.

priceboolean

Add a best-effort, APPROXIMATE USD trade size (dominant priced leg via the free DefiLlama spot-price API). Adds latency; never a settlement figure.

Response

Live classification of a single transaction against the four attribution vectors.

tx_hashstring required

The queried transaction hash (lower-cased).

chainstring required

The blockchain the lookup ran against.

foundboolean required

Whether the transaction was found and classified.

statusinteger nullable

On-chain receipt status (1 = success, 0 = reverted).

primary_vectorstring nullable

The dominant attribution vector: proxy, aggregator, fee_recipient, calldata_suffix, direct, or unclassified.

vectorsstring[]

All attribution vectors this transaction matches.

is_directboolean

Whether the caller hit a DEX pool directly.

is_proxyboolean

Whether the trade routed through a proxy/router (hidden-frontend signal).

is_aggregatorboolean

Whether a known aggregator router was involved.

aggregator_namestring nullable

Name of the matched aggregator, if any.

has_calldata_suffixboolean

Whether the calldata carries a non-ABI-aligned suffix fingerprint.

poolsstring[]

Liquidity pools (Swap-event emitters) touched by the transaction.

routing_legsinteger

Number of Swap events (pool legs) in the transaction.

sandwichedboolean

Whether this transaction appears as a victim in our detected sandwich set.

trace_usedboolean

Whether internal traces were used to refine the classification (deep mode).

deepboolean

Whether deep (trace-based) classification was requested.

estimated_volume_usdnumber nullable

Best-effort, APPROXIMATE USD trade size (dominant priced leg, DefiLlama spot price). Null when pricing was not requested or no leg could be priced. Never use as a settlement figure.

volume_estimate_basisstring nullable

How estimated_volume_usd was derived, when present.

priceboolean

Whether best-effort USD sizing was requested.

cachedboolean

Whether this result was served from cache.

notestring nullable

Diagnostic note (e.g. when Alchemy is unconfigured or the tx is unknown).

Example response

{
  "chain": "ethereum",
  "status": 1,
  "primary_vector": "aggregator",
  "originator": {
    "address": "0x111111125421ca6dc452d289314280a0f8842a65",
    "name": "1inch: AggregationRouterV6"
  },
  "fee_recipients": [
    {
      "address": "0x37305b1cd40574e4c5ce33f8e8306be057fd7341",
      "name": "Banana Gun: Fee Wallet",
      "token_contract": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
      "raw_amount": "1250000"
    }
  ],
  "originating_frontend": {
    "bucket": "aggregator_api_direct",
    "frontend_name": "1inch: AggregationRouterV6",
    "method": "aggregator",
    "confidence": "medium"
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.