Oauth key expiry | Community
Skip to main content
Level 3
January 19, 2024
Solved

Oauth key expiry

  • January 19, 2024
  • 2 replies
  • 663 views

Hi,

We are looking to integrate with a 3rd party by leveraging one of the api.  However, it seems the Oauth key has a very short expire window.  How do we work around as we don't want to go in and update the key everyday?  Any help is appreciated.

Thanks

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by abhinavbalooni

Hey @cbsimp 

 

I am sure you already know, the refresh of a token is a security feature which is meant to keep your connections safe, so with a production setup, it is always better to have the token generated within a timeframe.

 

Also, when you mention, you don't want to go in and update, how are you generating the token? Reason for asking this is that tokens can be generated programatically just before making the api call and can then be plugged into the api call headers. My suggestion would be to try and generate it in the script/code before making the api call instead of trying to circumvent the expiry. This way you won't have to do it manually.

 

Cheers,

Abhinav

2 replies

brekrut
Adobe Employee
Adobe Employee
January 19, 2024

It depends on the API which you are looking to use.

 

Query service does have a non-expiring Service Account, but all other end points have an beaer token which need to be refreshed.

abhinavbalooni
Community Advisor
abhinavbalooniCommunity AdvisorAccepted solution
Community Advisor
January 19, 2024

Hey @cbsimp 

 

I am sure you already know, the refresh of a token is a security feature which is meant to keep your connections safe, so with a production setup, it is always better to have the token generated within a timeframe.

 

Also, when you mention, you don't want to go in and update, how are you generating the token? Reason for asking this is that tokens can be generated programatically just before making the api call and can then be plugged into the api call headers. My suggestion would be to try and generate it in the script/code before making the api call instead of trying to circumvent the expiry. This way you won't have to do it manually.

 

Cheers,

Abhinav