LootLocker Unreal SDK 11.1.0
Game backend SDK for Unreal Engine
Loading...
Searching...
No Matches
Referrals

Detailed Description

Invite friends with a referral code and track the referrals you have made.

A publisher defines referral programs in the Web Console, each with a qualifying action and a reward for the referrer and optionally for the referee. Every player has a referral code, which is their public UID. An invited player redeems it by supplying it as referral_code in the session optionals when starting their first session; returning players are ignored. The referral is then claimed until the qualifying action happens, at which point it becomes qualified and the rewards are granted. A program may cap how many referrals a single player is rewarded for.

See the LootLocker documentation.

Typedef Documentation

◆ FLootLockerReferralInviteResponseDelegate

typedef void(* FLootLockerReferralInviteResponseDelegate) (FLootLockerReferralInviteResponse)

C++ response callback delegate; receives an FLootLockerReferralInviteResponse result.

◆ FLootLockerReferralListResponseDelegate

typedef void(* FLootLockerReferralListResponseDelegate) (FLootLockerReferralListResponse)

C++ response callback delegate; receives an FLootLockerReferralListResponse result.

Enumeration Type Documentation

◆ ELootLockerReferralQualifier

enum class ELootLockerReferralQualifier : uint8
strong

The action that turns a claimed referral into a payout.

Enumerator
session_started 
entitlement_owned 
game_asserted 
publisher_currency_earned 

◆ ELootLockerReferralStatus

enum class ELootLockerReferralStatus : uint8
strong

The state of a referral relation.

Enumerator
claimed 
qualified 
Void 

Function Documentation

◆ GetReferralInvite()

FString ULootLockerSDKManager::GetReferralInvite ( const FLootLockerReferralInviteResponseDelegate & OnCompletedRequest,
const FString & ForPlayerWithUlid = "" )
static

Get the calling player's referral code and their rewarded-referral count against each active program's cap.

Use this to render an invite-a-friend screen: share the code, and have the invited player supply it as the referral_code session optional when starting their first session.

Parameters
OnCompletedRequestDelegate for handling the server response
ForPlayerWithUlidOptional: Execute for the specified player ULID (default player if empty)
Returns
A unique id for this request, use this to match callbacks to requests when you have multiple simultaneous requests outbound

◆ ListMyReferrals()

FString ULootLockerSDKManager::ListMyReferrals ( int Page,
int PerPage,
const FLootLockerReferralListResponseDelegate & OnCompletedRequest,
const FString & ForPlayerWithUlid = "" )
static

List the calling player's own referrals, newest first, including ones still pending their qualifying action.

Session-scoped: the player and game come from the session token.

Parameters
PageOptional: 1-based page of referrals (server default when 0)
PerPageOptional: Number of referrals per page, 1-200 (server default when 0)
OnCompletedRequestDelegate for handling the server response
ForPlayerWithUlidOptional: Execute for the specified player ULID (default player if empty)
Returns
A unique id for this request, use this to match callbacks to requests when you have multiple simultaneous requests outbound

Typedefs

typedef void(* FLootLockerReferralInviteResponseDelegate) (FLootLockerReferralInviteResponse)
 C++ response callback delegate; receives an FLootLockerReferralInviteResponse result.
typedef void(* FLootLockerReferralListResponseDelegate) (FLootLockerReferralListResponse)
 C++ response callback delegate; receives an FLootLockerReferralListResponse result.

Enumerations

enum class  ELootLockerReferralQualifier : uint8 { ELootLockerReferralQualifier::session_started = 0 , ELootLockerReferralQualifier::entitlement_owned = 1 , ELootLockerReferralQualifier::game_asserted = 2 , ELootLockerReferralQualifier::publisher_currency_earned = 3 }
 The action that turns a claimed referral into a payout. More...
enum class  ELootLockerReferralStatus : uint8 { ELootLockerReferralStatus::claimed = 0 , ELootLockerReferralStatus::qualified = 1 , ELootLockerReferralStatus::Void = 2 }
 The state of a referral relation. More...

Functions

static FString ULootLockerSDKManager::GetReferralInvite (const FLootLockerReferralInviteResponseDelegate &OnCompletedRequest, const FString &ForPlayerWithUlid="")
 Get the calling player's referral code and their rewarded-referral count against each active program's cap.
static FString ULootLockerSDKManager::ListMyReferrals (int Page, int PerPage, const FLootLockerReferralListResponseDelegate &OnCompletedRequest, const FString &ForPlayerWithUlid="")
 List the calling player's own referrals, newest first, including ones still pending their qualifying action.