Skip to main content
curl -X GET "https://api.polyhush.com/api/v1/trading/orders" \
     -H "X-API-Key: your-api-key"

Description

Returns all open GTC (Good Till Cancelled) limit orders for the authenticated user. These are orders that are currently sitting on the order book waiting to be matched.
Market orders (FOK/FAK) execute immediately and will not appear in this list.

Response

orders
array
Array of open order objects.
count
integer
Total number of open orders.

Order Object

id
string
Unique order identifier.
token_id
string
The outcome token ID this order is for.
market_id
string
The market/condition ID.
side
string
Order side: "BUY" or "SELL".
price
number
Limit price per share (0.01 - 0.99).
size
number
Total order size in shares.
filled_size
number
Number of shares already filled.
remaining_size
number
Number of shares still on the order book.
status
string
Order status: "PLACED" or "PARTIALLY_FILLED".
created_at
string
ISO 8601 timestamp when the order was created.
updated_at
string
ISO 8601 timestamp when the order was last updated.
market_question
string
The full market question text.
outcome_name
string
The name of the outcome (e.g., “Yes”, “No”).
{
  "orders": [
    {
      "id": "ord_abc123def456",
      "token_id": "12345678901234567890123456789012345678901234567890123456789012345678901234567890",
      "market_id": "0xabcd1234...5678",
      "side": "BUY",
      "price": 0.45,
      "size": 100,
      "filled_size": 25,
      "remaining_size": 75,
      "status": "PARTIALLY_FILLED",
      "created_at": "2024-01-15T10:30:00.000Z",
      "updated_at": "2024-01-15T11:45:00.000Z",
      "market_question": "Will BTC exceed $100k by end of 2024?",
      "outcome_name": "Yes"
    },
    {
      "id": "ord_xyz789ghi012",
      "token_id": "98765432109876543210987654321098765432109876543210987654321098765432109876543210",
      "market_id": "0xefgh5678...1234",
      "side": "SELL",
      "price": 0.72,
      "size": 50,
      "filled_size": 0,
      "remaining_size": 50,
      "status": "PLACED",
      "created_at": "2024-01-15T14:00:00.000Z",
      "updated_at": "2024-01-15T14:00:00.000Z",
      "market_question": "Will ETH 2.0 launch in Q1 2024?",
      "outcome_name": "No"
    }
  ],
  "count": 2
}

Error Responses

StatusDescription
401Unauthorized - Invalid or missing API key
500Internal server error