module Evrythng class Client # Defines methods related to collections module Collections # Returns a list of collections # # @param options [Hash] A customizable set of options. # @return [Array] The requested list of collections. # @see http://dev.evrythng.com/collections # @example Return the list of collections # Evrythng.collections def collections(options={}) get('collections', options) end # Creates a collection # # @param name [String] The name of collection. # @param description [String] The description of collection. # @param options [Hash] A customizable set of options. # @return [Hash] The created collection. # @see http://dev.evrythng.com/collections # @example Create the authenticating user's collection # Evrythng.collection_create("This is a new collection!", "Here comes the description.") def collection_create(name, description=nil, options={}) post('collections', options.merge(:name => name, :description => description)) end end end end