Module: Bugsnag::Api::Client::Organizations
- Included in:
- Bugsnag::Api::Client
- Defined in:
- lib/bugsnag/api/client/organizations.rb
Overview
Methods for the Organizations API
Instance Method Summary collapse
-
#create_organization(name, options = {}) ⇒ Sawyer::Resource
Create an Organization.
-
#delete_organization(id, options = {}) ⇒ Object
Delete an Organization.
-
#organization(id, options = {}) ⇒ Sawyer::Resource
View an Organization.
-
#update_organization(id, name, auto_upgrade, options = {}) ⇒ Sawyer::Resource
Update an Organization.
Instance Method Details
#create_organization(name, options = {}) ⇒ Sawyer::Resource
Create an Organization
13 14 15 |
# File 'lib/bugsnag/api/client/organizations.rb', line 13 def create_organization(name, = {}) post "organizations", .merge({:name => name}) end |
#delete_organization(id, options = {}) ⇒ Object
Delete an Organization
39 40 41 |
# File 'lib/bugsnag/api/client/organizations.rb', line 39 def delete_organization(id, = {}) boolean_from_response :delete, "organizations/#{id}", end |
#organization(id, options = {}) ⇒ Sawyer::Resource
View an Organization
21 22 23 |
# File 'lib/bugsnag/api/client/organizations.rb', line 21 def organization(id, = {}) get "organizations/#{id}", end |
#update_organization(id, name, auto_upgrade, options = {}) ⇒ Sawyer::Resource
Update an Organization
31 32 33 |
# File 'lib/bugsnag/api/client/organizations.rb', line 31 def update_organization(id, name, auto_upgrade, = {}) patch "organizations/#{id}", .merge({:name => name, :auto_upgrade => auto_upgrade}) end |