Smartsheet token - expiration time

Przemek
Przemek
edited 12/09/19 in API & Developers

Hi,

How to expand expiration time for token without using of SDK (no APPLICATION)? - I just needed it for simple csv download & then process it via Informatica Power Center.

Just execution of script/cmd like this one:

curl https://api.smartsheet.com/2.0/users/me -H "Authorization: Bearer xxx" -o $PMRootDir/scripts/json_data_curl.json -v

Is there any way to set it from beginning to 1 year for example?

Comments

  • dave-inden
    dave-inden ✭✭✭

    The tokens you generate in the UI of Smartsheet are long lived. They are valid for 10 years by default. For this process you can go into your account and choose the Account menu (profile picture in upper right) > Personal Settings > API Access > Generate new access token.

    That token can be plugged into your script without having to do any authentication requests to create it. It will be valid for 10 years and can be used as needed for requests made by your account.

    Note, once you generate the token and close the menu there isn't a method to look it back up again, so you'll need to store it somewhere securely. Also, it is the equivalent of your email and password for your account. It would provide API access to everything in your account. You'll want to make sure to store it securely and to not let it get publicly posted anywhere. Also, once revoked it cannot be brought back and you would have to generate a new one.