GetIdentityInterface()->GetAuthToken(0) result "DummyAuthTicket"

anonymous_user_71b31e23
Mon, 11 Oct 2021 13:19:41 +0000
C++

I’m trying to retrieve my auth token after I logged in with my epic account. However the token what I’m receiving is “DummyAuthTicket”, even though the login status is “LoggedIn”. What am I missing?

This is how I’m logging in:

 FOnlineAccountCredentials credentials = FOnlineAccountCredentials();
 credentials.Id = "username";
 credentials.Token = "password";
 credentials.Type = "epic";

 IOnlineSubsystem* OSS = IOnlineSubsystem::Get();
 OSS->GetIdentityInterface()->AddOnLoginCompleteDelegate_Handle(0, FOnLoginCompleteDelegate::CreateUObject(this, &UConnection::OnLoginCompleted));
 bool success = OSS->GetIdentityInterface()->Login(0, credentials);

And this is the callback function, where I’m trying to retrieve the auth token:

IOnlineSubsystem* OSS = IOnlineSubsystem::Get();
FString authToken = OSS->GetIdentityInterface()->GetAuthToken(0);
FString loginStatus = ELoginStatus::ToString(OSS->GetIdentityInterface()->GetLoginStatus(0));
UE_LOG(LogTemp, Warning, TEXT("Successful login! Authtoken: %s LoginStatus: %s"), *authToken, *loginStatus);

3 posts - 3 participants