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

# public/get_all_instruments

> Returns a paginated, name-descending list of full instrument definitions filtered by `instrument_type`, optional `currency` and optional `risk_universe_id`, with `page`/`page_size` (max 1000) controls and pagination metadata. For options, `expired` selects the listing: `false` returns live options, `true` returns only expired options. An option enters the expired listing up to a minute before it expires, so it does not drop out of both listings at expiry. Perps and spot ignore `expired`. An empty listing returns `instrument_not_found`; a page past the end returns the last page. An option's `settlement_price` here can lag settlement by a few minutes; `public/get_instrument` returns it at once. Public endpoint.



## OpenAPI

````yaml /openapi.json post /public/get_all_instruments
openapi: 3.1.0
info:
  title: Derive v3 API
  version: 0.2.0
  description: JSON-RPC 2.0 methods, served over WebSocket and HTTP POST.
servers:
  - url: https://api.derive.xyz/v3
    description: Production (HTTP POST base)
  - url: https://testnet.api.derive.xyz/v3
    description: Testnet (HTTP POST base)
security: []
tags:
  - name: Subaccounts
    description: >-
      List, inspect, and label subaccounts, portfolios, positions, and
      collateral.
  - name: Session Keys
    description: Register, edit, and list delegated signing keys.
  - name: Account
    description: Wallet-level account information and settings.
  - name: Orderbook
    description: Place, replace, cancel, and query orders, trigger orders, and algos.
  - name: RFQ
    description: 'Request-for-quote: send RFQs, quote, and execute block trades.'
  - name: Liquidations
    description: >-
      Open a Dutch auction against a breaching subaccount, quote the auctions
      running right now, bid on them, and review past ones.
  - name: Vault Shareholders
    description: >-
      Deposit into and withdraw from vaults, and track shares, requests, and
      performance.
  - name: Vault Curators
    description: >-
      Create and operate curated vaults: settle deposit and withdrawal requests,
      and manage vault metadata.
  - name: History
    description: >-
      Per-account historical records: orders, trades, transfers, and
      settlements.
  - name: Market Maker Protection
    description: Configure, read, and reset market-maker protection.
  - name: Transfers & Withdrawals
    description: Move collateral between subaccounts, to other wallets, and on-chain.
  - name: Onchain Actions
    description: >-
      L1 onchain actions submitted via OnchainActionManager: register deposit
      addresses, list pending deposits, and inspect onchain action history.
  - name: System
    description: Rate limits, transaction lookups, and live incidents.
  - name: Market Data
    description: Instruments, currencies, tickers, and market-wide feeds.
  - name: Maker Scoring
    description: Maker programs, score breakdowns, and detailed scoring snapshots.
  - name: Referrals
    description: Referral codes and program performance.
  - name: Other
    description: Uncategorized.
paths:
  /public/get_all_instruments:
    post:
      tags:
        - Market Data
      summary: public/get_all_instruments
      description: >-
        Returns a paginated, name-descending list of full instrument definitions
        filtered by `instrument_type`, optional `currency` and optional
        `risk_universe_id`, with `page`/`page_size` (max 1000) controls and
        pagination metadata. For options, `expired` selects the listing: `false`
        returns live options, `true` returns only expired options. An option
        enters the expired listing up to a minute before it expires, so it does
        not drop out of both listings at expiry. Perps and spot ignore
        `expired`. An empty listing returns `instrument_not_found`; a page past
        the end returns the last page. An option's `settlement_price` here can
        lag settlement by a few minutes; `public/get_instrument` returns it at
        once. Public endpoint.
      operationId: public_get_all_instruments
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/GetAllInstrumentsRequest'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetAllInstrumentsResponse'
        default:
          description: JSON-RPC error (see Error Codes)
components:
  schemas:
    GetAllInstrumentsRequest:
      type: object
      required:
        - expired
        - instrument_type
      properties:
        currency:
          default: null
          type:
            - string
            - 'null'
        expired:
          type: boolean
        instrument_type:
          $ref: '#/components/schemas/AssetType'
        page:
          default: null
          type:
            - integer
            - 'null'
          format: uint64
          minimum: 0
        page_size:
          default: null
          type:
            - integer
            - 'null'
          format: uint64
          minimum: 0
        risk_universe_id:
          default: null
          type:
            - integer
            - 'null'
          format: uint32
          minimum: 0
    GetAllInstrumentsResponse:
      type: object
      required:
        - instruments
        - pagination
      properties:
        instruments:
          type: array
          items:
            $ref: '#/components/schemas/Instrument'
        pagination:
          $ref: '#/components/schemas/Pagination'
    AssetType:
      description: 'Asset type of the instrument: `"option"`, `"perp"`, or `"erc20"`.'
      type: string
      enum:
        - option
        - perp
        - erc20
    Instrument:
      type: object
      required:
        - amount_step
        - base_asset_address
        - base_asset_sub_id
        - base_currency
        - base_fee
        - fifo_min_allocation
        - instrument_name
        - instrument_type
        - is_active
        - maker_fee_rate
        - maximum_amount
        - minimum_amount
        - pro_rata_amount_step
        - pro_rata_fraction
        - quote_currency
        - scheduled_activation
        - scheduled_deactivation
        - taker_fee_rate
        - tick_size
      properties:
        amount_step:
          type: string
        base_asset_address:
          description: >-
            The traded asset's contract address — word 0 (`asset`) of the order
            action `data`. Use this (not `erc20_details`) when signing an order.
          type: string
        base_asset_sub_id:
          description: >-
            The traded asset's sub-id — word 1 (`subId`) of the order action
            `data`. Decimal string; `"0"` for perps and spot.
          type: string
        base_currency:
          type: string
        base_fee:
          type: string
        erc20_details:
          anyOf:
            - $ref: '#/components/schemas/SpotPublicDetails'
            - type: 'null'
        fifo_min_allocation:
          type: string
        instrument_name:
          type: string
        instrument_type:
          $ref: '#/components/schemas/AssetType'
        is_active:
          type: boolean
        maker_fee_rate:
          type: string
        mark_price_fee_rate_cap:
          type:
            - string
            - 'null'
        maximum_amount:
          type: string
        minimum_amount:
          type: string
        option_details:
          anyOf:
            - $ref: '#/components/schemas/OptionDetails'
            - type: 'null'
        perp_details:
          anyOf:
            - $ref: '#/components/schemas/PerpDetails'
            - type: 'null'
        pro_rata_amount_step:
          type: string
        pro_rata_fraction:
          type: string
        quote_currency:
          type: string
        scheduled_activation:
          type: integer
          format: int64
        scheduled_deactivation:
          type: integer
          format: int64
        taker_fee_rate:
          type: string
        tick_size:
          type: string
    Pagination:
      description: Response envelope for paginated RPCs.
      type: object
      required:
        - count
        - num_pages
      properties:
        count:
          type: integer
          format: uint64
          minimum: 0
        num_pages:
          type: integer
          format: uint64
          minimum: 0
    SpotPublicDetails:
      type: object
      required:
        - borrow_index
        - decimals
        - supply_index
        - underlying_erc20_address
      properties:
        borrow_index:
          type: string
        decimals:
          type: integer
          format: uint8
          minimum: 0
        supply_index:
          type: string
        underlying_erc20_address:
          type: string
    OptionDetails:
      type: object
      required:
        - expiry
        - index
        - option_type
        - strike
      properties:
        expiry:
          type: integer
          format: uint64
          minimum: 0
        index:
          type: string
        option_type:
          type: string
        settlement_price:
          type:
            - string
            - 'null'
        strike:
          type: string
    PerpDetails:
      type: object
      required:
        - aggregate_funding
        - funding_rate
        - index
        - max_rate_per_hour
        - min_rate_per_hour
      properties:
        aggregate_funding:
          type: string
        funding_rate:
          type: string
        index:
          type: string
        max_rate_per_hour:
          type: string
        min_rate_per_hour:
          type: string
        srm_perp_margin_requirements:
          description: >-
            Null when no SRM in the instrument's risk universe prices its
            currency.
          anyOf:
            - $ref: '#/components/schemas/SrmPerpMarginRequirements'
            - type: 'null'
    SrmPerpMarginRequirements:
      description: >-
        The SRM's perp margin rates for one `(currency, risk universe)`, and the
        leverage they imply.


        PMRM purposefully does not have a mirror struct as the leverage depends
        heavily on the composition of the portfolio.
      type: object
      required:
        - im_perp_req
        - max_leverage
        - mm_perp_req
      properties:
        im_perp_req:
          description: Initial margin rate, as a fraction of perp notional.
          type: string
        max_leverage:
          description: >-
            `1 / im_perp_req`, rounded to 2 decimals. A zero `im_perp_req`
            scales the perp market out. It reports `"0"` here, not unbounded
            leverage.
          type: string
        mm_perp_req:
          description: Maintenance margin rate, as a fraction of perp notional.
          type: string

````

## Related topics

- [Migration skill for your coding agent](/migrating/breaking-changes.md)
- [Changelog](/changelog.md)
- [public/get_risk_universes](/api-reference/market-data/publicget_risk_universes.md)


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