Create a customer
curl --request POST \
--url https://back.leap.onclarity.com/api/customer/create \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"first_name": "<string>",
"attributes": {},
"last_name": "<string>",
"avatar_url": "<string>",
"tags": [
123
]
}
'import requests
url = "https://back.leap.onclarity.com/api/customer/create"
payload = {
"first_name": "<string>",
"attributes": {},
"last_name": "<string>",
"avatar_url": "<string>",
"tags": [123]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
first_name: '<string>',
attributes: {},
last_name: '<string>',
avatar_url: '<string>',
tags: [123]
})
};
fetch('https://back.leap.onclarity.com/api/customer/create', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": 123,
"first_name": "<string>",
"organization_id": 123,
"attributes": [
{
"key": "<string>",
"value": "<string>"
}
],
"last_name": "<string>",
"avatar_url": "<string>",
"tags": [
{
"id": 123,
"name": "<string>",
"color": "<string>",
"description": "<string>"
}
],
"custom_attributes": {},
"gender": "<string>",
"gender_source": "<string>",
"merged_into_id": 123,
"has_open_suggestion": false,
"channels": [
"whatsapp"
]
}{
"code": "<string>",
"status": "error",
"message": "<string>",
"extra": {}
}{
"code": "<string>",
"status": "error",
"message": "<string>",
"extra": {}
}Customers
Create a customer
POST
/
api
/
customer
/
create
Create a customer
curl --request POST \
--url https://back.leap.onclarity.com/api/customer/create \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"first_name": "<string>",
"attributes": {},
"last_name": "<string>",
"avatar_url": "<string>",
"tags": [
123
]
}
'import requests
url = "https://back.leap.onclarity.com/api/customer/create"
payload = {
"first_name": "<string>",
"attributes": {},
"last_name": "<string>",
"avatar_url": "<string>",
"tags": [123]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
first_name: '<string>',
attributes: {},
last_name: '<string>',
avatar_url: '<string>',
tags: [123]
})
};
fetch('https://back.leap.onclarity.com/api/customer/create', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": 123,
"first_name": "<string>",
"organization_id": 123,
"attributes": [
{
"key": "<string>",
"value": "<string>"
}
],
"last_name": "<string>",
"avatar_url": "<string>",
"tags": [
{
"id": 123,
"name": "<string>",
"color": "<string>",
"description": "<string>"
}
],
"custom_attributes": {},
"gender": "<string>",
"gender_source": "<string>",
"merged_into_id": 123,
"has_open_suggestion": false,
"channels": [
"whatsapp"
]
}{
"code": "<string>",
"status": "error",
"message": "<string>",
"extra": {}
}{
"code": "<string>",
"status": "error",
"message": "<string>",
"extra": {}
}Authorizations
Your organization API key (it starts with anek_org_). The same key works on the Voice API and the Support API. See Authentication.
Body
application/json
Response
Request fulfilled, document follows
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Channel type (web, android_sdk, ios_sdk, whatsapp)
Available options:
whatsapp, android_sdk, ios_sdk, web, voice, social, x, email, instagram, linkedin