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

# Get Recent Trades

> This endpoint allows users to get recent trades for a specific market.

```http theme={null}
GET /api/v1/trades
```

#### Query Parameters

<table><thead><tr><th width="176">Field</th><th width="98">Type</th><th width="95">Need</th><th width="189">Description</th><th>Example</th></tr></thead><tbody><tr><td>`"symbol"`</td><td>string</td><td>optional</td><td>Trading pair symbol. If omitted, returns recent trades across all markets.</td><td>`BTC`</td></tr></tbody></table>

```http theme={null}
/api/v1/trades?symbol=BTC
```

#### Response

* Status 200: Successfully retrieved recent trades

```json theme={null}
{
  "success": true,
  "data": [
    {
      "event_type": "fulfill_taker",
      "price": "104721",
      "amount": "0.0001",
      "side": "close_long",
      "cause": "normal",
      "created_at": 1765006315306
    }
  ],
  "error": null,
  "code": null,
  "last_order_id": 1557404170
}
```

| Field | Type | Description |
| - | - | - |
| `'event_type'` | string | `"fulfill_taker"` if maker `"fulfill_maker"` if taker |
| `'price'` | decimal string | Price in USD at which trade event has occurred |
| `'amount'` | decimal string | Amount in token denomination for which the trade has occurred. |
| `'side'` | string | `"open_long"` `"open_short"` `"close_long"` `"close_short"` |
| `'cause'` | string | `"normal"` regular user-initiated trading `"market_liquidation"` position was liquidated due to insufficient margin `"backstop_liquidation"` position was liquidated by backstop mechanism `"settlement"` position was closed due to Auto-Deleveraging (ADL) or other settlement `"insolvency_liquidation"` position was closed due to account insolvency `"game_settlement"` position was settled by the prediction game `"fulfill_rfq"` trade resulted from an RFQ fill |
| `'created_at'` | integer | Timestamp in milliseconds of trade event |

The response also includes a top-level `last_order_id` field (a sibling of `data`, `error`, and `code` — not a member of each trade object):

| Field | Type | Description |
| - | - | - |
| `'last_order_id'` | integer or null | [Last ID](https://docs.pacifica.fi/api-documentation/api/last-id.md) — the highest sequence number among the returned trades. `null` when the result is empty. |

* Status 400: Invalid request parameters
* Status 401: Unauthorized access
* Status 500: Internal server error

#### Code Example (Python)

```python theme={null}
import requests

response = requests.get(
    "/api/v1/trades?symbol=BTC",
    headers={"Accept": "*/*"},
)

data = response.json()
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.