Skip to main content
Solved

why access key of a user is expire every time from my site

  • December 17, 2024
  • 3 replies
  • 47 views

Forum|alt.badge.img+1

Hello All
can you please help me to find out that why every time access key is expire.
i have a website where i need to fetch all the races of a user who have account in strava, now i have created that user access token key and store in my database, every time when user come and want to see all races its showing that your access key is expire, again i have to regenerate the key and the process going on. 
kan anyone please tell me why its happen?

Best answer by Jan_Mantau

This is intended, you got a refresh_token in order to update the access_token. You should go through the explanations in https://developers.strava.com/docs/getting-started/#oauth again.

View original

3 replies

Jan_Mantau
Superuser
Forum|alt.badge.img+26
  • Superuser
  • 946 replies
  • Answer
  • December 17, 2024

This is intended, you got a refresh_token in order to update the access_token. You should go through the explanations in https://developers.strava.com/docs/getting-started/#oauth again.


Forum|alt.badge.img+1
  • Author
  • Hub Rookie
  • 1 reply
  • January 30, 2025

Thank you for your help!

 

The piece I think we are missing is once authorized, we are not able to get the client ID so that we can fetch the refresh token. Does anyone know a way to retrieve this client ID once a user authorizes without that user having to go into their account or copy that ID out of the url?

 

We are only getting access for 6 hours before the authorization expires.


Jan_Mantau
Superuser
Forum|alt.badge.img+26
  • Superuser
  • 946 replies
  • January 30, 2025

The user doesn’t have a client id, only your app has it and you can copy it from your API settings page https://www.strava.com/settings/api

Also you don’t fetch the refresh token as an extra step, it always comes alongside the access token.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept, you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings