Skip to main content

Epic Online Services (EOS)

Titan integrates with Epic Online Services for production authentication.

Overview

EOS Connect provides:

  • Cross-platform identity
  • Integration with Epic Games Store
  • Player authentication without managing passwords

Configuration

Configure EOS in appsettings.json:

{
"Eos": {
"ClientId": "your-eos-client-id",
"ClientSecret": "your-eos-client-secret",
"DeploymentId": "your-deployment-id",
"SandboxId": "your-sandbox-id"
}
}
SettingDescription
ClientIdYour EOS application client ID
ClientSecretYour EOS application secret
DeploymentIdEOS deployment identifier
SandboxIdEOS sandbox identifier

[!IMPORTANT] In production, EOS configuration is required. The API will fail to start if EOS options are missing.

Token Validation

EosConnectService validates tokens using OpenID Connect:

  1. Fetches JWKS from EOS endpoints
  2. Validates signature using public keys
  3. Verifies claims (issuer, audience, expiration)
  4. Extracts user ID from the sub claim
public class EosConnectService : IAuthService
{
public async Task<AuthResult> ValidateTokenAsync(string token)
{
// Validate JWT signature and claims
var validationResult = await ValidateJwtAsync(token);

if (!validationResult.IsValid)
return AuthResult.Failed("Invalid token");

var productUserId = validationResult.Claims
.First(c => c.Type == "sub").Value;

return AuthResult.Success(
Guid.Parse(productUserId),
"EOS",
["Player"]
);
}
}

User ID Mapping

EOS provides a Product User ID (PUID) which becomes the Titan Account ID:

EOS ConceptTitan Equivalent
Product User IDAccount ID (Guid)
Display NameUser Profile
Platform AccountLinked Identity

Development Without EOS

For local development, use the Mock provider:

{
"token": "mock:550e8400-e29b-41d4-a716-446655440000",
"provider": "Mock"
}

The Mock provider:

  • Accepts any GUID after mock:
  • Only available in Development environment
  • Does not validate with external services
if (builder.Environment.IsDevelopment())
{
builder.Services.AddKeyedSingleton<IAuthService, MockAuthService>("Mock");
}

Unreal Engine Integration

In Unreal Engine, use the EOS SDK to get the ID token:

// Get EOS ID Token
EOS_Auth_Token* AuthToken = nullptr;
EOS_Auth_CopyIdToken(AuthHandle, &CopyOptions, &AuthToken);

// Login to Titan
FString Token = UTF8_TO_TCHAR(AuthToken->JsonWebToken);
TitanClient->Login(Token, "EOS");

See the Client SDK for the complete integration guide.

Troubleshooting

Token Validation Fails

  1. Check EOS credentials - Verify ClientId and ClientSecret
  2. Check token expiration - EOS tokens expire quickly
  3. Verify deployment - Use correct DeploymentId for your environment

User Not Found

EOS Product User IDs are created on first login. Ensure:

  1. User has linked their Epic account
  2. EOS Connect is configured in your product