S
S
Sergey2016-02-03 17:02:57
Classmates
Sergey, 2016-02-03 17:02:57

How to restore/extend a session?

Good afternoon.
Preamble. In our application (iframe), when logging in, users.hasAppPermission is requested - MESSAGING, then - users.getInfo of the current user (name, avatar, etc.). After the application is running - requests users.getInfo.
There are two problems with the session
1) The user enters the application and immediately upon entering the first request receives {"error_code":102,"error_msg":"PARAM_SESSION_EXPIRED : Session expired","error_data":null}
It is not clear how this can be, because logically, he had to go to the page with the game, that is, the session should somehow last, because. the user is clearly logged in.
2) The user is in the system, playing (the first case was successfully completed). After a while, the system generates a users.getInfo request. The answer is similar to the first case. In this case, "some time" can be 30 minutes, maybe 2 hours, maybe more - it depends on the user's activity and the environment.
Question. Is there any way to avoid or work around this problem by creating/getting a new session or extending the current one (for case 1)? And is it possible to somehow extend the active session (for case 2)?
Or maybe there are some alternative workarounds/solutions to this problem?
Users, quite obviously, are unhappy when they cannot take advantage of social opportunities during an active game. Asking them to re-login or restart the application for this is completely unuser-friendly.
Thank you.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
N
NipponSunrise, 2016-02-26
@NipponSunrise

up.

A
Alexander Gunko, 2016-10-06
@x10der

A similar situation, we use fapi5.js from a flash game via ExternalInterface.
Most players have no problems, but in the logs we see a lot of errors
PARAM_SESSION_EXPIRED : Session expired
crashes on the first request, after updating the page with the game it passes

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question