Token expiration

Sure, just check the docs: http://docs.spark.io/api/#authentication-configure-when-your-token-expires :wink:

It’s such a relief. Thanks!

But it seems that there’s an error in the docs:

Setting this to 0 seconds will create a token that never expires.

“expires_in = 0” just creates token that is already expired:

{
   "error": "invalid_token",
   "error_description": "The access token provided has expired."
}
1 Like

Hey @dave - what’s the right syntax for a token that doesn’t expire?

Hmm, that should be right, I’ll see what’s up.

edit: found it, really bizarre the unit tests didn’t catch this, looks like it regressed, patched and pushing out a fix…

Give it another try now, should be fixed. :slight_smile:

Thanks,
David

1 Like

I get “ok”: true in response to deleting a non-existent token.

Is this a newly released feature? I didn’t know I can set expiration time!

3 Likes

Rather new actually :slight_smile:

3 Likes

So if I login the Spark Build to reset the Token, by default the token will not expire, correct.
This is what I notice recently.

Yup that’s the latest update due to the introduction of expiry controllable access token :slight_smile:

See: http://docs.spark.io/api/#authentication-generate-a-new-access-token

1 Like