Method: BaseCRM::ContactsService#create
- Defined in:
- lib/basecrm/services/contacts_service.rb
#create(contact) ⇒ Contact
Create a contact
post ‘/contacts’
Create a new contact A contact may represent a single individual or an organization
58 59 60 61 62 63 64 65 |
# File 'lib/basecrm/services/contacts_service.rb', line 58 def create(contact) validate_type!(contact) attributes = sanitize(contact) _, _, root = @client.post("/contacts", attributes) Contact.new(root[:data]) end |