BETAThe Prediction Market API is currently in beta and subject to breaking changes as we continue to improve the product. If you have any feedback, please reach out in Discord.
Prerequisite
To use social features, you need:- An API key from the Jupiter Portal
User Profiles
UseGET /profiles/{ownerPubkey} to retrieve a user’s prediction market statistics and performance metrics.
| Field | Description |
|---|---|
realizedPnlUsd | Total realized profit/loss in micro USD |
totalVolumeUsd | Total trading volume in micro USD |
predictionsCount | Total number of predictions made |
correctPredictions | Number of winning predictions |
wrongPredictions | Number of losing predictions |
totalActiveContracts | Current open contract count |
totalPositionsValueUsd | Current portfolio value in micro USD |
P&L History
UseGET /profiles/{ownerPubkey}/pnl-history to retrieve time-series P&L data for charting.
| Parameter | Type | Description |
|---|---|---|
interval | string | Time interval: 24h, 1w, or 1m |
count | number | Number of data points (default: 10) |
Trade Feed
UseGET /trades to retrieve recent trades across the platform. This provides a global activity feed of filled orders.
| Field | Description |
|---|---|
ownerPubkey | Trader’s wallet address |
action | buy or sell |
side | yes or no |
contracts | Number of contracts traded |
priceUsd | Execution price in micro USD |
amountUsd | Total trade value in micro USD |
eventTitle | Parent event title |
marketTitle | Market title |
Leaderboards
UseGET /leaderboards to retrieve competitive rankings.
| Parameter | Type | Description |
|---|---|---|
period | string | Time period: all_time, weekly, monthly |
metric | string | Ranking metric: pnl, volume, win_rate |
limit | number | Number of results (1-100) |
| Metric | Description |
|---|---|
pnl | Ranked by realized profit/loss |
volume | Ranked by total trading volume |
win_rate | Ranked by prediction accuracy |
Use Cases
Analytics Dashboard
Combine leaderboards with profiles for competitive analysis:Summary
| Feature | Endpoint | Description |
|---|---|---|
| Profiles | GET /profiles/{pubkey} | User stats and performance |
| P&L History | GET /profiles/{pubkey}/pnl-history | Time-series P&L data |
| Follow | POST /follow/{pubkey} | Follow a trader |
| Unfollow | DELETE /unfollow/{pubkey} | Unfollow a trader |
| Followers | GET /followers/{pubkey} | List followers |
| Following | GET /following/{pubkey} | List who user follows |
| Trade Feed | GET /trades | Global recent trades |
| Leaderboards | GET /leaderboards | Competitive rankings |
