Module: RedboothRuby::Operations::Create::ClassMethods
- Defined in:
- lib/redbooth-ruby/operations/create.rb
Instance Method Summary collapse
-
#create(attributes) ⇒ Object
Creates a new object.
Instance Method Details
#create(attributes) ⇒ Object
Creates a new object
8 9 10 11 12 13 14 15 16 17 |
# File 'lib/redbooth-ruby/operations/create.rb', line 8 def create(attributes) session = attributes.delete(:session) response = RedboothRuby.request(:post, nil, api_collection_url(attributes), attributes, (session: session) ) new(response.data.merge(session: session)) end |