LootLocker
The BasicsGame SystemsContent ManagementPlayer Management
LootLocker
  • 📌The Basics
    • Getting Started
    • What is LootLocker?
    • Core Concepts
      • Players
      • Assets
      • Character Classes
      • API Types
      • Web Console
      • Stage & Live Environments
      • Glossary
    • Unity Quick Start
      • Install the SDK
      • Configure the SDK
      • Authenticate Your First Player
      • Update the SDK
    • Unreal Quick Start
      • Install & Configure the SDK
        • Older versions
      • Authenticate Your First Player
    • Godot Quick Start
      • Install the SDK
      • Configure the SDK
      • Authenticate Your First Player
      • Update the SDK
    • SDKs
    • Samples
      • Authentication Samples
      • Leaderboard Samples
      • Progression Samples
      • Player Samples
    • Launching Your Game
    • Support
      • Error Codes
      • Unreal Marketplace Plugin Support
  • 🎭Players
    • Overview
    • Authentication
      • How To
        • Guest Login
        • Steam
        • Apple
        • Apple Game Center
        • Google
        • Epic Games
        • PlayStation
        • Meta / Oculus
        • Xbox
        • Nintendo Switch
    • Files
      • How To
        • Manage Files in Web Console
        • Work with Files In-Game
    • Inventory
      • How To
        • Work with Player Inventory
    • Messages
      • How To
        • Configure Messages in Web Console
    • Names
      • How To
        • Work with Player Names
    • Player Manager
      • How To
        • Manage Players through Web Console
        • Manage Players In-Game
        • Use Player Operations
    • Unified Player Accounts
      • How To
        • Configure UPA in Web Console
        • Use Remote Login In-Game
        • Connect Identiy Provider to Player
        • External Provider Linking
        • Transition from Guest Login to Other Provider
        • Disconnect Identity Provider from Player
    • White Label Login
      • How To
        • Configure White Label Login
        • Create a New White Label User
        • Request User Verification
        • Handle Returning Users
        • Start a White Label Session
  • 🪙Commerce
    • Overview
    • Catalogs
      • How To
        • Configure Catalogs in LootLocker Console
        • List all Catalogs
        • Use Catalogs In-Game
        • Setup In-Game Store
    • Currencies
      • How To
        • Configure a Currency in Web Console
        • Use Currencies In-Game
    • DLC Management
      • How To
        • Configure DLC in Web Console
        • Use DLC In-Game
    • Entitlements
      • How To
        • Work with Entitlements In-Game
    • Real Money Purchases
      • How To
        • Configure In-App Purchase in Web Console
        • Make Purchases through Google Play Store
        • Make Purchases through Apple Store
        • Make Purchases through Steam Store
    • Virtual Purchases
    • Wallets
      • How To
        • Manage a Wallet in Web Console
        • Use Wallets In-Game
  • ⚔️Content
    • Overview
    • Assets
      • How To
        • Create & Configure an Asset
        • Organize & Search for Assets
        • Retrieve Assets In-Game
        • Set up Asset Storage Template
        • Check Grant Notifications
        • Set up a Game Config Asset
        • Create a Loot Box
        • Work with Loot Boxes In-Game
        • Create a Drop Table
        • Work with Drop Tables In-Game
        • Create a Rental Asset
        • Work with Rental Assets In-Game
    • User Generated Content (UGC)
      • How To
        • Create UGC In-Game
    • Twitch Drops
  • 🕹️Game Systems
    • Overview
    • Classes & Heroes
      • How To
        • Base Classes
        • Hero Classes
        • Implement Classes In-Game
        • Implement Heroes In-Game
    • Leaderboards
      • How To
        • Configure Leaderboard in Web Console
        • Use Player Leaderboards
        • Use Generic Leaderboards
        • Use Metadata to Store Additional Information
        • Use Scheduled Reset with Rewards
        • Use Leaderboards for Time Based Rankings
      • Leaderboard FAQ
      • GameMaker References
    • Feedback
      • How To
        • Manage Feedback Categories
        • Create Player Feedback
        • Create UGC Feedback
        • Create Game Feedback
        • View and Manage Feedback
    • Progressions
      • How To
        • Create a Progression
        • Game Progressions
        • Player Progressions
        • Class Progressions
        • Asset Instance Progressions
    • Triggers
      • How To
        • Setup a trigger in the Web Console
        • Invoke trigger from game
  • ⛓️Shared Systems
    • Overview
    • Metadata
      • How To
        • Add Metadata in Console
        • Fetch a Single Metadata In-Game
        • Fetch Metadata In-Game by Tags
        • Fetch Metadata In-Game from Multiple Sources
    • Notifications
      • How To
        • List Notifications and Mark as Read In-Game
  • 🗝️Admin
    • Settings
    • User Settings
    • Organization Settings
    • CORS Allowlist
  • ⭕️ Legacy
    • Deprecations
      • Unity SDK Deprecation Log
        • Version 2.1.5 - Migration to Open UPM
        • Version 2.0.0
      • Unreal SDK Deprecation Log
        • Version 4.0.0
        • Version 3.0.0
    • Legacy Storage
    • Legacy Triggers
      • Activate a trigger
      • Create a trigger
    • Legacy Progressions
      • Create a Progression System
      • Use a Progression System In-Game
Powered by GitBook
On this page
  • Prerequisites
  • Start Link Flow
  • Poll for Link Status
  • Handle Link Results
  1. Players
  2. Unified Player Accounts
  3. How To

External Provider Linking

PreviousConnect Identiy Provider to PlayerNextTransition from Guest Login to Other Provider

Last updated 21 days ago

In this How-to, we will link an existing Steam Account with a new Epic Games Account using authentication through auth.game.

The overall flow is as follows:

  1. The player starts the linking process in the game client.

  2. The game client redirects the player to the LootLocker authentication website (auth.game).

  3. The player signs in with the provider they want add to their account.

  4. The game client polls the server to check if the player has completed the web flow yet.

  5. Once the player has completed the web flow, the game client links the new provider to the existing account.

Prerequisites

Before we begin, ensure you have the following:

Start Link Flow

We start in the game client, where we initiate the link flow. This will generate a URL that the player can use to authenticate with the provider.

Specific reference for providers are here:

curl --location --request POST 'https://api.lootlocker.com/game/session/remote/link/lease' \
    --header 'x-session-token: your_token_here' \
    --header 'Content-Type: application/json' \
    --data-raw '{
        "game_key": "your_api_key_here",
        "game_version": "1.0.0.0"
    }'

Coming Soon...

Coming Soon...

Poll for Link Status

While the player is authenticating with the provider, we need to poll the server to check if the player has completed the web flow yet. We recommend a polling interval of 2-3 seconds.

Specific reference for providers are here:

curl --location --request POST 'https://api.lootlocker.com/game/session/remote/link/lease' \
    --header 'x-session-token: your_token_here' \
    --header 'Content-Type: application/json' \
    --data-raw '{
        "game_key": "your_api_key_here",
        "game_version": "1.0.0.0"
    }'

Coming Soon...

Coming Soon...

Handle Link Results

Once the player has completed the web flow, the endpoint we have been polling will return a success response with a LootLocker session.

We have 2 main scenarios here:

  • The provider they authenticated with does not exist on another LootLocker account

  • The provider they authenticated with already exists on another LootLocker account

Depending on the scenario, we will need to handle the response differently.

In the following exameple, we will handle the first scenario, where the provider does not exist on another LootLocker account.

Specific reference for providers are here:

The provider name will be returned in the poll response.

    curl --location --request PUT 'https://api.lootlocker.io/game/v1/connected-accounts/transfer-providers' \
    --header 'Content-Type: application/json' \
    --data-raw '{
        "source_token": "session_token_from_game_client_here",
        "target_token": "session_token_from_poll_response_here",
        "identitiy_providers": [
            "provider_name_here",
        ]
    }'

Coming Soon...

Coming Soon...

In the second scenario, where the provider already exists on another LootLocker account, we will need to handle the flow differently.

The steps for moving the provider to the new account are the same as above, but we need to ensure the player understands that they are moving the provider to a different account, and that they might lose access to the old account.

In some games, you might even want to migrate some data from the old account to the new account.

This is a more complex flow, and we recommend reaching out to us for help with this.

🎭
A game created in the LootLocker web console
UPA configured in the LootLocker web console
A player with an active LootLocker game session
Begin Remote Session Link Lease
Begin Remote Session Link Lease
Begin Remote Session Link Lease