API Docs

v1 · Last updated 2026-11-19

This document is for game servers that integrate with Fizzplay. It covers both the APIs your game server calls on Fizzplay and the API Fizzplay calls on your game server. Request and response bodies are UTF-8 JSON (except the login code exchange, which uses a form body). Error message values are in English.

The source of this document is the Markdown file api.md, and the web page is built from that file. For development tools and AI coding assistants, use api.md. Fizzplay server tests send the request examples in this document to the real server and check that the response examples, field names, value types, error codes, and messages match. The info string of each example code block (fizzplay:request METHOD PATH · fizzplay:response METHOD PATH STATUS) shows which request or response the example is.

Overview

EndpointCalled byWhat it does
GET https://accounts.fizzplay.org/authorizeBrowserHands login over to Fizzplay
POST /api/v1/tokenGame serverExchanges a login code for an account
GET https://accounts.fizzplay.org/logoutBrowserEnds the Fizzplay login too when the player logs out of the game
GET /api/v1/accounts/{account_id}Game serverReads the account's current nickname, profile picture, and title
GET /api/v1/accountsGame serverReads the current nickname, profile picture, and title of several accounts at once
POST {events_url}FizzplayTells the game server what happened to an account (account deletion, unlinking, restriction, logout on all devices, profile change) (implemented by the game)
GET https://accounts.fizzplay.org/.well-known/jwks.jsonGame serverPublic keys for verifying account event signatures
PUT /api/v1/avatars/{avatar_id}Game serverRegisters or updates a profile picture
DELETE /api/v1/avatars/{avatar_id}Game serverDeletes a registered profile picture
PUT /api/v1/titles/{title_id}Game serverRegisters or updates a title
DELETE /api/v1/titles/{title_id}Game serverDeletes a registered title
GET /api/v1/itemsGame serverLists the profile pictures and titles the game registered
POST /api/v1/accounts/{account_id}/avatarsGame serverGrants profile pictures
POST /api/v1/accounts/{account_id}/titlesGame serverGrants titles
PUT /api/v1/accounts/{account_id}/avatarGame serverEquips the profile picture the player chose in the game
PUT /api/v1/accounts/{account_id}/titleGame serverEquips or unequips the title the player chose in the game
GET {기록 URL}/internal/fizzplay/profiles/{account_id}FizzplayQueries the game server for a player's records (implemented by the game)
GET /api/v1/accounts/{account_id}/cashGame serverReads the Cash balance
POST /api/v1/accounts/{account_id}/cash/spendGame serverDeducts Cash
POST /api/v1/accounts/{account_id}/cash/reverseGame serverReverses a Cash deduction
GET https://accounts.fizzplay.org/cash/chargeBrowserTop-up screen

Getting started

ItemDetails
SupportedWeb games with a game server. Login results are delivered to your game server's /api/auth/callback (the path cannot be changed; one origin per game). Integrating with only a browser or app and no game server is not supported yet.
Game addressYour game is served at https://<game ID>.fizzplay.org. This address is your game origin. Fizzplay points this name at your game server (DNS), and your game server obtains the certificate itself. Serve only the registered game at this address. Do not build screens that imitate the Fizzplay login screen, and send logins only to accounts.fizzplay.org. Give your game's login cookies the __Host- prefix, and never set Domain=fizzplay.org on any cookie. Before you move your game to another server, tell Fizzplay. Release the old server and its IP only after Fizzplay has pointed the address at the new server. The records URL and the account events URL may be this address or another HTTPS address of your game server.
Base URLhttps://accounts.fizzplay.org. All APIs your game server calls are under /api/v1. The one exception is the public key for verifying account event signatures (/.well-known/jwks.json), which is served without authentication or allowed IPs.
HTTPSHTTPS only. An HTTP request gets a redirect with no body (301 · 308) that points to the https:// address, but by then the API secret key has already gone out unencrypted. HTTP Basic authentication does not encrypt the API secret key, so call https:// URLs from the start. If you set your game server's HTTP client not to follow redirects, you will notice this mistake right away.
AuthenticationHTTP Basic. The username is the game ID and the password is the API secret key: Authorization: Basic base64(GAME_ID:API_SECRET).
Allowed IPsOnly requests from the public IPs of the game servers registered at onboarding (the IPs your game servers use for outbound traffic) are accepted (others get 403 ip_not_allowed). You can register several individual addresses (ranges and CIDR blocks are not accepted), and both IPv4 and IPv6 work. This keeps a leaked API secret key from being used anywhere else. If an IP changes, tell Fizzplay before the change so the registration can be updated.
Accounts you can accessOnly accounts that logged in to your game with Fizzplay and gave consent (linked accounts). An unlinked account gets the same 404 account_not_found as a nonexistent one, even if it exists. If the player unlinks your game on the Fizzplay account screen, requests also get 404, and consent is asked again at the next login. As an exception, a Cash deduction made before the unlinking can still be resent with the same key or reversed after the unlinking.
Concurrent requestsIf more than 4 requests are in progress at once for a game, Fizzplay responds with 429 too_many_requests. When many requests are in progress across all games, you may get 429 with fewer than that. There is no requests-per-second limit.
Account IDaccount_id. A string of up to 64 letters, digits, and underscores (_) (e.g. a_k2m9x0q4z7w1pt). It never changes, so you can use it as is as your game's player ID. The nickname (nickname) can be changed by the player.
LanguageThe account's language (locale) is one of ko · en · ja · zh-Hans (BCP 47). The player sets it in their Fizzplay account, and the game renders its screens in this language. The default language is English: since supported languages may be added, treat unknown values as English (en). Before login, you can render in the same language by reading the fp_locale cookie. Fizzplay sets it for all of fizzplay.org, with one of the same four values. Because the browser sends this value, treat an unknown value as if the cookie were absent. The cookie exists only in browsers that have logged in or chosen a language on Fizzplay. Without it, decide by the browser's language setting (Accept-Language): Fizzplay decides in the same order too (chosen language → device language → country of access → English). Games read this cookie but never set or change it.
TimestampsUnix time in milliseconds (integer). Only iat in account event SETs is in seconds (a JWT rule).
Response fieldsFields may be added to response JSON. Games ignore fields they do not know.
Test environmentThere is no separate test server. On the production server, only payments run in test mode (Test and live).

Errors

A failed request returns a status code and a body in the format below.

{ "error": "account_not_found", "message": "Account not found." }
  • error is the error code. It consists of lowercase letters and underscores and never changes. Games branch on the status code and error code.
  • message is English text for game developers. It may change, so do not branch on it. It is meant for logs; on player screens, show text your game prepared for the error code.
  • Some error codes add more fields (e.g. balance in insufficient_cash).
StatusError codeMeaningEndpoints
400bad_requestThe request body is not JSON, a required field is missing, or a value has the wrong type (e.g. amount is a string or a decimal, grade is a number above 255). When reading multiple accounts: ids is invalid.Reading multiple accounts; profile picture and title registration, granting, and equipping; Cash deduction and reversal
400bad_id · bad_name · bad_image · bad_gradeThe ID, name, image file, or title grade breaks the rules.Profile picture and title registration
400invalid_avatars · invalid_titlesThe list to grant is empty or has more than 200 entries.Profile picture and title granting
400not_issuerThe picture or title was not registered by this game, or was deleted. When unequipping a title: the equipped title belongs to another game.Profile picture and title granting and equipping
400not_ownedThe account does not own the picture or title.Profile picture and title equipping
400invalid_amount · invalid_item · invalid_keyThe amount, item name, or key is out of the allowed range.Cash deduction and reversal (invalid_key only)
401unauthorizedThe game ID or API secret key is wrong.All /api/v1
401invalid_codeThe login code is wrong, expired, or already used. This is also the response when the body is not a form (e.g. JSON) and the code cannot be read.Code exchange
403ip_not_allowedThe request came from somewhere other than a registered game server IP.All /api/v1
403account_suspendedThe account is restricted (temporary suspension or termination of the service agreement), so Cash cannot be deducted. Other endpoints, such as reading accounts, the balance, and reversal, respond as usual.Cash deduction
404account_not_foundThe account does not exist, was deleted, or is not linked with this game.Endpoints that handle accounts (reading multiple accounts reports it in missing, and code exchange as invalid_code)
404item_not_foundNot a picture or title this game registered and still uses.Profile picture and title deletion
404not_foundThe endpoint does not exist.All /api/v1
404no_such_spendThere is no deduction with that key.Cash reversal
409id_takenThe ID is used by another game.Profile picture and title registration
409too_many_itemsThe game has reached the number it can register.Profile picture and title registration
409item_taken_downA Fizzplay operator took this picture or title down. Only an operator can restore it.Profile picture and title registration
409insufficient_cashThe balance is too low.Cash deduction
409key_reusedA different deduction request was sent with the same key.Cash deduction
409daily_limitThis game would exceed the Cash it can deduct from this account in 24 hours.Cash deduction
409key_reversedThe key has already been reversed.Cash deduction
429too_many_requestsToo many requests are in progress at once.All /api/v1
500server_errorA problem on the Fizzplay server.All /api/v1

When to retry:

  • 429 · 5xx · timeouts · dropped connections: send the same request again. Start after 1 second and double the interval each time (up to 30 seconds), and send Cash deductions with the same key. While the Fizzplay server is down, 5xx bodies may not be JSON.
    • Do not resend a code exchange. A code is used only once, so a resent request gets 401 invalid_code. Start the login over from the beginning.
    • If you resend a delete (DELETE) and get 404 item_not_found, the earlier request already deleted it.
  • Any other 4xx: fix the request. Sending it again unchanged gives the same result. However, responses that depend on the account's state, such as insufficient_cash · daily_limit · account_suspended · account_not_found, change when that state changes (a top-up · 24 hours passing · the restriction ending · linking again).

For example, when reading an account:

Response 401

{ "error": "unauthorized", "message": "Game authentication failed." }

Response 403

{ "error": "ip_not_allowed", "message": "Requests from this IP address are not allowed." }

Response 404

{ "error": "account_not_found", "message": "Account not found." }

Handling player data

Games integrated with Fizzplay handle player data by the rules in this section. We check these rules during the onboarding review (Review checklist).

What you receive and where you may use it

  • The only player information Fizzplay gives a game is the account ID, nickname, profile picture, title, and language, plus the Cash balance when the game handles Cash. Fizzplay tells you what happens to an account (account deletion, restrictions, and so on) through account events. It never gives email addresses, names, phone numbers, or Google Account information.
  • Use what you receive only to log the player in and to show the player on your game's screens. Do not use it for advertising or sale, combine it with data from other services, or hand it to anyone else.
  • Use the account's language (locale) only to render that player's own screens. Do not show it to other players.
  • Keep the API secret on the game server only. Never put it in a browser, an app, or a source repository.

Referring to players

  • Refer to players by account_id only. Store account_id for player keys in your database, opponents in match records, friend and block lists, and leaderboards.
  • Never look up players or connect records by nickname. Nicknames change, and a released nickname can be taken by someone else after 30 days.
  • Do not put a unique constraint (UNIQUE) on nickname copies. A copy that has not been updated yet can briefly share a nickname with another player.
  • Link a player to their Fizzplay profile with profile_url from the response. Never build the address from a nickname.

Account copies

The source of truth for the nickname, profile picture, title, and language is Fizzplay; what the game stores is a copy.

  • A copy is a cache. At login and when the player views their own info, read the account again with Reading accounts and overwrite the copy.
  • Once another player's copy was stored more than a day (24 hours) ago, update it with Reading multiple accounts, either before showing it or periodically.
  • When avatar or title comes back as null, clear it from the copy too.
  • If Fizzplay cannot be reached, or you get a 5xx or a timeout, keep using the stored copy. Do not treat this as a missing account.
  • When you receive an account event, update right away without waiting a day. Events can be missed, so keep following the one-day rule. Restrictions and logouts on all devices are not in the Reading accounts response, so you can learn of them only through account events.

Accounts that are gone

  • If you get 404 account_not_found or the account is in missing, the player has either deleted their account or unlinked your game. The two cannot be told apart.
    • Stop showing the copy of that player's nickname, profile picture, and title, and replace it with a nameless label such as "Deleted player". Remove the player from leaderboards.
    • End that player's login sessions in your game.
    • If the player logs in again (they linked your game again), restore the copy. A person who deleted their account never comes back with the same account_id: signing up again with the same Google Account gives a new account_id that is not connected to the old account.
  • When you receive an account deletion event (account-purged), delete that person's Fizzplay copy and the game data that belongs only to them (progress, achievements, owned items, login sessions, and so on) without delay. Keep match records played together, because they are also the other player's records; in them, the person appears as "Deleted player".
  • Delete the game data of a player who unlinked, the same way as for an account deletion, once 7 days have passed since your game learned of the unlinking (when it received the unlinking event or first got 404 or missing). If the player logs in again in the meantime, do not delete it. A player who unlinks and then deletes their account sends your game no deletion event, so this rule covers that case too.
  • This period is stated in the Fizzplay Privacy Policy, and it applies as is to games that have no privacy policy of their own. If your game has its own privacy policy, do not set a longer period there.
  • When your agreement with Fizzplay ends, every player is treated as having unlinked on that day. Delete the information you received through players' Fizzplay accounts and those players' game data by the 7-day rule above.
  • If an unusually large number of accounts come back in missing at once, do not act on them right away; check again. It may be a problem on Fizzplay's side.

Ending game login sessions

Your game creates and manages its own login sessions. End that player's login sessions in your game on every device in the following cases.

  • When you get 404 account_not_found or the account is in missing, and when you receive an account deletion event (account-purged) (Accounts that are gone).
  • When you receive a restriction start event (account-disabled). Fizzplay has restricted that account (temporary suspension or termination of the service agreement).
  • When you receive a logout-on-all-devices event (sessions-revoked). The player or a Fizzplay operator logged that account out on all devices.

When you end sessions because of a restriction or a logout on all devices, do not delete the copy or the game data. The player logs in again and continues playing. While an account is restricted, Fizzplay does not issue a code, so your game does not need to block the login itself.

Login integration

This uses the OAuth 2.0 authorization code flow with PKCE (S256). The game cannot see Fizzplay's session cookie; it only receives a code that can be used just 1 time.

  1. The game server creates a state and a PKCE code_verifier, stores them in the game's cookies, and redirects the browser to Fizzplay /authorize.
  2. Fizzplay handles the login (including nickname setup for new players). The first time a player logs in to this game (including when they log in again after unlinking), Fizzplay shows a consent screen asking whether to log in to this game, and the player must agree to continue. Once the player agrees, the account is linked with this game.
  3. Fizzplay sends the browser to the game's redirect URI: <game origin>/api/auth/callback?code=…&state=…. If the player does not agree, ?error=access_denied&state=… is appended instead of a code.
  4. The game server checks state and exchanges the code for an account at /api/v1/token.
  5. The game creates its own login session with the account_id it received.

1. Redirect the browser to Fizzplay

GEThttps://accounts.fizzplay.org/authorize

Query parameterValue
client_idGame ID
redirect_uri<game origin>/api/auth/callback. Must match the registered redirect URI character for character.
stateA random string created by the game. Up to 128 letters, digits, -, and _
code_challengeThe SHA-256 of code_verifier, encoded as base64url (no padding): 43 characters
code_challenge_methodS256
promptOptional. login makes the player choose a Google account again regardless of the current login state (to log in with a different account).

code_verifier is 43 to 128 characters of letters, digits, -, ., _, and ~ (RFC 7636).

// Node.js (게임 서버)
import { createHash, randomBytes } from 'node:crypto';

const verifier = randomBytes(32).toString('base64url');            // 43자
const challenge = createHash('sha256').update(verifier).digest('base64url');
const state = randomBytes(16).toString('base64url');
// verifier · state는 __Host- 쿠키(HttpOnly · Secure · SameSite=Lax)에 저장한다

const url = new URL('https://accounts.fizzplay.org/authorize');
url.search = new URLSearchParams({
  client_id: 'mygame',
  redirect_uri: 'https://mygame.fizzplay.org/api/auth/callback',
  state,
  code_challenge: challenge,
  code_challenge_method: 'S256',
});
// 302 → url

If the request is invalid (unregistered game, unregistered redirect URI, malformed request), Fizzplay does not redirect to the game and shows an error screen instead.

Fizzplay does not issue a code for a restricted account (temporary suspension or termination of the service agreement). The player sees the reason and period on a Fizzplay notice screen, and the browser does not return to the redirect URI. Your game does not need to do anything.

2. Exchange the code for an account

POST/api/v1/token

The body is a form (application/x-www-form-urlencoded). If you send JSON, the code cannot be read and you get 401 invalid_code. A code can be exchanged only once, within 60 seconds of being issued. A code that failed because of a wrong verifier or redirect URI cannot be used again either, so in that case start over from step 1.

FieldValue
codeThe code received at the redirect URI
code_verifierThe verifier created in step 1
redirect_uriThe same redirect URI as in step 1
curl https://accounts.fizzplay.org/api/v1/token \
  -u "mygame:$FIZZPLAY_API_SECRET" \
  -d code=8f3k…  -d code_verifier=dBjftJeZ4CVP…  \
  -d redirect_uri=https://mygame.fizzplay.org/api/auth/callback

Response 200

{ "account_id": "a_k2m9x0q4z7w1pt", "nickname": "피즈", "locale": "ko", "profile_url": "https://accounts.fizzplay.org/profiles/a_k2m9x0q4z7w1pt" }

Response 401

{ "error": "invalid_code", "message": "The code is invalid, expired, or already used." }

An account whose exchange succeeds is linked with this game (the player agreed on the consent screen), so it can be accessed through the account, profile picture, and Cash APIs below. A player who agreed but did not make it back to your game (a failed callback, a closed window) is linked too, so your game can receive account events for an account_id it has never seen.

Logout

GEThttps://accounts.fizzplay.org/logout

When the player logs out of the game, end the game's login session, then redirect the browser to https://accounts.fizzplay.org/logout?client_id=<game ID>. This also ends the Fizzplay login on that device, and the browser returns to <game origin>/. It keeps the next person from getting into the previous player's account just by pressing the login button. A request that comes from a link opened on another site (Sec-Fetch-Site: cross-site) does not end the Fizzplay login; it only sends the browser back to the game. If client_id is missing or wrong, the Fizzplay login ends and the browser goes to the Fizzplay login screen.

Reading accounts

GET/api/v1/accounts/{account_id}

Response 200

{ "account_id": "a_k2m9x0q4z7w1pt", "nickname": "피즈", "avatar": "mygame-crown", "title": null, "locale": "ko", "profile_url": "https://accounts.fizzplay.org/profiles/a_k2m9x0q4z7w1pt" }
FieldTypeMeaning
account_idstringAccount ID
nicknamestringCurrent nickname
avatarstring · nullID of the equipped profile picture. null means no picture is equipped (including a deleted picture), so draw the first letter of the nickname instead.
titleobject · nullThe equipped title { id, name, grade, game }. It may belong to another game, so its name (locale → name), grade (1–5 · null), and the ID of the game that grants it (game) are included. Use game to show which game a title comes from. null if no title is equipped.
localestringThe account's language. The game renders its screens in this language and treats unknown values as English (en).
profile_urlstringURL of the player's Fizzplay public profile, https://accounts.fizzplay.org/profiles/{account_id}. It is built from the account ID, so it leads to the same person even if the nickname changes. This format does not change.

When linking a player to their Fizzplay profile, use profile_url. Do not build the URL from the nickname: nicknames change, and a nickname that has been given up can be taken by someone else after 30 days.

Reading multiple accounts

GET/api/v1/accounts

Updates, in one request, the copies on screens that show other players, such as rankings, match records, and friend lists. Put 1 to 100 comma-separated account IDs in the ids query parameter. Repeated IDs are counted once. It counts as a single request toward the concurrent request limit.

curl "https://accounts.fizzplay.org/api/v1/accounts?ids=a_k2m9x0q4z7w1pt,a_q8r1s5x7k2m9p4" \
  -u "mygame:$FIZZPLAY_API_SECRET"

Response 200

{
  "accounts": [
    { "account_id": "a_k2m9x0q4z7w1pt", "nickname": "피즈", "avatar": "mygame-pawn", "title": null, "profile_url": "https://accounts.fizzplay.org/profiles/a_k2m9x0q4z7w1pt" }
  ],
  "missing": ["a_q8r1s5x7k2m9p4"]
}
  • accounts: The accounts linked with this game, in the order requested. The fields are account_id · nickname · avatar · title · profile_url, with the same meanings as in Reading accounts. Only values shown on the public profile are included: this API is for drawing other players, so the account's language (locale) is not included.
  • missing: Accounts that don't exist, deleted accounts, accounts not linked with this game, and malformed IDs. These cases are not distinguished.

Response 400

{ "error": "bad_request", "message": "Invalid request body. Expected ids=<1 to 100 comma-separated account ids>." }

If ids is missing, empty, or has more than 100 IDs, the response is 400 bad_request.

Account events

Fizzplay tells the game servers linked with an account what happened to that account. It POSTs a signed Security Event Token (SET, RFC 8417) to the game server (RFC 8935). Events carry no data: if the receiving game needs the account's current values, it reads the account again with Reading accounts.

Register

Tell Fizzplay the URL that receives events (events_url, e.g. https://mygame.fizzplay.org/api/fizzplay/events) at onboarding. Only HTTPS URLs can be registered. Games that haven't registered one are not sent events, so their copies stay in sync only through the one-day rule in Account copies, and they cannot learn of restrictions or logouts on all devices (Ending game login sessions).

Event types

What happenedEvent URIWhen
Account deletionhttps://schemas.openid.net/secevent/risc/event-type/account-purgedThe player deleted their Fizzplay account, or a Fizzplay operator deleted the account. That account_id is never reused.
Unlinkinghttps://fizzplay.org/secevent/link-revokedThe player unlinked this game on the Fizzplay account screen.
Restriction starthttps://schemas.openid.net/secevent/risc/event-type/account-disabledFizzplay restricted that account (temporary suspension or termination of the service agreement). While the account is restricted, Fizzplay does not issue login codes for it or deduct its Cash.
Restriction endhttps://schemas.openid.net/secevent/risc/event-type/account-enabledThe restriction ended (the period expired or it was lifted). The player can log in again.
Logout on all deviceshttps://schemas.openid.net/secevent/risc/event-type/sessions-revokedThe player or a Fizzplay operator logged that account out on all devices.
Profile changehttps://fizzplay.org/secevent/profile-changedOne of the nickname, equipped profile picture, equipped title, or language changed. Changes made in this game are sent too.

The four URIs that start with schemas.openid.net are from the OpenID RISC standard; the other two are defined by Fizzplay. If a profile change has not started being sent yet, later changes are merged into that one event (changes are not merged into an event that has started being sent; they go out separately). So iat is the time of the first of the merged changes. Don't compare iat with the time you last synced your copy to discard an event; always read the account again when you receive one. Profile changes may not go out right away: a change caused by a picture or title being deleted or taken down is sent after 1 minute, and a merged event can be delayed up to 5 minutes from the first change.

A restriction's start and end are each sent once per restriction. When restrictions overlap, a start arrives for each restriction, and the end arrives once, when the last restriction ends. Restrictions that started and ended while the Fizzplay server was down, and restrictions lifted before they started, are not sent.

Receive

POST{events_url}

POST /api/fizzplay/events HTTP/1.1
Host: mygame.fizzplay.org
Content-Type: application/secevent+jwt
Accept: application/json

eyJhbGciOiJFZERTQSIsInR5cCI6InNlY2V2ZW50K2p3dCIsImtpZCI6Imt…

The body is a SET (JWS compact <header>.<payload>.<signature>, each part base64url). Fizzplay waits up to 10 seconds for a response. Decoded, the header and payload look like this.

{ "alg": "EdDSA", "typ": "secevent+jwt", "kid": "kPrK_qmxVWaYVA9wwBF6Iuo3vVzz7TxHCTwXBygrS4k" }
{
  "iss": "https://accounts.fizzplay.org",
  "aud": "mygame",
  "iat": 1763370000,
  "jti": "1f0e9c1a-7d0b-4c5e-9a57-3f0c2d9b8e11",
  "sub_id": { "format": "opaque", "id": "a_k2m9x0q4z7w1pt" },
  "events": { "https://schemas.openid.net/secevent/risc/event-type/account-purged": {} }
}
FieldMeaning
issThe Fizzplay account service, https://accounts.fizzplay.org
audThe game ID of the receiving game
iatWhen it happened. This value alone is Unix time in seconds (a JWT rule).
jtiEvent ID (UUID). It stays the same when the event is sent again.
sub_idThe account, { "format": "opaque", "id": <account_id> } (RFC 9493)
eventsOne event URI mapped to an empty object {}

Verify the signature

  1. Check that the header's alg is EdDSA and typ is secevent+jwt.
  2. Look up the key for kid in Fizzplay's JWKS. Cache a fetched JWKS for up to 1 hour. If an unknown kid arrives, fetch the JWKS again, but leave at least 1 minute between refetches.
  3. Verify the Ed25519 signature over <header>.<payload> exactly as received.
  4. Check that iss is https://accounts.fizzplay.org and aud is the game's own game ID.

GEThttps://accounts.fizzplay.org/.well-known/jwks.json

Response 200

{ "keys": [{ "kty": "OKP", "crv": "Ed25519", "x": "11qYAYKxCrfVS_7TyWQHOg7hcvPapiMlrwIaaPcHURo", "kid": "kPrK_qmxVWaYVA9wwBF6Iuo3vVzz7TxHCTwXBygrS4k", "use": "sig", "alg": "EdDSA" }] }

kid is the JWK thumbprint (RFC 7638) of the public key, so when the key changes, kid changes too. The response carries Cache-Control: public, max-age=3600.

Respond

  • Once verification passes, you may finish processing before responding 202 (no body). However, Fizzplay treats no response within 10 seconds as a failure and sends again, so respond within that time. Fizzplay treats a 2xx as received.
  • Events arrive several at a time (up to 20 per game at once). When a picture or title is deleted, a profile change goes to every account that has it equipped. Calling Reading accounts right inside the receiving handler can exceed the concurrent request limit (4) and cause 429, so respond 202 first, then read the accounts again separately, one at a time, or batch them with Reading multiple accounts.
  • If processing fails, respond with a 5xx. The event will then be sent again.
  • If verification fails, respond 400 with the body below (RFC 8935 Section 2.4). err is one of invalid_request · invalid_key · invalid_issuer · invalid_audience · authentication_failed, and description is human-readable text.
{ "err": "invalid_key", "description": "Unknown kid." }
  • Accept unknown event URIs with 202 and ignore them. More event types may be added.

Retries, duplicates, and order

  • Anything other than a 2xx (connection failure, timeout, 3xx, 4xx, 5xx) is sent again. Redirects are not followed. The intervals before the next attempt are 1 minute, 5 minutes, 30 minutes, 2 hours, 6 hours, 12 hours, 24 hours, 24 hours, and 24 hours. If the event is still not accepted after 10 sends in total (about 4 days), Fizzplay gives up.
  • The same event may arrive twice. Process each jti only once, or make processing it more than once give the same result.
  • Order is not guaranteed. Events carry no data, so reading the current account again on every event gives the right result regardless of order.
  • Events can be missed (events Fizzplay gave up on because the game server could not accept them for more than about 4 days, and restrictions that started and ended while the Fizzplay server was down). The one-day rule in Account copies fills that gap. If a restriction start or logout-on-all-devices event is missed, that player's login sessions in your game last until they expire by your game's own rules. Even then, Fizzplay blocks new logins and Cash deductions for a restricted account.

Handle

  • Account deletion (account-purged): Delete that account's Fizzplay copy (nickname, profile picture, title) and the game data that belongs only to that person. In records shared with other players, show that person as "Deleted player". There is no account to read again.
  • Unlinking (link-revoked) · profile change (profile-changed): Read the account again with Reading accounts. On 200, update the copy; on 404, stop showing the copy ("Deleted player"). If a player who unlinked logs in again (going through the consent screen again), restore the copy. An event for an account_id you have never seen means that player agreed but did not make it back to your game. Your game has no data for that player, so you may accept it with 202 and ignore it.
  • If a player unlinks your game and then deletes their account, no account deletion event is sent to your game (your game only sees 404). Delete that person's data after 7 days, the same as for unlinking.
  • Restriction start (account-disabled) · logout on all devices (sessions-revoked): End that player's login sessions in your game on every device. Do not delete the copy or the game data; there is no need to read the account again.
  • Restriction end (account-enabled): There is nothing to do. Whether an account is restricted is not in the Reading accounts response, so if your game stored the restricted state, clear it on this event. The start and end can arrive out of order, so follow the event with the later iat.

Profile pictures

The game registers profile pictures with Fizzplay and grants them to players. A player equips one of the pictures they own, and the equipped picture shows in every game and on Fizzplay screens. The image file URL is https://fizzplay.org/media/avatars/{avatar id}.webp.

ItemRule
Picture IDUp to 32 lowercase letters, digits, and -. It must be unique across the whole platform, so it starts with <game ID>- (e.g. mygame-crown).
NameAn object of locale → name. ko is required, and each locale's name is 1–20 characters. Line breaks, invisible characters, angle brackets (< >), and words that could impersonate a Fizzplay operator are not accepted (400 bad_name). fizzplay · 운영자 · 관리자 · 고객센터 · 운영팀 · 공식 · official · admin · operator · support · staff · moderator (including words with the same meaning in Japanese and Chinese) are not accepted anywhere in a name. The same goes for spaces or symbols in between, a different letter case, and look-alike characters (0 · o and so on), so Badminton · Support Crew · 비공식 are not accepted either. gm · mod · system · 시스템 · root are not accepted only when they are the whole name. Up to 16 locales; keys must be the account languages (ko · en · ja · zh-Hans) or of the form ll · ll-RR like fr · zh-TW (zh-Hant · es-419 are not accepted). Screens pick the name in the viewer's language → en → ko.
Image fileWebP, square, 128–512px per side, 64KB or less, not animated. It is cropped to a circle on screen, so leave the edges empty.
CountUp to 500 per game (including deleted ones)

Register

PUT/api/v1/avatars/{avatar_id}

Request body

{ "name": { "ko": "달", "en": "Moon" }, "image": "UklGRrALAABXRUJQVlA4IKQLAAD…" }

Response 200

{ "id": "mygame-moon" }

Response 400

{ "error": "bad_id", "message": "ID must be up to 32 lowercase letters, digits, or hyphens, and start with the game ID and a hyphen." }
  • Creates the picture if it doesn't exist, or updates it if it does. Once registered, it can be granted right away without review.
  • Sending the same request again gives the same result (idempotent). You can resend every picture on each deployment, or compare with hash in the registered list and send only the changed ones.
  • image is the image file encoded as a standard base64 string (RFC 4648 Section 4: + · /, with = padding, no line breaks). It is required for a new registration and omitted when you only update the name (if omitted, the image file stays as is). If the base64 is invalid or the request body exceeds 128KB, you get 400 bad_image.
  • Updating the image file also changes the picture for accounts that have it equipped. Picture URLs are cached for 1 hour, so the change can take up to 1 hour to show. A 404 for a picture that doesn't exist is also cached for 1 minute, so the URL of a newly registered or re-registered picture can return 404 for up to 1 minute.
  • Register a different picture under a new ID. If you reuse a deleted ID for a different picture, accounts that received the picture under that ID before will get the new picture, and accounts that had it equipped when it was deleted will have the new picture equipped.
  • Fizzplay operators can take down a picture that breaks the rules. A picture taken down disappears as if deleted, and registering the same ID again returns 409 item_taken_down. Only an operator can restore it.

Delete

DELETE/api/v1/avatars/{avatar_id}

Response 200

{ "id": "mygame-moon" }

Response 404

{ "error": "item_not_found", "message": "This game has no registered item with that ID." }
  • Deletes only pictures registered by this game. Deleting a picture that was already deleted or taken down by a Fizzplay operator gets 404 item_not_found.
  • Once deleted, the picture can no longer be granted, it disappears from the lists of accounts that own it, and accounts that have it equipped go back to no picture (the first letter of the nickname). The picture URL returns 404 (it may stay up to 1 hour because of caching).
  • Players' grant records remain. If you register the same ID again, accounts that received it before own that picture again, and accounts that had it equipped when it was deleted have it equipped again (unless they have equipped another picture since).

Registered list

GET/api/v1/items

Response 200

{
  "avatars": [{ "id": "mygame-crown", "name": { "ko": "왕관" }, "hash": "6d1f0c5e…" }],
  "titles": [{ "id": "mygame-vip", "name": { "ko": "VIP" }, "grade": 2 }]
}

The pictures and titles this game registered and still uses (not deleted). hash is the SHA-256 of the image file in hexadecimal (base 16).

Grant

POST/api/v1/accounts/{account_id}/avatars

Request body

{ "avatars": ["mygame-crown", "mygame-pawn"] }

Response 200

{ "avatar": "mygame-crown" }

Response 400

{ "error": "not_issuer", "message": "This game does not issue that avatar." }
  • Granting: the account comes to own the picture. Equipping: the account uses one of the pictures it owns as its profile picture.
  • avatar in the response is the ID of the picture the account has equipped after the grant.
  • Granting only adds (nothing is taken back). Sending the same request again gives the same result (idempotent).
  • Grant only pictures registered by this game, up to 200 at a time. If even one is invalid, nothing is granted and the response is 400.
  • For an account with no equipped picture (including accounts whose equipped picture was deleted or taken down by a Fizzplay operator), the first picture in the array is equipped automatically. If the player already used a picture in your game, put that picture at the front of the array to carry over their choice.

Equip

PUT/api/v1/accounts/{account_id}/avatar

Request body

{ "avatar": "mygame-pawn" }

Response 200

{ "avatar": "mygame-pawn" }

Response 400

{ "error": "not_owned", "message": "The account does not own that avatar." }
  • Equips the picture the player chose in the game. An account has one profile picture, so it also changes on the Fizzplay public profile and in other games.
  • Only pictures registered by this game and owned by the account can be equipped. A picture from another game, or one that was deleted or taken down by a Fizzplay operator, gets 400 not_issuer, and a picture the account doesn't own gets 400 not_owned.
  • Call this only when the player chose the picture themselves. The game never changes it on the player's behalf. The consent screen at first login tells the player about this, and after a change, the player's Fizzplay account screen shows that it was changed in your game.

Titles

A title is a short phrase the game registers with Fizzplay and grants to players (e.g. Regular VIP). A player equips one of the titles they own (or none), and the equipped title shows on the Fizzplay public profile and in other games. Unlike pictures, a granted title is not equipped automatically.

ItemRule
Title IDUp to 32 lowercase letters, digits, and -. It must be unique across the whole platform, so it starts with <game ID>- (e.g. mygame-regular-2).
NameAn object of locale → name. ko is required, and each locale's name is 1–16 characters. Line breaks, invisible characters, angle brackets (< >), and words that could impersonate a Fizzplay operator are not accepted (400 bad_name). fizzplay · 운영자 · 관리자 · 고객센터 · 운영팀 · 공식 · official · admin · operator · support · staff · moderator (including words with the same meaning in Japanese and Chinese) are not accepted anywhere in a name. The same goes for spaces or symbols in between, a different letter case, and look-alike characters (0 · o and so on), so Badminton · Support Crew · 비공식 are not accepted either. gm · mod · system · 시스템 · root are not accepted only when they are the whole name. Up to 16 locales; keys must be the account languages (ko · en · ja · zh-Hans) or of the form ll · ll-RR like fr · zh-TW (zh-Hant · es-419 are not accepted). Screens pick the name in the viewer's language → en → ko.
gradeDecoration grade 1–5, or null (no decoration). If omitted, it is null: omitting it to update only the name clears the grade, so always send it. Fizzplay draws a different border for each grade. 1 is the lowest.
CountUp to 1000 per game (including deleted ones)

For a title with grades (e.g. a title whose name changes at each grade from Bronze to Diamond), register one title per grade, and when the player reaches a grade, grant the title for that grade.

Register

PUT/api/v1/titles/{title_id}

Request body

{ "name": { "ko": "단골 VIP", "en": "Regular VIP" }, "grade": 2 }

Response 200

{ "id": "mygame-regular-2" }

Response 400

{ "error": "bad_grade", "message": "grade must be 1 to 5 or null." }
  • Creates the title if it doesn't exist, or updates it if it does. Once registered, it can be granted right away without review. Sending the same request again gives the same result (idempotent).
  • Changing the name or grade takes effect immediately for accounts that have the title equipped.
  • Register a different title under a new ID. If you reuse a deleted ID for a different title, accounts that received the title under that ID before will get the new title, and accounts that had it equipped when it was deleted will have the new title equipped.
  • Fizzplay operators can take down a title that breaks the rules. A title taken down disappears as if deleted, and registering the same ID again returns 409 item_taken_down. Only an operator can restore it.

Delete

DELETE/api/v1/titles/{title_id}

Response 200

{ "id": "mygame-regular-2" }

Response 404

{ "error": "item_not_found", "message": "This game has no registered item with that ID." }
  • Deletes only titles registered by this game. Once deleted, the title can no longer be granted, it disappears from the lists of accounts that own it, and accounts that have it equipped go back to no title. Deleting a title that was already deleted or taken down by a Fizzplay operator gets 404 item_not_found.
  • Players' grant records remain. If you register the same ID again, accounts that received it before own that title again, and accounts that had it equipped when it was deleted have it equipped again (unless they have equipped another title since).

Grant

POST/api/v1/accounts/{account_id}/titles

Request body

{ "titles": ["mygame-regular-1", "mygame-regular-2"] }

Response 200

{ "title": null }
  • title in the response is the title the account has equipped after the grant (same format as title in account reads, null if none). Granting alone does not equip.
  • Granting only adds (nothing is taken back). Sending the same request again gives the same result (idempotent).
  • Grant only titles registered by this game, up to 200 at a time. If even one is invalid, nothing is granted and the response is 400.

Equip

PUT/api/v1/accounts/{account_id}/title

Request body

{ "title": "mygame-regular-2" }

Response 200

{ "title": { "id": "mygame-regular-2", "name": { "ko": "단골 VIP", "en": "Regular VIP" }, "grade": 2, "game": "mygame" } }

Response 400

{ "error": "not_issuer", "message": "This game does not issue that title." }
  • Equips the title the player chose in the game, or unequips it with { "title": null }. title in the response is the title equipped afterward (same format as title in account reads, null if none).
  • Only titles registered by this game and owned by the account can be equipped. A title from another game, or one that was deleted or taken down by a Fizzplay operator, gets 400 not_issuer, and a title the account doesn't own gets 400 not_owned. Even if a title from another game is equipped, you can switch to one of your game's titles (there is one title slot).
  • Unequipping works only when the currently equipped title belongs to your game. If it belongs to another game, the response is 400 not_issuer; if no title is equipped, the response is null as is. A request without a title field is not an unequip but 400 bad_request.
  • Call this only when the player chose the title themselves. There is one exception: when you grant a higher-grade title from the same achievement as the equipped title, you may switch the equipped title to it.

Game records

When Fizzplay renders a public profile, "My records" on the portal (fizzplay.org), or how to get pictures and titles on the Fizzplay account screen, it queries your game server for records. It queries only accounts linked with your game. Records are not cached, so Fizzplay queries each time a screen is opened. The game implements this endpoint under the records URL it registered at onboarding (the HTTPS origin of the game server, e.g. https://mygame.fizzplay.org).

GET{기록 URL}/internal/fizzplay/profiles/{account_id}

  • Requests carry Authorization: Bearer <records token>. If the token doesn't match, respond with 401. The records token is a different value from the API secret key and is issued separately at onboarding.
  • Requests carry the viewer's language (ko · en · ja · zh-Hans) in Accept-Language. Send display text in this language. If you don't know the language, send it in English.
  • Respond 200 with the JSON below, or 404 if the account has never played your game.
  • If the response takes longer than 1.5 seconds, the body exceeds 256KB, or the format is wrong, only your game's section on the public profile shows a message that the records could not be loaded, and your game is left out of "My records" on the portal. Fizzplay does not send more than 8 queries to one game at once; queries beyond that are treated as failed to load.
  • Redirects are not followed.

Example 200 response

{
  "version": 1,
  "first_played_at": 1794700000000,
  "last_played_at": 1794800000000,
  "headline": { "label": "티어", "value": "룩", "note": "1342점" },
  "stats": [{ "label": "랭크전", "value": "58판" }],
  "achievements": {
    "total": 29,
    "items": [{
      "id": "regular", "hidden": false, "name": "단골", "grade": "실버",
      "description": "랭크전 100판 하기", "icon": "mygame-coffee", "title": "mygame-regular-3",
      "unlocked_at": 1794700000000, "progress": { "current": 58, "target": 100 }, "rarity": 0.25
    }]
  },
  "recent": [{
    "at": 1794800000000, "title": "랭크전", "result": "승리", "tone": "good",
    "players": [{ "id": "a_x1oio7aq00d985", "team": "상대" }],
    "value": "+18점", "note": "7분"
  }]
}
FieldTypeMeaning
versionintegerVersion of this format. Currently 1
first_played_atintegerWhen the player first played
last_played_atinteger · nullWhen the player last played. The game list on the public profile is sorted by this (by first_played_at if null).
headlineobject · nullHeadline record. It fits on one line of the game list, so keep it short.
headline.label · headline.valuestringLabel and value (e.g. Tier · Rook)
headline.notestring · nullA short note next to the value (e.g. 1342 pts)
stats[]arrayStats. Send the most important first. "My records" on the portal home page shows only the first 3.
stats[].label · stats[].valuestringLabel and value (e.g. Ranked · 58 matches)
achievementsobject · nullAchievements. null for games without achievements
achievements.totalintegerTotal number of achievements in this game (even if not all are in items). If smaller than items, the number of items is used.
achievements.items[].idstringAchievement ID
achievements.items[].hiddenbooleanHidden achievement. Its name, grade, description, icon, title, progress, and unlock rate are not shown until it is unlocked (even if the game sends them). Defaults to false
achievements.items[].name · descriptionstring · nullAchievement name and unlock condition. If the name is null, the achievement ID is shown as is.
achievements.items[].gradestring · nullName of the grade reached (e.g. Silver). null for achievements without grades
achievements.items[].iconstring · nullID of the profile picture this achievement gives. Use only pictures registered by your game.
achievements.items[].titlestring · nullID of the title this achievement gives (for graded achievements, the next grade's title). Use only titles registered by your game. In the player's title list, it shows as a title they get by unlocking this achievement (when the achievement has a name).
achievements.items[].unlocked_atinteger · nullWhen it was unlocked. null means not unlocked yet.
achievements.items[].progressobject · nullProgress { current, target } (integers). Ignored if target is 0 or less; current is clamped to 0–target.
achievements.items[].raritynumber · nullShare of this game's players who unlocked it (0–1)
recent[]arrayRecent records, newest first. See Recent records below

Required fields (if any one is missing, none of that game's records can be read): version · first_played_at · headline.label · headline.value · stats[].label · stats[].value · achievements.total · achievements.items[].id · achievements.items[].progress.current · achievements.items[].progress.target · recent[].at · recent[].title · recent[].players[].id

Nullable fields: last_played_at · headline · headline.note · achievements · achievements.items[].name · achievements.items[].grade · achievements.items[].description · achievements.items[].icon · achievements.items[].title · achievements.items[].unlocked_at · achievements.items[].progress · achievements.items[].rarity · recent[].result · recent[].tone · recent[].players[].team · recent[].value · recent[].note

All other fields may be omitted. Do not send arrays (stats · items · recent · players) or hidden as null; omit them or send an empty array or false.

  • The game sends display text fully composed. Fizzplay shows the strings it receives as is, without needing to know the game's rules. Units (pts, matches, min) and number formats are also up to the game.
  • Send only the headline · stats · achievements · recent your game has. Anything you don't send has no section on the profile.
  • Count and length limits: only the first 8 stats, 200 items, and 20 recent are used, and the rest are dropped. Strings are cut at 120 characters. recent is cut to 20 first, and then entries with an empty title are dropped. Invisible characters in strings (zero-width characters, characters that change text direction, and control characters such as line breaks) are removed before counting.
  • Fizzplay ignores fields not defined in this document. Even if fields are added to this format, version stays 1; it goes up only when the meaning of an existing field changes. In that case, the game switches only after Fizzplay can read the new version first (Fizzplay currently reads only version 1).

Recent records

recent is an array of what the player did recently, newest first. A match, a stage, or an accomplishment is each one line. Fizzplay doesn't know what each line is about; it places the text the game wrote in fixed spots.

FieldValue
atWhen it ended
titleWhat the player did (mode, stage, map). If it is an empty string, the line is dropped.
resultResult text. Up to 6 characters (e.g. Win · 3rd · Clear). The result cell is narrow (about 4 Korean characters), so longer text is shortened on display. Omit it if there is no result.
toneColor tone of the result badge. good (positive) · bad (negative) · neutral (neutral). Missing or undefined values are treated as neutral.
playersAll other accounts that took part (teammates and opponents alike). Up to 16 per line
players[].idAccount ID
players[].teamSide name (e.g. Opponent · Teammate). Accounts with the same team are grouped together.
valueThe most important value (e.g. +18 pts · 128,400 pts · 1:23.456)
noteAn extra value (e.g. 7 min · Full combo)
  • If there is one other account, its nickname shows right on the line; if there are several, the line expands to show them all by side. If team is omitted, they show as one group.
  • Only accounts linked with your game are shown by nickname. With several accounts, the rest are shown only as a count, and if no account can be shown by nickname, the people section is not drawn. You can send every account in the match as is: Fizzplay removes the profile owner.
  • Opponents that are not Fizzplay accounts (bots, bosses) go in title (e.g. Practice · Bot level 5).

Examples by game type:

Gameresult (tone)titlevaluenote
1v1 matchWin (good)Ranked+18 pts7 min
Team matchLoss (bad)5v5 ranked4/7/1131 min
Battle royale3rd (good)Squad · Desert7 kills18 min
Time attackNew record (good)Moonlight Circuit1:23.4560.8 s faster
Score attackS (good)Hard · Stage 12128,400 ptsFull combo
StageClear (good)3-4 Ice Cave★★★2 min 11 s
Co-opFailed (bad)Fire Dragon RaidPhase 312 min
Growth / idleOmittedReached farm level 30OmittedOmitted

Fizzplay Cash

Fizzplay manages Cash balances and the ledger. Top-ups and refunds happen only on Fizzplay, and the game requests a Cash deduction when it sells an item. 1C equals ₩1, and the game name and item name appear as is in the player's "My Cash" history.

Balance

GET/api/v1/accounts/{account_id}/cash

Response 200

{ "account_id": "a_k2m9x0q4z7w1pt", "balance": 12000, "test": true }

If test is true, payments are in test mode (Test and live).

Deduct

POST/api/v1/accounts/{account_id}/cash/spend

FieldValue
amountCash to deduct. 1 to 1,000,000
itemItem name shown in the "My Cash" history. 1–40 characters after trimming leading and trailing spaces; a name with invisible characters (zero-width characters, text direction characters, line breaks, and so on) is not accepted (400 invalid_item) (e.g. Board skin · Neon)
keyA unique value from your game that identifies this purchase (idempotency key). Up to 64 letters, digits, -, _, ., and : (e.g. your game's order ID)
curl https://accounts.fizzplay.org/api/v1/accounts/a_k2m9x0q4z7w1pt/cash/spend \
  -u "mygame:$FIZZPLAY_API_SECRET" -H 'content-type: application/json' \
  -d '{ "amount": 300, "item": "보드 스킨 · 네온", "key": "order-8f2c" }'

Request body

{ "amount": 300, "item": "보드 스킨 · 네온", "key": "order-8f2c" }

Response 200

{ "balance": 11700, "test": true }

Response 409

{ "error": "insufficient_cash", "message": "Insufficient cash.", "balance": 200 }

Response 409

{ "error": "key_reused", "message": "That key was already used for a different spend." }

Response 409

{ "error": "key_reversed", "message": "That key's spend was reversed. Use a new key to purchase again." }

Response 400

{ "error": "invalid_amount", "message": "amount must be between 1 and 1,000,000." }
  • Requests with the same key are deducted only once (idempotent). If you didn't get a response (timeout, dropped connection), send the same request again with the same key. If the deduction already happened, it is not deducted again, and the response is 200 with the current balance. Even if the player unlinked in the meantime, a request with the same key gets the original result. A new deduction for an unlinked account gets 404 account_not_found.
  • A key must be unique per purchase within your game. Sending a request with the same key but a different amount, item, or account gets 409 key_reused, and nothing is deducted.
  • Order: deduct on Fizzplay first, and grant the item after receiving 200. If you ultimately can't grant the item, reverse that deduction with "Reverse" below.
  • With insufficient_cash, nothing was deducted. balance is the current balance. Send the player to the top-up screen.
  • A game can deduct up to 1,000,000C from one account in 24 hours. This is counted as the deductions in the last 24 hours minus the Cash reversed during that time. Beyond that you get 409 daily_limit and nothing is deducted. Do not grant the item, and ask the player to buy again later.
  • With 403 account_suspended, the account is restricted and nothing is deducted. Do not grant the item, and tell the player that their Fizzplay account is restricted. A request you resend with the same key because you got no response gets the original result even after the restriction starts (200 and the balance if it was already deducted).

Reverse

POST/api/v1/accounts/{account_id}/cash/reverse

If you deducted Cash but couldn't grant the item, reverse that deduction (same key) to give the Cash back.

Request body

{ "key": "order-8f2c" }

Response 200

{ "balance": 12000, "test": true }

Response 404

{ "error": "no_such_spend", "message": "This game has no spend for this account with that key." }
  • Reverses only a deduction this game made for that account with that key, and only once. Resending still reverses only once and responds 200 with the current balance (idempotent).
  • Reverses a whole deduction (never part of one). There is no time limit.
  • You can reverse it even if the player unlinked in the meantime. If the account is not linked and has no deduction with that key, the response is 404 account_not_found, not no_such_spend.
  • A reversed key cannot be used to deduct again (409 key_reversed). If the player buys again, send a new key.
  • It appears in the player's "My Cash" history as a canceled purchase.

Send players to the top-up screen

GEThttps://accounts.fizzplay.org/cash/charge

If a player doesn't have enough Cash, send the browser to the top-up screen. After the top-up, the result screen shows a "Back to game name" button.

https://accounts.fizzplay.org/cash/charge?return=https%3A%2F%2Fmygame.fizzplay.org%2Fshop&package=c10000
  • return: the game URL to return to after the top-up. Only URLs that start with your game origin (followed directly by / or nothing), contain no spaces or \, and are up to 1,024 printable ASCII characters are accepted. Otherwise it is ignored without an error, and the result screen has no back button.
  • package: optional. The id of the package to preselect on the charge screen (e.g. c10000; the number is both won and Cash). If missing or unknown, the default package is selected. Packages may change, so use it only when you need to.

Top-up cancellations and games

A player can cancel a top-up within 7 days of topping up, as long as their balance is at least the amount of that top-up. Cancelling requires that much Cash to remain, so the game never needs to take back items it has already sold. Even when a refund through customer support (such as a minor's contract cancellation) returns Cash that was already spent, Fizzplay only deducts Cash from the balance and never asks the game to take back items.

Test and live

  • Payments are currently in test mode (the payment providers' test keys · sandbox). test in Cash responses is true, and no real money changes hands. Anyone can top up with a test payment, so do not grant items of real value during this time.
  • Test payments: choose Toss Payments' quick account transfer on the top-up screen; a test phone number is already filled in, and the password is 000000.
  • When we switch to live, all Cash and history built up in test mode will be deleted. We will announce it before the switch.

Review checklist

  1. Both new and existing players finish logging in and return to the game. If the player cancels on the consent screen at first login, the game receives access_denied and tells the player.
  2. Login fails if the state doesn't match or the code is used twice.
  3. Logging out of the game also ends the Fizzplay login, so the next person can't get into the previous player's account.
  4. When the nickname changes, the game's copy also changes at the next login.
  5. The records endpoint responds 401 when called without a token, and 404 for an account that has never played.
  6. Sending the same purchase twice deducts Cash only once and grants the item only once.
  7. When Cash runs short, the player goes to the top-up screen and comes back to the game.
  8. The API secret key and records token are nowhere in the browser, app, or repository.
  9. Deductions for purchases that couldn't be fulfilled are reversed, and a new key is used when buying again.
  10. The game's headline record, stats, and recent record text read as intended on the public profile.
  11. Pictures and titles chosen in the game show on the Fizzplay public profile, and the equip APIs are called only when the player chooses (except when switching to a higher-grade title from the same achievement).
  12. The age rating shown on the game's first screen and on the portal (rating, content descriptors, rating number) matches the rating certificate. With no rating, no rating is shown.
  13. Copies of other players' nicknames, profile pictures, and titles are updated by reading multiple accounts once they are a day old, and show as "Deleted player" on 404 or missing.
  14. Links to a player's Fizzplay profile use profile_url.
  15. A game that receives account events responds 400 when the signature, iss, or aud doesn't match and 202 when they do, and gets the same result even if the same jti arrives twice.
  16. Players are referred to by account_id only, and are never looked up or connected to records by nickname.
  17. A player that comes back 404 or in missing has their game login sessions ended and is removed from leaderboards, and on a deletion event the game data that belongs only to them is deleted. The data of a player who unlinked is deleted after 7 days.
  18. The game is served at https://<game ID>.fizzplay.org, sets Domain=fizzplay.org on no cookie, and has no screen that imitates the Fizzplay login screen.
  19. A game that receives account events ends that player's game login sessions on every device when it receives a restriction start (account-disabled) or a logout on all devices (sessions-revoked), and does not delete game data. A player whose restriction has ended can log in again.
  20. When a Cash deduction returns 403 account_suspended, the item is not granted and the player is told that their account is restricted.