---
title: "GET /historical-pnl"
method: GET
path: "/historical-pnl"
---

# GET /historical-pnl

`GET /historical-pnl`

## Query parameters

- `address` string, required
- `subaccountNumber` number, double, required
- `limit` number, double
- `createdBeforeOrAtHeight` number, double
- `createdBeforeOrAt` string
- `createdOnOrAfterHeight` number, double
- `createdOnOrAfter` string
- `page` number, double

## Response `200`

Ok

- HistoricalPnlResponse
  - `pageSize` integer
  - `totalResults` integer
  - `offset` integer
  - `historicalPnl` PnlTicksResponseObject[], required
    - `equity` string, required
    - `totalPnl` string, required
    - `netTransfers` string, required
    - `createdAt` string, required
    - `blockHeight` string, required
    - `blockTime` string, required

## Changes

> 50 revisions in range; 1 could not be searched.

- **2025-04-21** `a7d995a71a03` — 2 breaking
  - removed the required property `historicalPnl/items/id` from the response with the `200` status
  - removed the required property `historicalPnl/items/subaccountId` from the response with the `200` status
- **2024-05-17** `1a224771e29d` — 4 info
  - added the new optional `query` request parameter `page`
  - added the optional property `offset` to the response with the `200` status
  - added the optional property `pageSize` to the response with the `200` status
  - added the optional property `totalResults` to the response with the `200` status
- **2024-05-14** `90fd32395633` — 4 warning, 2 info
  - deleted the `query` request parameter `page`
  - removed the optional property `offset` from the response with the `200` status
  - removed the optional property `pageSize` from the response with the `200` status
  - removed the optional property `totalResults` from the response with the `200` status
  - …2 more

[Change history](https://skmtc.dev/dydxprotocol/apis/indexer-api/changes/historical-pnl/get.md)

---

[API](https://skmtc.dev/dydxprotocol/apis/indexer-api.md) · [All operations](https://skmtc.dev/dydxprotocol/apis/indexer-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/dydxprotocol/indexer-api/revisions/5005547cef75/schema)
