# Authentication for steam and gamesparks via online subsystem

**URL:** <https://forums.unrealengine.com/t/authentication-for-steam-and-gamesparks-via-online-subsystem/462859>\
**Category:** Platform & Builds\
**Tags:** onlinesubsystem, Steam, unreal-engine, question\
**Created:** [March 25, 2020, 6:25pm UTC](https://forums.unrealengine.com/t/authentication-for-steam-and-gamesparks-via-online-subsystem/462859 "2020-03-25T18:25:02Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![ShinyBlade777](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ShinyBlade777](https://forums.unrealengine.com/u/ShinyBlade777)\
**Post date:** [March 25, 2020, 6:25pm UTC](https://forums.unrealengine.com/t/authentication-for-steam-and-gamesparks-via-online-subsystem/462859/1 "2020-03-25T18:25:02Z")

</div>

I’m having trouble authenticating my game on game sparks, I am using Unreal’s online subsystem to get an auth token from steam, but I need to convert it from FString to Hex for game sparks to accept it. Here’s what I have so far:

```
FString USteamHelper::GetSessionTicket()
{
IOnlineSubsystem* OnlineInterface;
OnlineInterface = IOnlineSubsystem::Get();
FString SessionTicket = OnlineInterface->GetIdentityInterface()->GetAuthToken(0);
int TicketLength = SessionTicket.GetAllocatedSize();
FString HexSessionTicket = SessionTicket.FromHexBlob(*SessionTicket, TicketLength);
return HexSessionTicket;
}

Error C2664 'FString FString::FromHexBlob(const uint8 *,const uint32)': cannot convert argument 1 from 'const TCHAR *' to 'const uint8 *'

```

Any help would really be apreciated

---

<div class="post-metadata">

**Author:** ![Maide](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Maide](https://forums.unrealengine.com/u/Maide)\
**Post date:** [March 25, 2020, 8:25pm UTC](https://forums.unrealengine.com/t/authentication-for-steam-and-gamesparks-via-online-subsystem/462859/2 "2020-03-25T20:25:00Z")

</div>

Hi ShinyBlade777,

The string you get from GetAuthToken is already a hex-encoded string; you don’t need to convert it to hex. You do need to check if it’s valid (not .IsEmpty()) though, as GetAuthToken will return an empty string it can’t generate an auth ticket.

---

<div class="post-metadata">

**Author:** ![ShinyBlade777](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ShinyBlade777](https://forums.unrealengine.com/u/ShinyBlade777)\
**Post date:** [March 26, 2020, 8:15pm UTC](https://forums.unrealengine.com/t/authentication-for-steam-and-gamesparks-via-online-subsystem/462859/3 "2020-03-26T20:15:41Z")

</div>

Ok, Thank you, that helps. One step closer to the answer as to why it wont authenticate. It is getting a ticket, I can hook up a print string to it, and it puts out a string, so if its already the right format, there must be an issue elsewhere.

---

<div class="post-metadata">

**Author:** ![Miguel1900](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/miguel1900/32/1010694_2.png) [@Miguel1900](https://forums.unrealengine.com/u/Miguel1900)\
**Post date:** [November 25, 2025, 6:49pm UTC](https://forums.unrealengine.com/t/authentication-for-steam-and-gamesparks-via-online-subsystem/462859/4 "2025-11-25T18:49:33Z")

</div>

@ShinyBlade777 Did you solve it? similar issue over here.
