Accounts, Progress & Multiplayer
QS Play provides its own player account system and cloud-based progress storage. In many cases, games can rely entirely on the platform's account and data services without implementing their own login experience or save infrastructure.
This section describes the available integration approaches, required account-related rules, progress storage recommendations, and multiplayer support.
Accounts & Progress
Integration Options
Choose the approach that best fits your game.
No Account Integration
The game does not display player profile information and does not depend on portal authentication.
Player progress can still be stored using the Data Module:
data.setItem()
data.getItem()
Guest progress survives page refreshes and is automatically transferred to the player's account if the player signs in later.
Portal Account Only
The game displays the current player's profile information using user.getUser():
user.getUser()
This may include the player's name and avatar, for example in the game interface or in a leaderboard stored through the Data Module. No custom backend is required.
Custom Backend Connected to QS Play Accounts
Games with their own backend can associate player records with QS Play accounts using a token for the game backend:
user.getUserToken()
This approach can be used for features such as a global leaderboard or cross-device progress beyond the capabilities of the Data Module.
Required Rules
Guest Players Must Be Able to Play
Guest and unauthenticated players must be able to access gameplay unless mandatory authentication has been approved separately by the QS Play team.
The API returns null from user.getUser():
user.getUser()
for both guests and unauthenticated players.
Do Not Implement Custom Login Screens
Authentication must be handled through the QS Play account system.
Use the authentication prompt:
user.showAuthPrompt()
Do not add custom email, password, or social login forms inside the game.
Handle Account Changes Without Reloading
Players may sign in or sign out while the game is running. Subscribe to authentication changes once during startup using the authentication listener:
user.addAuthListener()
When the authentication state changes, update the game interface and any cached player profile data.
Do Not Treat qsid as a Secret
The qsid value returned by:
user.getUser().qsid
is public and may be used for display or identification. Do not use it to verify a player on your backend.
For backend authentication, use the user token and verify it on your server:
user.getUserToken()
Progress Storage
Use the QS Play Data Module for player progress, settings, achievements, and similar data whenever possible.
The Data Module:
- works for both guests and authenticated players;
- preserves guest progress across page reloads;
- transfers guest data to the player's account after sign-in.
Use a custom backend only when the game requires functionality that the Data Module does not provide, such as a shared leaderboard across players.
When using a custom backend, validate the player with user.getUserToken() rather than trusting a qsid value sent directly by the client.
The Data Module stores your game's own save data, and the portal never reads it. To show the player's level in this game in their portal profile, also report it with game.reportPlayerLevel().
Multiplayer Games
This section applies only to games with online multiplayer functionality.
Multiplayer Responsibilities
QS Play does not provide:
- multiplayer servers;
- room creation or management;
- matchmaking;
- game-state synchronization;
- multiplayer chat.
The game must provide and operate its own networking infrastructure.
The QS Play SDK supports invitation links that pass room or session parameters from the player who creates the invitation to the player who opens it.
Create an Invitation Link
After creating a room on your multiplayer server, generate an invitation link using:
game.inviteLink(params)
Provide the link to the player through an Invite button, copy-to-clipboard action, in-game chat, or another sharing method.
Join a Session from an Invitation
When the game starts, check for invitation parameters using:
game.getInviteParams()
If the result is not null, use the returned parameters to connect the player to the relevant room instead of showing the standard start menu.
Handle Invalid Invitations
The game must handle cases where:
- the room no longer exists;
- the room is full;
- the match has already started;
- the invitation parameters are invalid or no longer usable.
The QS Play SDK does not validate the room state. This remains the responsibility of the game's multiplayer server.
Current Limitations
Multiplayer invitations currently work only when the player opens a shared link, causing the game to load in a new tab or reload the current page.
QS Play does not currently provide:
- live invitation notifications for players already in the game;
- a shared room browser;
- a platform-level friends list;
- rooms discoverable on the portal without a direct link.
If your game requires additional multiplayer functionality, contact the QS Play team before implementation.