Market Data

public/get_trade_history

Returns paginated, anonymized trades with optional filters: trade_id (a UUID, which overrides all other filters), instrument_name, instrument_type (erc20/option/perp), currency, subaccount_id, batch_status (a batch-status name; unset returns trades in every batch state), and from_timestamp/to_timestamp. Without trade_id, subaccount_id or instrument_name, or whenever batch_status is set, the window is limited to the 30 days ending at to_timestamp (or now). Each trade is enriched with its settlement status and transaction hash. Public endpoint.

post/public/get_trade_history

Request

  • Base URL: https://api.derive.xyz/v3
  • URL: https://api.derive.xyz/v3/public/get_trade_history
  • Auth: none declared

Request body

batch_status'Batching' | 'Executing' | 'Da' | 'Proving' | 'Settling' | 'Settled' | 'BatchingError' | 'ExecutingError' | 'DaError' | 'ProvingError' | 'SettlingError' | 'SettledError'

Batch lifecycle status — the single source of lifecycle truth for every operation in the batch (individual ops carry no status of their own). Each stage has a healthy variant and a corresponding ...Error variant meaning that stage failed. Serialized as the variant name (string) in API responses.

currencystring nullable
from_timestampinteger nullable
instrument_namestring nullable
instrument_type'option' | 'perp' | 'erc20'

Asset type of the instrument: "option", "perp", or "erc20".

pageinteger nullable
page_sizeinteger nullable
subaccount_idinteger nullable
to_timestampinteger nullable
trade_idstring nullable

Response

Success

Changes

No recorded changes to this operation across all 1 revision of this API.