Appearance
Challenge Purchase
Challenges are purchased through your sportsbook's payment flow. FAST does not handle money: your backend collects payment first, then notifies FAST to create the challenge.
Flow
- User selects a challenge tier in your UI.
- Your backend collects payment through your payment system.
- On successful payment, call FAST to create the challenge.
- If FAST returns an error, refund the user.
Endpoint
POST /v1/challenges/purchaseRequest
bash
curl -X POST https://api.fundedfast.eu/v1/challenges/purchase \
-H "X-API-Key: your-api-key" \
-H "Content-Type: application/json" \
-d '{
"userId": "your-user-id",
"challengeTierId": "d3eebc99-9c0b-4ef8-bb6d-6bb9bd380a11"
}'| Field | Type | Required | Description |
|---|---|---|---|
userId | string | yes | Your sportsbook user identifier |
challengeTierId | string (UUID) | yes | ID from GET /v1/challenge-tiers |
referralCode | string | no | Your referral or affiliate code, stored on the challenge for your own tracking |
The purchase needs your server key, or a user token for the same userId (the widget's own purchase). The public widget key alone cannot buy, and a user token for another user gets 403 forbidden.
Responses
201 Created
Challenge created successfully. FAST dispatches a challenge.activated webhook.
json
{
"challenge": {
"id": "a1b2c3d4-...",
"userId": "your-user-id",
"challengeTierId": "d3eebc99-...",
"status": "active",
"ownStake": 100.0,
"bonusAmount": 900.0,
"startingBalance": 1000.0,
"currentBalance": 1000.0,
"targetBalance": 2000.0,
"startedAt": "2026-01-15T10:00:00Z",
"expiresAt": "2026-02-04T10:00:00Z",
"currency": "EUR"
},
"correlationId": "uuid"
}The full object also carries tenantId, rulesetId, refundableOwnStake, peakBalance, failureReason, bet counters, activeDays, dailyLoss and timestamps. currency is the tier's currency; every amount is in it.
The challenge starts at FAST's own clock when the request arrives; a time in the request is ignored. ownStake is what the user actually paid: the tier price less any purchase discount reward. A refund, the stake returned with the first payout and your FAST invoice all use that amount. The discounted part becomes bonus, so the starting balance stays the same.
Your approval URL is asked for that same amount: purchasePrice in the approval is the charged price, after the discount, with tierPrice and purchaseDiscount beside it. If a discount reward expires or arrives between the approval and the purchase, FAST records nothing and answers 409 purchase_price_changed. Release what you reserved and call again; the new approval carries the new price.
409 Conflict
The user cannot start a new challenge right now. The error field says why:
error | Cause |
|---|---|
active_challenge_exists | User already has an active challenge |
challenge_awaiting_choice | User passed a challenge and has not chosen continue or refund yet |
active_funded_account_exists | User has an active funded account |
tier_not_found | No such challenge tier for your tenant |
tier_disabled | The tier exists but is disabled |
user_self_excluded | User is self-excluded |
monthly_challenge_limit_reached | The monthly challenge limit is used up: your plan's limit, or the lower limit you set with PUT /v1/admin/settings/challenge-limit. Every challenge created this calendar month counts, whatever its status |
purchase_price_changed | The purchase discount changed after your approval URL approved the price; nothing was recorded, so call again |
json
{
"error": "active_challenge_exists",
"message": "User already has an active challenge",
"correlationId": "uuid"
}429 Purchase Cooldown
After a challenge fails or is cancelled, the user cannot buy again until the operator's next local midnight (the timezone set in the operator settings, Europe/Zagreb by default). The response says when the cooldown ends:
json
{
"error": "purchase_cooldown",
"message": "Please wait 312 minute(s) before purchasing a new challenge (cooldown expires at the operator's midnight)",
"cooldownUntil": "2026-01-16T00:00:00.000Z",
"correlationId": "uuid"
}402 / 403 Approval
If the purchase comes from the widget, your approval URL must approve it. 403 approval_required means no approval URL is configured (production tenants only; staging auto-approves). 402 purchase_declined means your approval URL declined it. Purchases from your server with a server API key skip the 403 and only call the approval URL if one is set.
400 Bad Request
Missing or invalid required fields.
json
{
"error": "validation_error",
"message": "userId and challengeTierId are required",
"correlationId": "uuid"
}One Active Challenge Per User
FAST enforces a strict one-active-challenge-per-user constraint. A user cannot purchase a new challenge while they have:
- An active challenge in progress
- A passed challenge awaiting the continue/refund choice
- An active funded account
The user can purchase again after a challenge fails, expires or is cancelled, or a funded account is revoked or closed. After a failed or cancelled challenge, the next purchase opens at the operator's next midnight (see the 429 above).
Fetching Available Tiers
List enabled challenge tiers to display in your shop:
bash
curl -H "X-API-Key: your-api-key" \
https://api.fundedfast.eu/v1/challenge-tiersjson
{
"challengeTiers": [
{
"id": "d3eebc99-...",
"name": "Standard",
"ownStake": 100.0,
"bonusAmount": 900.0,
"targetBalance": 2000.0,
"durationDays": 20,
"fundedAccountBalance": 2000.0,
"profitSplitPercent": 80
}
],
"correlationId": "uuid"
}Each tier also carries its challenge ruleset limits (minOdds, maxOdds, minStakePercent, maxStakePercent, maxTicketPayout, maxAccumulatorSelections, minBetsRequired, minActiveDays, dailyDrawdownPercent, cooldownDurationHours, totalDrawdownPercent, luckyBetMaxProfitPercent) for rules disclosure. maxOdds, maxStakePercent and maxTicketPayout are null when there is no limit; cooldownDurationHours is null when the pause lasts until the operator's next local midnight. Only enabled tiers are returned.