Andrew Stover
Andrew Stover

Reputation: 301

Google App Script Properties Service | Security and Property lifetime

The docs for the App Scripts Properties service don't give specifics on who can see what properties and how long the properties are saved.

What I'm wanting to do is have my web app give tokens to users to basically "initialize" a GSheet with paid features. Rather than go through a whole login flow, I'm thinking I can just have users input the token in a prompt and then use the User Property to save the token.

var userProperties = PropertiesService.getUserProperties()
userProperties.setProperty('token', token)

What I'm not sure of is it safe or not to basically save a long lived bearer token as a property here? Is there any way it could be accessible to another user? Is that property saved for the life of the gSheet?

Upvotes: 2

Views: 544

Answers (1)

TheAddonDepot
TheAddonDepot

Reputation: 8964

The docs for the App Scripts Properties service don't give specifics on who can see what properties and how long the properties are saved.

  1. https://developers.google.com/apps-script/guides/properties#comparison_of_property_stores
  2. https://developers.google.com/apps-script/guides/services/quotas
  3. https://developers.google.com/apps-script/reference/cache/cache-service

Upvotes: 1

Related Questions