Skip to main content
The Player Authentication API service allows you to verify a player’s identity in your web store using the authentication methods you configure, such as SSO Login, Pre-Authenticated Login, and Game Redirect Login. When a player attempts to log in, Appcharge triggers the Authenticate Player Callback on your server with the login details. This callback prompts your server to validate the player’s credentials and respond with either the player data or an authentication error. After your server returns the player data, Appcharge logs the player into the web store. If a player uses Game Redirect Login, Appcharge first calls the Initiate Game Auth Callback on your server to start an authentication session in your game. Once that session completes, Appcharge calls the Authenticate Player Callback to verify the player’s credentials.
For the full step-by-step flow, see About Game Redirect Login.
Learn more about the Player Authentication feature. With the Player Authentication API service, you can:

Before you begin

Review the following before you begin:
  • Make sure you’ve completed the Player Authentication setup in the Publisher Dashboard.
  • Authenticate Player Callback:
    • The token field varies by login method:
      • SSO Login: Token returned by the SSO provider.
      • Player ID Login: Player ID entered by the player.
    • For both Pre-Authenticated Login and Game Redirect Login, Appcharge sends authMethod: "otp" and includes an otp object:
      • Pre-Authenticated Login: Appcharge extracts the player code and access token from your game’s deeplink and forwards them to your Authenticate Player Callback.
      • Game Redirect Login: Appcharge first calls the Initiate Game Auth Callback on your server to start the flow. Your game responds with the player code and token through the return URL, and Appcharge forwards them to your Authenticate Player Callback. To enable Game Redirect Login, follow Set up Game Redirect Login.
I