Skip to main content
Answered

Beginner question: How to get Activity:write permissions ?

  • Mar 18, 2025 7:33 PM UTC
  • 3 replies
  • 353 views

Forum|alt.badge.img+1

I'm writing software that controls my treadmill. The idea is that I can run any run in the world, and the treadmill responds to the gpx data coming in and is doing all climbs as if it were the real world.

At the end of a run, I want to upload my activity to Strava. And that is the point in which I get stuck….
Using the client id, client secret I'm able to get a bearer token. This token has read permissions.  In order to write to an activity I need write permissions.  I cant figure out how I can exchange the bearer token for an authorization token that authorizes me to write data to the activity. 

Can anyone help me?   

 

 

Best answer by Jan_Mantau

When requesting the bearer token with your client id and secret you have to list all the permissions you want to have in the “scope” parameter of the URL, in this case at least activity:write. As this is your own account you want to access it would be normal to request all the other possible permissions too, together that would lead to scope=read_all,profile:read_all,activity:read_all,activity:write

 It’s all outlined in https://developers.strava.com/docs/authentication/

View original

3 replies

Jan_Mantau
Forum|alt.badge.img+26
  • Hub Powerhouse
  • Answer
  • Mar 18, 2025 10:30 PM UTC

When requesting the bearer token with your client id and secret you have to list all the permissions you want to have in the “scope” parameter of the URL, in this case at least activity:write. As this is your own account you want to access it would be normal to request all the other possible permissions too, together that would lead to scope=read_all,profile:read_all,activity:read_all,activity:write

 It’s all outlined in https://developers.strava.com/docs/authentication/


Forum|alt.badge.img+1
  • Author
  • Hub Rookie
  • Mar 20, 2025 8:10 AM UTC

​@Jan_Mantau  If I understand you correctly, all I have to do when requesting the access_token is passing in a scope parameter with all the permissions I want on my own account?  Is it that easy?


Jan_Mantau
Forum|alt.badge.img+26
  • Hub Powerhouse
  • Mar 20, 2025 8:23 AM UTC

Exactly