Clarification on sandbox (and live) access tokens
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If I understand correctly, the sandbox access tokens are good for roughly 30 seconds? That means if you're chasing bugs in your code, you'd have to request a new access token each time you needed to test a change?
How does this work in the live environment? I'm working on integrating subscriptions into my website, and I need to display the available subscription plans for each product. I'd rather not have to hard-code the subscription plan numbers into the software, but to do a call for a list of available plans when a customer requests it. Is an access token request going to be required every time a customer clicks on the dropdown for plans, in order to display the list?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @newnaturals,
I can answer half this question right now. Access tokens are valid for a minimum of 8 hours. Between sandbox and live, these two environments should be at parity. Does this help you answering your 2nd part of this question?
This detail can be confirmed in our REST API Authentication sample code documentation. Note: The below number is reflective of seconds.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks, eight hours is certainly better than 30 seconds. It doesn't solve the problem of having to obtain a new access key for each customer inquiry, but will help with debugging situations.

Haven't Found your Answer?
It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.
- Missing shipping address with billingAgreement API in Sandbox Environment
- Advanced checkout buttons in REST APIs
- NOT_ENABLED_TO_VAULT_PAYMENT_SOURCE only when using "paypal" as my payment source in REST APIs
- Generating/Refreshing Token and Checking Order Status Using REST API in Java in REST APIs
- PayPal subscriptions using a credit card without registering an account in PayPal Payments Standard