---
updatedAt: 2026-08-19T09:49:50.000Z
agentTools:
  projectIndex: https://apidocs.bct.host/llms.txt
---

# Get Order Book

Get the order book of a particular coin-pair.

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "rest-v4",
    "version": "1.1"
  },
  "servers": [
    {
      "url": "https://trade-hk.oslsandbox.com"
    }
  ],
  "components": {
    "securitySchemes": {
      "sec0": {
        "type": "apiKey",
        "in": "header",
        "name": "api-key"
      },
      "sec1": {
        "type": "apiKey",
        "in": "header",
        "name": "api-signature"
      },
      "sec2": {
        "type": "apiKey",
        "in": "header",
        "name": "api-expires"
      }
    }
  },
  "security": [
    {
      "sec0": [],
      "sec1": [],
      "sec2": []
    }
  ],
  "paths": {
    "/api/v4/orderBook/L2": {
      "get": {
        "summary": "Get Order Book",
        "description": "Get the order book of a particular coin-pair.",
        "operationId": "get-order-book",
        "parameters": [
          {
            "name": "symbol",
            "in": "query",
            "description": "<<glossary:Currency-pair>>.",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "depth",
            "in": "query",
            "description": "Order book depth per side. Send 0 for full depth.",
            "schema": {
              "type": "string",
              "default": "25"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n  \"symbol\": \"BTCUSD\",\n  \"asks\": [\n    [\n      \"19268\",\n      \"0.0024\"\n    ],\n    [\n      \"19271\",\n      \"0.0048\"\n    ],\n    [\n      \"19308\",\n      \"0.0042\"\n    ]\n  ],\n  \"bids\": [\n    [\n      \"19253\",\n      \"0.003\"\n    ],\n    [\n      \"19235\",\n      \"0.0048\"\n    ],\n    [\n      \"19231\",\n      \"0.0024\"\n    ],\n    [\n      \"19225\",\n      \"0.0036\"\n    ],\n    [\n      \"19213\",\n      \"0.0048\"\n    ]\n  ],\n  \"updateTime\": \"2022-10-22T14:05:42.365Z\"\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "symbol": {
                      "type": "string",
                      "example": "BTCUSD"
                    },
                    "asks": {
                      "type": "array",
                      "items": {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "example": "19268"
                        }
                      }
                    },
                    "bids": {
                      "type": "array",
                      "items": {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "example": "19253"
                        }
                      }
                    },
                    "updateTime": {
                      "type": "string",
                      "example": "2022-10-22T14:05:42.365Z"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "400",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n   \"error\":{\n      \"message\":\"invalid symbol\",\n      \"name\":\"INVALID_SYMBOL\"\n   }\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "error": {
                      "type": "object",
                      "properties": {
                        "message": {
                          "type": "string",
                          "example": "invalid symbol"
                        },
                        "name": {
                          "type": "string",
                          "example": "INVALID_SYMBOL"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "401",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n   \"error\":{\n      \"message\":\"unable to auth with auth service\",\n      \"name\":\"AUTH_SERVICE_UNABLE_TO_AUTH\"\n   }\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "error": {
                      "type": "object",
                      "properties": {
                        "message": {
                          "type": "string",
                          "example": "unable to auth with auth service"
                        },
                        "name": {
                          "type": "string",
                          "example": "AUTH_SERVICE_UNABLE_TO_AUTH"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "404": {
            "description": "404",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n  \"error\": {\n    \"message\": \"Not found\",\n    \"name\": \"NOT_FOUND\"\n  }\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "error": {
                      "type": "object",
                      "properties": {
                        "message": {
                          "type": "string",
                          "example": "Not found"
                        },
                        "name": {
                          "type": "string",
                          "example": "NOT_FOUND"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "500",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n  \"error\": {\n    \"message\": \"internal server error\",\n    \"name\": \"INTERNAL_SERVER_ERROR\"\n  }\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "error": {
                      "type": "object",
                      "properties": {
                        "message": {
                          "type": "string",
                          "example": "internal server error"
                        },
                        "name": {
                          "type": "string",
                          "example": "INTERNAL_SERVER_ERROR"
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "deprecated": false,
        "security": []
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```