# Derive API ## Docs - [Get account settings and fees for a wallet](https://v3.docs.derive.xyz/api-reference/account/get-account-settings-and-fees-for-a-wallet.md): Returns account-level information for a given wallet address: the list of its subaccount IDs, WebSocket rate limits (matching, non-matching, perp, and option messages per second) and any per-endpoint overrides, cancel-on-disconnect and RFQ-maker flags, the account creation timestamp, and a fee_info… - [Auctions watch](https://v3.docs.derive.xyz/api-reference/channels/auctionswatch.md): Channel name: `auctions.watch`. Public channel that streams the live state of all ongoing liquidation and insolvency auctions across the exchange. Takes no parameters. - [Margin watch](https://v3.docs.derive.xyz/api-reference/channels/marginwatch.md): Channel name: `margin.watch`. Public channel that streams margin and mark-to-market state for all accounts, letting you monitor collateralization and liquidation risk across the exchange. Takes no parameters. - [Orderbook](https://v3.docs.derive.xyz/api-reference/channels/orderbook.md): Channel name: `orderbook.{instrument_name}.{group}.{depth}`. Public channel that periodically publishes aggregated bids and asks for a single instrument, where {instrument_name} is the market (e.g. ETH-PERP), {group} is the price-level aggregation size (1, 10, or 100), and {depth} is the number of l… - [Spot feed](https://v3.docs.derive.xyz/api-reference/channels/spotfeed.md): Channel name: `spot_feed.{currency}`. Public channel that streams the spot price feed for a given underlying, where {currency} selects the asset (e.g. ETH or BTC). - [Subaccount balances](https://v3.docs.derive.xyz/api-reference/channels/subaccountbalances.md): Channel name: `{subaccount_id}.balances`. Private channel (requires authentication) that streams balance and position updates for one of your subaccounts, where {subaccount_id} is the numeric subaccount identifier. - [Subaccount best quotes](https://v3.docs.derive.xyz/api-reference/channels/subaccountbestquotes.md): Channel name: `{subaccount_id}.best.quotes`. Private channel (requires authentication) that streams best-quote updates relevant to your subaccount, where {subaccount_id} is the numeric subaccount identifier. - [Subaccount orders](https://v3.docs.derive.xyz/api-reference/channels/subaccountorders.md): Channel name: `{subaccount_id}.orders`. Private channel (requires authentication) that streams live order updates (opens, fills, cancels, and status changes) for your subaccount, where {subaccount_id} is the numeric subaccount identifier. - [Subaccount quotes](https://v3.docs.derive.xyz/api-reference/channels/subaccountquotes.md): Channel name: `{subaccount_id}.quotes`. Private channel (requires authentication) that streams updates to your RFQ quotes for a subaccount, where {subaccount_id} is the numeric subaccount identifier. - [Subaccount trades](https://v3.docs.derive.xyz/api-reference/channels/subaccounttrades.md): Channel name: `{subaccount_id}.trades`. Private channel (requires authentication) that streams your subaccount's own trade fills as they occur, where {subaccount_id} is the numeric subaccount identifier. - [Subaccount trades tx status](https://v3.docs.derive.xyz/api-reference/channels/subaccounttradestxstatus.md): Channel name: `{subaccount_id}.trades.{tx_status}`. Private channel (requires authentication) that streams your subaccount's trades filtered by on-chain settlement outcome, where {subaccount_id} is the numeric subaccount identifier and {tx_status} is the settlement state (settled, reverted, or timed… - [Ticker slim](https://v3.docs.derive.xyz/api-reference/channels/tickerslim.md): Channel name: `ticker_slim.{instrument_name}.{interval}`. Public channel that streams a lightweight ticker (prices and key stats) for an instrument, where {instrument_name} is the market and {interval} is the update cadence in milliseconds (100 or 1000). - [Trades by instrument](https://v3.docs.derive.xyz/api-reference/channels/tradesbyinstrument.md): Channel name: `trades.{instrument_name}`. Public channel that streams the public trade tape for a single instrument, where {instrument_name} is the market whose fills you want to follow. - [Trades by instrument type currency](https://v3.docs.derive.xyz/api-reference/channels/tradesbyinstrumenttypecurrency.md): Channel name: `trades.{instrument_type}.{currency}`. Public channel that streams public trades filtered by market category, where {instrument_type} is the kind of instrument (erc20, option, or perp) and {currency} is the underlying asset (e.g. ETH or BTC). - [Trades by instrument type currency tx status](https://v3.docs.derive.xyz/api-reference/channels/tradesbyinstrumenttypecurrencytxstatus.md): Channel name: `trades.{instrument_type}.{currency}.{tx_status}`. Public channel that streams public trades filtered by category, underlying, and settlement outcome, where {instrument_type} is the instrument kind (erc20, option, or perp), {currency} is the underlying asset, and {tx_status} is the on-… - [Wallet rfqs](https://v3.docs.derive.xyz/api-reference/channels/walletrfqs.md): Channel name: `{wallet}.rfqs`. Private channel (requires authentication) that streams RFQ (request-for-quote) updates for all subaccounts under a wallet, where {wallet} is your wallet address. - [Get deposit history for a subaccount](https://v3.docs.derive.xyz/api-reference/history/get-deposit-history-for-a-subaccount.md): Returns settled deposits for a single subaccount or an entire wallet (specify exactly one), optionally bounded by a start/end timestamp window. Each entry reports the deposited amount as a decimal, the fee routed to the security module (the net credited amount is amount minus fee), and the resolved… - [Get historical orders for a subaccount](https://v3.docs.derive.xyz/api-reference/history/get-historical-orders-for-a-subaccount.md): Returns a paginated history of orders for a single subaccount or for an entire wallet (specify exactly one), optionally bounded by a from/to timestamp window. Each page includes the order records plus pagination info with the total count and number of pages. - [Get historical trades for a subaccount](https://v3.docs.derive.xyz/api-reference/history/get-historical-trades-for-a-subaccount.md): Returns a paginated history of executed trades for a single subaccount or an entire wallet (specify exactly one), with optional filters for a time window, order id, instrument name, or quote id. The response includes the trade records and pagination info with total count and page count. - [Get interest history for a subaccount](https://v3.docs.derive.xyz/api-reference/history/get-interest-history-for-a-subaccount.md): Returns realized interest settlements per subaccount, for a single subaccount or an entire wallet (specify exactly one), optionally bounded by a start/end timestamp window. Each entry gives the settled interest as a decimal, where a negative value was paid (borrowed) and a positive value was receive… - [Get option settlement history for a subaccount](https://v3.docs.derive.xyz/api-reference/history/get-option-settlement-history-for-a-subaccount.md): Returns option settlement (expiry) events for a single subaccount or an entire wallet (specify exactly one). Each settlement includes the reconstructed option instrument name and the settled amounts for that expired position. - [Get perpetual funding history for a subaccount](https://v3.docs.derive.xyz/api-reference/history/get-perpetual-funding-history-for-a-subaccount.md): Returns a paginated history of perpetual funding (settlement) events for a single subaccount or an entire wallet (specify exactly one), optionally bounded by a start/end timestamp window and filtered by perpetual instrument name. The response includes the funding events with their instrument name an… - [Get spot transfer history for a subaccount](https://v3.docs.derive.xyz/api-reference/history/get-spot-transfer-history-for-a-subaccount.md): Returns settled spot (ERC-20) transfers involving a single subaccount or an entire wallet (specify exactly one), optionally bounded by a start/end timestamp window. Each entry reports the transfer amount and fee as decimals along with direction — the sender sees the gross amount plus fee, the receiv… - [Get withdrawal history for a subaccount](https://v3.docs.derive.xyz/api-reference/history/get-withdrawal-history-for-a-subaccount.md): Returns settled withdrawals for a single subaccount or an entire wallet (specify exactly one), optionally bounded by a start/end timestamp window. Each entry reports the withdrawn amount as a decimal, the fee routed to the security module (the net amount sent to the recipient is amount minus fee), a… - [Get a single tradeable instrument](https://v3.docs.derive.xyz/api-reference/market-data/get-a-single-tradeable-instrument.md): Returns the full public definition of one instrument named by `instrument_name`: type, activation window and active status, tick size, min/max/step amounts, maker/taker/base fee rates, pro-rata matching parameters, base/quote currencies, and type-specific details (option, perp, or spot). Expired opt… - [Get details for a single currency](https://v3.docs.derive.xyz/api-reference/market-data/get-details-for-a-single-currency.md): Returns the full detail record for one currency named by the required `currency` parameter: supported instrument types, risk managers, current and 24h spot price, margin collateral discounts, lending APYs and totals, per-manager open-interest caps and current OI, and protocol asset addresses. Return… - [Get latest signed oracle feeds](https://v3.docs.derive.xyz/api-reference/market-data/get-latest-signed-oracle-feeds.md): Returns the most recent oracle-signed feed data — spot, forward, volatility (SVI), rate, and perp feeds — each with signer addresses and signatures for on-chain submission. Optional `currency` and `expiry` filters narrow the result (use `expiry` 0 for spot/perp only); both default to all. Public end… - [Get lending interest-rate candles](https://v3.docs.derive.xyz/api-reference/market-data/get-lending-interest-rate-candles.md): Returns lending borrow/supply APY OHLC candles for a `currency`'s pool over an optional time window (UTC milliseconds) at a `period` of 1h or larger (defaults to 1h; sub-hour periods are rejected). An optional `risk_universe_id` restricts to one pool; otherwise every universe's candles are returned,… - [Get perp funding-rate candles](https://v3.docs.derive.xyz/api-reference/market-data/get-perp-funding-rate-candles.md): Returns funding-rate OHLC candles for a perpetual instrument (`instrument_name`) over an optional `start_timestamp`/`end_timestamp` window (UTC milliseconds) at a `period` granularity (defaults to 1h; 60s up to 1w supported). Each candle carries open/high/low/close per-hour rates plus a `funding_rat… - [Get settled option settlement prices](https://v3.docs.derive.xyz/api-reference/market-data/get-settled-option-settlement-prices.md): Returns the settlement price for each settled option expiry of a `currency`, with the expiry date (YYYYMMDD), unix expiry timestamp, and price. Only already-settled expiries are returned. Unknown currencies return a not-found error. Public endpoint. - [Get spot index price candles](https://v3.docs.derive.xyz/api-reference/market-data/get-spot-index-price-candles.md): Returns spot index OHLC candles for a `currency` between required `start_timestamp` and `end_timestamp` (UTC seconds) at the given `period` granularity (1m up to 1w). Each candle includes open/high/low/close and a `price` mirroring the close. The requested range is clamped to a maximum number of buc… - [Get the ticker for one instrument](https://v3.docs.derive.xyz/api-reference/market-data/get-the-ticker-for-one-instrument.md): Returns the latest ticker snapshot for a single instrument named by `instrument_name`. The payload matches the data of a `ticker_slim.{instrument}.{interval}` subscription update (mark/index prices, best bid/ask, sizes, greeks, and related fields). Returns an error if no ticker is available. Public… - [Get tickers for a currency and type](https://v3.docs.derive.xyz/api-reference/market-data/get-tickers-for-a-currency-and-type.md): Returns a map of instrument name to latest ticker snapshot for an `instrument_type`. Options require both `currency` and an 8-digit `expiry_date` (YYYYMMDD); perps and spot accept an optional `currency` (omit to fetch all currencies) and reject `expiry_date`. Public endpoint. - [Get trade OHLCV candles for an instrument](https://v3.docs.derive.xyz/api-reference/market-data/get-trade-ohlcv-candles-for-an-instrument.md): Returns traded-price OHLCV candles for an `instrument_name` between required `start_timestamp` and `end_timestamp` (UTC seconds) at the given `period` (1m up to 1w), aggregated from executed trade history. Each candle includes open/high/low/close prices plus USD and contract volume, formatted for ch… - [List all supported currencies with details](https://v3.docs.derive.xyz/api-reference/market-data/list-all-supported-currencies-with-details.md): Returns detailed metadata for every configured currency, including supported instrument types, risk managers, spot price and 24h-ago price, SRM/portfolio margin collateral discounts, lending borrow/supply APYs, open-interest caps and utilization per manager, and protocol asset addresses. Currencies… - [List assets for a currency and type](https://v3.docs.derive.xyz/api-reference/market-data/list-assets-for-a-currency-and-type.md): Returns the assets of a given `asset_type` (option, perp, or erc20) for a `currency`, with `expired` controlling whether past-expiry options are included. Each entry includes the asset id, name, on-chain address and sub_id, collateral/position flags, and type-specific details (option strike/expiry/s… - [List instruments with pagination](https://v3.docs.derive.xyz/api-reference/market-data/list-instruments-with-pagination.md): Returns a paginated list of full instrument definitions filtered by `instrument_type`, optional `currency`, and `expired` flag, with `page`/`page_size` (max 1000) controls and pagination metadata. Expired options are included when the `expired` flag is set. Public endpoint. - [List names of all live instruments](https://v3.docs.derive.xyz/api-reference/market-data/list-names-of-all-live-instruments.md): Returns a sorted list of the names of every currently live instrument (active and within its scheduled activation window). Takes no parameters and returns names only, not full definitions. Public endpoint. - [Query anonymized public trade history](https://v3.docs.derive.xyz/api-reference/market-data/query-anonymized-public-trade-history.md): Returns paginated, anonymized settled trades with optional filters: `trade_id` (a UUID, which overrides all other filters), `instrument_name`, `instrument_type` (erc20/option/perp), `currency`, `subaccount_id`, `tx_status` (a batch-status name, default Settled), and `from_timestamp`/`to_timestamp`.… - [Get market maker protection config](https://v3.docs.derive.xyz/api-reference/market-maker-protection/get-market-maker-protection-config.md): Returns the market maker protection (MMP) settings for a subaccount, optionally filtered to a single currency. Each entry reports the amount and delta limits (as decimal strings), the rolling interval and freeze duration (in milliseconds), and the current freeze state, including whether MMP is curre… - [Reset market maker protection freeze](https://v3.docs.derive.xyz/api-reference/market-maker-protection/reset-market-maker-protection-freeze.md): Clears an active market maker protection freeze and resets the rolling MMP window for a subaccount, optionally scoped to a single currency. Use this to resume quoting after MMP has frozen a subaccount. Requires a trading-scoped session key and returns "ok" on success. - [Set market maker protection config](https://v3.docs.derive.xyz/api-reference/market-maker-protection/set-market-maker-protection-config.md): Creates or fully replaces the market maker protection settings for a subaccount and currency. Accepts an amount limit and delta limit (as decimals) plus the rolling interval and freeze duration in milliseconds; omitted limits default to zero. Requires a trading-scoped session key and echoes the appl… - [Authenticate a WebSocket connection](https://v3.docs.derive.xyz/api-reference/methods/authenticate-a-websocket-connection.md): WebSocket-only method that authenticates the connection so subsequent private/* calls and private channel subscriptions act on your wallet without per-request headers. Pass the wallet address, a millisecond UTC timestamp, and an EIP-191 signature of that timestamp made by either the wallet itself or… - [Enable or disable cancel on disconnect](https://v3.docs.derive.xyz/api-reference/methods/enable-or-disable-cancel-on-disconnect.md): WebSocket-only method that toggles cancel on disconnect for the authenticated wallet. While enabled, dropping the WebSocket connection cancels the wallet's open orders, trigger and algo orders, and quotes. Pass enabled true or false; omitting it leaves the setting unchanged. Requires a session key w… - [Subscribe to notification channels](https://v3.docs.derive.xyz/api-reference/methods/subscribe-to-notification-channels.md): WebSocket-only method that subscribes the connection to one or more notification channels by name — see the Subscriptions section for the available channels and their address formats (e.g. orderbook.ETH-PERP.10.20). Duplicate names are deduplicated; private channels require a logged-in connection wi… - [Unsubscribe from notification channels](https://v3.docs.derive.xyz/api-reference/methods/unsubscribe-from-notification-channels.md): WebSocket-only method that removes the connection's subscriptions for the given channel names; omit channels (or pass null) to unsubscribe from everything. Returns a per-channel status map ("ok" or an error string) plus the subscriptions that remain after the call. - [Cancel a single order by id](https://v3.docs.derive.xyz/api-reference/orderbook/cancel-a-single-order-by-id.md): Cancels one resting order identified by order_id, subaccount_id and instrument_name. Requires any trade scope on the session; returns the cancelled order with its final status. - [Cancel a trigger order by id](https://v3.docs.derive.xyz/api-reference/orderbook/cancel-a-trigger-order-by-id.md): Cancels a single pending trigger order identified by order_id and subaccount_id. Requires any trade scope; returns the cancelled order. - [Cancel all algo orders for a subaccount](https://v3.docs.derive.xyz/api-reference/orderbook/cancel-all-algo-orders-for-a-subaccount.md): Cancels every active algo order on the given subaccount. Requires any trade scope; returns "ok" on success. - [Cancel all open orders for a subaccount](https://v3.docs.derive.xyz/api-reference/orderbook/cancel-all-open-orders-for-a-subaccount.md): Cancels every open order on the given subaccount. Optional cancel_trigger_orders and cancel_algo_orders flags additionally clear the subaccount's trigger and algo orders in the same call. Requires any trade scope; returns "ok" on success. - [Cancel all orders on an instrument](https://v3.docs.derive.xyz/api-reference/orderbook/cancel-all-orders-on-an-instrument.md): Cancels every open order for a subaccount on a single instrument. Requires any trade scope; returns the number of orders cancelled. - [Cancel all trigger orders for a subaccount](https://v3.docs.derive.xyz/api-reference/orderbook/cancel-all-trigger-orders-for-a-subaccount.md): Cancels every pending trigger order on the given subaccount. Requires any trade scope; returns "ok" on success. - [Cancel an algo order by id](https://v3.docs.derive.xyz/api-reference/orderbook/cancel-an-algo-order-by-id.md): Cancels a single active algo order identified by order_id and subaccount_id, stopping any further child-order execution. Requires any trade scope; returns the cancelled order. - [Cancel an existing order and place a new one](https://v3.docs.derive.xyz/api-reference/orderbook/cancel-an-existing-order-and-place-a-new-one.md): Atomically cancels a resting order (identified by order_id_to_cancel or nonce_to_cancel) and submits a replacement order in a single request. The payload is a full new-order specification plus the cancel target and an optional expected_filled_amount guard. Requires a signed order payload and Orderbo… - [Cancel an order by nonce](https://v3.docs.derive.xyz/api-reference/orderbook/cancel-an-order-by-nonce.md): Cancels a single order identified by its signing nonce, instrument_name and subaccount_id. The owning wallet is taken from the authenticated session rather than the request. Requires any trade scope; returns the cancelled order. - [Cancel orders matching a label](https://v3.docs.derive.xyz/api-reference/orderbook/cancel-orders-matching-a-label.md): Cancels a subaccount's open orders that carry the given client label, optionally scoped to a single instrument_name. When an instrument is supplied the call is acknowledged with the number of orders cancelled; without one it runs as a bulk fire-and-forget cancel and returns a -1 sentinel count. Requ… - [Estimate order cost and margin without authentication](https://v3.docs.derive.xyz/api-reference/orderbook/estimate-order-cost-and-margin-without-authentication.md): Public dry-run variant of order_quote that estimates fill price, fees, margin impact, projected order status and realized PnL for a prospective order without placing it, returning all values as decimal strings. Unlike private/order_quote it bypasses session scope checks, so it can be used to preview… - [Estimate the cost and margin impact of an order](https://v3.docs.derive.xyz/api-reference/orderbook/estimate-the-cost-and-margin-impact-of-an-order.md): Dry-run pricing helper that estimates the outcome of a prospective order without placing it, returning projected fill price and amount, fees, pre/post initial margin, realized PnL, resulting order status and (where relevant) liquidation price and max tradable amount. All monetary values are returned… - [List algo orders for a subaccount](https://v3.docs.derive.xyz/api-reference/orderbook/list-algo-orders-for-a-subaccount.md): Returns all active algo orders (e.g. time-sliced execution orders) for the given subaccount as a flat list. Read-only query. - [List open orders for a subaccount](https://v3.docs.derive.xyz/api-reference/orderbook/list-open-orders-for-a-subaccount.md): Returns all currently open orders for the given subaccount, including each order's instrument, direction, prices, amounts and status. Read-only query. - [List trigger orders for a subaccount](https://v3.docs.derive.xyz/api-reference/orderbook/list-trigger-orders-for-a-subaccount.md): Returns all pending trigger (conditional) orders for the given subaccount that have not yet fired. Read-only query. - [Look up a single order by id](https://v3.docs.derive.xyz/api-reference/orderbook/look-up-a-single-order-by-id.md): Returns one order (active or completed) by order_id and subaccount_id; the subaccount filter enforces ownership. Returns the order or an order-does-not-exist error. - [Place a new order](https://v3.docs.derive.xyz/api-reference/orderbook/place-a-new-order.md): Submits a signed limit or market order for a subaccount, specifying instrument, direction, amount, limit price and max fee, plus optional flags like time-in-force, reduce-only, post-only and MMP. The same endpoint also creates trigger orders (via trigger_type/trigger_price) and algo orders (via algo… - [Preview an order's EIP-712 signing data](https://v3.docs.derive.xyz/api-reference/orderbook/preview-an-orders-eip-712-signing-data.md): Takes the same params as private/order and rebuilds the order Action without executing anything, returning the EIP-712 encoded_data, encoded_data_hashed, action_hash, typed_data_hash, domain_separator, action_typehash, module, owner and expected_signer, plus the decoded order action data. Byte-compa… - [public/get_pending_deposits](https://v3.docs.derive.xyz/api-reference/other/publicget_pending_deposits.md) - [Get referral program performance](https://v3.docs.derive.xyz/api-reference/referrals/get-referral-program-performance.md): Returns broker-program referral performance for a referral code, identified either by the code itself or by the referrer's wallet, over a requested time window (start_ms to end_ms, capped at 28 days). The response includes total notional volume, referred fees, fee rewards, builder fees collected, th… - [List all referral codes](https://v3.docs.derive.xyz/api-reference/referrals/list-all-referral-codes.md): Returns every registered referral code along with the owner's wallet address and, when configured, the wallet that receives referral rewards. Takes no parameters. - [Cancel a single maker quote by id](https://v3.docs.derive.xyz/api-reference/rfq/cancel-a-single-maker-quote-by-id.md): Cancels one open quote owned by the subaccount, identified by quote_id (optionally further constrained by rfq_id, label, or nonce). Returns the cancelled quote, or a quote-not-found error if it does not exist or is no longer open. Requires an RFQ trade scope. - [Cancel a single RFQ by id](https://v3.docs.derive.xyz/api-reference/rfq/cancel-a-single-rfq-by-id.md): Cancels one open RFQ owned by the given subaccount and cascade-cancels any quotes makers have submitted against it, notifying those makers. Identify the RFQ by its rfq_id. Returns "ok" on success. Requires an RFQ trade scope. - [Cancel and resubmit a maker quote atomically](https://v3.docs.derive.xyz/api-reference/rfq/cancel-and-resubmit-a-maker-quote-atomically.md): Maker-side call that atomically cancels an existing quote and submits a new signed quote for the same RFQ in one operation. You provide the new priced legs, direction, max fee, and EIP-712 signature, plus the quote to cancel (by quote_id or nonce_to_cancel). Returns the cancellation result together… - [Cancel multiple maker quotes by filter](https://v3.docs.derive.xyz/api-reference/rfq/cancel-multiple-maker-quotes-by-filter.md): Cancels all open quotes on a subaccount that match the supplied filters (any combination of quote_id, rfq_id, label, and nonce, applied together) in a single atomic operation. Omitting the optional filters targets all of the subaccount's open quotes. Returns the list of cancelled quote ids. Requires… - [Cancel multiple RFQs by filter](https://v3.docs.derive.xyz/api-reference/rfq/cancel-multiple-rfqs-by-filter.md): Cancels all open RFQs on a subaccount that match the supplied filters (any combination of rfq_id, label, and nonce, applied together), cascade-cancelling their quotes. Omitting the optional filters targets all of the subaccount's open RFQs. Returns the set of cancelled RFQs. Requires an RFQ trade sc… - [Create a request for quote (RFQ)](https://v3.docs.derive.xyz/api-reference/rfq/create-a-request-for-quote-rfq.md): Taker-side call that opens a new RFQ for a multi-leg structure on a subaccount, inviting makers to quote it. You supply the legs (instrument, amount, and direction per leg) plus optional limits such as min/max total cost, a partial-fill step, a label, and a list of specific counterparties to restric… - [Execute a maker quote to fill an RFQ](https://v3.docs.derive.xyz/api-reference/rfq/execute-a-maker-quote-to-fill-an-rfq.md): Taker-side call that accepts a specific maker quote and settles the trade atomically. You reference the rfq_id and quote_id and supply the taker's priced legs, direction, max fee, and EIP-712 signature (signer, signature, nonce, expiry), with an optional taker-protection flag. The signature is verif… - [List a subaccount's quotes with history](https://v3.docs.derive.xyz/api-reference/rfq/list-a-subaccounts-quotes-with-history.md): Returns a paginated, merged view of a subaccount's quotes, combining currently open quotes with the archived history of filled, cancelled, and expired ones. Supports filtering by quote_id, rfq_id, status, and a from/to timestamp window, with page and page_size controls. Each entry includes priced le… - [List a subaccount's RFQs with history](https://v3.docs.derive.xyz/api-reference/rfq/list-a-subaccounts-rfqs-with-history.md): Returns a paginated, merged view of a subaccount's RFQs, combining currently open RFQs with the archived history of filled, cancelled, and expired ones. Supports filtering by rfq_id, status, and a from/to timestamp window, with page and page_size controls. Each entry includes legs, status, timestamp… - [Poll quotes received on a taker's RFQs](https://v3.docs.derive.xyz/api-reference/rfq/poll-quotes-received-on-a-takers-rfqs.md): Taker-side call that lists the maker quotes received against RFQs owned by the subaccount. Supports filtering by quote_id, rfq_id, status, and a timestamp window, with pagination. Returns public quote views (including the maker's wallet) without any signing material. - [Poll RFQs visible to a maker](https://v3.docs.derive.xyz/api-reference/rfq/poll-rfqs-visible-to-a-maker.md): Maker-side call that lists the RFQs a subaccount is eligible to quote, i.e. RFQs that are open to all makers or that name the maker's wallet as a counterparty. Supports filtering by rfq_id, status, an originating RFQ subaccount, and a timestamp window, with pagination. Returns public RFQ views witho… - [Preview EIP-712 signing data for a quote](https://v3.docs.derive.xyz/api-reference/rfq/preview-eip-712-signing-data-for-a-quote.md): Public signing-preview helper that returns the EIP-712 encoding artifacts (encoded data, its hash, the action hash, and the typed-data hash) for a maker quote a client is about to sign. It does not verify signatures, persist anything, or place a quote; use it to construct and check the exact payload… - [Preview EIP-712 signing data for a quote execution](https://v3.docs.derive.xyz/api-reference/rfq/preview-eip-712-signing-data-for-a-quote-execution.md): Public signing-preview helper that returns the taker's EIP-712 encoding artifacts (encoded data and hashes) plus the maker-side encoded legs and legs hash for a quote execution a client is about to sign. It does not verify signatures, persist anything, or execute the trade; use it to construct and c… - [Preview the best quote for an RFQ](https://v3.docs.derive.xyz/api-reference/rfq/preview-the-best-quote-for-an-rfq.md): Taker-side dry run that evaluates a prospective RFQ (its legs and intended direction) without creating anything. Returns the best available maker quote if one exists, along with the expected fee, validity, projected liquidation prices, and realized-PnL estimate for taking it. - [Submit a maker quote for an RFQ](https://v3.docs.derive.xyz/api-reference/rfq/submit-a-maker-quote-for-an-rfq.md): Maker-side call that submits a priced, signed quote in response to an existing RFQ. You provide the priced legs, direction, max fee, an EIP-712 signature (signer, signature, nonce, expiry), and optional label or MMP flag. The quote's signature is verified and validated against the referenced RFQ bef… - [Edit a session key's off-chain settings](https://v3.docs.derive.xyz/api-reference/session-keys/edit-a-session-keys-off-chain-settings.md): Updates an existing session key's label, IP allowlist, and/or off-chain scopes for a given wallet; it cannot change on-chain (protocol) scopes, for which you must re-register with private/create_session_key. Editing only the label needs account-info permission, while changing the IP allowlist or off… - [List a wallet's session keys](https://v3.docs.derive.xyz/api-reference/session-keys/list-a-wallets-session-keys.md): Returns every session key registered to the given wallet, including expired and not-yet-activated keys, each with its public address, scopes, expiry, label, IP allowlist, and permitted subaccounts. - [List wallets for a session key](https://v3.docs.derive.xyz/api-reference/session-keys/list-wallets-for-a-session-key.md): Public lookup that returns the wallet addresses a given session key is registered to, sorted by expiry, with expired keys omitted. An optional scope filter narrows results to keys holding that off-chain scope; returns an error if no matching, unexpired keys exist. - [Register a scoped session key](https://v3.docs.derive.xyz/api-reference/session-keys/register-a-scoped-session-key.md): Authorizes a new session key for a wallet from a signed action, granting it a set of on-chain (protocol) scopes and off-chain scopes with an expiry, an optional label, an optional IP allowlist, and an optional list of subaccounts it may act on (defaults to all of the wallet's subaccounts). Send the… - [Get active positions for a subaccount](https://v3.docs.derive.xyz/api-reference/subaccounts/get-active-positions-for-a-subaccount.md): Returns the subaccount ID and the list of its active positions, including size, mark price, average price, unrealized and realized PnL, and Greeks where applicable, valued against live feed data at request time. A lighter alternative to get_subaccount when only positions are needed. - [Get collateral balances for a subaccount](https://v3.docs.derive.xyz/api-reference/subaccounts/get-collateral-balances-for-a-subaccount.md): Returns the subaccount ID and the list of its collateral balances, including each asset's amount and current value valued against live feed data. A lighter alternative to get_subaccount when only collateral holdings are needed. - [Get full portfolio for a subaccount](https://v3.docs.derive.xyz/api-reference/subaccounts/get-full-portfolio-for-a-subaccount.md): Returns the complete portfolio for a single subaccount: its label, manager and risk-universe identifiers, margin type and liquidation status, aggregate valuation and margin figures (positions, collaterals, initial and maintenance margin, open-order margin) as decimal strings, plus the full lists of… - [Get full portfolios for all of a wallet's subaccounts](https://v3.docs.derive.xyz/api-reference/subaccounts/get-full-portfolios-for-all-of-a-wallets-subaccounts.md): Returns the complete portfolio (same shape as get_subaccount) for every subaccount owned by the given wallet, including valuations, margin figures, open orders, positions, and collaterals. If an individual subaccount's portfolio cannot be built, it is returned as a placeholder entry with failed_to_f… - [List subaccount IDs for a wallet](https://v3.docs.derive.xyz/api-reference/subaccounts/list-subaccount-ids-for-a-wallet.md): Returns the wallet address and the sorted list of subaccount IDs owned by that wallet. Yields an empty list if the wallet has no subaccounts. - [Set a subaccount's label](https://v3.docs.derive.xyz/api-reference/subaccounts/set-a-subaccounts-label.md): Updates the human-readable label for a subaccount. The label must be at most 16 characters, otherwise an invalid-params error is returned. Requires a signed session key with account-info scope; on success it echoes back the subaccount ID and the new label. - [Get L1 onchain action history](https://v3.docs.derive.xyz/api-reference/system/get-l1-onchain-action-history.md): Returns the lifecycle of onchain actions submitted via `OnchainActionManager.sol`. Public endpoint. - [Get remaining rate limits for the connection](https://v3.docs.derive.xyz/api-reference/system/get-remaining-rate-limits-for-the-connection.md): Returns the caller's current remaining rate-limit allowances for the active connection, broken out into matching-request, non-matching-request, and per-endpoint buckets. On WebSocket connections it also includes the remaining connection allowance. - [Get the current server time](https://v3.docs.derive.xyz/api-reference/system/get-the-current-server-time.md): Returns the current server time in milliseconds since the UNIX epoch. Takes no parameters and requires no authentication. Use it to align the timestamps and nonces bound into signed actions with the server clock. - [Look up an operation's on-chain status](https://v3.docs.derive.xyz/api-reference/system/look-up-an-operations-on-chain-status.md): Looks up the settlement lifecycle of a previously submitted operation by its operation UUID (op_uuid). Returns the operation's serialized data along with its batch status, settlement transaction hash, and any error log; the status is null until the operation has been picked up for settlement. - [Preview EIP-712 encoding for a withdrawal](https://v3.docs.derive.xyz/api-reference/transfers-&-withdrawals/preview-eip-712-encoding-for-a-withdrawal.md): Dry-run helper that returns the EIP-712 typed data and hashes that would be computed for the given withdrawal parameters, so clients can verify their own signing and hashing before submitting. Takes the same inputs as private/withdraw (subaccount, signer, nonce, amount, max fee, expiry, asset) but p… - [Register a deterministic deposit address for a wallet](https://v3.docs.derive.xyz/api-reference/transfers-&-withdrawals/register-a-deterministic-deposit-address-for-a-wallet.md): Returns the deterministic on-chain deposit address for a wallet and records it so incoming deposits are watched and credited. Pass the wallet and optionally an existing subaccount id; when creating a new subaccount (subaccount omitted or 0) a non-zero manager_id is required. Repeated calls return th… - [Transfer a spot asset between your subaccounts](https://v3.docs.derive.xyz/api-reference/transfers-&-withdrawals/transfer-a-spot-asset-between-your-subaccounts.md): Submits a signed transfer of a single spot asset from one subaccount to another subaccount you own. You specify the source and destination subaccounts (or set new_subaccount_manager to create a new destination subaccount under a manager), the asset and its sub_id, the amount, a nonce, signer, signat… - [Transfer a spot asset to another owner's subaccount](https://v3.docs.derive.xyz/api-reference/transfers-&-withdrawals/transfer-a-spot-asset-to-another-owners-subaccount.md): Submits a signed transfer of a single spot asset to a subaccount belonging to a different owner. Alongside the standard transfer fields (asset, sub_id, amount, nonce, signer, signature, expiry, max USD fee) you give the recipient's wallet address and either an existing destination subaccount or 0 to… - [Transfer positions between two subaccounts by RFQ](https://v3.docs.derive.xyz/api-reference/transfers-&-withdrawals/transfer-positions-between-two-subaccounts-by-rfq.md): Atomically transfers one or more derivative positions between a maker and a taker subaccount using matched, signed transfer quotes. Each side supplies its subaccount, signer, nonce, signature, expiry, max fee, direction, and priced legs (instrument, amount, price); the two quotes must mirror each ot… - [Update a wallet's whitelisted transfer recipients](https://v3.docs.derive.xyz/api-reference/transfers-&-withdrawals/update-a-wallets-whitelisted-transfer-recipients.md): Adds and/or removes recipient wallet addresses on an account's transfer whitelist via a signed, wallet-level action. Provide the owner wallet, signer, nonce, signature with expiry, and the add and remove address lists. This is an owner-or-admin operation (session keys need the admin scope); it retur… - [Withdraw an asset from a subaccount to L1](https://v3.docs.derive.xyz/api-reference/transfers-&-withdrawals/withdraw-an-asset-from-a-subaccount-to-l1.md): Submits a signed request to withdraw a spot asset out of a subaccount. You provide the subaccount id, asset name, amount in underlying units, a nonce, the signer, an EIP-712 signature with its expiry, and the maximum sequencer fee (in USD) you authorise; setting force_batch controls whether the with… - [Create a new curated vault](https://v3.docs.derive.xyz/api-reference/vault-curators/create-a-new-curated-vault.md): Registers a new vault on-chain from a signed action; the signing wallet becomes the vault's curator and seeds the initial deposit from its funding subaccount. Inputs set the deposit asset, initial deposit amount, initial share price, management/performance fee rates (in basis points), max slippage,… - [Force-exit a shareholder from a vault](https://v3.docs.derive.xyz/api-reference/vault-curators/force-exit-a-shareholder-from-a-vault.md): Curator-only endpoint that builds an on-chain action to forcibly redeem a given holder's entire share balance at the current mark-to-market share price. Inputs are the vault subaccount and the holder's wallet address. Requires the curator mint-and-burn permission. - [List vaults a wallet curates](https://v3.docs.derive.xyz/api-reference/vault-curators/list-vaults-a-wallet-curates.md): Returns the subaccount ids of the vaults curated by the given wallet. The wallet parameter must match the authenticated connection. Read-only. - [Page a vault's pending deposit requests](https://v3.docs.derive.xyz/api-reference/vault-curators/page-a-vaults-pending-deposit-requests.md): Curator-only endpoint that returns a FIFO page of a vault's pending deposit (mint) requests. Inputs are the vault subaccount and a page limit. Requires the curator mint-and-burn permission. - [Page a vault's pending withdrawal requests](https://v3.docs.derive.xyz/api-reference/vault-curators/page-a-vaults-pending-withdrawal-requests.md): Curator-only endpoint that returns a FIFO page of a vault's pending withdraw (burn) requests. Inputs are the vault subaccount and a page limit. Requires the curator mint-and-burn permission. - [Reject a pending vault deposit request](https://v3.docs.derive.xyz/api-reference/vault-curators/reject-a-pending-vault-deposit-request.md): Curator-only endpoint that removes a queued deposit request off-chain (no on-chain settlement), recording the rejection with an optional short reason. Takes the request id and returns an acknowledgement. Requires the curator mint-and-burn permission. - [Settle a queued vault deposit](https://v3.docs.derive.xyz/api-reference/vault-curators/settle-a-queued-vault-deposit.md): Curator-only endpoint that settles a pending deposit request by signing a mint approval at a quoted share price (USD per share). Takes the request id and the user's deposit-action hash, mints the corresponding shares, and returns the settlement result. Requires the curator mint-and-burn permission. - [Settle a queued vault withdrawal](https://v3.docs.derive.xyz/api-reference/vault-curators/settle-a-queued-vault-withdrawal.md): Curator-only endpoint that settles a pending withdraw request by signing a burn approval at a quoted share price (USD per share). Takes the request id and the user's withdraw-action hash, burns the shares, and returns the settlement result. Requires the curator mint-and-burn permission. - [Update a vault's off-chain metadata](https://v3.docs.derive.xyz/api-reference/vault-curators/update-a-vaults-off-chain-metadata.md): Applies an off-chain patch to a vault the caller curates, updating any of its display name, description, advisory mark-to-market cap (a USD decimal), or whitelist-only flag. Only the fields supplied are changed. The caller must own the vault's subaccount (i.e. be its curator); description length is… - [Cancel all of a wallet's vault requests](https://v3.docs.derive.xyz/api-reference/vault-shareholders/cancel-all-of-a-wallets-vault-requests.md): Submits a signed cancel action that drains all of the caller's pending deposit and withdraw requests for a given vault and posts the corresponding on-chain operation. Input is the vault subaccount; any subaccount the caller owns may sign. Requires the user-cancel permission. - [Get a single vault by subaccount](https://v3.docs.derive.xyz/api-reference/vault-shareholders/get-a-single-vault-by-subaccount.md): Returns the full vault record — on-chain state plus curator metadata — for one vault subaccount id. Unauthenticated and read-only. - [Get a vault's economic action history](https://v3.docs.derive.xyz/api-reference/vault-shareholders/get-a-vaults-economic-action-history.md): Returns a vault's finalized deposit, withdrawal, fee-accrual, and cancel events — including NAV, share price, high-water mark, and the fee-share split across management, performance, curator, and protocol — at the vault level (per-holder position details are omitted). Inputs are the vault subaccount… - [Get a vault's sampled performance series](https://v3.docs.derive.xyz/api-reference/vault-shareholders/get-a-vaults-sampled-performance-series.md): Returns a time series of a vault's mark-to-market performance (NAV, share price, total and curator shares, high-water mark, optional benchmark) sampled hourly and downsampled to the requested resolution (1h, 8h, 24h, or 1wk). Supports optional from/to unix-second bounds and a limit (newest first, de… - [Get a wallet's paginated vault request history](https://v3.docs.derive.xyz/api-reference/vault-shareholders/get-a-wallets-paginated-vault-request-history.md): Returns the caller's full vault action history (deposits, withdrawals, force-withdrawals, and cancels) across every status — enqueued, requested, applied, cancelled, rejected, or expired — with one row per action at its latest state. Paginated by page and page_size; monetary amounts, prices, and sha… - [Get a wallet's vault share balances](https://v3.docs.derive.xyz/api-reference/vault-shareholders/get-a-wallets-vault-share-balances.md): Returns the caller's share balance for every vault it holds shares in, each paired with the full enriched vault row (the same shape as public/get_vault). The wallet parameter must match the authenticated connection. Read-only. - [List a wallet's pending vault requests](https://v3.docs.derive.xyz/api-reference/vault-shareholders/list-a-wallets-pending-vault-requests.md): Returns the caller's currently-pending vault deposit and withdraw requests, read live from the vault queue. Not paginated (the live queue is bounded); settled and terminal history is served by get_vault_request_history. The wallet parameter must match the authenticated connection. - [List all vaults](https://v3.docs.derive.xyz/api-reference/vault-shareholders/list-all-vaults.md): Returns every vault in the system, each paired with its subaccount id, paginated by page and page_size. Unauthenticated and read-only. - [List vaults a wallet holds shares in](https://v3.docs.derive.xyz/api-reference/vault-shareholders/list-vaults-a-wallet-holds-shares-in.md): Returns the subaccount ids of the vaults in which the given wallet holds shares. The wallet parameter must match the authenticated connection. Read-only. - [Request a deposit into a vault](https://v3.docs.derive.xyz/api-reference/vault-shareholders/request-a-deposit-into-a-vault.md): Submits a signed deposit action from the user's source subaccount and enqueues it in the vault's pending-deposit queue for the curator to settle. Inputs are the target vault subaccount, the deposit asset, and the amount as a decimal string. Returns an acknowledgement with the queued request; require… - [Request a withdrawal from a vault](https://v3.docs.derive.xyz/api-reference/vault-shareholders/request-a-withdrawal-from-a-vault.md): Submits a signed withdraw action that enqueues a request to burn a given number of vault shares and redeem the proceeds to the user's subaccount. Inputs are the vault subaccount and the share quantity to burn (decimal string). Returns an acknowledgement with the queued request; requires the user-wit… - [Access Scopes](https://v3.docs.derive.xyz/authentication/access-scopes.md): The two scope sets that bound what a session key may do. - [Action Signing](https://v3.docs.derive.xyz/authentication/action-signing.md): The EIP-712 scheme every state-changing action must carry. - [Session Keys](https://v3.docs.derive.xyz/authentication/session-keys.md): Delegated signing keys: create, edit, list, and their lifecycle. - [Session Login](https://v3.docs.derive.xyz/authentication/session-login.md): Authenticate a connection or request on behalf of a wallet. - [Changelog](https://v3.docs.derive.xyz/changelog.md): Release notes for the Derive API. - [Connecting over WebSocket](https://v3.docs.derive.xyz/connecting.md): Open a session, send JSON-RPC frames, and keep the connection alive with heartbeats. - [Error Codes](https://v3.docs.derive.xyz/error-codes.md): The JSON-RPC error shape and the full Derive v3 application error catalog. - [Contracts](https://v3.docs.derive.xyz/getting-started/contracts.md): On-chain contract addresses for the Derive v3 testnet (Sepolia) deployment. - [Programmatic Onboarding](https://v3.docs.derive.xyz/getting-started/depositing.md): Integrate your app within minutes. - [Introduction](https://v3.docs.derive.xyz/getting-started/introduction.md): How to interact with the Derive Exchange. - [Quickstart](https://v3.docs.derive.xyz/getting-started/quickstart.md): Make your first trade. - [JSON-RPC Envelope](https://v3.docs.derive.xyz/json-rpc.md): The JSON-RPC 2.0 request/response envelope and the WebSocket and HTTP transports shared by every method. - [Migration skill for your coding agent](https://v3.docs.derive.xyz/migrating/breaking-changes.md): Use this doc as a SKILL.MD for your coding agent to migration your current code to the v3 API. - [Coming soon](https://v3.docs.derive.xyz/migrating/coming-soon.md): v2 methods that are not yet in testnet but will be added before v3 mainnet launch. - [New features](https://v3.docs.derive.xyz/migrating/new-features.md): Methods and capabilities that v3 adds on top of the v2 surface. - [DevEx improvements](https://v3.docs.derive.xyz/migrating/v3-improvements.md): A unified stack - simpler integration - [Rate Limits](https://v3.docs.derive.xyz/rate-limits.md): The two-tier rate-limit model: per-wallet request-budget classes and the per-instrument order-rate limit. - [Subscriptions](https://v3.docs.derive.xyz/subscriptions.md): Real-time WebSocket channels: subscribe to a list of channel names and receive server-pushed notification frames. - [Cancel on Disconnect](https://v3.docs.derive.xyz/trading/cancel-on-disconnect.md): Automatically cancel a wallet's resting orders when its WebSocket connection drops. - [Instrument Names](https://v3.docs.derive.xyz/trading/instrument-names.md): How spot, perp, and option instruments are named on the Derive v3 API. - [Managers & Risk Universes](https://v3.docs.derive.xyz/trading/managers-and-risk-universes.md): How margin managers and risk universes shape what a subaccount can trade and hold. - [Market Maker Protection](https://v3.docs.derive.xyz/trading/market-maker-protection.md): Auto-cancel a maker's quotes and freeze trading when fills breach configurable thresholds within a rolling window. - [Orderbook Trading](https://v3.docs.derive.xyz/trading/order-types.md): Limit and market orders, time-in-force, direction, order flags, trigger and algo orders, replace, and cancellation. - [RFQ Trading](https://v3.docs.derive.xyz/trading/rfq.md): Request a quote on a multi-leg package, collect maker quotes, and execute the block atomically. - [Transfers & Withdrawals](https://v3.docs.derive.xyz/trading/transfers-withdrawals.md): Move collateral between subaccounts, to other wallets, and on-chain, plus transferring positions. - [Create a Vault](https://v3.docs.derive.xyz/vaults/create-a-vault.md): Launch a vault in 3 minutes via the UX or SDK. - [Process Deposits & Withdrawals](https://v3.docs.derive.xyz/vaults/deposits-withdrawals.md): The request-and-settle flow: shareholders queue signed intents; the curator settles each by minting or burning shares at a quoted price. - [Fees](https://v3.docs.derive.xyz/vaults/fees.md): How management and performance fees accrue, the high-water mark and benchmark assets, and the protocol fee share. - [Trade](https://v3.docs.derive.xyz/vaults/trade.md): Trade the vault subaccount like any other subaccount. - [Winddowns](https://v3.docs.derive.xyz/vaults/winddowns.md): Close a vault: settle final withdrawals, force-burn remaining holders, and understand the terminal closed state. ## OpenAPI Specs - [openapi](https://v3.docs.derive.xyz/openapi.json) ## AsyncAPI Specs - [websocket.asyncapi](https://v3.docs.derive.xyz/websocket.asyncapi.json) - [subscriptions.asyncapi](https://v3.docs.derive.xyz/subscriptions.asyncapi.json)