-
Notifications
You must be signed in to change notification settings - Fork 4
Auth
Epic Online Services Interface: Auth Interface
The Auth Interface lets players (users) log into their Epic Account from your game (product) so they can access the features provided by Epic Account Services (EAS), such as Friends, Presence, UserInfo and Ecom interfaces. The Auth Interface handles Epic account-related interactions with EOS, providing the ability to authenticate users and obtain access tokens.
The following guides are available:
These functions are provided for handling authentication:
- EpicGames_Auth_AddNotifyLoginStatusChanged
- EpicGames_Auth_CopyIdToken
- EpicGames_Auth_CopyUserAuthToken
- EpicGames_Auth_DeletePersistentAuth
- EpicGames_Auth_GetLoginStatus
- EpicGames_Auth_GetSelectedAccountId
- EpicGames_Auth_LinkAccount
- EpicGames_Auth_Login
- EpicGames_Auth_Logout
- EpicGames_Auth_QueryIdToken
- EpicGames_Auth_RemoveNotifyLoginStatusChanged
- EpicGames_Auth_VerifyIdToken
These are the constants used by this module:
- EpicGames_Scope_Flags
- EpicGames_Login_Credential_Type
- EpicGames_External_Credential_Type
- EpicGames_Login_Status
These are the structs used by this module:
Epic Online Services Function: EOS_Auth_AddNotifyLoginStatusChanged
This function registers to receive login status updates.
This function operates asynchronously, which means that it does not immediately return the requested result. Instead, upon completion of the task, it will trigger the Social Async Event.
Syntax:
EpicGames_Auth_AddNotifyLoginStatusChanged()
Returns:
Triggers:
Key | Type | Description |
---|---|---|
type | String | The string "EpicGames_Auth_AddNotifyLoginStatusChanged"
|
CurrentStatus | EpicGames_Login_Status | The status at the time of the notification |
PrevStatus | EpicGames_Login_Status | The status prior to the change |
Example:
identifier = EpicGames_Auth_AddNotifyLoginStatusChanged();
The code sample above saves the identifier that can be used inside a Social Async Event.
if (async_load[? "type"] == "EpicGames_Auth_AddNotifyLoginStatusChanged")
{
if (async_load[? "status"] == EpicGames_Success)
{
show_debug_message(async_load[? "type"] + " succeeded!");
}
else
{
show_debug_message(async_load[? "type"] + " failed: " + async_load[? "status_message"]);
}
}
The code above matches the response against the correct event type and logs the success of the task.
Epic Online Services Function: EOS_Auth_CopyIdToken
This function fetches an ID token for an Epic Account ID. ID tokens are used to securely verify user identities with online services. The most common use case is using an ID token to authenticate the local user by their selected account ID, which is the account ID that should be used to access any game-scoped data for the current application. An ID token for the selected account ID of a locally authenticated user will always be readily available. To retrieve it for the selected account ID, you can use EpicGames_Auth_CopyIdToken directly after a successful user login.
Syntax:
EpicGames_Auth_CopyIdToken(accountID)
Argument | Type | Description |
---|---|---|
accountID | String | The Epic Account ID of the user being queried. |
Returns:
Example:
var _struct = EpicGames_Auth_CopyIdToken(accountID);
if(_struct.status == EpicGames_Success)
{
JsonWebToken = _struct.JsonWebToken;
}
The above code shows an example of how the function should be used. The token associated with the provided account ID is returned inside the struct, alongside other useful information.
Epic Online Services Function: EOS_Auth_CopyUserAuthToken
This function fetches a user auth token for an Epic Account ID. A user authentication token allows any code with possession (backend/client) to perform certain actions on behalf of the user. Because of this, for the purposes of user identity verification, the EpicGames_Auth_CopyIdToken should be used instead.
Syntax:
EpicGames_Auth_CopyUserAuthToken(accountID)
Argument | Type | Description |
---|---|---|
accountID | String | The Epic Account ID of the user being queried |
Returns:
Example:
var _struct = EpicGames_Auth_CopyUserAuthToken(accountID);
if(_struct.status == EpicGames_Success)
{
var _access_token = _struct.AccessToken;
}
The above code shows an example of how the function should be used. The access token associated with the provided account ID is returned inside the struct alongside other useful information.
Epic Online Services Function: EOS_Auth_DeletePersistentAuth
This function deletes a previously received and locally stored persistent auth access token for the currently logged in user of the local device. On Desktop and Mobile platforms, the access token is deleted from the keychain of the local user and a backend request is made to revoke the token on the authentication server. On Console platforms, even though the caller is responsible for storing and deleting the access token on the local device, this function should still be called with the access token before its deletion to make the best effort in attempting to also revoke it on the authentication server. If the function would fail on Console, the caller should still proceed as normal to delete the access token locally as intended.
Syntax:
EpicGames_Auth_DeletePersistentAuth(refreshToken)
Argument | Type | Description |
---|---|---|
refreshToken | String | A long-lived refresh token that is used with the EpicGames_LCT_PersistentAuth login type and is to be revoked from the authentication server. Only used on Console platforms. On Desktop and Mobile platforms, set this parameter to undefined . |
Returns:
N/A
Example:
EpicGames_Auth_DeletePersistentAuth(refreshtoken);
The above code shows an example of how the function should be used. The refresh token provided will be revoked and invalidated.
Epic Online Services Function: EOS_Auth_GetLoginStatus
This function fetches the EpicGames login status for an Epic Account ID.
Syntax:
EpicGames_Auth_GetLoginStatus(accountId)
Argument | Type | Description |
---|---|---|
accountId | String | The Epic Account ID of the user being queried |
Returns:
Example:
switch(EpicGames_Auth_GetLoginStatus(AccountID))
{
case EpicGames_LS_NotLoggedIn:
draw_text(100, 190, "LoginStatus: NotLoggedIn");
break;
case EpicGames_LS_UsingLocalProfile:
draw_text(100, 190, "LoginStatus: UsingLocalProfile");
break;
case EpicGames_LS_LoggedIn:
draw_text(100, 190, "LoginStatus: LoggedIn");
break;
}
The above code shows an example of how the function should be used. A login status constant is returned and checked against the provided built-in constants.
Epic Online Services Function: EOS_Auth_GetSelectedAccountId
This function fetches the selected account ID to the current application for a local authenticated user.
Syntax:
EpicGames_Auth_GetSelectedAccountId(account)
Argument | Type | Description |
---|---|---|
account | String | The selected account ID corresponding to the given account ID. |
Returns:
Example:
var _account_ID = EpicGames_Auth_GetSelectedAccountId(accountID);
The above code shows an example of how the function should be used.
Epic Online Services Function: EOS_Auth_LinkAccount
This function links an external account by continuing the previous login attempt with a continuance token. On Desktop and Mobile platforms, the user will be presented the Epic Account Portal to resolve their identity. On Console, the user will login to their Epic Account using an external device, e.g. a mobile device or a desktop PC, by browsing to the presented authentication URL and entering the device code presented by the game on the console. On success, the user will be logged in at the completion of this action. This will commit this external account to the Epic Account and cannot be undone in the SDK.
This function operates asynchronously, which means that it does not immediately return the requested result. Instead, upon completion of the task, it will trigger the Social Async Event.
Syntax:
EpicGames_Auth_LinkAccount(accountID, scope_flags)
Argument | Type | Description |
---|---|---|
accountID | String | The Epic Account ID of the logged in local user whose Epic Account will be linked with the local Nintendo NSA ID Account. By default set to undefined . |
scope_flags | EpicGames_Scope_Flags | Combination of the enumeration flags to specify how the account linking operation will be performed. |
Returns:
Triggers:
Key | Type | Description |
---|---|---|
type | String | The string "EpicGames_Auth_LinkAccount"
|
status | EpicGames_Result | The status code for the operation. EpicGames_Success indicates that the operation succeeded; other codes indicate errors |
status_message | String | Text representation of the status code |
AccountID | String | The Epic Account ID used upon calling the function that generated this callback. |
identifier | Real | The asynchronous listener ID. |
Example:
var _scope_flags = EpicGames_AS_BasicProfile | EpicGames_AS_FriendsList | EpicGames_AS_Presence;
identifier = EpicGames_Auth_Login(accountID, _scope_flags);
The code sample above saves the identifier that can be used inside a Social Async Event.
if (async_load[? "type"] == "EpicGames_Auth_LinkAccount")
if(async_load[? "identifier"] == identifier)
{
if (async_load[? "status"] == EpicGames_Success)
{
show_debug_message(async_load[? "type"] + " succeeded!");
}
else
{
show_debug_message(async_load[? "type"] + " failed: " + async_load[? "status_message"]);
}
}
The code above matches the response against the correct event type and logs the success of the task.
Epic Online Services Function: EOS_Auth_Login
This function logs in / authenticates with user credentials.
Note
The permissions that you pass must correspond exactly to the ones you set in the Developer Portal. See Permissions.
This function operates asynchronously, which means that it does not immediately return the requested result. Instead, upon completion of the task, it will trigger the Social Async Event.
Syntax:
EpicGames_Auth_Login(type, scope_flags, id, token, external_type)
Argument | Type | Description |
---|---|---|
type | EpicGames_Login_Credential_Type | Type of login. Needed to identify the auth method to use. |
scope_flags | EpicGames_Scope_Flags | Auth scope flags are permissions to request from the user while they are logging in. This is a bitwise-or union (pipe symbol ` |
id | String | ID of the user logging in, based on EpicGames_Login_Credential_Type |
token | String | Credentials or token related to the user logging in |
external_type | EpicGames_External_Credential_Type | Type of external login. Needed to identify the external auth method to use. Used when login type is set to EpicGames_LCT_ExternalAuth , ignored otherwise (see the External Login Flow Guide on the Logging In page for more details). Note that you must still pass a value for this parameter when not using an external auth method. |
Returns:
Triggers:
Key | Type | Description |
---|---|---|
type | String | The string "EpicGames_Auth_Login"
|
status | EpicGames_Result | The status code for the operation. EpicGames_Success indicates that the operation succeeded; other codes indicate errors |
status_message | String | Text representation of the status code |
identifier | Real | The asynchronous listener ID |
AccountID | String | The Epic Account ID of the local user who has logged in |
SelectedAccountId | String | The Epic Account ID that has been previously selected to be used for the current application. Applications should use this ID to authenticate with online backend services that store game-scoped data for users. Only when status is success |
Example:
identifier = EpicGames_Auth_Login(
EpicGames_LCT_ExchangeCode,
EpicGames_AS_BasicProfile | EpicGames_AS_FriendsList | EpicGames_AS_Presence,
"",
code,
-1);
The code sample above saves the identifier that can be used inside a Social Async Event.
if (async_load[? "type"] == "EpicGames_Auth_Login")
if(async_load[? "identifier"] == identifier)
{
if (async_load[? "status"] == EpicGames_Success)
{
show_debug_message(async_load[? "type"] + " succeeded!");
}
else
{
show_debug_message(async_load[? "type"] + " failed: " + async_load[? "status_message"]);
}
}
The code above matches the response against the correct event type and logs the success of the task.
Epic Online Services Function: EOS_Auth_Logout
This function signs the player out of the online service.
This function operates asynchronously, which means that it does not immediately return the requested result. Instead, upon completion of the task, it will trigger the Social Async Event.
Syntax:
EpicGames_Auth_Logout(accountID)
Argument | Type | Description |
---|---|---|
accountID | String | The Epic Account ID of the local user who is being logged out |
Returns:
Triggers:
Key | Type | Description |
---|---|---|
type | String | The string "EpicGames_Auth_Logout"
|
status | EpicGames_Result | The status code for the operation. EpicGames_Success indicates that the operation succeeded; other codes indicate errors |
status_message | String | Text representation of the status code |
identifier | Real | The asynchronous listener ID |
Example:
identifier = EpicGames_Auth_Logout(accountID);
The code sample above save the identifier that can be used inside a Social Async Event.
if (async_load[? "type"] == "EpicGames_Auth_Logout")
if (async_load[? "identifier"] == identifier)
{
if (async_load[? "status"] == EpicGames_Success)
{
show_debug_message(async_load[? "type"] + " succeeded!");
}
else
{
show_debug_message(async_load[? "type"] + " failed: " + async_load[? "status_message"]);
}
}
The code above matches the response against the correct event type and logs the success of the task.
Epic Online Services Function: EOS_Auth_QueryIdToken
This function queries the backend for an ID token that describes one of the merged account IDs of a local authenticated user. The ID token can be used to impersonate a merged account ID when communicating with online services. An ID token for the selected account ID of a locally authenticated user will always be readily available and does not need to be queried explicitly.
This function operates asynchronously, which means that it does not immediately return the requested result. Instead, upon completion of the task, it will trigger the Social Async Event.
Syntax:
EpicGames_Auth_QueryIdToken(accountID, accountID_target)
Argument | Type | Description |
---|---|---|
accountID | String | The Epic Account ID of the local authenticated user. |
accountID_target | String | The target Epic Account ID for which to query an ID token. This account ID may be the same as the input LocalUserId or another merged account ID associated with the local user's Epic account. An ID token for the selected account ID of a locally authenticated user will always be readily available. To retrieve it for the selected account ID, you can use EpicGames_Auth_CopyIdToken directly after a successful user login. |
Returns:
Triggers:
Key | Type | Description |
---|---|---|
type | String | The string "EpicGames_Auth_QueryIdToken"
|
status | EpicGames_Result | The status code for the operation. EpicGames_Success indicates that the operation succeeded; other codes indicate errors |
status_message | String | Text representation of the status code |
identifier | Real | The asynchronous listener ID. |
Example:
identifier = EpicGames_Auth_QueryIdToken(accountID, accountID);
The code sample above save the identifier that can be used inside a Social Async Event.
if (async_load[? "type"] == "EpicGames_Auth_QueryIdToken")
if (async_load[? "identifier"] == identifier)
{
if (async_load[? "status"] == EpicGames_Success)
{
show_debug_message(async_load[? "type"] + " succeeded!");
}
else
{
show_debug_message(async_load[? "type"] + " failed: " + async_load[? "status_message"]);
}
}
The code above matches the response against the correct event type and logs the success of the task.
Epic Online Services Function: EOS_Auth_RemoveNotifyLoginStatusChanged
This function unregisters from receiving login status updates.
Syntax:
EpicGames_Auth_RemoveNotifyLoginStatusChanged(id)
Argument | Type | Description |
---|---|---|
id | Real | handle ID representing the registered callback (from EpicGames_Auth_AddNotifyLoginStatusChanged) |
Returns:
N/A
Example:
var _handle = EpicGames_Auth_AddNotifyLoginStatusChanged();
//...
//...later
//...
EpicGames_Auth_RemoveNotifyLoginStatusChanged(_handle);
The code sample above enables the login status notifications (EpicGames_Auth_AddNotifyLoginStatusChanged) and later disables them by refering to the previously generated handle.
Epic Online Services Function: EOS_Auth_VerifyIdToken
This function verifies a given ID token for authenticity and validity.
This function operates asynchronously, which means that it does not immediately return the requested result. Instead, upon completion of the task, it will trigger the Social Async Event.
Syntax:
EpicGames_Auth_VerifyIdToken(accountID, JsonWebToken)
Argument | Type | Description |
---|---|---|
accountID | String | The Epic Account ID of the local user who is being verified |
JsonWebToken | String | The ID token to verify. |
Returns:
Triggers:
Key | Type | Description |
---|---|---|
type | String | The string "EpicGames_Auth_VerifyIdToken"
|
status | EpicGames_Result | The status code for the operation. EpicGames_Success indicates that the operation succeeded; other codes indicate errors |
status_message | String | Text representation of the status code |
identifier | Real | The asynchronous listener ID. |
Example:
identifier = EpicGames_Auth_VerifyIdToken(accountID, JsonWebToken);
The code sample above keeps a handle that can be used inside a Social Async Event.
if(async_load[? "type"] == "EpicGames_Auth_VerifyIdToken")
if(async_load[? "identifier"] == identifier)
{
if (async_load[? "status"] == EpicGames_Success)
{
show_debug_message(async_load[? "type"] + " succeeded!");
}
else
{
show_debug_message(async_load[? "type"] + " failed: " + async_load[? "status_message"]);
}
}
The code above matches the response against the correct event type and logs the success of the task.
Epic Online Services Enum: EOS_EAuthScopeFlags
List of the supported scope flags associated with the login API calls:
These constants are referenced by the following functions:
Member | Description |
---|---|
EpicGames_AS_NoFlags |
|
EpicGames_AS_BasicProfile |
Permissions to see your account ID, display name, language and count |
EpicGames_AS_FriendsList |
Permissions to see a list of your friends who use this application |
EpicGames_AS_Presence |
Permissions to set your online presence and see presence of your friend |
EpicGames_AS_FriendsManagement |
Permissions to manage the Epic friends list. This scope is restricted to Epic first party products, and attempting to use it will result in authentication failure. |
EpicGames_AS_Email |
Permissions to see email in the response when fetching information for a user. This scope is restricted to Epic first party products, and attempting to use it will result in authentication failure. |
EpicGames_AS_Country |
Permissions to see your country |
Epic Online Services Constant: EOS_EExternalCredentialType
List of the supported identity providers to authenticate a user. The type of authentication token is specific to each provider. Tokens in string format should be passed as-is to the function.
These constants are referenced by the following functions:
Member | Description |
---|---|
EpicGames_ECT_EPIC |
Epic Account Services Token Using ID Token is preferred, retrieved with EpicGames_Auth_CopyIdToken that returns JsonWebToken. Using Auth Token is supported for backwards compatibility, retrieved with EpicGames_Auth_CopyUserAuthToken that returns AccessToken. Supported with EpicGames_Connect_Login. |
EpicGames_ECT_STEAM_APP_TICKET |
Steam Encrypted App Ticket Generated using the RequestEncryptedAppTicket API of Steamworks SDK. The retrieved App is then passed into the EpicGames_Auth_Login or EpicGames_Connect_Login APIs. |
EpicGames_ECT_STEAM_SESSION_TICKET |
Steam Auth Session Ticket generated using the ISteamUser::GetAuthTicketForWebApi API of Steamworks SDK. |
EpicGames_ECT_PSN_ID_TOKEN |
PlayStation(TM)Network ID Token Retrieved from the PlayStation(R) SDK. Please see first-party documentation for additional information. Supported with EpicGames_Auth_Login, EpicGames_Connect_Login. |
EpicGames_ECT_XBL_XSTS_TOKEN |
Xbox Live XSTS Token Retrieved from the GDK and XDK. Please see first-party documentation for additional information. Supported with EpicGames_Auth_Login, EpicGames_Connect_Login. |
EpicGames_ECT_DISCORD_ACCESS_TOKEN |
Discord Access Token Retrieved using the GetOAuth2Token API of Discord SDK. Supported with EpicGames_Auth_Login. |
EpicGames_ECT_GOG_SESSION_TICKET |
GOG Galaxy Encrypted App Ticket Generated using the RequestEncryptedAppTicket API of GOG Galaxy SDK. The retrieved App is then passed into the EpicGames_Auth_Login API. |
EpicGames_ECT_NINTENDO_ID_TOKEN |
Nintendo Account ID Token Identifies a Nintendo user account and is acquired through web flow authentication where the local user logs in using their email address/sign-in ID and password. This is the common Nintendo account that users login with outside the Nintendo Switch device. Supported with EpicGames_Auth_Login, EpicGames_Connect_Login. |
EpicGames_ECT_NINTENDO_NSA_ID_TOKEN |
Nintendo Service Account ID Token (NSA ID) The NSA ID identifies uniquely the local Nintendo Switch device. The authentication token is acquired locally without explicit user credentials. As such, it is the primary authentication method for seamless login on Nintendo Switch. The NSA ID is not exposed directly to the user and does not provide any means for login outside the local device. Because of this, Nintendo Switch users will need to link their Nintendo Account or another external user account to their Product User ID in order to share their game progression across other platforms. Otherwise, the user will not be able to login to their existing Product User ID on another platform due to missing login credentials to use. It is recommended that the game explicitly communicates this restriction to the user so that they will know to add the first linked external account on the Nintendo Switch device and then proceed with login on another platform. In addition to sharing cross-platform game progression, linking the Nintendo Account or another external account will allow preserving the game progression permanently. Otherwise, the game progression will be tied only to the local device. In case the user loses access to their local device, they will not be able to recover the game progression if it is only associated with this account type. Supported with EpicGames_Auth_Login, EpicGames_Connect_Login. |
EpicGames_ECT_UPLAY_ACCESS_TOKEN |
Uplay Access Token |
EpicGames_ECT_OPENID_ACCESS_TOKEN |
OpenID Provider Access Token Supported with EpicGames_Connect_Login. |
EpicGames_ECT_DEVICEID_ACCESS_TOKEN |
Device ID access token that identifies the current locally logged in user profile on the local device. The local user profile here refers to the operating system user login, for example the user's Windows Account or on a mobile device the default active user profile. This credential type is used to automatically login the local user using the EOS Connect Device ID feature. The intended use of the Device ID feature is to allow automatically logging in the user on a mobile device and to allow playing the game without requiring the user to necessarily login using a real user account at all. This makes a seamless first-time experience possible and allows linking the local device with a real external user account at a later time, sharing the same EpicGames_ProductUserId that is being used with the Device ID feature. Supported with EpicGames_Connect_Login. |
EpicGames_ECT_APPLE_ID_TOKEN |
Apple ID Token; Supported with EpicGames_Connect_Login. |
EpicGames_ECT_GOOGLE_ID_TOKEN |
Google ID Token; Supported with EpicGames_Connect_Login. |
EpicGames_ECT_OCULUS_USERID_NONCE |
Oculus User ID and Nonce (call ovr_User_GetUserProof , to retrieve the nonce). Then pass the local User ID and the Nonce as a "{UserID}{Nonce}" formatted string for the EpicGames_Connect_Login Token parameter. Note that in order to successfully retrieve a valid non-zero ID for the local user using ovr_User_GetUser , your Oculus App needs to be configured in the Oculus Developer Dashboard to have the User ID feature enabled. Supported with EpicGames_Connect_Login. |
EpicGames_ECT_ITCHIO_JWT |
itch.io JWT Access Token. Use the itch.io app manifest to receive a JWT access token for the local user via the ITCHIO_API_KEY process environment variable. The itch.io access token is valid for 7 days after which the game needs to be restarted by the user as otherwise EOS Connect authentication session can no longer be refreshed. Supported with EpicGames_Connect_Login. |
EpicGames_ECT_ITCHIO_KEY |
itch.io Key Access Token. This access token type is retrieved through the OAuth 2.0 authentication flow for the itch.io application. Supported with EpicGames_Connect_Login. |
EpicGames_ECT_EPIC_ID_TOKEN |
Epic Games ID Token. Acquired using EpicGames_Auth_CopyIdToken that returns JsonWebToken. Supported with EpicGames_Connect_Login. |
EpicGames_ECT_AMAZON_ACCESS_TOKEN |
Amazon Access Token. Supported with EpicGames_Connect_Login. |
Epic Online Services Enum: EOS_ELoginCredentialType
These constants represent all possible types of login methods, availability depends on permissions granted to the client.
These constants are referenced by the following functions:
Member | Description |
---|---|
EpicGames_LCT_Password |
The argument to be passed in |
EpicGames_LCT_ExchangeCode |
A short-lived one-time use exchange code to login the local user. When started, the application is expected to consume the exchange code by using the EpicGames_Auth_Login API as soon as possible. This is needed in order to authenticate the local user before the exchange code would expire. Attempting to consume an already expired exchange code will return AuthExchangeCodeNotFound error by the EpicGames_Auth_Login API. |
EpicGames_LCT_PersistentAuth |
Desktop and Mobile only; deprecated on Console platforms in favor of EOS_LCT_ExternalAuth login method. Long-lived access token that is stored on the local device to allow persisting a user login session over multiple runs of the application. When using this login type, if an existing access token is not found or it is invalid or otherwise expired, the error result EpicGames_InvalidAuth is returned. On Console platforms, after a successful login using the EOS_LCT_DeviceCode login type, the persistent access token is retrieved using the EpicGames_Auth_CopyUserAuthToken API and stored by the application for the currently logged in user of the local device. |
EpicGames_LCT_DeviceCode |
Deprecated and no longer used. |
EpicGames_LCT_Developer |
Login with named credentials hosted by the EOS SDK Developer Authentication Tool. |
EpicGames_LCT_RefreshToken |
Refresh token that was retrieved from a previous call to EpicGames_Auth_Login API in another local process context. Mainly used in conjunction with custom launcher applications. in-between that requires authenticating the user before eventually starting the actual game client application. In such scenario, an intermediate launcher will log in the user by consuming the exchange code it received from the Epic Games Launcher. To allow the game client to also authenticate the user, it can copy the refresh token using the EpicGames_Auth_CopyUserAuthToken API and pass it via launch parameters to the started game client. The game client can then use the refresh token to log in the user. |
EpicGames_LCT_AccountPortal |
Desktop and Mobile only. Initiate a login through the Epic account portal. for example when starting the application through a proprietary ecosystem launcher or otherwise. |
EpicGames_LCT_ExternalAuth |
Login using external account provider credentials, such as Steam, PlayStation(TM)Network, Xbox Live, or Nintendo. This is the intended login method on Console. On Desktop and Mobile, used when launched through any of the commonly supported platform clients (see the External Login Flow Guide on the Logging In page for more details) |
Epic Online Services Enum: EOS_ELoginStatus
These constants are used to describe the Login status of a given account or connection and are returned by the following functions:
These constants are referenced by the following functions:
- EpicGames_Auth_AddNotifyLoginStatusChanged
- EpicGames_Auth_GetLoginStatus
- EpicGames_Connect_AddNotifyLoginStatusChanged
Member | Description |
---|---|
EpicGames_LS_NotLoggedIn |
Player has not logged in or chosen a local profile |
EpicGames_LS_UsingLocalProfile |
Player is using a local profile but is not logged in |
EpicGames_LS_LoggedIn |
Player has been validated by the platform-specific authentication service |
This struct contains detailed info on an access token used for authentication.
This struct is referenced by the following functions:
Member | Type | Description |
---|---|---|
status | EpicGames_Result | The status code for the operation. EpicGames_Success indicates that the operation succeeded; other codes indicate errors |
status_message | String | Text representation of the status code |
JsonWebToken | String | The ID token as a JSON Web Token (JWT) string |
AccountId | String | The Epic Account ID associated with this auth token |
AccessToken | String | Access token for the current user login session |
App | String | Name of the app related to the client ID involved with this token |
AuthType | Real | Type of auth token (EpicGames_ATT_Client or EpicGames_ATT_User ) |
ClientId | String | Client ID that requested this token |
ExpiresAt | String | Absolute time in UTC before the access token expires, in ISO 8601 format |
ExpiresIn | Real | Time before the access token expires, in seconds, relative to the call to EpicGames_Auth_CopyUserAuthToken |
RefreshToken | String | Refresh token. |
RefreshExpiresAt | String | Absolute time in UTC before the refresh token expires, in ISO 8601 format |
RefreshExpiresIn | Real | Time before the access token expires, in seconds, relative to the call to EpicGames_Auth_CopyUserAuthToken |
This struct contains details on an ID Token in the form of a JSON Web Token string.
This struct is referenced by the following functions:
Member | Type | Description |
---|---|---|
status | EpicGames_Result | The status code for the operation. EpicGames_Success indicates that the operation succeeded; other codes indicate errors |
status_message | String | Text representation of the status code |
JsonWebToken | String | The ID token as a JSON Web Token (JWT) string. |
AccountId | String | The Epic Account ID described by the ID token. Use EpicGames_EpicAccountId_FromString to populate this field when validating a received ID token. |
YoYoGames 2024