---
title: "private/get_option_settlement_history"
method: POST
path: "/private/get_option_settlement_history"
tags: ["History"]
---

# private/get_option_settlement_history

`POST /private/get_option_settlement_history`

## Request

- Base URL: `https://api.derive.xyz/v3`
- URL: `https://api.derive.xyz/v3/private/get_option_settlement_history`
- Auth: API key in header `X-DeriveWallet` and API key in header `X-DeriveTimestamp` and API key in header `X-DeriveSignature`

Returns option settlement (expiry) events for a single subaccount or an entire wallet (specify exactly one). Each settlement includes the reconstructed option instrument name, the settled amount and value for that expired position, and the realized settlement PnL against the position's cost basis, with and without trading fees.

## Request body

- GetOptionSettlementHistoryParams: Parameters for `private/get_option_settlement_history`. One of `wallet` or `subaccount_id` must be provided; `wallet` returns every subaccount's settlements.
  - `subaccount_id` integer, nullable
  - `wallet` string, nullable

## Response `200`

Success

- OptionSettlementHistoryResponse
  - `settlements` OptionSettlementResponse[], required
    - `amount` string, decimal, required: Settled balance (negative = short, positive = long).
    - `expiry` integer, required: Expiry of the option, unix seconds.
    - `instrument_name` string, required
    - `option_settlement_pnl` string, decimal, nullable, required: USD profit or loss from the settlement: settlement value minus the position's average cost including fees times amount. `null` when no closing balance row exists for the settlement (settled before balance history was recorded).
    - `option_settlement_pnl_excl_fees` string, decimal, nullable, required: Same as `option_settlement_pnl` but against the average price excluding fees.
    - `settlement_price` string, decimal, required: Decimal string of the human value (e.g. `"1.5"`), up to 12 fractional digits; a string or JSON number is accepted
    - `settlement_value` string, decimal, required: Crystallized cash value = intrinsic value * amount.
    - `subaccount_id` integer, required

## Other responses

- `default`: JSON-RPC error (see Error Codes)

## Changes

- **2026-10-20** `0c500202be49`: 2 info
  - the endpoint scheme security `DeriveWallet AND DeriveTimestamp AND DeriveSignature` was added to the API
  - added the media type `application/json` for the response with the status `default`

[Operation history](https://skmtc.dev/lyra/apis/derive-v3-api/changes/private/get_option_settlement_history/post.md)

---

[API](https://skmtc.dev/lyra/apis/derive-v3-api.md) - [All operations](https://skmtc.dev/lyra/apis/derive-v3-api/llms.txt) - [OpenAPI document](https://skmtc.dev/lyra/apis/derive-v3-api/revisions/415f8a73b10c?raw)
