HitBTC Order Books API

The Order Books API from HitBTC — 2 operation(s) for order books.

Operations 2

GET /public/orderbook Get order books #
GET /public/orderbook/{symbol} Get an order book #

Documentation

Specifications

Schemas & Data

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/hitbtc:hitbtc-order-books-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

hitbtc-order-books-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Hitbtc Order Books API
  version: ''
  description: 'Operations tagged Order Books across 2 of this provider''s published API definitions: hitbtc-api-v3-spec.yaml, hitbtc-openapi.yml. Each path carries the servers of the definition it was published in.'
servers:
- url: /api/3
- url: https://api.hitbtc.com/api/3
  description: Production; the served spec declares the relative server /api/3 and the docs at api.hitbtc.com name this host
- url: https://api.demo.hitbtc.com/api/3
  description: Demo Environment (Sandbox), per api.hitbtc.com docs
tags:
- name: Order Books
paths:
  /public/orderbook:
    get:
      tags:
      - Order Books
      summary: Get order books
      parameters:
      - $ref: '#/components/parameters/marketData_Symbols'
      - name: depth
        in: query
        schema:
          type: integer
          default: 10
        description: 'The number of price levels.


          ℹ️ Set to `0` to view the full order book.

          '
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/marketData_OrderBookMap'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/marketData_InstrumentNotFound'
                - $ref: '#/components/schemas/marketData_Validation'
        '404':
          $ref: '#/components/responses/marketData_404'
      security: []
      description: '**Permission**: None


        **IP limit**: 30/50'
      operationId: getPublicOrderbook
      x-operation-id-source: derived
    servers:
    - url: /api/3
  /public/orderbook/{symbol}:
    get:
      tags:
      - Order Books
      summary: Get an order book
      parameters:
      - $ref: '#/components/parameters/marketData_SymbolPath'
      - name: depth
        in: query
        schema:
          type: integer
          default: 100
        description: 'The number of price levels.


          ℹ️ Set to `0` to view the full order book.

          '
      - name: volume
        in: query
        schema:
          type: number
        description: 'The minimum total volume among the levels.


          Format: decimal

          '
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/marketData_OrderBook'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/marketData_InstrumentNotFound'
                - $ref: '#/components/schemas/marketData_Validation'
        '404':
          $ref: '#/components/responses/marketData_404'
      security: []
      description: '**Permission**: None


        **IP limit**: 30/50'
      operationId: getPublicOrderbookBySymbol
      x-operation-id-source: derived
    servers:
    - url: /api/3
components:
  responses:
    marketData_404:
      description: Not Found
      content:
        application/json:
          schema:
            type: object
            required:
            - timestamp
            - path
            - status
            - error
            - message
            - requestId
            properties:
              timestamp:
                type: string
                format: date-time
                description: Request timestamp.
                example: '2024-03-22T15:04:05.590Z'
              path:
                type: string
                description: Request path.
                example: /api/3/public/PATH
              status:
                type: integer
                description: Error status.
                example: 404
              error:
                type: string
                description: Error description.
                example: Not Found
              message:
                type: string
                nullable: true
                enum:
                - null
                description: Error message.
              requestId:
                type: string
                description: Request identifier.
                example: 0cdf39b4-28499640
  schemas:
    marketData_Error:
      type: object
      required:
      - timestamp
      - error
      - path
      - requestId
      properties:
        timestamp:
          type: string
          format: date-time
          description: Request timestamp.
        error:
          type: object
          required:
          - description
          - code
          - message
          properties:
            description:
              type: string
              description: Error description.
            code:
              type: integer
              format: int
              description: Error code.
            message:
              type: string
              description: Error description.
        path:
          type: string
          description: Request path.
        requestId:
          type: string
          description: Request identifier.
    marketData_OrderBook:
      title: Order book
      type: object
      required:
      - timestamp
      - ask
      - bid
      properties:
        timestamp:
          type: string
          format: date-time
          description: Publication timestamp.
          example: '2024-06-26T12:32:01.636Z'
        ask:
          type: array
          items:
            type: array
            minItems: 2
            maxItems: 2
            items:
              type: string
          description: Ask levels (price and volume).
          example:
          - '30607.36'
          - '7.63670'
        bid:
          type: array
          items:
            type: array
            minItems: 2
            maxItems: 2
            items:
              type: string
          description: Bid levels (price and volume).
          example:
          - '30362.40'
          - '6.20293'
    marketData_OrderBookMap:
      title: Order books
      type: object
      additionalProperties:
        x-additionalPropertiesName: symbol
        $ref: '#/components/schemas/marketData_OrderBook'
      example:
        BTCUSDT:
          timestamp: '2024-06-26T12:32:01.636Z'
          ask:
          - - '30607.36'
            - '7.63670'
          bid:
          - - '30362.40'
            - '6.20293'
    marketData_InstrumentNotFound:
      title: Instrument not found
      $ref: '#/components/schemas/marketData_Error'
      type: object
      description: Provided currency or symbol not found.
      example:
        timestamp: '2024-03-22T15:04:05.590Z'
        error:
          description: Try get /public/INSTRUMENT, to get list of all available INSTRUMENT.
          code: 2002
          message: 'No such INSTRUMENT: PARAMETER'
        path: /api/3/public/PATH
        requestId: 0cdf39b4-28499640
    marketData_Validation:
      $ref: '#/components/schemas/marketData_Error'
      type: object
      description: "Any of:\n  * missing required parameter;\n  * invalid value of a numeric parameter.\n"
      example:
        timestamp: '2024-03-22T15:04:05.590Z'
        error:
          description: Validation error. Please, check request parameters and try again.
          code: 10001
          message: Bad request parameter [PARAMETER] ISSUE
        path: /api/3/public/PATH
        requestId: 0cdf39b4-28499640
    marketData_SymbolCommon:
      title: Symbol
      type: string
      description: Symbol code.
  parameters:
    marketData_Symbols:
      name: symbols
      in: query
      style: form
      explode: false
      schema:
        type: array
        items:
          $ref: '#/components/schemas/marketData_SymbolCommon'
      description: A comma-separated list of symbol codes.
    marketData_SymbolPath:
      name: symbol
      in: path
      required: true
      schema:
        $ref: '#/components/schemas/marketData_SymbolCommon'
  securitySchemes:
    wallet_BasicAuth:
      type: http
      description: Provide a public key as the username and a secret key as the password.
      scheme: basic
    wallet_BearerAuth:
      type: http
      description: Provide a bearer token obtained from the authentication service.
      scheme: bearer
      bearerFormat: JWT
    trading_BasicAuth:
      type: http
      description: Provide a public key as the username and a secret key as the password.
      scheme: basic
    trading_BearerAuth:
      type: http
      description: Provide a bearer token obtained from the authentication service.
      scheme: bearer
      bearerFormat: JWT
x-refined-from:
- hitbtc-api-v3-spec.yaml
- hitbtc-openapi.yml