php - Use an access token provided by Google APIs for a long time -


i created app uses google analytics api. however, i've got following question:

when i'm asking access token i'm getting access token expires after 3600 seconds. got refresh token can use generate more access tokens later on.

do need use refresh token generate working access token every hour or there way have user authenticate once , use same code without going through expiration trouble?

i want have cronjob, , while know, it's easy use refresh token obtain new one, i'm still asking if it's somehow possible have access token lasts forever?

otherwise i'll refresh token when needed.

there middle path: can request access token new on each call rather use refresh token.

that simplifies things can have 1 function access token , use within cron job. eliminates needing store refresh otken between cron executions.


Comments

Popular posts from this blog

javascript - how to protect a flash video from refresh? -

android - Associate same looper with different threads -

visual studio 2010 - Connect to informix database windows form application -