module Crm::Core::Mixins::Modifiable::ClassMethods
@api public
Public Instance Methods
create(attributes = {})
click to toggle source
Creates a new item using the given attributes
. @example
Crm::Contact.create({ language: 'en', last_name: 'Smith', }) # => Crm::Contact
@param attributes [Hash{String, Symbol => String}] the attributes of the new item. @return [BasicResource] the created item. @raise [Errors::InvalidKeys] if attributes
contains unknown attribute names. @raise [Errors::InvalidValues] if attributes
contains incorrect values. @api public
# File lib/crm/core/mixins/modifiable.rb, line 24 def create(attributes = {}) new(RestApi.instance.post(path, attributes)) end