Skip to content

POST /api/launch ​

Create a player session and get a ready-to-embed iframe url. Called server-to-server from the operator's backend. See the Launch guide for the full flow.

Endpoint ​

POST https://api.oddyne.com/api/launch

Auth ​

Authorization: Bearer <YOUR_SITE_API_KEY>

Server-side only

The site API key is issued at onboarding and identifies your site. Never call this from the browser — mint the launch on your server and pass only the returned url to the iframe.

Request body ​

JSON, camelCase.

json
{
  "siteId": "<YOUR_SITE_ID>",
  "userId": "<YOUR_PLAYER_ID>",
  "username": "player_display_name",
  "currency": "USD",
  "lang": "en",
  "partner": "affiliate-name",
  "template": "classic",
  "device": "desktop",
  "view": "live",
  "balance": 100.00
}
FieldTypeRequiredNotes
siteIdstringYesMust match the key's site.
userIdstringYesYour internal player id.
usernamestringNoPlayer display name.
currencystringNoISO currency code.
langstringNoLanguage code.
partnerstringNoAffiliate / brand tag (risk grouping).
templatestringNoTheme / branding selector.
deviceenumNomobile | desktop | terminal. Default desktop.
viewenumNolive | prematch | tickets. Default live.
balancenumberNoStarting balance to display.

Request ​

bash
curl -X POST https://api.oddyne.com/api/launch \
  -H "Authorization: Bearer <YOUR_SITE_API_KEY>" \
  -H "Content-Type: application/json" \
  -d '{ "siteId": "<YOUR_SITE_ID>", "userId": "<YOUR_PLAYER_ID>", "currency": "USD", "lang": "en", "device": "desktop", "view": "live" }'

Response 200 ​

json
{
  "url": "https://<EMBED_HOST>/?siteId=<YOUR_SITE_ID>&token=<jwt>&lang=en&theme=classic&view=live&device=desktop",
  "token": "<jwt>",
  "expiresAt": "2026-08-09T12:00:00Z"
}
FieldTypeNotes
urlstringReady-to-embed iframe URL. Embed exactly — do not modify.
tokenstringSigned player session JWT (already in url). Short-lived.
expiresAtstringISO-8601 UTC expiry. Mint a fresh launch per session.

Errors ​

StatusMeaning
400Missing required field (siteId or userId).
401Missing or invalid site API key.
403siteId does not match the key's site.

Integration documentation for the Oddyne Sportsbook.