curl --request POST \
--url https://api.elemente.ai/api/v1/calls \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/json' \
--data '
{
"agentId": "123e4567-e89b-12d3-a456-426614174000",
"channel": "call",
"skillId": "123e4567-e89b-12d3-a456-426614174000",
"customerOverride": {
"firstName": "John",
"lastName": "Doe",
"phoneNumber": "+1234567890",
"email": "admin@email.com",
"language": "en-US",
"customFields": [
{
"name": "Order ID",
"value": "12345"
},
{
"name": "Order Date",
"value": "2025-03-12"
},
{
"name": "Order Amount",
"value": 150.75
},
{
"name": "Active Status",
"value": true
}
]
},
"agentOverride": {
"name": "John Doe",
"phone": "+12673624524",
"imageURL": "https://example.com/image.jpg",
"language": "en-US",
"voiceStability": 0.5,
"voiceSpeed": 1.5
},
"customerName": "John Does",
"customerPhone": "+1234567890",
"customerEmail": "customer@email.com"
}
'import requests
url = "https://api.elemente.ai/api/v1/calls"
payload = {
"agentId": "123e4567-e89b-12d3-a456-426614174000",
"channel": "call",
"skillId": "123e4567-e89b-12d3-a456-426614174000",
"customerOverride": {
"firstName": "John",
"lastName": "Doe",
"phoneNumber": "+1234567890",
"email": "admin@email.com",
"language": "en-US",
"customFields": [
{
"name": "Order ID",
"value": "12345"
},
{
"name": "Order Date",
"value": "2025-03-12"
},
{
"name": "Order Amount",
"value": 150.75
},
{
"name": "Active Status",
"value": True
}
]
},
"agentOverride": {
"name": "John Doe",
"phone": "+12673624524",
"imageURL": "https://example.com/image.jpg",
"language": "en-US",
"voiceStability": 0.5,
"voiceSpeed": 1.5
},
"customerName": "John Does",
"customerPhone": "+1234567890",
"customerEmail": "customer@email.com"
}
headers = {
"Authorization": "Basic <encoded-value>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Basic <encoded-value>', 'Content-Type': 'application/json'},
body: JSON.stringify({
agentId: '123e4567-e89b-12d3-a456-426614174000',
channel: 'call',
skillId: '123e4567-e89b-12d3-a456-426614174000',
customerOverride: {
firstName: 'John',
lastName: 'Doe',
phoneNumber: '+1234567890',
email: 'admin@email.com',
language: 'en-US',
customFields: [
{name: 'Order ID', value: '12345'},
{name: 'Order Date', value: '2025-03-12'},
{name: 'Order Amount', value: 150.75},
{name: 'Active Status', value: true}
]
},
agentOverride: {
name: 'John Doe',
phone: '+12673624524',
imageURL: 'https://example.com/image.jpg',
language: 'en-US',
voiceStability: 0.5,
voiceSpeed: 1.5
},
customerName: 'John Does',
customerPhone: '+1234567890',
customerEmail: 'customer@email.com'
})
};
fetch('https://api.elemente.ai/api/v1/calls', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.elemente.ai/api/v1/calls",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'agentId' => '123e4567-e89b-12d3-a456-426614174000',
'channel' => 'call',
'skillId' => '123e4567-e89b-12d3-a456-426614174000',
'customerOverride' => [
'firstName' => 'John',
'lastName' => 'Doe',
'phoneNumber' => '+1234567890',
'email' => 'admin@email.com',
'language' => 'en-US',
'customFields' => [
[
'name' => 'Order ID',
'value' => '12345'
],
[
'name' => 'Order Date',
'value' => '2025-03-12'
],
[
'name' => 'Order Amount',
'value' => 150.75
],
[
'name' => 'Active Status',
'value' => true
]
]
],
'agentOverride' => [
'name' => 'John Doe',
'phone' => '+12673624524',
'imageURL' => 'https://example.com/image.jpg',
'language' => 'en-US',
'voiceStability' => 0.5,
'voiceSpeed' => 1.5
],
'customerName' => 'John Does',
'customerPhone' => '+1234567890',
'customerEmail' => 'customer@email.com'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.elemente.ai/api/v1/calls"
payload := strings.NewReader("{\n \"agentId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"channel\": \"call\",\n \"skillId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"customerOverride\": {\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"phoneNumber\": \"+1234567890\",\n \"email\": \"admin@email.com\",\n \"language\": \"en-US\",\n \"customFields\": [\n {\n \"name\": \"Order ID\",\n \"value\": \"12345\"\n },\n {\n \"name\": \"Order Date\",\n \"value\": \"2025-03-12\"\n },\n {\n \"name\": \"Order Amount\",\n \"value\": 150.75\n },\n {\n \"name\": \"Active Status\",\n \"value\": true\n }\n ]\n },\n \"agentOverride\": {\n \"name\": \"John Doe\",\n \"phone\": \"+12673624524\",\n \"imageURL\": \"https://example.com/image.jpg\",\n \"language\": \"en-US\",\n \"voiceStability\": 0.5,\n \"voiceSpeed\": 1.5\n },\n \"customerName\": \"John Does\",\n \"customerPhone\": \"+1234567890\",\n \"customerEmail\": \"customer@email.com\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Basic <encoded-value>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.elemente.ai/api/v1/calls")
.header("Authorization", "Basic <encoded-value>")
.header("Content-Type", "application/json")
.body("{\n \"agentId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"channel\": \"call\",\n \"skillId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"customerOverride\": {\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"phoneNumber\": \"+1234567890\",\n \"email\": \"admin@email.com\",\n \"language\": \"en-US\",\n \"customFields\": [\n {\n \"name\": \"Order ID\",\n \"value\": \"12345\"\n },\n {\n \"name\": \"Order Date\",\n \"value\": \"2025-03-12\"\n },\n {\n \"name\": \"Order Amount\",\n \"value\": 150.75\n },\n {\n \"name\": \"Active Status\",\n \"value\": true\n }\n ]\n },\n \"agentOverride\": {\n \"name\": \"John Doe\",\n \"phone\": \"+12673624524\",\n \"imageURL\": \"https://example.com/image.jpg\",\n \"language\": \"en-US\",\n \"voiceStability\": 0.5,\n \"voiceSpeed\": 1.5\n },\n \"customerName\": \"John Does\",\n \"customerPhone\": \"+1234567890\",\n \"customerEmail\": \"customer@email.com\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.elemente.ai/api/v1/calls")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"agentId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"channel\": \"call\",\n \"skillId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"customerOverride\": {\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"phoneNumber\": \"+1234567890\",\n \"email\": \"admin@email.com\",\n \"language\": \"en-US\",\n \"customFields\": [\n {\n \"name\": \"Order ID\",\n \"value\": \"12345\"\n },\n {\n \"name\": \"Order Date\",\n \"value\": \"2025-03-12\"\n },\n {\n \"name\": \"Order Amount\",\n \"value\": 150.75\n },\n {\n \"name\": \"Active Status\",\n \"value\": true\n }\n ]\n },\n \"agentOverride\": {\n \"name\": \"John Doe\",\n \"phone\": \"+12673624524\",\n \"imageURL\": \"https://example.com/image.jpg\",\n \"language\": \"en-US\",\n \"voiceStability\": 0.5,\n \"voiceSpeed\": 1.5\n },\n \"customerName\": \"John Does\",\n \"customerPhone\": \"+1234567890\",\n \"customerEmail\": \"customer@email.com\"\n}"
response = http.request(request)
puts response.read_body{
"id": "123e4567-e89b-12d3-a456-426614174000",
"status": "in-progress",
"agentPhone": "+1234567890",
"agentEmail": "+1234567890",
"customerPhone": "+1234567890",
"customerEmail": "+1234567890",
"agentId": "123e4567-e89b-12d3-a456-426614174000",
"customerId": "123e4567-e89b-12d3-a456-426614174000",
"skillId": "123e4567-e89b-12d3-a456-426614174000",
"customerName": "John Doe",
"transcription": "Hello, how can I help you?",
"recordingUrl": "https://example.com/recording.wav",
"messages": [
{
"sid": "SM1234567890abcdef",
"timestamp": "2025-03-17T14:30:00Z",
"sender": "agent",
"content": "Hello, how can I assist you today?",
"mediaUrl": "https://example.com/image.jpg",
"status": "delivered"
}
],
"duration": "7200"
}Create Call
curl --request POST \
--url https://api.elemente.ai/api/v1/calls \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/json' \
--data '
{
"agentId": "123e4567-e89b-12d3-a456-426614174000",
"channel": "call",
"skillId": "123e4567-e89b-12d3-a456-426614174000",
"customerOverride": {
"firstName": "John",
"lastName": "Doe",
"phoneNumber": "+1234567890",
"email": "admin@email.com",
"language": "en-US",
"customFields": [
{
"name": "Order ID",
"value": "12345"
},
{
"name": "Order Date",
"value": "2025-03-12"
},
{
"name": "Order Amount",
"value": 150.75
},
{
"name": "Active Status",
"value": true
}
]
},
"agentOverride": {
"name": "John Doe",
"phone": "+12673624524",
"imageURL": "https://example.com/image.jpg",
"language": "en-US",
"voiceStability": 0.5,
"voiceSpeed": 1.5
},
"customerName": "John Does",
"customerPhone": "+1234567890",
"customerEmail": "customer@email.com"
}
'import requests
url = "https://api.elemente.ai/api/v1/calls"
payload = {
"agentId": "123e4567-e89b-12d3-a456-426614174000",
"channel": "call",
"skillId": "123e4567-e89b-12d3-a456-426614174000",
"customerOverride": {
"firstName": "John",
"lastName": "Doe",
"phoneNumber": "+1234567890",
"email": "admin@email.com",
"language": "en-US",
"customFields": [
{
"name": "Order ID",
"value": "12345"
},
{
"name": "Order Date",
"value": "2025-03-12"
},
{
"name": "Order Amount",
"value": 150.75
},
{
"name": "Active Status",
"value": True
}
]
},
"agentOverride": {
"name": "John Doe",
"phone": "+12673624524",
"imageURL": "https://example.com/image.jpg",
"language": "en-US",
"voiceStability": 0.5,
"voiceSpeed": 1.5
},
"customerName": "John Does",
"customerPhone": "+1234567890",
"customerEmail": "customer@email.com"
}
headers = {
"Authorization": "Basic <encoded-value>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Basic <encoded-value>', 'Content-Type': 'application/json'},
body: JSON.stringify({
agentId: '123e4567-e89b-12d3-a456-426614174000',
channel: 'call',
skillId: '123e4567-e89b-12d3-a456-426614174000',
customerOverride: {
firstName: 'John',
lastName: 'Doe',
phoneNumber: '+1234567890',
email: 'admin@email.com',
language: 'en-US',
customFields: [
{name: 'Order ID', value: '12345'},
{name: 'Order Date', value: '2025-03-12'},
{name: 'Order Amount', value: 150.75},
{name: 'Active Status', value: true}
]
},
agentOverride: {
name: 'John Doe',
phone: '+12673624524',
imageURL: 'https://example.com/image.jpg',
language: 'en-US',
voiceStability: 0.5,
voiceSpeed: 1.5
},
customerName: 'John Does',
customerPhone: '+1234567890',
customerEmail: 'customer@email.com'
})
};
fetch('https://api.elemente.ai/api/v1/calls', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.elemente.ai/api/v1/calls",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'agentId' => '123e4567-e89b-12d3-a456-426614174000',
'channel' => 'call',
'skillId' => '123e4567-e89b-12d3-a456-426614174000',
'customerOverride' => [
'firstName' => 'John',
'lastName' => 'Doe',
'phoneNumber' => '+1234567890',
'email' => 'admin@email.com',
'language' => 'en-US',
'customFields' => [
[
'name' => 'Order ID',
'value' => '12345'
],
[
'name' => 'Order Date',
'value' => '2025-03-12'
],
[
'name' => 'Order Amount',
'value' => 150.75
],
[
'name' => 'Active Status',
'value' => true
]
]
],
'agentOverride' => [
'name' => 'John Doe',
'phone' => '+12673624524',
'imageURL' => 'https://example.com/image.jpg',
'language' => 'en-US',
'voiceStability' => 0.5,
'voiceSpeed' => 1.5
],
'customerName' => 'John Does',
'customerPhone' => '+1234567890',
'customerEmail' => 'customer@email.com'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.elemente.ai/api/v1/calls"
payload := strings.NewReader("{\n \"agentId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"channel\": \"call\",\n \"skillId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"customerOverride\": {\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"phoneNumber\": \"+1234567890\",\n \"email\": \"admin@email.com\",\n \"language\": \"en-US\",\n \"customFields\": [\n {\n \"name\": \"Order ID\",\n \"value\": \"12345\"\n },\n {\n \"name\": \"Order Date\",\n \"value\": \"2025-03-12\"\n },\n {\n \"name\": \"Order Amount\",\n \"value\": 150.75\n },\n {\n \"name\": \"Active Status\",\n \"value\": true\n }\n ]\n },\n \"agentOverride\": {\n \"name\": \"John Doe\",\n \"phone\": \"+12673624524\",\n \"imageURL\": \"https://example.com/image.jpg\",\n \"language\": \"en-US\",\n \"voiceStability\": 0.5,\n \"voiceSpeed\": 1.5\n },\n \"customerName\": \"John Does\",\n \"customerPhone\": \"+1234567890\",\n \"customerEmail\": \"customer@email.com\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Basic <encoded-value>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.elemente.ai/api/v1/calls")
.header("Authorization", "Basic <encoded-value>")
.header("Content-Type", "application/json")
.body("{\n \"agentId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"channel\": \"call\",\n \"skillId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"customerOverride\": {\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"phoneNumber\": \"+1234567890\",\n \"email\": \"admin@email.com\",\n \"language\": \"en-US\",\n \"customFields\": [\n {\n \"name\": \"Order ID\",\n \"value\": \"12345\"\n },\n {\n \"name\": \"Order Date\",\n \"value\": \"2025-03-12\"\n },\n {\n \"name\": \"Order Amount\",\n \"value\": 150.75\n },\n {\n \"name\": \"Active Status\",\n \"value\": true\n }\n ]\n },\n \"agentOverride\": {\n \"name\": \"John Doe\",\n \"phone\": \"+12673624524\",\n \"imageURL\": \"https://example.com/image.jpg\",\n \"language\": \"en-US\",\n \"voiceStability\": 0.5,\n \"voiceSpeed\": 1.5\n },\n \"customerName\": \"John Does\",\n \"customerPhone\": \"+1234567890\",\n \"customerEmail\": \"customer@email.com\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.elemente.ai/api/v1/calls")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"agentId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"channel\": \"call\",\n \"skillId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"customerOverride\": {\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"phoneNumber\": \"+1234567890\",\n \"email\": \"admin@email.com\",\n \"language\": \"en-US\",\n \"customFields\": [\n {\n \"name\": \"Order ID\",\n \"value\": \"12345\"\n },\n {\n \"name\": \"Order Date\",\n \"value\": \"2025-03-12\"\n },\n {\n \"name\": \"Order Amount\",\n \"value\": 150.75\n },\n {\n \"name\": \"Active Status\",\n \"value\": true\n }\n ]\n },\n \"agentOverride\": {\n \"name\": \"John Doe\",\n \"phone\": \"+12673624524\",\n \"imageURL\": \"https://example.com/image.jpg\",\n \"language\": \"en-US\",\n \"voiceStability\": 0.5,\n \"voiceSpeed\": 1.5\n },\n \"customerName\": \"John Does\",\n \"customerPhone\": \"+1234567890\",\n \"customerEmail\": \"customer@email.com\"\n}"
response = http.request(request)
puts response.read_body{
"id": "123e4567-e89b-12d3-a456-426614174000",
"status": "in-progress",
"agentPhone": "+1234567890",
"agentEmail": "+1234567890",
"customerPhone": "+1234567890",
"customerEmail": "+1234567890",
"agentId": "123e4567-e89b-12d3-a456-426614174000",
"customerId": "123e4567-e89b-12d3-a456-426614174000",
"skillId": "123e4567-e89b-12d3-a456-426614174000",
"customerName": "John Doe",
"transcription": "Hello, how can I help you?",
"recordingUrl": "https://example.com/recording.wav",
"messages": [
{
"sid": "SM1234567890abcdef",
"timestamp": "2025-03-17T14:30:00Z",
"sender": "agent",
"content": "Hello, how can I assist you today?",
"mediaUrl": "https://example.com/image.jpg",
"status": "delivered"
}
],
"duration": "7200"
}Authorizations
Basic authentication header of the form Basic <encoded-value>, where <encoded-value> is the base64-encoded string username:password.
Body
Input data for creating a new interaction
Your agents UUID
"123e4567-e89b-12d3-a456-426614174000"
The interaction channel, you can send your agent to call, sms, whatsapp or webchat
call, sms, whatsapp, email, webchat "call"
Your skill UUID
"123e4567-e89b-12d3-a456-426614174000"
Your agent override settings
Show child attributes
Show child attributes
{
"firstName": "John",
"lastName": "Doe",
"phoneNumber": "+1234567890",
"email": "admin@email.com",
"language": "en-US",
"customFields": [
{ "name": "Order ID", "value": "12345" },
{
"name": "Order Date",
"value": "2025-03-12"
},
{ "name": "Order Amount", "value": 150.75 },
{ "name": "Active Status", "value": true }
]
}
Your agent override settings
Show child attributes
Show child attributes
{
"name": "John Doe",
"phone": "+12673624524",
"imageURL": "https://example.com/image.jpg",
"language": "en-US",
"voiceStability": 0.5,
"voiceSpeed": 1.5
}
The customer's name to create a new customer
"John Does"
The customer's phone number to create a new customer
"+1234567890"
The customer's email to create a new customer
"customer@email.com"
Response
Initiate call
Interaction ID
"123e4567-e89b-12d3-a456-426614174000"
Interaction status
"in-progress"
Agent phone number
"+1234567890"
Agent Email
"+1234567890"
Customer phone number
"+1234567890"
Customer email
"+1234567890"
Agent ID
"123e4567-e89b-12d3-a456-426614174000"
Customer ID
"123e4567-e89b-12d3-a456-426614174000"
Skill ID
"123e4567-e89b-12d3-a456-426614174000"
Customer name
"John Doe"
Transcription
"Hello, how can I help you?"
Recording URL
"https://example.com/recording.wav"
conversation messages
[
{
"sid": "SM1234567890abcdef",
"timestamp": "2025-03-17T14:30:00Z",
"sender": "agent",
"content": "Hello, how can I assist you today?",
"mediaUrl": "https://example.com/image.jpg",
"status": "delivered"
}
]
Session duration in seconds
"7200"
