Client side access token

436 views
Skip to first unread message

Ibrahim Tawbe

unread,
Mar 30, 2012, 10:54:35 AM3/30/12
to google-docum...@googlegroups.com
Hi
   the access token last for 3600
   if I used the same url again will the user be prompted again to allow access or i'll get the new access token directly ?

Ibrahim Tawbe

unread,
Mar 30, 2012, 12:10:04 PM3/30/12
to google-docum...@googlegroups.com
yes , the user will have to press allow access again after an hour , so I added

if (document.getElementById('submit_approve_access') != null ) {
    document.getElementById('submit_approve_access').click();
}

this page run in the background

Alain Vongsouvanh

unread,
Mar 30, 2012, 4:58:05 PM3/30/12
to google-docum...@googlegroups.com
Hello,

If you're using the Google APIs JavaScript client library, you can try to retrieve an access token using the "immediate" mode:

This will send a request to the token sever and returns one if the user has already approved access for your application (without prompting the user).

Best,
Alain
--
Alain Vongsouvanh | Developer Programs Engineer

Pisith

unread,
Apr 1, 2012, 2:09:13 PM4/1/12
to google-docum...@googlegroups.com
Hello,

The "immediate" mode will fail if the user is logged in to two accounts(gmail).

Does it have a mode like "claimed_id" which is used in OpenID? or any other modes?

Thanks,
Pisith
Reply all
Reply to author
Forward
0 new messages