5#include "CoreMinimal.h"
8#include "LootLockerIdentityRequestHandler.generated.h"
15UENUM(BlueprintType, Category =
"LootLocker")
67USTRUCT(BlueprintType, Category =
"LootLocker")
73 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
77 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
81 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
85 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
97USTRUCT(BlueprintType, Category =
"LootLocker")
103 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
107 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
116 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
120 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
128USTRUCT(BlueprintType, Category =
"LootLocker")
134 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
138 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
142 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
151USTRUCT(BlueprintType, Category =
"LootLocker")
157 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
161 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
165 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
179USTRUCT(BlueprintType, Category =
"LootLocker")
185 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
189 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
193 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
200USTRUCT(BlueprintType, Category =
"LootLocker")
206 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
210 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
217USTRUCT(BlueprintType, Category =
"LootLocker")
223 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
227 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
237USTRUCT(BlueprintType, Category =
"LootLocker")
243 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
247 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
251 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
255 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
266USTRUCT(BlueprintType, Category =
"LootLocker")
272 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
276 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
280 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
284 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
294 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
298 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
305USTRUCT(BlueprintType, Category =
"LootLocker")
311 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
321USTRUCT(BlueprintType, Category =
"LootLocker")
327 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
331 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
335 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
342USTRUCT(BlueprintType, Category =
"LootLocker")
348 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
355 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
359 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
366USTRUCT(BlueprintType, Category =
"LootLocker")
372 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
376 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
380 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
387USTRUCT(BlueprintType, Category =
"LootLocker")
393 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
397 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
401 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
405 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
414 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
418 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category =
"LootLocker")
void(* FLootLockerDefaultDelegate)(FLootLockerResponse)
Definition LootLockerResponse.h:38
ULootLockerIdentityRequestHandler()
Definition LootLockerIdentityRequestHandler.h:448
static FString GetIdentity(const FLootLockerPlayerData &PlayerData, const FLootLockerIdentityResponseDelegate &OnComplete)
static FString PreviewIdentityMerge(const FLootLockerPlayerData &PlayerData, const FString &MergeIdentityId, const FLootLockerIdentityMergePreviewResponseDelegate &OnComplete)
static void ParseLinkConflict(FLootLockerIdentityLinkResponse &Response)
Parses the 409 merge offer onto the response.
static ELootLockerIdentityProvider SlugToProvider(const FString &Slug)
Resolves a provider slug to its enumerator, or Unknown when this SDK does not map it.
static FString GetProviderCredentialId(const FLootLockerIdentityResponse &Identity, ELootLockerIdentityProvider Provider)
The credential id for a provider, or an empty string when no credential for it is linked.
static FString UnlinkProvider(const FLootLockerPlayerData &PlayerData, const FString &CredentialId, const FLootLockerDefaultDelegate &OnComplete)
static FString ProviderToSlug(ELootLockerIdentityProvider Provider)
The wire slug for a provider, which is the lowercased enumerator name.
static FString LookupIdentities(const FLootLockerPlayerData &PlayerData, const FLootLockerIdentityLookupRequest &Request, const FLootLockerIdentityLookupResponseDelegate &OnComplete)
static FString LinkProvider(const FLootLockerPlayerData &PlayerData, const FLootLockerIdentityLinkRequest &Request, const FLootLockerIdentityLinkResponseDelegate &OnComplete)
static FString MergeIdentities(const FLootLockerPlayerData &PlayerData, const FLootLockerIdentityMergeRequest &Request, const FLootLockerIdentityMergeResponseDelegate &OnComplete)
static void MarkProvidersPresent(FLootLockerIdentityResponse &Response)
Sets has_providers when the payload carried a providers array.
void(* FLootLockerIdentityResponseDelegate)(FLootLockerIdentityResponse)
C++ response delegate for reading the current identity.
Definition LootLockerIdentityRequestHandler.h:428
void(* FLootLockerIdentityMergePreviewResponseDelegate)(FLootLockerIdentityMergePreviewResponse)
C++ response delegate for previewing an identity merge.
Definition LootLockerIdentityRequestHandler.h:434
void(* FLootLockerIdentityLookupResponseDelegate)(FLootLockerIdentityLookupResponse)
C++ response delegate for looking identities up.
Definition LootLockerIdentityRequestHandler.h:430
ELootLockerIdentityProvider
Platforms that can be presented as a credential when linking a provider to an identity.
Definition LootLockerIdentityRequestHandler.h:27
void(* FLootLockerIdentityLinkResponseDelegate)(FLootLockerIdentityLinkResponse)
C++ response delegate for linking a provider credential.
Definition LootLockerIdentityRequestHandler.h:432
void(* FLootLockerIdentityMergeResponseDelegate)(FLootLockerIdentityMergeResponse)
C++ response delegate for merging identities.
Definition LootLockerIdentityRequestHandler.h:436
@ Google_sign_in
Definition LootLockerIdentityRequestHandler.h:44
@ Google_play_games
Definition LootLockerIdentityRequestHandler.h:50
@ Nintendo_switch
Definition LootLockerIdentityRequestHandler.h:39
@ Steam
Definition LootLockerIdentityRequestHandler.h:34
@ Epic_games
Definition LootLockerIdentityRequestHandler.h:45
@ Lootlocker_delegation
Definition LootLockerIdentityRequestHandler.h:48
@ Twitch
Definition LootLockerIdentityRequestHandler.h:49
@ Google_play_store
Definition LootLockerIdentityRequestHandler.h:37
@ Publisher_account
A publisher account credential (email).
Definition LootLockerIdentityRequestHandler.h:56
@ White_label_login
Definition LootLockerIdentityRequestHandler.h:41
@ Apple_app_store
Definition LootLockerIdentityRequestHandler.h:36
@ Unknown
A provider this SDK does not recognise, or one the response did not populate.
Definition LootLockerIdentityRequestHandler.h:33
@ Discord
Definition LootLockerIdentityRequestHandler.h:51
@ Psn
Definition LootLockerIdentityRequestHandler.h:35
@ Apple_sign_in
Definition LootLockerIdentityRequestHandler.h:43
@ Apple_game_center
Definition LootLockerIdentityRequestHandler.h:46
@ Guest
Definition LootLockerIdentityRequestHandler.h:42
@ Meta
Definition LootLockerIdentityRequestHandler.h:47
@ Amazon_luna
Definition LootLockerIdentityRequestHandler.h:40
@ Xbox_one
Definition LootLockerIdentityRequestHandler.h:38
One game in which a player of this identity has been active.
Definition LootLockerIdentityRequestHandler.h:69
int32 game_id
The legacy integer id of the game.
Definition LootLockerIdentityRequestHandler.h:74
FString first_session_at
The first time a session was started for this identity in the game.
Definition LootLockerIdentityRequestHandler.h:78
FString last_session_at
The most recent time a session was started for this identity in the game.
Definition LootLockerIdentityRequestHandler.h:82
int32 session_count
The number of sessions started for this identity in the game.
Definition LootLockerIdentityRequestHandler.h:86
The body of the 409 returned when the credential being linked already belongs to another identity.
Definition LootLockerIdentityRequestHandler.h:323
FString message
The message the server attached to the conflict.
Definition LootLockerIdentityRequestHandler.h:328
FString conflicting_identity_id
The ULID of the identity that already owns the credential.
Definition LootLockerIdentityRequestHandler.h:332
FLootLockerIdentityMergePreview merge_preview
What a merge of the requesting identity (keep) into the conflicting identity (merge) would resolve.
Definition LootLockerIdentityRequestHandler.h:336
Request to record a provider credential against the player's identity.
Definition LootLockerIdentityRequestHandler.h:202
ELootLockerIdentityProvider provider
The provider platform the credential belongs to.
Definition LootLockerIdentityRequestHandler.h:207
FString provider_uid
The provider's identifier for the player, for example the Steam ID.
Definition LootLockerIdentityRequestHandler.h:211
Response returned after linking a provider credential.
Definition LootLockerIdentityRequestHandler.h:344
bool has_conflict
Whether Conflict was populated, because Conflict itself is a value type that cannot be null.
Definition LootLockerIdentityRequestHandler.h:360
FLootLockerIdentityLinkConflict conflict
Set when the request was answered with 409 because the credential belongs to another identity.
Definition LootLockerIdentityRequestHandler.h:356
bool created
True when a new credential was recorded, false when the identity already owned it.
Definition LootLockerIdentityRequestHandler.h:349
Request to look identities up by id and/or by the games they have been active in.
Definition LootLockerIdentityRequestHandler.h:181
TArray< FString > identity_ids
Optional: The ULIDs of the identities to look up.
Definition LootLockerIdentityRequestHandler.h:186
bool include_game_activity
Optional: Whether to populate game_activity on each result.
Definition LootLockerIdentityRequestHandler.h:194
TArray< int32 > game_ids
Optional: The legacy integer ids of games to filter the identities by.
Definition LootLockerIdentityRequestHandler.h:190
Response containing zero or more identities.
Definition LootLockerIdentityRequestHandler.h:307
TArray< FLootLockerIdentityResponse > identities
The identities matching the lookup.
Definition LootLockerIdentityRequestHandler.h:312
Response containing a merge preview.
Definition LootLockerIdentityRequestHandler.h:368
FString merge_identity_id
The ULID of the identity that would be merged into the kept identity.
Definition LootLockerIdentityRequestHandler.h:377
FString keep_identity_id
The ULID of the identity the caller keeps.
Definition LootLockerIdentityRequestHandler.h:373
TArray< FLootLockerIdentityPlayerConflict > player_conflicts
The games in which both identities have a live player.
Definition LootLockerIdentityRequestHandler.h:381
What merging two identities would resolve, without executing anything.
Definition LootLockerIdentityRequestHandler.h:153
TArray< FLootLockerIdentityPlayerConflict > player_conflicts
The games in which both identities have a live player.
Definition LootLockerIdentityRequestHandler.h:166
FString merge_identity_id
The ULID of the identity that would be merged into the kept identity.
Definition LootLockerIdentityRequestHandler.h:162
FString keep_identity_id
The ULID of the identity the caller keeps.
Definition LootLockerIdentityRequestHandler.h:158
Request to merge another identity into the current one.
Definition LootLockerIdentityRequestHandler.h:239
FString trigger_provider
Optional: The provider whose credential conflict led to this merge, recorded in the merge log.
Definition LootLockerIdentityRequestHandler.h:252
TArray< FLootLockerIdentityMergeResolution > resolutions
One entry per game listed in the merge preview's player_conflicts.
Definition LootLockerIdentityRequestHandler.h:248
FString trigger_provider_uid
Optional: The provider credential that led to this merge, recorded in the merge log.
Definition LootLockerIdentityRequestHandler.h:256
FString merge_identity_id
The ULID of the identity to merge into the authenticated identity.
Definition LootLockerIdentityRequestHandler.h:244
The choice of which player to keep in one game where both identities have a live player.
Definition LootLockerIdentityRequestHandler.h:219
int32 game_id
The legacy integer id of the game this resolution is for.
Definition LootLockerIdentityRequestHandler.h:224
int32 keep_player_id
The player to keep in this game.
Definition LootLockerIdentityRequestHandler.h:228
Response returned after merging two identities, containing the surviving identity.
Definition LootLockerIdentityRequestHandler.h:389
TArray< FLootLockerIdentityGameActivity > game_activity
The games the surviving identity has been active in.
Definition LootLockerIdentityRequestHandler.h:406
FString created_at
When the surviving identity was created.
Definition LootLockerIdentityRequestHandler.h:402
TArray< FLootLockerIdentityProviderInfo > providers
The provider credentials linked to the surviving identity.
Definition LootLockerIdentityRequestHandler.h:415
int32 publisher_id
The legacy integer id of the publisher that owns the identity.
Definition LootLockerIdentityRequestHandler.h:398
bool has_providers
Whether providers was present in the payload.
Definition LootLockerIdentityRequestHandler.h:419
One game in which both identities being merged have a live player, and therefore needs a choice of wh...
Definition LootLockerIdentityRequestHandler.h:130
int32 merge_player_id
The player id belonging to the identity that is merged away.
Definition LootLockerIdentityRequestHandler.h:143
int32 game_id
The legacy integer id of the game the conflict is in.
Definition LootLockerIdentityRequestHandler.h:135
int32 keep_player_id
The player id belonging to the identity that is kept.
Definition LootLockerIdentityRequestHandler.h:139
A provider credential linked to an identity.
Definition LootLockerIdentityRequestHandler.h:99
FString created_at
When the credential was linked to the identity.
Definition LootLockerIdentityRequestHandler.h:121
ELootLockerIdentityProvider provider_type
The provider this credential belongs to, resolved from Provider.
Definition LootLockerIdentityRequestHandler.h:117
FString provider
The provider slug, for example "steam", "psn" or "xbox_one", exactly as the backend stored it.
Definition LootLockerIdentityRequestHandler.h:108
Response containing a single identity.
Definition LootLockerIdentityRequestHandler.h:268
int32 publisher_id
The legacy integer id of the publisher that owns the identity.
Definition LootLockerIdentityRequestHandler.h:277
TArray< FLootLockerIdentityGameActivity > game_activity
The games this identity has been active in.
Definition LootLockerIdentityRequestHandler.h:285
bool has_providers
Whether providers was present in the payload, because an empty array cannot be told from absent.
Definition LootLockerIdentityRequestHandler.h:299
FString created_at
When the identity was created.
Definition LootLockerIdentityRequestHandler.h:281
TArray< FLootLockerIdentityProviderInfo > providers
The provider credentials linked to this identity.
Definition LootLockerIdentityRequestHandler.h:295
Definition LootLockerPlayerData.h:12
Base response struct — every SDK callback receives a struct that derives from this.
Definition LootLockerResponse.h:19