One Trading API
REST APIWebSocket API
REST APIWebSocket API
  1. Trading
  • 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. Trading

Get Order by Order ID

GET
https://api.onetrading.com/fast/v1/account/orders/{order_id}
Get information about an existing order using the exchange generated order_id.
Will only return orders from the last 30 days.
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request GET 'https://api.onetrading.com/fast/v1/account/orders/'
Response Response Example
200 - Example 1
{
  "order": {
    "account_id": "449e7a5c-69d3-4b8a-aaaf-5c9b713ebc65",
    "order_id": "93101167-9065-4b9c-b98b-5d789a3ed9fe",
    "client_id": "5b3fa7ba-57d3-4017-a65b-d57dcd2db643",
    "amount": "string",
    "side": "BUY",
    "instrument_code": "string",
    "price": "string",
    "time": "2019-08-24T14:15:22Z",
    "sequence": "string",
    "total_fee": "string",
    "fee_currency": "string",
    "time_last_updated": "string",
    "order_book_sequence": "string",
    "filled_amount": "string",
    "status": "BOOKED",
    "average_price": "string"
  },
  "trades": [
    {
      "fee": {
        "fee_amount": "string",
        "fee_currency": "string"
      },
      "trade": {
        "trade_id": "716cb486-5256-4659-973c-189b58daa723",
        "order_id": "93101167-9065-4b9c-b98b-5d789a3ed9fe",
        "account_id": "449e7a5c-69d3-4b8a-aaaf-5c9b713ebc65",
        "amount": "string",
        "side": "BUY",
        "instrument_code": "string",
        "price": "string",
        "time": "2019-08-24T14:15:22Z",
        "sequence": "string",
        "matched_as": "MAKER"
      }
    }
  ]
}

Request

Authorization
Add the parameter
Authorization
to Headers
,whose value is to concatenate the Token after the Bearer.
Example:
Authorization: Bearer ********************
Path Params
order_id
string <uuid>
required
The order ID to fetch order details for

Responses

🟢200Success
application/json
Body
order
object (Order) 
required
account_id
string <uuid>
required
The account ID the order belongs to
order_id
string <uuid>
required
Unique identifier of the order
client_id
string <uuid>
required
Unique client identifier for the order. This can be specified at time of booking the order by the client, otherwise is randomly generated
amount
string 
required
The amount of currency for this order
side
enum<string> 
required
BUY or SELL
Allowed values:
BUYSELL
instrument_code
string 
required
The market identifier for the order
price
string 
required
The price at which the order is set to execute
time
string <date-time>
required
The time the order was booked at
sequence
string 
required
An incremental identifier for tracking the order in the exchange
total_fee
string 
optional
The total cumulative fee paid for the order. This is a sum of fees for all trades executed for this order
fee_currency
string 
optional
The currency code that the fee was paid in
time_last_updated
string 
required
Time of the last activity on the order
order_book_sequence
string 
optional
DEPRECATED - This will be removed soon, use sequence instead
filled_amount
string 
required
The already filled amount of currency for this order
status
enum<string> 
required
The current state of the order is represented by the status, when it first enters the book it will have a status of BOOKED , as trades are executed, it will change to FILL or FILLED_FULLY depending on how much of the order is filled.
If the order is cancelled by the user before any trades are executed, it will have a status of CANCELLED. If there are already trades on the order then subsequently cancelled by the user, the order will have a status of FILLED_CLOSED.
If the order is rejected by the exchange for one of several reasons, it will have a state of either FILLED_REJECTED, INSUFFICIENT_FUNDS, or INSUFFICIENT_LIQUIDITY.
Allowed values:
BOOKEDFILLMOVEDFILLED_FULLYFILLED_CLOSEDFILLED_REJECTEDCANCELLEDINSUFFICIENT_FUNDSINSUFFICIENT_LIQUIDITY
average_price
string 
optional
Weighed average price of all trades belonging to this order. Not present if there are no trades for this order.
trades
array [object {2}] 
required
fee
object (Fee) 
required
trade
object (Trade) 
required
🟠404Record Not Found
🟠400Bad Request
Previous
Create Order
Next
Get Order by Client ID
Built with