Sign In Register

How can we help you today?

Start a new topic
Answered

UE4 Steam Integration

Hello,


I've been trying to use SteamConnectRequest by sending the session ticket of steam, but I keep getting "NOTAUTHENTICATED" response.


I'm getting the steam session ticket using:

FString SessionTicket = OnlineInterface->GetIdentityInterface()->GetAuthToken(0);


An example of a steam session ticket I receive:


"14000000564E6918DAD11CE5F7A06C0501001001B21D4F58180000000100000002000000AA5887B29201A8C0F7F9270111000000B20000003200000004000000F7A06C0501001001E0010000AA5887B29201A8C00000000058ED4E58D89C6A58010000000000000000001335BB960202372CE847D444578F60E784BD49136350A3A60D01875442D3872084996C331020900542EEDF4043B826B151458B07C8F3425A90403933694716BA3EC6B72993A6354D61A3ED9E4395ED1648E874591CF00697E00C8397B1EB67E62752548E86DFA853D9AF5F55A6480E6D7356B2BF5F292D986244B5B7D1AF8F1F"


I have tried transforming it to hex like Hive said in this post: https://support.gamesparks.net/support/discussions/topics/1000078113

but I still receive the "NOTAUTHENTICATED" message.


Any help would be appreciated!


Thank you


Best Answer

Hey Elie, 


Your gameID would be the 6 digit number in your API key, so if my API key is u300466LS80Z my gameID is:


300466


To make any call to call to Steam you need an API key. You can generate one for yourself here: 


https://steamcommunity.com/dev/apikey


Cheers,

Omar


Hi,


Alongside the NOTAUTHENTICATED error there comes some more useful information.


Can you print your whole JSON response and show it to me please. 


I can confirm that this approach works, I've successfully authenticated using SteamConnectRequest and GetAuthToken(0).


Cheers,

Omar 

Hi Omar,


The JSON response I get is the following:


{

"steamTicket":"NOTAUTHENTICATED",

"steamError":"Received HTTP status code 403"

}


I also received a timeout error.


Appreciate the help.

Hey Elie, 


What's your gameID? 


I want to look at your game config.


Cheers,

Omar

Hey Omar,


I don't know how to get the gameID, could you please tell me? Maybe you mean a snapshot ID? If you mean a snapshot ID then here's one I just saved: 58517a6e9225195ad0254c69


I can tell you that for my steam integration in the GameSparks portal, I have added Steam App ID = 480, but I don't know what the Steam Api Key is so I've put it as 480 also. 480 is a shared dev key by UE4 for development before having the game greenlit on steam.


Regards,


Elie

Answer

Hey Elie, 


Your gameID would be the 6 digit number in your API key, so if my API key is u300466LS80Z my gameID is:


300466


To make any call to call to Steam you need an API key. You can generate one for yourself here: 


https://steamcommunity.com/dev/apikey


Cheers,

Omar

Dear Omar,


I finally managed to make it work by generating an api key from steam as you suggested, thank you for your help!


Though I still get sometimes a timeout error. Should I add 10 to 15 seconds "Request Timeout Seconds" parameter to the SteamConnectRequest? I have it to 0 at the moment.


Regards,


Elie

Login to post a comment