I’m looking to update the PowerShell module started here: https://github.com/adamdriscoll/stravapwsh. However, the challenge I’m having are the requirements put on me with regard to creating a new application. I’m just interested in getting a Token to utilize the module and update it, not create an application.
For example, I’d like to be able to perform all the various available API calls, but from the terminal. Any help in acquiring a Token without creating an app is appreciated.
I don’t know of a good, reliable way to get a token with the scopes you want without creating your own app. However, that doesn’t mean you have to create a full-fledged application; you really only need to create an app so you have a client ID and client secret. You can stay in what Strava calls “single player mode” and either create a small script to get a token, or use the swagger playground to get one (https://developers.strava.com/playground)
If you take the scripting approach, I think the most accessible option would be to use the Python stravalib. There is excellent documentation on it and a lot of examples online (you could probably even get chatgpt to create mostly working code for you). You can use the localhost option to authorize your app and get a token and refresh token. Once you’ve got a refresh token you won’t have to go through the process again, you can just use it in the Python code to get a new token afters your expires. Tie that in with the powershell script and you should be good to go.
Reply
Login to the community
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.