Java wrapper of Heroku Platform API.
https://devcenter.heroku.com/articles/platform-api-reference
- RateLimitRating
- Account
- AccountFeature
- Addon
- AddonService
- App
- AppFeature
- AppTransfer
- Collaborator
- Config
- Domain
- Dyno
- Formation
- Key
- LogDrain
- LogSession
- OAuthAuthorization
- OAuthClient
- OAuthToken
- Plan
- Region
- Release
- SSLEndpoint
- Stack
None(2013-12-06)
//Get the url of Heroku authentication page.
String oauthUrl = PlatformApi.getOAuthUrl("<YOUR_CLIENT_ID>", Scope.Global);
//... Authenticate and get code.
PlatformApi api = PlatformApi.fromOAuth("<YOUR_CLIENT_SECRET>", code);
//Get application list
List<App> appList = api.getAppList();
App app = appList.get(0);
//heroku ps:scale web=5
Formation api.updateFormation(app.getName(), "web", 5, 1);
//heroku ps:restart
api.restart(app.getName());
MIT