Skip to content
TraceFast Docs

The DEX liquidity added and removed in a transaction

Open the transaction's liquidity events →

Every liquidity event in the transaction, in log order — the pool, its protocol, the provider, whether liquidity was added or removed, and each token leg: the token with its declared symbol and decimals (verbatim, not verified), the raw amount and in token units, and its USD value with the price and how it was valued, as the source states them. An empty list means no liquidity event happened in the transaction. A transaction past the events' reach answers 422 rather than an empty list. Uniswap v4 liquidity events are not recorded.

GET https://tracefast.xyz/api/v1/chains/1/transactions/{hash}/liquidity-events
ParameterInTypeNotes
hashpathstringThe transaction hash, 0x + 64 hex, any case.

Access — an API key on the Investigation plan or higher (plans), or no key at all: pay per call with x402 at the same path on https://mpp.tracefast.xyz/api/v1, at the price its 402 states. As a tool for AI agents: get_transaction_liquidity_events on the MCP server. Stable — see stability.

chains/1 is a literal: other chain ids answer 404 chain_not_supported. An unknown query parameter is refused rather than ignored.

Response

200 application/json, a transaction that added liquidity to the Uniswap v3 USDC/WETH pool. Lists in the example are cut to two entries.

{
  "data": {
    "chainId": 1,
    "hash": "0x7730d7a24d8e69cc5f74b5ffded346d4dc735a9f3ad78703b6a24ecec6151c06",
    "events": [
      {
        "logIndex": 131,
        "pool": "0x88e6a0c2ddd26feeb64f039a2c41296fcb3f5640",
        "protocol": "uniswap",
        "protocolVersion": "v3",
        "provider": "0xc36442b4a4522e871399cd717abdd847ab11fe88",
        "action": "add",
        "eventType": "mint",
        "pricedLegs": 2,
        "unpricedLegs": 0,
        "legs": [
          {
            "token": "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
            "role": "underlying",
            "amountRaw": "138126992059",
            "amount": 138126.992059,
            "direction": "pool_in",
            "amountUsd": 138126.992059,
            "priceUsd": 1,
            "valuationStatus": "priced"
          },
          {
            "token": "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
            "role": "underlying",
            "amountRaw": "0",
            "amount": 0,
            "direction": "zero",
            "amountUsd": 0,
            "priceUsd": 1796.2609021225487,
            "valuationStatus": "priced"
          }
        ]
      }
    ]
  },
  "meta": {
    "chain": "ethereum",
    "timestamp": 1794918389768,
    "cached": false,
    "asOfBlock": 26434404,
    "docs": "https://docs.tracefast.xyz/api/transaction-liquidity-events"
  }
}

data

FieldMeaning
chainIdChain id. 1 is Ethereum mainnet.
eventsThe transaction's liquidity events, in log order.
hashThe transaction hash, lowercase and 0x-prefixed.

data.events[]

FieldMeaning
actionadd or remove.
eventTypeThe event as the pool names it, for example mint, burn, add_liquidity.
legsThe event's token legs.
logIndexThe event's index in the block.
poolThe pool, lowercase and 0x-prefixed.
pricedLegsThe event's token legs that could be priced.
protocolThe pool's protocol, for example uniswap or curve.
protocolVersionThe protocol's version, for example v3.
providerThe liquidity provider the event names, where it names one.
unpricedLegsThe event's token legs that could not be priced.

data.events[].legs[]

FieldMeaning
amountamountRaw in whole token units (scaled by decimals) as a floating-point number — an approximation for display; amountRaw is exact. Absent when the decimals are unknown.
amountRawThe amount in the token's smallest unit, as a signed decimal string: positive into the pool, negative out of it. The exact amount.
amountUsdThe leg's USD value, as a positive number. Absent when it could not be priced.
decimalsThe decimals the token contract declares. Absent when unknown.
directionWhether the leg went into the pool or out of it: pool_in, pool_out, zero or unknown.
priceUsdThe USD price of one whole token behind amountUsd. Absent when it could not be priced.
roleThe token's role in the event, as the source states it.
symbolThe symbol the token contract declares — verbatim, not verified. Absent when unknown. Absent when longer than 64 characters — left out whole, never shortened.
tokenThe leg's token, lowercase and 0x-prefixed. Absent when it could not be resolved.
valuationStatusHow the leg was valued, as the source states it: priced when it carries a USD value, otherwise why it does not.

meta is the same envelope on every method — see conventions.

Errors

StatusWhen
400bad_request: a malformed hash (tx_hash_invalid), or a query parameter was given
404not_found: no transaction with that hash; chain_not_supported, or an unknown path
422block_not_available: the transaction is past the liquidity events' reach (coverage_gap, details.maxAvailableBlock), or transactions are temporarily unavailable around it; retry later
503service_unavailable: the events' reach could not be read; retry with backoff; or service_degraded: who is calling could not be established right now; retry after Retry-After.

Malformed input, unknown parameters and the key check's 401/403/429/503 are the same for every method — see conventions and API keys.


Last updated 19 Nov 2026, 11:46 UTC · verified against TraceFast v1.0.332 · Markdown