Create Contact
Create a new contact in an account.
Settings:
|
URL |
https://online.99digital.co.il/api/v1/accounts/{account_id}/contacts |
|
Method |
JSON via POST |
Authorization:
|
Header Parameter |
Description |
|
api_access_token |
user API key |
The user API key provides access to endpoints based on the user permissions levels and can be obtained by visiting the profile page.
Path Parameters:
|
Parameter |
Description |
Required |
|
account_id |
The numeric id of the account |
yes |
Request body:
|
Parameter |
type |
Description |
Required |
|
inbox_id |
integer |
The numeric id of the inbox |
yes |
|
name |
string |
Name of the contact |
no |
|
|
string |
Email of the contact |
no |
|
phone_number |
string |
Phone number of the contact in e164 format. for example: +972771234567 |
no |
|
avatar_url |
string |
The url to a jpeg, png file for the contact avatar |
no |
|
identifier |
string |
A unique identifier for the contact in external system |
no |
|
custom_attributes |
string |
An object where you can store custom attributes for contact. example {"type":"customer", "age":30} |
no |
Request body example:
{
"inbox_id": 0,
"name": "string",
"email": "string",
"phone_number": "string",
"avatar_url": "string",
"identifier": "string",
"custom_attributes": {}
}
Response:
{
"payload": {
"contact": {
"id": 0,
"name": "string",
"email": "string",
"phone_number": "string",
"availability_status": "offline",
"identifier": "string",
"thumbnail": "string",
"blocked": false,
"created_at": 0,
"custom_attributes": {
"attribute_key": "attribute_value"
},
"additional_attributes": {},
"contact_inboxes": [
{
"source_id": "string",
"inbox": {}
}
]
},
"contact_inbox": {
"inbox": {},
"source_id": "string"
}
}
}
Response-Explain:
|
Parameter |
Description |
|
payload |
Object containing the |
|
payload -> contact |
Object containing the contact details |
|
payload -> contact -> id |
Contact numeric id |
|
payload -> contact -> name |
Full name of the contact |
|
payload -> contact -> email |
Email address of the contact |
|
payload -> contact -> phone_number |
Phone number of the contact |
|
payload -> contact -> availability_status |
Availability status of the contact
|
|
payload -> contact -> identifier |
A unique identifier for the contact in external system |
|
payload -> contact -> thumbnail |
Avatar URL of the contact |
|
payload -> contact -> blocked |
Whether the contact is blocked |
|
payload -> contact -> created_at |
Timestamp of contact creation time |
|
payload -> contact -> custom_attributes |
The object to save custom attributes for contact, accepts custom attributes key and value |
|
payload -> contact -> additional_attributes |
The object containing additional attributes related to the contact |
|
payload -> contact -> contact_inboxes |
Array of objects (contact_inboxes) |
|
payload -> contact_inbox |
|
|
payload -> contact_inbox -> source_id |
Contact inbox source id |
|
payload -> contact_inbox -> inbox |
Object containing the inbox details |
Created with the Personal Edition of HelpNDoc: Create iPhone web-based documentation