Closed andhapp closed 7 years ago
Hey, for add-ons, we pass the body's config blob on to the partner, which is how in this case version is passed. So I believe you would want an invocation like:
heroku.addon.create('heroku-postgresql:standard-0', { config: { version: "9.4.9" } })
Hope that clarifies for you, it probably should be better and more clearly documented.
Thanks. I've been using the following command to create addons:
heroku.addon.create(APP_NAME, { plan: 'heroku-postgresql:standard-0' })
Is that right? Looks different from what you've suggested.
Oops, just my faulty memory, let me try again:
heroku.addon.create(APP_NAME, {
config: { version: "9.4.9" },
plan: 'heroku-postgresql:standard-0'
})
I think that should be accurate, sorry for the confusion.
No worries. Thanks. That works!
Can I raise a PR to update README with an example of the same?
Yeah, a PR to add that to the README sounds great, thanks!
Hey,
I am using the API to create add-ons and that works fine. However, I'd like to specify a version for the addon to be installed on my account. For example: Heroku PostgreSql, I'd like to install postgres 9.4.9 as opposed to the latest.
How can I achieve that in the API?
I couldn't see any examples or anything in the code related to this. May be it's not possible but would like to know before I start exploring other options.
Thanks.