Reputation: 79
Using the Heroku Platform API, is it possible to generate an OAuth Token which only has access to a single Heroku application?
I need to be able to add domains programmatically using Heroku's Platform API, without using a global access token which has access to all my Heroku applications.
Any help would be greatly appreciated!
Upvotes: 7
Views: 514
Reputation: 36532
I have a workaround.
I created a new heroku account, and I added the new account as a collaborator on just the app I want to give access to.
So the oauth token can be created for the new collaborator account, and it only has access to the app(s) you want it to have access to.
Upvotes: 1
Reputation: 79
Looks like it's not currently possible.
Reply from Heroku:
Tokens are currently scoped to the user they're being generated for, with optional limiting scopes (read vs write vs read-protected vs write-protected, etc. https://devcenter.heroku.com/articles/oauth#scopes ). It's not possible to limit them to a single app of many on your account.
Upvotes: 0