cURL
curl --request POST \
--url https://app.closerx.ai/api/agent/create/ \
--header 'Company-Name: <company-name>' \
--header 'api_key: <api-key>'import requests
url = "https://app.closerx.ai/api/agent/create/"
headers = {
"Company-Name": "<company-name>",
"api_key": "<api-key>"
}
response = requests.post(url, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Company-Name': '<company-name>', api_key: '<api-key>'}
};
fetch('https://app.closerx.ai/api/agent/create/', 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://app.closerx.ai/api/agent/create/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Company-Name: <company-name>",
"api_key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.closerx.ai/api/agent/create/"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Company-Name", "<company-name>")
req.Header.Add("api_key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.closerx.ai/api/agent/create/")
.header("Company-Name", "<company-name>")
.header("api_key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.closerx.ai/api/agent/create/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Company-Name"] = '<company-name>'
request["api_key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"success": true,
"message": "<string>",
"data": {
"agent": {
"pk": 123,
"agent_name": "<string>",
"agent_id": "<string>",
"voice_id": "<string>",
"language": "<string>",
"interruption_sensitivity": "<string>",
"voicemail": true,
"voicemail_message": "<string>",
"end_call_after_silence": 123,
"max_call_duration": 123,
"reminder_trigger": 123,
"ambient_sound": "<string>",
"analysis_data": [
"<string>"
],
"llm": 123,
"voice_speed": 123,
"voice_temperature": 123,
"volume": 123,
"enable_backchannel": true,
"normalize_for_speech": true,
"enable_transcription_formatting": true,
"reminder_trigger_ms": 123,
"reminder_max_count": 123,
"boosted_keywords": [
"<string>"
],
"ambient_sound_volume": 123,
"voicemail_detection_timeout_ms": 123,
"begin_message_delay_ms": 123,
"updated_at": "2023-11-07T05:31:56Z",
"is_locked": true,
"calendar_id": "<string>",
"inbound_appoitment": true,
"ring_duration_sec": 123,
"stt_mode": "<string>",
"backchannel_words": "<string>",
"backchannel_frequency": 123,
"call_scheduling": true,
"agent_crm_type": "<string>",
"voicemail_option": {
"action": {
"type": "<string>"
}
}
},
"llm": {
"pk": 123,
"model": "<string>",
"states": "<string>",
"s2s_model": "<string>",
"model_temperature": "<string>",
"general_prompt": "<string>",
"general_tools": [
{}
],
"begin_message": "<string>",
"ghl_book_meeting": true,
"price_set_per_model": "<string>",
"custom_message": "<string>"
}
}
}{
"success": true,
"message": "<string>",
"data": {}
}Agent
Create Agent
Creates a new AI call agent with default settings
POST
/
agent
/
create
/
cURL
curl --request POST \
--url https://app.closerx.ai/api/agent/create/ \
--header 'Company-Name: <company-name>' \
--header 'api_key: <api-key>'import requests
url = "https://app.closerx.ai/api/agent/create/"
headers = {
"Company-Name": "<company-name>",
"api_key": "<api-key>"
}
response = requests.post(url, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Company-Name': '<company-name>', api_key: '<api-key>'}
};
fetch('https://app.closerx.ai/api/agent/create/', 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://app.closerx.ai/api/agent/create/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Company-Name: <company-name>",
"api_key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.closerx.ai/api/agent/create/"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Company-Name", "<company-name>")
req.Header.Add("api_key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.closerx.ai/api/agent/create/")
.header("Company-Name", "<company-name>")
.header("api_key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.closerx.ai/api/agent/create/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Company-Name"] = '<company-name>'
request["api_key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"success": true,
"message": "<string>",
"data": {
"agent": {
"pk": 123,
"agent_name": "<string>",
"agent_id": "<string>",
"voice_id": "<string>",
"language": "<string>",
"interruption_sensitivity": "<string>",
"voicemail": true,
"voicemail_message": "<string>",
"end_call_after_silence": 123,
"max_call_duration": 123,
"reminder_trigger": 123,
"ambient_sound": "<string>",
"analysis_data": [
"<string>"
],
"llm": 123,
"voice_speed": 123,
"voice_temperature": 123,
"volume": 123,
"enable_backchannel": true,
"normalize_for_speech": true,
"enable_transcription_formatting": true,
"reminder_trigger_ms": 123,
"reminder_max_count": 123,
"boosted_keywords": [
"<string>"
],
"ambient_sound_volume": 123,
"voicemail_detection_timeout_ms": 123,
"begin_message_delay_ms": 123,
"updated_at": "2023-11-07T05:31:56Z",
"is_locked": true,
"calendar_id": "<string>",
"inbound_appoitment": true,
"ring_duration_sec": 123,
"stt_mode": "<string>",
"backchannel_words": "<string>",
"backchannel_frequency": 123,
"call_scheduling": true,
"agent_crm_type": "<string>",
"voicemail_option": {
"action": {
"type": "<string>"
}
}
},
"llm": {
"pk": 123,
"model": "<string>",
"states": "<string>",
"s2s_model": "<string>",
"model_temperature": "<string>",
"general_prompt": "<string>",
"general_tools": [
{}
],
"begin_message": "<string>",
"ghl_book_meeting": true,
"price_set_per_model": "<string>",
"custom_message": "<string>"
}
}
}{
"success": true,
"message": "<string>",
"data": {}
}Authorizations
Headers
The name of the schema to be used for the request
⌘I
