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

Query Parameters

detailed
boolean
default:"false"
If true, returns enriched positions with current prices, unrealized P&L, and market info.

Response

Returns an array of position objects.

Basic Fields (always included)

market_id
string
Market identifier (condition ID).
token_id
string
Token identifier for this outcome.
side
string
Position side (e.g., "Yes", "No").
size
number
Number of shares held.
average_price
number
Average entry price per share.

Additional fields when detailed=true

market_question
string
The market question text.
outcome_name
string
Name of the outcome you hold.
current_price
number
Current market price for this outcome. May be null if price data is unavailable.
unrealized_pnl
number
Unrealized profit/loss in USDC. May be null if price data is unavailable.
unrealized_pnl_pct
number
Unrealized P&L as a percentage. May be null if price data is unavailable.
market_value
number
Current market value of position. May be null if price data is unavailable.
cost_basis
number
Original cost of position.
reserved_for_sell
number
Shares reserved in pending sell orders.
available_to_sell
number
Shares available to sell (calculated as size - reserved_for_sell). Only included when detailed=true.
Always check available_to_sell before placing sell orders to ensure you don’t try to sell shares that are already reserved in pending orders.
[
  {
    "market_id": "0x1234...abcd",
    "token_id": "12345678901234567890",
    "side": "Yes",
    "size": 100,
    "average_price": 0.55
  }
]