question

dominiquecanzeri avatar image
dominiquecanzeri asked

renew sessionticket/entitytoken

hello,

I was wondering what was the suggested way to extend a user/server session when we get a InvalidSessionTicket/InvalidSessionId/AuthTokenExpired/EntityTokenExpired, etc

For server/admin session, I guess a simple GetEntityToken() should work, but what about clients?

Should we trigger a manual ClientAPI.LoginWith.... when that happens? Is there another way to renew a session on the client?

thanks

Authentication
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
Sarah Zhang avatar image
Sarah Zhang answered

>> Should we trigger a manual ClientAPI.LoginWith.... when that happens? Is there another way to renew a session on the client?

Yes, we should trigger a login method to reacquire a new session ticket for players. One session ticket is throwaway, it expires after 24 hours. So, currently calling login API again is the only way to renew a session on the client.

You can try to implement the automatic login mechanism in the clients instead call the login API manually. PlayFab Anonymous login mechanisms are designed for such usages, you can check the doc Login basics and best practices for the suggestions to do login mechanism. Generally, your game should use an anonymous login for creating a new account and linking new devices to an existing account.

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.