LootLocker Unity SDK 8.2.0
Game backend SDK for Unity
Loading...
Searching...
No Matches
Connected Accounts

Detailed Description

Link multiple platform accounts together under a single LootLocker player identity.

Once linked, the same player profile loads regardless of which platform the game is started on, enabling cross-platform progression and cross-saves. Linking can be done via External Linking (redirects to the LootLocker auth.game website; recommended for most cases) or Direct Linking (used when the player is already on the target platform). Also supports transitioning a Guest Login to any other provider.

See the LootLocker documentation.

Function Documentation

◆ ConnectAppleAccountByRestSignIn()

static void LootLocker.Requests.LootLockerSDKManager.ConnectAppleAccountByRestSignIn ( string  authorizationCode,
Action< LootLockerAccountConnectedResponse >  onComplete,
string  forPlayerWithUlid = null 
)
inlinestatic

Connect an Apple Account (authorized by Rest Sign In) to the currently logged in LootLocker account allowing that google account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Apple account is linked into.

Parameters
authorizationCodeAuthorization code, provided by apple during Sign In
onCompleteonComplete Action for handling the response
forPlayerWithUlidOptional : Execute the request for the specified player. If not supplied, the default player will be used.

◆ ConnectDiscordAccount()

static void LootLocker.Requests.LootLockerSDKManager.ConnectDiscordAccount ( string  token,
Action< LootLockerAccountConnectedResponse >  onComplete,
string  forPlayerWithUlid = null 
)
inlinestatic

Connect an Discord Account to the currently logged in LootLocker account allowing that Discord account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Discord account is linked into.

Parameters
tokenThe Token from Discord sign in
onCompleteonComplete Action for handling the response
forPlayerWithUlidOptional : Execute the request for the specified player. If not supplied, the default player will be used.

◆ ConnectEpicAccount()

static void LootLocker.Requests.LootLockerSDKManager.ConnectEpicAccount ( string  Token,
Action< LootLockerAccountConnectedResponse >  onComplete,
string  forPlayerWithUlid = null 
)
inlinestatic

Connect an Epic Account to the currently logged in LootLocker account allowing that Epic account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Epic account is linked into.

Parameters
TokenThe Token from Epic sign in
onCompleteonComplete Action for handling the response
forPlayerWithUlidOptional : Execute the request for the specified player. If not supplied, the default player will be used.

◆ ConnectGoogleAccount() [1/2]

static void LootLocker.Requests.LootLockerSDKManager.ConnectGoogleAccount ( string  idToken,
Action< LootLockerAccountConnectedResponse >  onComplete,
string  forPlayerWithUlid = null 
)
inlinestatic

Connect a Google Account to the currently logged in LootLocker account allowing that google account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Google account is linked into.

Parameters
idTokenThe Id Token from google sign in
onCompleteonComplete Action for handling the response
forPlayerWithUlidOptional : Execute the request for the specified player. If not supplied, the default player will be used.

◆ ConnectGoogleAccount() [2/2]

static void LootLocker.Requests.LootLockerSDKManager.ConnectGoogleAccount ( string  idToken,
GoogleAccountProviderPlatform  platform,
Action< LootLockerAccountConnectedResponse >  onComplete,
string  forPlayerWithUlid = null 
)
inlinestatic

Connect a Google Account (with a Google Platform specified) to the currently logged in LootLocker account allowing that google account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Google account is linked into.

Parameters
idTokenThe Id Token from google sign in
platformGoogle OAuth2 ClientID platform
onCompleteonComplete Action for handling the response
forPlayerWithUlidOptional : Execute the request for the specified player. If not supplied, the default player will be used.

◆ ConnectGooglePlayGamesAccount()

static void LootLocker.Requests.LootLockerSDKManager.ConnectGooglePlayGamesAccount ( string  authCode,
Action< LootLockerAccountConnectedResponse >  onComplete,
string  forPlayerWithUlid = null 
)
inlinestatic

Connect a Google Play Games account to the currently logged in LootLocker account allowing that Google Play Games account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Google Play Games account is linked into.

Parameters
authCodeThe auth code from Google Play Games sign in
onCompleteonComplete Action for handling the response
forPlayerWithUlidOptional : Execute the request for the specified player. If not supplied, the default player will be used.

◆ ConnectNintendoAccount()

static void LootLocker.Requests.LootLockerSDKManager.ConnectNintendoAccount ( string  nsaIdToken,
Action< LootLockerAccountConnectedResponse >  onComplete,
string  forPlayerWithUlid = null 
)
inlinestatic

Connect a Nintendo Switch account to the currently logged in LootLocker account allowing that Nintendo Switch account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Nintendo Switch account is linked into.

Parameters
nsaIdTokenThe NSA ID token from Nintendo Switch sign in
onCompleteonComplete Action for handling the response
forPlayerWithUlidOptional : Execute the request for the specified player. If not supplied, the default player will be used.

◆ ConnectPlaystationAccount()

static void LootLocker.Requests.LootLockerSDKManager.ConnectPlaystationAccount ( string  environment,
string  code,
Action< LootLockerAccountConnectedResponse >  onComplete,
string  forPlayerWithUlid = null 
)
inlinestatic

Connect a Playstation Account to the currently logged in LootLocker account allowing that Playstation account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Playstation account is linked into.

Parameters
environmentThe environment for the playstation account (dev, qa, prod)
codeThe code from playstation sign in
onCompleteonComplete Action for handling the response
forPlayerWithUlidOptional : Execute the request for the specified player. If not supplied, the default player will be used.

◆ ConnectRemoteSessionAccount()

static void LootLocker.Requests.LootLockerSDKManager.ConnectRemoteSessionAccount ( string  Code,
string  Nonce,
Action< LootLockerAccountConnectedResponse >  onComplete,
string  forPlayerWithUlid = null 
)
inlinestatic

Connect an identity provider (authorized using a remote link session) to the currently logged in LootLocker account allowing that authentication method to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Remote Session account is linked into.

Parameters
CodeThe lease code returned with the response when starting a lease process. Note that the process must have concluded successfully first.
NonceThe nonce returned with the response when starting a lease process. Note that the process must have concluded successfully first.
onCompleteonComplete Action for handling the response
forPlayerWithUlidOptional : Execute the request for the specified player. If not supplied, the default player will be used.

◆ ConnectSteamAccount()

static void LootLocker.Requests.LootLockerSDKManager.ConnectSteamAccount ( ref byte[]  ticket,
uint  ticketSize,
Action< LootLockerAccountConnectedResponse >  onComplete,
string  forPlayerWithUlid = null 
)
inlinestatic

Connect a Steam account to the currently logged in LootLocker account using a raw Steam session ticket (byte array).

Internally converts the ticket to hex-encoded format before sending. IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Steam account is linked into

Parameters
ticketThe raw Steam session ticket byte array
ticketSizeThe size of the ticket
onCompleteonComplete Action for handling the response
forPlayerWithUlidOptional : Execute the request for the specified player. If not supplied, the default player will be used.

◆ ConnectTwitchAccount()

static void LootLocker.Requests.LootLockerSDKManager.ConnectTwitchAccount ( string  authorizationCode,
Action< LootLockerAccountConnectedResponse >  onComplete,
string  forPlayerWithUlid = null 
)
inlinestatic

Connect a Twitch Account to the currently logged in LootLocker account allowing that Twitch account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Twitch account is linked into.

Parameters
authorizationCodeThe Authorization Code from Twitch sign in
onCompleteonComplete Action for handling the response
forPlayerWithUlidOptional : Execute the request for the specified player. If not supplied, the default player will be used.

◆ ConnectXboxAccount()

static void LootLocker.Requests.LootLockerSDKManager.ConnectXboxAccount ( string  xboxUserToken,
Action< LootLockerAccountConnectedResponse >  onComplete,
string  forPlayerWithUlid = null 
)
inlinestatic

Connect an Xbox account to the currently logged in LootLocker account allowing that Xbox account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Xbox account is linked into.

Parameters
xboxUserTokenThe Xbox user token
onCompleteonComplete Action for handling the response
forPlayerWithUlidOptional : Execute the request for the specified player. If not supplied, the default player will be used.

◆ DisconnectAccount()

static void LootLocker.Requests.LootLockerSDKManager.DisconnectAccount ( LootLockerAccountProvider  accountToDisconnect,
Action< LootLockerAccountConnectedResponse >  onComplete,
string  forPlayerWithUlid = null 
)
inlinestatic

Disconnect account from the currently logged in account.

Use this to disconnect an account (like a Google or Apple account) that can be used to start sessions for this LootLocker account so that it is no longer allowed to do that IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the provider is disconnected from

Parameters
accountToDisconnectWhat account to disconnect from this LootLocker Account
onCompleteonComplete Action for handling the response
forPlayerWithUlidOptional : Execute the request for the specified player. If not supplied, the default player will be used.

◆ ListConnectedAccounts()

static void LootLocker.Requests.LootLockerSDKManager.ListConnectedAccounts ( Action< LootLockerListConnectedAccountsResponse >  onComplete,
string  forPlayerWithUlid = null 
)
inlinestatic

List identity providers (like Apple, Google, etc.) that are connected to the currently logged in account.

Parameters
onCompleteonComplete Action for handling the response
forPlayerWithUlidOptional : Execute the request for the specified player. If not supplied, the default player will be used.

◆ TransferIdentityProvidersBetweenAccounts()

static void LootLocker.Requests.LootLockerSDKManager.TransferIdentityProvidersBetweenAccounts ( string  FromPlayerWithUlid,
string  ToPlayerWithUlid,
List< LootLockerAccountProvider >  ProvidersToTransfer,
Action< LootLockerListConnectedAccountsResponse >  onComplete 
)
inlinestatic

This endpoint lets you transfer identity providers between two players, provided you have a valid session for both.

The designated identity providers will be transferred FROM the player designated by the FromPlayerWithUlid parameter and TO the player designated by the ToPlayerWithUlid parameter. If any of the providers can not be transferred the whole operation will fail and NO identity providers will be transferred. IMPORTANT: This is a destructive action.Once an identity provider has been transferred they will allow authentication for the target player and no longer authenticate for the source player. This can leave the source player without means of authentication and thus unusable from the game.

** Limitations**

  • You can not move an identity provider that the source player does not have
  • You can not move an identity provider to a player that already has an account from said identity provider associated with their account.
  • You can not move an identity provider which isn't active in your game settings.

NOTE: This method requires LootLockerMultiUserSessionMode.Hotseat to be configured (via LootLockerConfig.multiUserSessionMode), because it needs two simultaneously active local sessions. It will return an error if the current mode is LootLockerMultiUserSessionMode.SingleSession or LootLockerMultiUserSessionMode.ProfileSwitching.

Parameters
FromPlayerWithUlidThe ULID of an authenticated player that you wish to move identity providers FROM
ToPlayerWithUlidThe ULID of an authenticated player that you wish to move identity providers TO
ProvidersToTransferWhich identity providers you wish to transfer
onCompleteonComplete Action for handling the response

Functions

static void LootLocker.Requests.LootLockerSDKManager.ListConnectedAccounts (Action< LootLockerListConnectedAccountsResponse > onComplete, string forPlayerWithUlid=null)
 List identity providers (like Apple, Google, etc.) that are connected to the currently logged in account.
 
static void LootLocker.Requests.LootLockerSDKManager.DisconnectAccount (LootLockerAccountProvider accountToDisconnect, Action< LootLockerAccountConnectedResponse > onComplete, string forPlayerWithUlid=null)
 Disconnect account from the currently logged in account.
 
static void LootLocker.Requests.LootLockerSDKManager.ConnectGoogleAccount (string idToken, Action< LootLockerAccountConnectedResponse > onComplete, string forPlayerWithUlid=null)
 Connect a Google Account to the currently logged in LootLocker account allowing that google account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Google account is linked into.
 
static void LootLocker.Requests.LootLockerSDKManager.ConnectGoogleAccount (string idToken, GoogleAccountProviderPlatform platform, Action< LootLockerAccountConnectedResponse > onComplete, string forPlayerWithUlid=null)
 Connect a Google Account (with a Google Platform specified) to the currently logged in LootLocker account allowing that google account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Google account is linked into.
 
static void LootLocker.Requests.LootLockerSDKManager.ConnectAppleAccountByRestSignIn (string authorizationCode, Action< LootLockerAccountConnectedResponse > onComplete, string forPlayerWithUlid=null)
 Connect an Apple Account (authorized by Rest Sign In) to the currently logged in LootLocker account allowing that google account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Apple account is linked into.
 
static void LootLocker.Requests.LootLockerSDKManager.ConnectTwitchAccount (string authorizationCode, Action< LootLockerAccountConnectedResponse > onComplete, string forPlayerWithUlid=null)
 Connect a Twitch Account to the currently logged in LootLocker account allowing that Twitch account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Twitch account is linked into.
 
static void LootLocker.Requests.LootLockerSDKManager.ConnectSteamAccount (ref byte[] ticket, uint ticketSize, Action< LootLockerAccountConnectedResponse > onComplete, string forPlayerWithUlid=null)
 Connect a Steam account to the currently logged in LootLocker account using a raw Steam session ticket (byte array).
 
static void LootLocker.Requests.LootLockerSDKManager.ConnectXboxAccount (string xboxUserToken, Action< LootLockerAccountConnectedResponse > onComplete, string forPlayerWithUlid=null)
 Connect an Xbox account to the currently logged in LootLocker account allowing that Xbox account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Xbox account is linked into.
 
static void LootLocker.Requests.LootLockerSDKManager.ConnectNintendoAccount (string nsaIdToken, Action< LootLockerAccountConnectedResponse > onComplete, string forPlayerWithUlid=null)
 Connect a Nintendo Switch account to the currently logged in LootLocker account allowing that Nintendo Switch account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Nintendo Switch account is linked into.
 
static void LootLocker.Requests.LootLockerSDKManager.ConnectGooglePlayGamesAccount (string authCode, Action< LootLockerAccountConnectedResponse > onComplete, string forPlayerWithUlid=null)
 Connect a Google Play Games account to the currently logged in LootLocker account allowing that Google Play Games account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Google Play Games account is linked into.
 
static void LootLocker.Requests.LootLockerSDKManager.ConnectEpicAccount (string Token, Action< LootLockerAccountConnectedResponse > onComplete, string forPlayerWithUlid=null)
 Connect an Epic Account to the currently logged in LootLocker account allowing that Epic account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Epic account is linked into.
 
static void LootLocker.Requests.LootLockerSDKManager.ConnectPlaystationAccount (string environment, string code, Action< LootLockerAccountConnectedResponse > onComplete, string forPlayerWithUlid=null)
 Connect a Playstation Account to the currently logged in LootLocker account allowing that Playstation account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Playstation account is linked into.
 
static void LootLocker.Requests.LootLockerSDKManager.ConnectDiscordAccount (string token, Action< LootLockerAccountConnectedResponse > onComplete, string forPlayerWithUlid=null)
 Connect an Discord Account to the currently logged in LootLocker account allowing that Discord account to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Discord account is linked into.
 
static void LootLocker.Requests.LootLockerSDKManager.ConnectRemoteSessionAccount (string Code, string Nonce, Action< LootLockerAccountConnectedResponse > onComplete, string forPlayerWithUlid=null)
 Connect an identity provider (authorized using a remote link session) to the currently logged in LootLocker account allowing that authentication method to start sessions for this player IMPORTANT: If you are using multiple users, be very sure to pass in the correct forPlayerWithUlid parameter as that will be the account that the Remote Session account is linked into.
 
static void LootLocker.Requests.LootLockerSDKManager.TransferIdentityProvidersBetweenAccounts (string FromPlayerWithUlid, string ToPlayerWithUlid, List< LootLockerAccountProvider > ProvidersToTransfer, Action< LootLockerListConnectedAccountsResponse > onComplete)
 This endpoint lets you transfer identity providers between two players, provided you have a valid session for both.