One Trading API
REST APIWebSocket API
REST APIWebSocket API
  1. Public
  • Public
    • Currencies
      GET
    • Instruments
      GET
    • Candlesticks
      GET
    • Fee Groups
      GET
    • Order Book
      GET
    • Market Ticker
      GET
    • Market Ticker For Instrument
      GET
    • Time
      GET
  • Trading
    • Balances
      GET
    • Fees
      GET
    • Get Orders
      GET
    • Create Order
      POST
    • Get Order by Order ID
      GET
    • Get Order by Client ID
      GET
    • Cancel All Orders
      DELETE
    • Cancel Order by Order ID
      DELETE
    • Cancel Order by Client ID
      DELETE
    • Get Trades for Order
      GET
    • Get Trades
      GET
    • Get Trade by Trade ID
      GET
  • Futures
    • Introduction
    • Funding Rate Methodology
    • Current Funding Rate
      GET
    • Funding Rate History
      GET
    • Futures Portfolio Summary
      GET
    • Get Futures Open Positions
      GET
  1. Public

Order Book

GET
https://api.onetrading.com/fast/v1/order-book/{instrument_code}
public
Get the specified instrument's order book.
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request GET 'https://api.onetrading.com/fast/v1/order-book/?level=1&depth=16'
Response Response Example
200 - Success
{
  "asks": [
    {
      "price": "100000",
      "amount": "6"
    }
  ],
  "bids": [
    {
      "price": "10000",
      "amount": "6"
    }
  ]
}

Request

Path Params
instrument_code
string 
required
Query Params
level
enum<string> 
deprecated
Level 1 = best bid and ask
Level 2 = Compiled order book up to market precision
Level 3 = Full order book
Allowed values:
123
Default:
3
Example:
1
depth
enum<string> 
optional
The amount of bids and asks to return. Depth of 1 will return top of book.
Allowed values:
124816
Default:
16
Example:
16

Responses

🟢200Success
application/json
Body
asks
array [object {2}] 
required
price
string 
required
amount
string 
required
bids
array [object {2}] 
required
price
string 
required
amount
string 
required
🟠400Bad Request
Previous
Fee Groups
Next
Market Ticker
Built with