Player Portal #
The Player Portal gives players the ability to manage their account information. This includes editing their display name and email, and managing account linking. The information populating the Player Portal comes from the AccountRpc.GetAccountV1Request
. The Player Portal is available at the following location when Pragma Engine is running:
- Social Portal: http://localhost:11000
For more information on creating custom pages and adding functionality to Player Portal, see Customization.
Player sign in #
The Sign In page will show a list of all available identity providers. Players with a Pragma Account can sign in using any of the identity providers linked to their account.
If a player attempts to sign in and there is no existing Pragma Account, the player will be prompted to create a new account.
Player sign up #
Players without a Pragma Account should click the Create Account button at the bottom of the Sign In page. On the Sign Up page, players will choose from a list of available identity providers.
If the selected identity provider account is already connected to an existing Pragma Account, a message will appear to inform the player and no new account will be created.
Signing up with a new account will always generate a new Pragma Account. To link multiple identity providers to the same account, see the Linked Accounts section.
Web portal sign in and sign up #
Pragma Engine offers two endpoints for players signing in and signing up on a web portal:
/v1/accounts/authenticatev1
/v1/accounts/createaccountv1
This authentication flow is optimized for web portal sign in and sign up, and only provides social tokens. Since players will be prompted in the web portal when creating an account, this flow prevents accidental account creation.
We recommend using these endpoints only for web portals since they are not subject to login queue. Login queue is integral for managing server load in multiplayer games. These endpoints are for social login only.
Web portal authentication #
To authenticate a player’s Pragma Account call /v1/accounts/authenticatev1
. There are two possible scenarios dependent on if a Pragma Account exists for the given identity provider account:
- If the account exists, it is authenticated and a social token is returned.
- If the account does not exist, the public endpoint returns HTTP 403 Forbidden and the platform returns an
AccountService_NotFound
error message.
Web portal account creation #
To create a Pragma Account for a player call /v1/accounts/createaccountv1
. There are two possible scenarios dependent on if a Pragma Account exists for the given identity provider account:
- If there is an existing account, the public endpoint returns HTTP 409 Conflict and the platform returns an
AccountService_AlreadyExists
error message. - If there is no existing account, a new Pragma Account is created. The newly created account is authenticated and a social token is returned.
Contents #
Topic | Description |
---|---|
Social Player Portal | Understanding the Social Player Portal. |