The Hub is now in read-only mode as we make improvements to the Hub experience. More information is available here.
01-12-2024 12:28 PM
I'm extremely new to this but after trying to get anything to work for 3 hours I thought I'd ask here.
I'm trying to get activity data for a Python project. I've followed all the steps on the getting started doc and now I'm trying to use the requests module in Python to get activity information.
Why isn't this working?
import requests
access_token = ""
headers = {"Authorization" : f"Bearer {access_token}"}
response = requests.get("https://www.strava.com/api/v3/athlete/activities", headers=headers)
print(response)
print(response.text)
I just keep getting:
<Response [401]>
{"message":"Authorization Error","errors":[{"resource":"Athlete","field":"access_token","code":"invalid"}]}
Really grateful for any help on this I'm completely lost 😕
Solved! Go to Solution.
01-12-2024 06:58 PM
check access token use new access token if its expires ... access token expires every 6hr
02-28-2024 08:58 AM
Encountering the same problem also. I can't authorize(?) my token when using local host
01-16-2024 01:17 AM
I am also facing the same problem
01-12-2024 06:58 PM
check access token use new access token if its expires ... access token expires every 6hr
Welcome to the Community - here is your guide to help you get started!