---
title: "Get recent Lighter trades"
method: GET
path: "/v1/lighter/trades/{symbol}/recent"
tags: ["Lighter - Trades"]
---

# Get recent Lighter trades

`GET /v1/lighter/trades/{symbol}/recent`

## Request

- Base URL: `https://api.0xarchive.io`
- URL: `https://api.0xarchive.io/v1/lighter/trades/{symbol}/recent`
- Auth: API key in header `X-API-Key`

Get the most recent trades for a coin, ordered by timestamp descending.

## Path parameters

- `symbol` string, required

## Query parameters

- `limit` integer
- `side` 'buy' | 'sell'

## Response `200`

List of recent trades

- ApiResponseLighterTradeArray: API response containing an array of Lighter trades. History responses serve canonical rows only and clamp `end` to `finalized_through`; `/recent` responses serve preliminary rows and report `preliminary_row_count`.
  - `success` boolean
  - `data` LighterTrade[]
    - `coin` string, required: Trading pair symbol (deprecated, use symbol instead)
    - `symbol` string, required: Trading pair symbol
    - `side` 'A' | 'B', required: Trade side of the account this row belongs to: 'B' (buy) or 'A' (sell/ask)
    - `price` string, required: Execution price
    - `size` string, required: Trade size in base units
    - `timestamp` string, date-time, required: Execution timestamp (UTC)
    - `tx_hash` string, nullable: Lighter settlement transaction hash (fixed-width hex). Canonical rows only.
    - `trade_id` integer, required: Unique Lighter trade ID. Each trade produces two rows (one per counterparty) sharing this ID.
    - `order_id` integer, nullable: Order ID of this account's order. Canonical rows only.
    - `crossed` boolean, required: True if this account was the taker (crossed the spread), false if maker
    - `fee` string, nullable: This account's fee for the fill. Canonical rows only.
    - `account_index` string: Lighter numeric account index this row belongs to (serialized as a string)
    - `source` 'bucket' | 'ws', required: Row provenance: 'bucket' = canonical (finalized by the daily reconcile of the deployment's published trade history), 'ws' = preliminary real-time capture
    - `position_size_before` number, nullable: This account's signed position size before the fill (long positive, short negative)
    - `position_size_after` number, nullable: Signed position size after the fill (derived: position_size_before plus/minus size by side)
    - `entry_quote_before` number, nullable: This account's position entry quote value before the fill
    - `initial_margin_fraction_before` number, nullable: This account's initial margin fraction before the fill
    - `allocated_margin_before` number, nullable: Isolated-margin allocation before the fill (0 for cross)
    - `allocated_margin_after` number, nullable: Isolated-margin allocation after the fill (0 for cross)
    - `position_sign_changed` boolean, nullable: True if the fill flipped this account's position between long and short
    - `trade_type` string, nullable: Upstream trade type. Canonical rows only.
    - `is_maker` boolean, nullable: True if this account was the maker. Canonical rows only.
    - `counterparty_address` string, nullable: Counterparty's Lighter account index (serialized as a string). Canonical rows only.
    - `client_id` integer, nullable: Client-assigned order ID. Canonical rows only.
    - `realized_pnl` number, nullable: Matching-engine realized PnL for this fill. Canonical rows only.
    - `integrator_fee` number, nullable: Integrator fee charged on the fill. Canonical rows only.
    - `fee_account_id` integer, nullable: Account credited with the fee. Canonical rows only.
    - `l2_block_height` integer, nullable: Lighter L2 block height containing the trade. Canonical rows only.
    - `transaction_time_us` integer, nullable: Intra-block transaction time in microseconds. Canonical rows only.
    - `usdc_amount` number, nullable: Notional value of the fill in USDC. Canonical rows only.
  - `meta` ResponseMeta: Response metadata. Every 2xx JSON response carries `meta.request_id`; list payloads add `count`; cursor-paged routes add `has_more` and, when another page follows, `next_cursor`; per-symbol routes add `symbol` and `venue`. Fields that do not apply to a route are omitted.
    - `count` integer: Number of records returned
    - `has_more` boolean: Cursor-paged routes: whether another page follows. `next_cursor` is present exactly when this is `true`. A final page can be empty when the previous page was exactly full; `has_more` is `false` on it.
    - `next_cursor` string: Opaque cursor for the next page, present exactly when `has_more` is `true`. Pass it back unchanged as `cursor` with the same filters. Do not parse or construct it.
    - `request_id` string, uuid, required: Unique request ID for support
    - `symbol` string: Per-symbol routes: the canonical public symbol the response describes (for example `BTC`, `xyz:TSLA`, `HYPE-USDC`, `#0`).
    - `venue` 'hyperliquid' | 'hip3' | 'hip4' | 'spot' | 'lighter' | 'rh-lighter': Per-symbol routes: the venue the response describes.
    - `coverage_from` string, date-time: Earliest coverage for the requested symbol and data type. Present only when the requested window ends before coverage begins.
    - `notice` string: Human-readable advisory about the response. Used when the requested window ends before coverage begins for the symbol, and on CVD responses that are one page of several; may carry other advisories in future.
    - `finalized_through` string, date-time: Two-tier datasets (Lighter trades): data at or before this instant is final; later data is preliminary.
    - `requested_end` string, date-time, nullable: The `end` the request asked for, echoed when it was clamped to `finalized_through`.
    - `clamped_to` string, date-time, nullable: The boundary the request's `end` was clamped to, when clamping occurred.
    - `preliminary_row_count` integer, nullable: Number of preliminary rows in this response, on routes that intentionally serve preliminary data (Lighter `/recent`).

## Other responses

- `400`: Invalid request: a parameter, symbol, interval, cursor or time range failed validation. See `error_code`.
- `401`: Authentication required: the API key is missing or invalid.
- `429`: Rate limit, concurrency limit or monthly credits exceeded. See `error_code`.
- `default`: Any other error. The body is an `ErrorResponse`; branch on `error_code`. A 503 (`upstream_unavailable`) carries `Retry-After`.

---

[API](https://skmtc.dev/0xarchive/apis/0xarchive-api-2.md) · [All operations](https://skmtc.dev/0xarchive/apis/0xarchive-api-2/llms.txt) · [OpenAPI document](https://skmtc.dev/0xarchive/apis/0xarchive-api-2/revisions/27076f55595f?raw)
