The following macros are not currently supported in the header:
- style
POST /contacts
The following endpoint should be used to create a brand new contact and affiliation. If you have an existing contact and wish to link it to another company, please see create affiliation.
Resource URL
Create a new contact object.
POST /contacts
Parameters
Table of allowed parameters. Underlined parameters are required.
company_id | unsigned int | Must point to a valid company. This is the company new affiliated contact will point. |
---|---|---|
firstname | String | Â |
middlename | string | Â |
surname | string | Â |
preferred_name | string | Â |
username | string | Must be unique. Otherwise you will get invalid_request |
password | string | Â |
title | string | Â |
salutation | string | Â |
comments | string | Â |
status | unsigned int | This must point to a valid affiliation status id, otherwise you will get an invalid_request |
standing | string | Must be potential, interested, active or inactive, otherwise you will get an invalid_request. |
country_id | unsigned int | Must point to a valid country |
physical_address_id | unsigned int | Physical address. Must point to a valid address |
postal_address_id | unsigned int | Postal address. Must point to a valid address. |
phone | string | The contact's phone number in relation to the affiliated company. e.,g this may be their work number. |
fax | string | The contact's fax in relation to the affiliation company. e.g, this may be their work fax number. |
string | Must be a valid email address | |
position | string | e.g, CEO, software engineer or volunteer fire fighter. |
status_id | unsigned int | The affiliations status id. Must point to a valid affiliation status |
standing | string | e.g, active, inactive |
communication | string | Must be yes or no. |
invoice_method | string | e.g, email, fax or postal |
Handling the response
Returns the created contact object. Please see get contact for details regarding handling of the response.