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

# Get orderbook

> Resting orders aggregated into price levels in the advertised pair orientation. On USDCcNGN-SPOT, bids are orders buying USDC and asks are orders selling it, priced in cNGN per USDC with quantities in USDC. Bid prices round down and ask prices round up to 6 decimal places, and quantities round down, so no level shows a better price or more size than is resting. Responses are cached for up to 5 seconds and carry Cache-Control: public, max-age=5, so polling faster than that returns the same data.



## OpenAPI

````yaml GET /v1/integrations/orderbook
openapi: 3.1.0
info:
  title: Numo orderbook API
  description: >-
    REST endpoints exposed by Numo's markets-service and execution-service for
    dollar stablecoins. Real-time book, trades, and order streams are served
    over the WebSocket endpoint documented in the WebSocket streams reference.
  version: 1.0.0
servers:
  - url: https://api.numofx.com
    description: markets-service
  - url: https://executor.numofx.com
    description: execution-service
security: []
tags:
  - name: Markets service
  - name: Execution service
paths:
  /v1/integrations/orderbook:
    get:
      tags:
        - Markets service
      summary: Get orderbook for integrators
      description: >-
        Resting orders aggregated into price levels in the advertised pair
        orientation. On USDCcNGN-SPOT, bids are orders buying USDC and asks are
        orders selling it, priced in cNGN per USDC with quantities in USDC. Bid
        prices round down and ask prices round up to 6 decimal places, and
        quantities round down, so no level shows a better price or more size
        than is resting. Responses are cached for up to 5 seconds and carry
        Cache-Control: public, max-age=5, so polling faster than that returns
        the same data.
      operationId: getIntegrationOrderbook
      parameters:
        - name: ticker_id
          in: query
          required: true
          schema:
            type: string
          description: >-
            A ticker_id from GET /v1/integrations/tickers, such as
            USDCcNGN-SPOT. An unknown value is rejected rather than answered
            with another market.
        - name: depth
          in: query
          schema:
            type: integer
            minimum: 1
            maximum: 500
            default: 50
          description: Maximum price levels per side.
      responses:
        '200':
          description: Aggregated levels, best first
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/IntegrationOrderbookResponse'
        '400':
          description: Missing or unknown ticker_id, or depth out of range
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
components:
  schemas:
    IntegrationOrderbookResponse:
      type: object
      required:
        - ticker_id
        - timestamp
        - bids
        - asks
      properties:
        ticker_id:
          type: string
        timestamp:
          type: integer
          description: Unix milliseconds at which the book was read.
        bids:
          type: array
          description: >-
            Levels buying the base asset, highest price first. Empty array,
            never null, when there are none.
          items:
            $ref: '#/components/schemas/IntegrationLevel'
        asks:
          type: array
          description: >-
            Levels selling the base asset, lowest price first. Empty array,
            never null, when there are none.
          items:
            $ref: '#/components/schemas/IntegrationLevel'
    ErrorResponse:
      type: object
      properties:
        error:
          type: string
    IntegrationLevel:
      type: array
      description: >-
        [price, quantity]: price in target_currency per base_currency, quantity
        in base_currency, summed over the resting orders at that price.
      prefixItems:
        - type: string
          description: Price
        - type: string
          description: Quantity in the base asset
      minItems: 2
      maxItems: 2

````