> ## Documentation Index
> Fetch the complete documentation index at: https://docs.trusset.org/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Off-Chain Trades

> Read the executed trade tape for an off-chain book

Returns executed trades on a book, newest first, in the same shape as [Get Order Book Trades](/endpoints/stock-trading/get-order-book-trades).

<Warning>
  This route resolves the book as a `STOCK_TOKEN` book. A book created without an explicit `tokenType` defaults to `LIGHT_TOKEN` and returns `ORDER_BOOK_NOT_FOUND` here, even though the same book reads fine from [Get Off-Chain Order Book](/endpoints/stock-trading/offchain-get-order-book) and its snapshot. Create off-chain stock books with `tokenType: "STOCK_TOKEN"` to keep the whole surface consistent.
</Warning>

Off-chain trades carry no settlement transaction. Their `settlementStatus` reflects the ledger transfer, and `makerAddress` and `takerAddress` carry `offchain:<customerRef>` rather than wallet addresses.

## Path Parameters

<ParamField path="orderBookId" type="string" required>Order book ID.</ParamField>

## Query Parameters

<ParamField query="limit" type="integer" default="50">Page size, capped at 100.</ParamField>

<ParamField query="offset" type="integer" default="0">Rows to skip.</ParamField>

## Response Fields

<ResponseField name="data" type="object">
  <Expandable>
    <ResponseField name="trades" type="array">Trade records. See [Get Order Book Trades](/endpoints/stock-trading/get-order-book-trades) for the field list.</ResponseField>
    <ResponseField name="total" type="integer">Total trades on the scope.</ResponseField>
    <ResponseField name="limit" type="integer">Page size applied.</ResponseField>
    <ResponseField name="offset" type="integer">Offset applied.</ResponseField>
  </Expandable>
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl "https://api.trusset.org/orderbooks/stocks/api/offchain/order-books/clx_ob_stock_001/trades?limit=25" \
    -H "X-API-Key: trusset_your_key_here"
  ```

  ```typescript TypeScript theme={null}
  const res = await fetch(
    `https://api.trusset.org/orderbooks/stocks/api/offchain/order-books/${orderBookId}/trades?limit=25`,
    { headers: { 'X-API-Key': 'trusset_your_key_here' } }
  );
  const { data } = await res.json();
  ```
</RequestExample>

<ResponseExample>
  ```json Response theme={null}
  {
    "success": true,
    "data": {
      "trades": [
        {
          "tradeId": "1c9e0f22-2b74-4a51-9f8e-73c1a0d4b6e5",
          "orderBookId": "clx_ob_stock_001",
          "takerOrderBookId": null,
          "origin": "CLOB",
          "makerAddress": "offchain:cust_1042",
          "takerAddress": "offchain:cust_2288",
          "price": "182350000",
          "quantity": "1000000",
          "makerFee": "500",
          "takerFee": "1500",
          "side": "BUY",
          "settlementId": null,
          "settlementStatus": "CONFIRMED",
          "settlementError": null,
          "createdAt": "2025-06-15T12:02:00.000Z"
        }
      ],
      "total": 12,
      "limit": 25,
      "offset": 0
    }
  }
  ```
</ResponseExample>

## Error Codes

| Code                   | HTTP  | Cause                                                                              |
| ---------------------- | ----- | ---------------------------------------------------------------------------------- |
| `ORDER_BOOK_NOT_FOUND` | `404` | No such stock book on this instance, or the book's token type is not `STOCK_TOKEN` |
