Skip to Content
API ReferenceCompetition API

Competition

A round is normal trading, scored over a window. There is no separate competition venue. Product rules are on Trading competition. The ranked board is Leaderboard.

Queue, cards, and payouts need a Privy JWT. A login token is refused. The overview is public.

Endpoints

MethodPathAuthDescription
GET/api/competitionPublicRounds, fees, whether the next round is soon
GET/api/competition/queue-positionPrivy JWTYour queue rank and live or final placement
GET/api/competition/queue-position/cardPrivy JWTJPEG of that standing
GET/api/competition/payout-detailsPrivy JWTWhether you can nominate a prize destination
POST/api/competition/payout-detailsPrivy JWTNominate it, once

The overview is cached briefly. The card is Cache-Control: private, no-store.

Overview

GET /api/competition

curl 'https://api.loafmarkets.com/api/competition'
{ "nextRoundSoon": false, "makerFeeBps": 0, "takerFeeBps": 5, "rounds": [ { "roundNumber": 3, "name": "Round 3", "rules": "…", "startsAt": 1764000000, "endsAt": 1765000000, "participantBatchSize": 50, "status": "ACTIVE", "newAssetMarket": null, "prizePool": [{ "place": 1, "amount": 500 }, { "place": 2, "toPlace": 10, "amount": 50 }], "volumeMultiplierTiers": [{ "minVolume": 0, "multiplier": 1 }], "volumeExponent": 0.5, "pnlMultiplier": 1, "bottomCullPercent": 20, "winners": null } ] }
FieldMeaning
roundsNull when there are none
statusDRAFT, PENDING, PREPARED, ACTIVE, ENDING, or ENDED
prizePool[].amountWhole USDC per participant. A band is inclusive of place and toPlace
winnersSet on a finished round. Otherwise null
newAssetMarketA market list row, or null

A winner:

FieldMeaning
placePlace
handleHandle
walletAddressWallet address

Points are a × volume^e + b × pnl. a is the volume tier’s multiplier, e is volumeExponent, b is pnlMultiplier. Volume is the account’s trade notional in the window, plus its side of each liquidation take. PnL is the change in account value over the window, not counting deposits and withdrawals. A token deposited during the window never adds a gain, whether it is held or sold. If it is sold below its mark at the end of the window, the difference counts as a loss. No route returns the marks themselves.

StatuscodeMeaning
500{ "error": "Failed to fetch competition info" }

Queue position

GET /api/competition/queue-position

{ "position": 12, "queueCount": 140, "leaderboardPosition": 4, "leaderboardPoints": 88.5, "referralCount": 2, "estimatedRoundEntry": 4 }
FieldMeaning
positionAdmission-queue rank
queueCountQueue length
leaderboardPositionLive rank while a round is ACTIVE, or the final place after it ends. Both this and position can be set during the break: a culled account is back in the queue and still on the frozen board
leaderboardPointsPoints on that board
referralCountReferral count
estimatedRoundEntryThe round number this queue rank is expected to enter

Show leaderboardPosition when it is set, otherwise position.

The card, GET /api/competition/queue-position/card, is a JPEG of the same standing.

StatuscodeMeaning
401UNAUTHENTICATEDA missing, invalid, or expired Privy JWT, or a login token
429RATE_LIMITEDToo many requests, or too many share cards, for this account. Retry after the Retry-After seconds
503The queue position is being refreshed, or share cards are busy. Retry shortly, after the Retry-After seconds when it is set
500INTERNAL_ERROR{ "error": "Failed to authenticate request" }. Authentication failed on the server, not because of the JWT. Try again in a moment
500{ "error": "Failed to fetch queue position" } or "Failed to generate queue-position card"

Payout

GET /api/competition/payout-details

{ "eligible": true, "roundNumber": 3, "place": 1, "submission": null }

eligible: false is a 200, not an error: you are not a winner of the latest ended round, or no round has ended. With no ended round, roundNumber, place, and submission are null. Otherwise roundNumber is the latest ended round. place is your rank on its final board, whether you won or not. It is null if you are not on that board. submission set means the prize destination is already nominated.

POST /api/competition/payout-details accepts exactly one of walletAddress or email.

curl -X POST 'https://api.loafmarkets.com/api/competition/payout-details' \ -H "authorization: Bearer $PRIVY_ACCESS_TOKEN" \ -H 'content-type: application/json' \ -d '{"walletAddress":"0xabc…"}'

The response is the same object, with submission: { payoutType, walletAddress, email, submittedAt }. The field you did not send is null. payoutType is WALLET or EMAIL.

StatuscodeMeaning
400INVALID_REQUESTThe body failed validation. Send exactly one of walletAddress or email
401UNAUTHENTICATEDA missing, invalid, or expired Privy JWT, or a login token
403Not a winner
409No round has ended yet, or a destination was already nominated for this round
429RATE_LIMITEDToo many requests for this account. Retry after the Retry-After seconds
503Final results are still being processed. Retry shortly
500INTERNAL_ERROR{ "error": "Failed to authenticate request" }. Authentication failed on the server, not because of the JWT. Try again in a moment
500{ "error": "Failed to fetch payout details" } or "Failed to submit payout details"
Last updated on