README.md in heroku-api-0.1.0 vs README.md in heroku-api-0.1.1
- old
+ new
@@ -10,13 +10,13 @@
Usage
-----
Start by creating a connection to Heroku with your credentials:
- require 'heroku-rb'
+ require 'heroku-api'
- heroku = Heroku.new(:api_key => API_KEY)
+ heroku = Heroku::API.new(:api_key => API_KEY)
NOTE: You can leave out the `:api_key` if `ENV['HEROKU_API_KEY']` is set instead.
Now you can make requests to the api.
@@ -35,21 +35,21 @@
heroku.post_addon('app', 'addon') # add 'addon' add-on to 'app' app
heroku.put_addon('app', 'addon') # update 'addon' add-on on 'app' app
### Apps
- heroku.delete_app('app') # delete an app named 'app'
- heroku.get_app('app') # get info about an app named 'app'
- heroku.get_apps # get a list of your apps
- heroku.post_apps # create an app with a generated name and the default stack
+ heroku.delete_app('app') # delete an app named 'app'
+ heroku.get_apps # get a list of your apps
+ heroku.get_app('app') # get info about an app named 'app'
+ heroku.post_app # create an app with a generated name and the default stack
+ heroku.post_app('name' => 'app') # create an app with a specified name
+ heroku.post_app_maintenance('app', '1') # toggle maintenance mode
- heroku.post_apps('name' => 'app') # create an app with a specified name
-
### Collaborators
delete_collaborator('app', 'email@example.com') # remove 'email@example.com' collaborator from 'app' app
- delete_collaborator('app') # list collaborators for 'app' app
+ get_collaborators('app') # list collaborators for 'app' app
post_collaborator('app', 'email@example.com') # add 'email@example.com' collaborator to 'app' app
### Config Variables
delete_config_var('app', 'KEY') # remove 'KEY' key from 'app' app
@@ -95,18 +95,21 @@
### Stacks
get_stack('app') # list available stacks
put_stack('app', 'stack') # migrate 'app' app to 'stack' stack
+### User
+ get_user # list user info
+
Mock
----
For practice or testing you can also use a simulated Heroku:
- require 'heroku-rb'
+ require 'heroku-api'
- heroku = Heroku.new(:api_key => API_KEY, :mock => true)
+ heroku = Heroku::API.new(:api_key => API_KEY, :mock => true)
After that commands should still behave the same, but they will only modify some local data instead of updating the state of things on Heroku.
Tests
-----