Skip to main content

Get All Orders

Retrieve orders of any status (open, filled, partial, canceled) for a specific pair.

warning

For all transactions related to the private endpoint, you must authorize before sending your request.

For more information you can check our Authentication V1 article. This endpoint requires the Trade API key permission.

  • pairSymbol is required.
  • If neither startTime nor endTime is supplied, the last 1 month of orders is returned.
  • page is zero-based (defaults to 0).
  • limit is optional, must be between 1 and 50, and defaults to 50.

All Orders​

GET /api/v1/allOrders

Query Parameters​

NameTypeDescription
pairSymbol*stringBTCUSDT, ETHUSDT etc.
orderIdlongIf set, returns orders with an id greater than or equal to this order id
startTimelongUnix time in milliseconds
endTimelongUnix time in milliseconds
pageintegerZero-based page number (default 0)
limitintegerPage size, 1–50. Default 50.

Headers​

NameTypeDescription
X-PCK*stringAPI public key.
X-Stamp*integerCurrent time in milliseconds since the Unix epoch (UTC).
X-Signature*stringHMAC-SHA256 signature. See Authentication V1.
X-NonceintegerOptional. Backward tolerance for X-Stamp in milliseconds. Default 5000, maximum 60000.
{
"success": true,
"message": null,
"code": 0,
"data": [
{
"id": 9932534,
"price": "85400.00",
"amount": "0.001",
"quantity": "0.001",
"pairSymbol": "BTCUSDT",
"pairSymbolNormalized": "BTC_USDT",
"type": "buy",
"method": "limit",
"orderClientId": "test",
"time": 1543996112263,
"updateTime": 1543996112263,
"status": "Untouched",
"stopPrice": "0",
"leftAmount": "0.001"
},
{
"id": 9932523,
"price": "85000.00",
"amount": "0.01",
"quantity": "0.01",
"pairSymbol": "BTCUSDT",
"pairSymbolNormalized": "BTC_USDT",
"type": "buy",
"method": "limit",
"orderClientId": "test",
"time": 1543500891493,
"updateTime": 1543501769613,
"status": "Canceled",
"stopPrice": "0",
"leftAmount": null
}
]
}

type is buy or sell, and method is limit or market. status is Untouched, Partial, Closed or Canceled.

Stop orders cannot be placed through the API, but orders you place on the BtcTurk Global website can be stop orders: their method is stoplimit or stopmarket and stopPrice is the trigger price. For other orders stopPrice is "0".

Code Example​

curl -X GET "https://api.global.btcturk.com/api/v1/allOrders?pairSymbol=BTCUSDT&limit=50" \
-H "X-PCK: YOUR_API_PUBLIC_KEY" \
-H "X-Stamp: 1735866257711" \
-H "X-Signature: COMPUTED_SIGNATURE"