Class: CachetComponents
- Inherits:
-
CachetClient
- Object
- CachetClient
- CachetComponents
- Defined in:
- lib/cachet.rb
Overview
Inherits CachetClient and handles all Components API Calls
Constant Summary
Constants inherited from CachetClient
CachetClient::INCIDENT_FIXED, CachetClient::INCIDENT_IDENTIFIED, CachetClient::INCIDENT_INVESTIGATING, CachetClient::INCIDENT_SCHEDULED, CachetClient::INCIDENT_WATCHING, CachetClient::STATUS_MAJOR_OUTAGE, CachetClient::STATUS_OPERATIONAL, CachetClient::STATUS_PARTIAL_OUTAGE, CachetClient::STATUS_PERFORMANCE_ISSUES, CachetClient::VERSION
Instance Method Summary collapse
-
#create(options) ⇒ Object
Create Component.
-
#delete(options) ⇒ Object
Delete Component.
-
#groups_create(options) ⇒ Object
Create Component Group.
-
#groups_delete(options) ⇒ Object
Delete Component Group.
-
#groups_list ⇒ Object
List all Component Groups.
-
#groups_list_id(options) ⇒ Object
List Component Group by ID.
-
#groups_update(options) ⇒ Object
Update Component Group.
-
#list ⇒ Object
List all Components.
-
#list_id(options) ⇒ Object
List Component by ID.
-
#update(options) ⇒ Object
Update Component.
Methods inherited from CachetClient
Constructor Details
This class inherits a constructor from CachetClient
Instance Method Details
#create(options) ⇒ Object
Create Component.
129 130 131 132 133 |
# File 'lib/cachet.rb', line 129 def create() request method: :post, url: @base_url + 'components', payload: end |
#delete(options) ⇒ Object
Delete Component.
159 160 161 162 |
# File 'lib/cachet.rb', line 159 def delete() request method: :delete, url: @base_url + 'components/' + ['id'].to_s end |
#groups_create(options) ⇒ Object
Create Component Group.
193 194 195 196 197 |
# File 'lib/cachet.rb', line 193 def groups_create() request method: :post, url: @base_url + 'components/groups', payload: end |
#groups_delete(options) ⇒ Object
Delete Component Group.
220 221 222 223 |
# File 'lib/cachet.rb', line 220 def groups_delete() request method: :delete, url: @base_url + 'components/groups/' + ['id'].to_s end |
#groups_list ⇒ Object
List all Component Groups.
169 170 171 172 |
# File 'lib/cachet.rb', line 169 def groups_list request method: :get, url: @base_url + 'components/groups' end |
#groups_list_id(options) ⇒ Object
List Component Group by ID.
180 181 182 183 |
# File 'lib/cachet.rb', line 180 def groups_list_id() request method: :get, url: @base_url + 'components/groups/' + ['id'].to_s end |
#groups_update(options) ⇒ Object
Update Component Group.
208 209 210 211 212 |
# File 'lib/cachet.rb', line 208 def groups_update() request method: :put, url: @base_url + 'components/groups/' + ['id'].to_s, payload: end |
#list ⇒ Object
List all Components.
102 103 104 105 |
# File 'lib/cachet.rb', line 102 def list request method: :get, url: @base_url + 'components' end |
#list_id(options) ⇒ Object
List Component by ID.
112 113 114 115 |
# File 'lib/cachet.rb', line 112 def list_id() request method: :get, url: @base_url + 'components/' + ['id'].to_s end |
#update(options) ⇒ Object
Update Component.
147 148 149 150 151 |
# File 'lib/cachet.rb', line 147 def update() request method: :put, url: @base_url + 'components/' + ['id'].to_s, payload: end |