google / google-api-javascript-client

Google APIs Client Library for browser JavaScript, aka gapi.
Apache License 2.0
3.12k stars 1.05k forks source link

How to keep users signed in without cookies #469

Open tjallingt opened 5 years ago

tjallingt commented 5 years ago

I'm working on a webapp that uses the google spreadsheets api. However since this app is running in a qt webengine which isn't storing cookies/session information i'd like to store and restore the required session data manually (the qt webengine stuff allows me to store strings). On the server you can use a refresh token to re-request a api access token but i'd like to keep everything clientside.

argarner commented 4 years ago

@tjallingt You can auth the token backend by doing this => https://developers.google.com/identity/sign-in/web/backend-auth.

You can refresh a token in the browser by viewing my comment here => https://github.com/google/google-api-javascript-client/issues/643#issuecomment-642350903 & the new documentation update issue I've raised here