TypeScript SDK — Predictions: Positions & Terms
Query open and settled positions, and manage prediction markets terms acceptance. All methods are on client.predictions. See the patterns guide for the recommended terms-acceptance flow.
getPositions
POST /v1/prediction-markets/positions · Authenticated
Retrieve your current open prediction market positions. Despite being a POST endpoint, parameters are passed as query params. Returns a PositionsResponse with a .positions array and .total count.
Code
Sort options: "positionValue", "+positionValue", "-positionValue", "unrealizedPnl", "+unrealizedPnl", "-unrealizedPnl", "expiryDate", "+expiryDate", "-expiryDate". Prefix + for ascending, - for descending.
Note — Although this uses POST on the wire, the SDK passes
eventTicker,limit,offset, andsortas query parameters, not a request body. POST endpoints are never automatically retried by the SDK.
getSettledPositions
POST /v1/prediction-markets/positions/settled · Authenticated
Retrieve your settled (resolved) prediction market positions. Despite being a POST endpoint, parameters are query params. Returns a SettledPositionsResponse with a .positions array and .total count.
Code
Sort options: "date", "-date", "payout", "+payout", "-payout". A bare field name defaults to descending.
Note — Although this uses POST on the wire, the SDK passes parameters as query parameters. POST endpoints are never automatically retried by the SDK.
acceptPredictionMarketsTerms
POST /v1/prediction-markets/terms/accept · Authenticated
Accept the latest prediction markets terms of service. This is a POST mutation — never automatically retried. You must call this before placing orders if you haven't already accepted.
Code
getPredictionMarketsTerms
GET /v1/prediction-markets/terms · Public
Retrieve the current prediction markets terms of service. Returns a PredictionMarketsTerms object with termsType, version, content, and updatedAt fields.
Code
Auto-retry — This GET endpoint automatically retries on 429/502/503/504 status codes.
getPredictionMarketsTermsStatus
GET /v1/prediction-markets/terms/status · Authenticated
Check whether the authenticated account has accepted the latest terms. Returns a PredictionMarketsTermsStatus object. This is the same check the SDK runs automatically before placeOrder and placeOrderBatch.
Code
Auto-retry — This GET endpoint automatically retries on transient failures.
Tip — You don't normally need to call this directly.
placeOrderandplaceOrderBatchcheck terms automatically and throwAcceptTermsRequiredif not accepted. See the patterns guide for the recommended flow.
What's next
- Events & Discovery — browse and search prediction market events
- Order Management — place, cancel, and query orders
- Combos — multi-leg combo instruments
- Volume & Metrics — daily/hourly volume and per-event share metrics
- Request Validation — how client-side validation works