Skip to main content
You can request a specific order by its order_id for the authenticated account.

Example Request

{
  "type": "get_order",
  "params": {
    "symbol": "SP500-USD",
    "order_id": "57cc1941-8ad1-4df3-b34c-bb556518befc"
  }
}
  • symbol (required) — the symbol for the order
  • order_id (required) — the order ID to retrieve

Sample Code

# Python (websocket-client)
import json, websocket

API_KEY = "YOUR_API_KEY"

def send(ws, obj): ws.send(json.dumps(obj))

def on_open(ws):
    # Authenticate
    send(ws, {"type": "auth", "params": {"api_key": API_KEY}})
    # Get order
    send(ws, {"type": "get_order", "params": {"symbol": "AAPL-USD", "order_id": "57cc1941-8ad1-4df3-b34c-bb556518befc"}})

ws = websocket.WebSocketApp(
    "wss://trade.qfex.com?api_key=YOUR_API_KEY",
    on_open=on_open,
    on_message=lambda _, m: print("Message:", m)
)
ws.run_forever()

Example Response

{
  "all_orders_response": {
    "orders": [
      {
        "order_id": "2f05173c-992a-426b-bcaf-6b341644bb62",
        "symbol": "GOOG-USD",
        "status": "ACK",
        "quantity": 2.708,
        "price": 251.25,
        "take_profit": 0.0,
        "stop_loss": 0.0,
        "side": "SELL",
        "type": "LIMIT",
        "time_in_force": "GTC",
        "user_id": "0020ce8e-eaee-480e-8d7f-b9241d756ee5",
        "client_order_id": "7a257796-a9c1-49bd-a80b-bcccdc81c103",
        "quantity_remaining": 2.708,
        "update_time": 1758208770.5512846,
        "trade_id": null
      }
    ],
    "stop_orders": []
  }
}
Only open orders (including partially filled) are returned. Filled and fully cancelled orders are not included.