Module: Evrythng::Client::Collections
- Included in:
- Evrythng::Client
- Defined in:
- lib/evrythng/client/collections.rb
Overview
Defines methods related to collections
Instance Method Summary collapse
-
#collection_create(name, description = nil, options = {}) ⇒ Hash
Creates a collection.
-
#collections(options = {}) ⇒ Array
Returns a list of collections.
Instance Method Details
#collection_create(name, description = nil, options = {}) ⇒ Hash
Creates a collection
25 26 27 |
# File 'lib/evrythng/client/collections.rb', line 25 def collection_create(name, description=nil, ={}) post('collections', .merge(:name => name, :description => description)) end |
#collections(options = {}) ⇒ Array
Returns a list of collections
12 13 14 |
# File 'lib/evrythng/client/collections.rb', line 12 def collections(={}) get('collections', ) end |