curl --request PATCH \
--url https://api.withallo.com/v2/api/numbers/{number}/agent \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "Maya",
"business_name": "Acme Plumbing",
"business_address": "<string>",
"business_phone": "+14155551234",
"business_email": "<string>",
"business_website": "<string>",
"business_industry": "<string>",
"language": "en-US",
"voice_id": "maya",
"greeting_message": "<string>",
"closing_message": "<string>",
"capabilities": {
"SCHEDULING": true,
"CALL_TRANSFER": true,
"WARM_TRANSFER": false
},
"transfer_rules": [
{
"description": "Billing or invoice questions",
"transfer_message": "Let me put you through to billing.",
"target_number": "+14155551234",
"target_member_id": "<string>",
"target_line_number": "<string>"
}
],
"scheduling": {
"calendars": {}
},
"knowledge": {
"text": "We serve the Austin metro area and open at 7am."
}
}
'import requests
url = "https://api.withallo.com/v2/api/numbers/{number}/agent"
payload = {
"name": "Maya",
"business_name": "Acme Plumbing",
"business_address": "<string>",
"business_phone": "+14155551234",
"business_email": "<string>",
"business_website": "<string>",
"business_industry": "<string>",
"language": "en-US",
"voice_id": "maya",
"greeting_message": "<string>",
"closing_message": "<string>",
"capabilities": {
"SCHEDULING": True,
"CALL_TRANSFER": True,
"WARM_TRANSFER": False
},
"transfer_rules": [
{
"description": "Billing or invoice questions",
"transfer_message": "Let me put you through to billing.",
"target_number": "+14155551234",
"target_member_id": "<string>",
"target_line_number": "<string>"
}
],
"scheduling": { "calendars": {} },
"knowledge": { "text": "We serve the Austin metro area and open at 7am." }
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'Maya',
business_name: 'Acme Plumbing',
business_address: '<string>',
business_phone: '+14155551234',
business_email: '<string>',
business_website: '<string>',
business_industry: '<string>',
language: 'en-US',
voice_id: 'maya',
greeting_message: '<string>',
closing_message: '<string>',
capabilities: {SCHEDULING: true, CALL_TRANSFER: true, WARM_TRANSFER: false},
transfer_rules: [
{
description: 'Billing or invoice questions',
transfer_message: 'Let me put you through to billing.',
target_number: '+14155551234',
target_member_id: '<string>',
target_line_number: '<string>'
}
],
scheduling: {calendars: {}},
knowledge: {text: 'We serve the Austin metro area and open at 7am.'}
})
};
fetch('https://api.withallo.com/v2/api/numbers/{number}/agent', 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.withallo.com/v2/api/numbers/{number}/agent",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'name' => 'Maya',
'business_name' => 'Acme Plumbing',
'business_address' => '<string>',
'business_phone' => '+14155551234',
'business_email' => '<string>',
'business_website' => '<string>',
'business_industry' => '<string>',
'language' => 'en-US',
'voice_id' => 'maya',
'greeting_message' => '<string>',
'closing_message' => '<string>',
'capabilities' => [
'SCHEDULING' => true,
'CALL_TRANSFER' => true,
'WARM_TRANSFER' => false
],
'transfer_rules' => [
[
'description' => 'Billing or invoice questions',
'transfer_message' => 'Let me put you through to billing.',
'target_number' => '+14155551234',
'target_member_id' => '<string>',
'target_line_number' => '<string>'
]
],
'scheduling' => [
'calendars' => [
]
],
'knowledge' => [
'text' => 'We serve the Austin metro area and open at 7am.'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"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.withallo.com/v2/api/numbers/{number}/agent"
payload := strings.NewReader("{\n \"name\": \"Maya\",\n \"business_name\": \"Acme Plumbing\",\n \"business_address\": \"<string>\",\n \"business_phone\": \"+14155551234\",\n \"business_email\": \"<string>\",\n \"business_website\": \"<string>\",\n \"business_industry\": \"<string>\",\n \"language\": \"en-US\",\n \"voice_id\": \"maya\",\n \"greeting_message\": \"<string>\",\n \"closing_message\": \"<string>\",\n \"capabilities\": {\n \"SCHEDULING\": true,\n \"CALL_TRANSFER\": true,\n \"WARM_TRANSFER\": false\n },\n \"transfer_rules\": [\n {\n \"description\": \"Billing or invoice questions\",\n \"transfer_message\": \"Let me put you through to billing.\",\n \"target_number\": \"+14155551234\",\n \"target_member_id\": \"<string>\",\n \"target_line_number\": \"<string>\"\n }\n ],\n \"scheduling\": {\n \"calendars\": {}\n },\n \"knowledge\": {\n \"text\": \"We serve the Austin metro area and open at 7am.\"\n }\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "<api-key>")
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.patch("https://api.withallo.com/v2/api/numbers/{number}/agent")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Maya\",\n \"business_name\": \"Acme Plumbing\",\n \"business_address\": \"<string>\",\n \"business_phone\": \"+14155551234\",\n \"business_email\": \"<string>\",\n \"business_website\": \"<string>\",\n \"business_industry\": \"<string>\",\n \"language\": \"en-US\",\n \"voice_id\": \"maya\",\n \"greeting_message\": \"<string>\",\n \"closing_message\": \"<string>\",\n \"capabilities\": {\n \"SCHEDULING\": true,\n \"CALL_TRANSFER\": true,\n \"WARM_TRANSFER\": false\n },\n \"transfer_rules\": [\n {\n \"description\": \"Billing or invoice questions\",\n \"transfer_message\": \"Let me put you through to billing.\",\n \"target_number\": \"+14155551234\",\n \"target_member_id\": \"<string>\",\n \"target_line_number\": \"<string>\"\n }\n ],\n \"scheduling\": {\n \"calendars\": {}\n },\n \"knowledge\": {\n \"text\": \"We serve the Austin metro area and open at 7am.\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.withallo.com/v2/api/numbers/{number}/agent")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"Maya\",\n \"business_name\": \"Acme Plumbing\",\n \"business_address\": \"<string>\",\n \"business_phone\": \"+14155551234\",\n \"business_email\": \"<string>\",\n \"business_website\": \"<string>\",\n \"business_industry\": \"<string>\",\n \"language\": \"en-US\",\n \"voice_id\": \"maya\",\n \"greeting_message\": \"<string>\",\n \"closing_message\": \"<string>\",\n \"capabilities\": {\n \"SCHEDULING\": true,\n \"CALL_TRANSFER\": true,\n \"WARM_TRANSFER\": false\n },\n \"transfer_rules\": [\n {\n \"description\": \"Billing or invoice questions\",\n \"transfer_message\": \"Let me put you through to billing.\",\n \"target_number\": \"+14155551234\",\n \"target_member_id\": \"<string>\",\n \"target_line_number\": \"<string>\"\n }\n ],\n \"scheduling\": {\n \"calendars\": {}\n },\n \"knowledge\": {\n \"text\": \"We serve the Austin metro area and open at 7am.\"\n }\n}"
response = http.request(request)
puts response.read_body{
"data": {
"agent": {
"id": "agt-abc123",
"status": "ACTIVE",
"name": "Maya",
"is_default": true,
"business_name": "Acme Plumbing",
"business_address": "12 Main Street, Austin TX",
"business_phone": "+14155551234",
"business_email": "[email protected]",
"business_website": "https://acme.test",
"business_industry": "Plumbing",
"language": "en-US",
"voice_id": "maya",
"greeting_message": "Thanks for calling Acme Plumbing, how can I help?",
"closing_message": "Thanks for calling, have a good day.",
"tone_of_voice": "FRIENDLY",
"answer_type": "CONCISE",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
},
"prompt": {
"sections": [
{
"section": "objective",
"title": "Objective",
"content": "Book a visit with the caller.",
"fields": [
{
"label": "Email",
"question": "What is the best email to send the quote to?",
"complete_when": "a valid email address is given"
}
]
}
],
"custom_prompt": "<string>"
},
"capabilities": {
"SCHEDULING": true,
"CALL_TRANSFER": true,
"WARM_TRANSFER": true
},
"business_hours": {
"timezone": "America/New_York",
"schedule": [
{
"day": "MO",
"schedule": [
{
"start_time": 32400,
"end_time": 61200
}
]
}
]
},
"transfer_rules": [
{
"description": "Billing or invoice questions",
"type": "EXTERNAL_NUMBER",
"transfer_message": "Let me put you through to billing.",
"target_number": "+14155551234",
"target_member_id": "<string>",
"target_line_number": "<string>"
}
],
"scheduling": {
"calendars": [
{
"calendar_connection_id": "exc-abc123",
"name": "Acme bookings",
"provider": "GOOGLE_CALENDAR",
"status": "ACTIVE",
"is_team_default": true,
"owner": {
"user_id": "<string>",
"user_name": "<string>",
"email": "<string>",
"is_current_user": true
},
"event_types": [
{
"id": "42",
"slug": "intro-call",
"title": "Intro call",
"length_in_minutes": 30,
"description": "Book this one when the caller wants a quote.",
"required_questions": [
{
"id": "notes",
"label": "Anything we should know before the visit?"
}
]
}
]
}
]
},
"knowledge": {
"text": "<string>",
"websites": [
{
"id": "wkb-abc123",
"url": "https://acme.test/pricing",
"status": "ACTIVE",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
],
"files": [
{
"id": "fkb-abc123",
"file_name": "pricing.pdf",
"status": "ACTIVE",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
]
}
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}Update configuration
Updates any part of the configuration except the prompt and the on/off status. Single values are merged, collections are replaced. This does not put the receptionist on the line: that is PUT /v2/api/numbers/{number}/agent/status.
curl --request PATCH \
--url https://api.withallo.com/v2/api/numbers/{number}/agent \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "Maya",
"business_name": "Acme Plumbing",
"business_address": "<string>",
"business_phone": "+14155551234",
"business_email": "<string>",
"business_website": "<string>",
"business_industry": "<string>",
"language": "en-US",
"voice_id": "maya",
"greeting_message": "<string>",
"closing_message": "<string>",
"capabilities": {
"SCHEDULING": true,
"CALL_TRANSFER": true,
"WARM_TRANSFER": false
},
"transfer_rules": [
{
"description": "Billing or invoice questions",
"transfer_message": "Let me put you through to billing.",
"target_number": "+14155551234",
"target_member_id": "<string>",
"target_line_number": "<string>"
}
],
"scheduling": {
"calendars": {}
},
"knowledge": {
"text": "We serve the Austin metro area and open at 7am."
}
}
'import requests
url = "https://api.withallo.com/v2/api/numbers/{number}/agent"
payload = {
"name": "Maya",
"business_name": "Acme Plumbing",
"business_address": "<string>",
"business_phone": "+14155551234",
"business_email": "<string>",
"business_website": "<string>",
"business_industry": "<string>",
"language": "en-US",
"voice_id": "maya",
"greeting_message": "<string>",
"closing_message": "<string>",
"capabilities": {
"SCHEDULING": True,
"CALL_TRANSFER": True,
"WARM_TRANSFER": False
},
"transfer_rules": [
{
"description": "Billing or invoice questions",
"transfer_message": "Let me put you through to billing.",
"target_number": "+14155551234",
"target_member_id": "<string>",
"target_line_number": "<string>"
}
],
"scheduling": { "calendars": {} },
"knowledge": { "text": "We serve the Austin metro area and open at 7am." }
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'Maya',
business_name: 'Acme Plumbing',
business_address: '<string>',
business_phone: '+14155551234',
business_email: '<string>',
business_website: '<string>',
business_industry: '<string>',
language: 'en-US',
voice_id: 'maya',
greeting_message: '<string>',
closing_message: '<string>',
capabilities: {SCHEDULING: true, CALL_TRANSFER: true, WARM_TRANSFER: false},
transfer_rules: [
{
description: 'Billing or invoice questions',
transfer_message: 'Let me put you through to billing.',
target_number: '+14155551234',
target_member_id: '<string>',
target_line_number: '<string>'
}
],
scheduling: {calendars: {}},
knowledge: {text: 'We serve the Austin metro area and open at 7am.'}
})
};
fetch('https://api.withallo.com/v2/api/numbers/{number}/agent', 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.withallo.com/v2/api/numbers/{number}/agent",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'name' => 'Maya',
'business_name' => 'Acme Plumbing',
'business_address' => '<string>',
'business_phone' => '+14155551234',
'business_email' => '<string>',
'business_website' => '<string>',
'business_industry' => '<string>',
'language' => 'en-US',
'voice_id' => 'maya',
'greeting_message' => '<string>',
'closing_message' => '<string>',
'capabilities' => [
'SCHEDULING' => true,
'CALL_TRANSFER' => true,
'WARM_TRANSFER' => false
],
'transfer_rules' => [
[
'description' => 'Billing or invoice questions',
'transfer_message' => 'Let me put you through to billing.',
'target_number' => '+14155551234',
'target_member_id' => '<string>',
'target_line_number' => '<string>'
]
],
'scheduling' => [
'calendars' => [
]
],
'knowledge' => [
'text' => 'We serve the Austin metro area and open at 7am.'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"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.withallo.com/v2/api/numbers/{number}/agent"
payload := strings.NewReader("{\n \"name\": \"Maya\",\n \"business_name\": \"Acme Plumbing\",\n \"business_address\": \"<string>\",\n \"business_phone\": \"+14155551234\",\n \"business_email\": \"<string>\",\n \"business_website\": \"<string>\",\n \"business_industry\": \"<string>\",\n \"language\": \"en-US\",\n \"voice_id\": \"maya\",\n \"greeting_message\": \"<string>\",\n \"closing_message\": \"<string>\",\n \"capabilities\": {\n \"SCHEDULING\": true,\n \"CALL_TRANSFER\": true,\n \"WARM_TRANSFER\": false\n },\n \"transfer_rules\": [\n {\n \"description\": \"Billing or invoice questions\",\n \"transfer_message\": \"Let me put you through to billing.\",\n \"target_number\": \"+14155551234\",\n \"target_member_id\": \"<string>\",\n \"target_line_number\": \"<string>\"\n }\n ],\n \"scheduling\": {\n \"calendars\": {}\n },\n \"knowledge\": {\n \"text\": \"We serve the Austin metro area and open at 7am.\"\n }\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "<api-key>")
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.patch("https://api.withallo.com/v2/api/numbers/{number}/agent")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Maya\",\n \"business_name\": \"Acme Plumbing\",\n \"business_address\": \"<string>\",\n \"business_phone\": \"+14155551234\",\n \"business_email\": \"<string>\",\n \"business_website\": \"<string>\",\n \"business_industry\": \"<string>\",\n \"language\": \"en-US\",\n \"voice_id\": \"maya\",\n \"greeting_message\": \"<string>\",\n \"closing_message\": \"<string>\",\n \"capabilities\": {\n \"SCHEDULING\": true,\n \"CALL_TRANSFER\": true,\n \"WARM_TRANSFER\": false\n },\n \"transfer_rules\": [\n {\n \"description\": \"Billing or invoice questions\",\n \"transfer_message\": \"Let me put you through to billing.\",\n \"target_number\": \"+14155551234\",\n \"target_member_id\": \"<string>\",\n \"target_line_number\": \"<string>\"\n }\n ],\n \"scheduling\": {\n \"calendars\": {}\n },\n \"knowledge\": {\n \"text\": \"We serve the Austin metro area and open at 7am.\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.withallo.com/v2/api/numbers/{number}/agent")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"Maya\",\n \"business_name\": \"Acme Plumbing\",\n \"business_address\": \"<string>\",\n \"business_phone\": \"+14155551234\",\n \"business_email\": \"<string>\",\n \"business_website\": \"<string>\",\n \"business_industry\": \"<string>\",\n \"language\": \"en-US\",\n \"voice_id\": \"maya\",\n \"greeting_message\": \"<string>\",\n \"closing_message\": \"<string>\",\n \"capabilities\": {\n \"SCHEDULING\": true,\n \"CALL_TRANSFER\": true,\n \"WARM_TRANSFER\": false\n },\n \"transfer_rules\": [\n {\n \"description\": \"Billing or invoice questions\",\n \"transfer_message\": \"Let me put you through to billing.\",\n \"target_number\": \"+14155551234\",\n \"target_member_id\": \"<string>\",\n \"target_line_number\": \"<string>\"\n }\n ],\n \"scheduling\": {\n \"calendars\": {}\n },\n \"knowledge\": {\n \"text\": \"We serve the Austin metro area and open at 7am.\"\n }\n}"
response = http.request(request)
puts response.read_body{
"data": {
"agent": {
"id": "agt-abc123",
"status": "ACTIVE",
"name": "Maya",
"is_default": true,
"business_name": "Acme Plumbing",
"business_address": "12 Main Street, Austin TX",
"business_phone": "+14155551234",
"business_email": "[email protected]",
"business_website": "https://acme.test",
"business_industry": "Plumbing",
"language": "en-US",
"voice_id": "maya",
"greeting_message": "Thanks for calling Acme Plumbing, how can I help?",
"closing_message": "Thanks for calling, have a good day.",
"tone_of_voice": "FRIENDLY",
"answer_type": "CONCISE",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
},
"prompt": {
"sections": [
{
"section": "objective",
"title": "Objective",
"content": "Book a visit with the caller.",
"fields": [
{
"label": "Email",
"question": "What is the best email to send the quote to?",
"complete_when": "a valid email address is given"
}
]
}
],
"custom_prompt": "<string>"
},
"capabilities": {
"SCHEDULING": true,
"CALL_TRANSFER": true,
"WARM_TRANSFER": true
},
"business_hours": {
"timezone": "America/New_York",
"schedule": [
{
"day": "MO",
"schedule": [
{
"start_time": 32400,
"end_time": 61200
}
]
}
]
},
"transfer_rules": [
{
"description": "Billing or invoice questions",
"type": "EXTERNAL_NUMBER",
"transfer_message": "Let me put you through to billing.",
"target_number": "+14155551234",
"target_member_id": "<string>",
"target_line_number": "<string>"
}
],
"scheduling": {
"calendars": [
{
"calendar_connection_id": "exc-abc123",
"name": "Acme bookings",
"provider": "GOOGLE_CALENDAR",
"status": "ACTIVE",
"is_team_default": true,
"owner": {
"user_id": "<string>",
"user_name": "<string>",
"email": "<string>",
"is_current_user": true
},
"event_types": [
{
"id": "42",
"slug": "intro-call",
"title": "Intro call",
"length_in_minutes": 30,
"description": "Book this one when the caller wants a quote.",
"required_questions": [
{
"id": "notes",
"label": "Anything we should know before the visit?"
}
]
}
]
}
]
},
"knowledge": {
"text": "<string>",
"websites": [
{
"id": "wkb-abc123",
"url": "https://acme.test/pricing",
"status": "ACTIVE",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
],
"files": [
{
"id": "fkb-abc123",
"file_name": "pricing.pdf",
"status": "ACTIVE",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
]
}
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}AGENTS_WRITEBehavior
Updates any part of the receptionist’s configuration except the prompt and the on/off status. Returns the whole configuration after the write, in the same shape as Get configuration. Two merge rules apply:- Single values are merged.
name, the business details,language,voice_id,greeting_message,closing_message,tone_of_voice,answer_typeandknowledge.textkeep their current value when you omit them. - Collections are replaced.
capabilities,business_hours,transfer_rulesandscheduling.calendarsare complete sets. Send one and it replaces what was configured, omit it and it is left alone.
capabilities map you send.
A field this endpoint does not declare is rejected with 400 UNKNOWN_FIELD, including read-only ones such as custom_prompt, prompt_metadata and status. Nothing is dropped in silence.
Transfer rules
description is the field that decides whether a transfer works. The receptionist matches what the caller says they want against this text, so write it as the caller’s reason (“billing or invoice questions”, “wants to book a repair”), not as an instruction to the receptionist.
Each rule needs the target its type implies:
| Type | Required field | Goes to |
|---|---|---|
EXTERNAL_NUMBER | target_number | Any phone number, in E.164 format |
MEMBER | target_member_id | A teammate, by their id from GET /v2/api/users |
INBOX | target_line_number | Another of your Allo numbers |
transfer_rules[1].description.
Business hours
schedule is required whenever you send business_hours. Times are seconds since midnight, so 9am to 5pm is 32400 to 61200, and a day left out of the list is closed.
Scheduling calendars
scheduling.calendars is a map keyed by a calendar id from List calendars. A calendar the receptionist does not have yet is linked to it, one mapped to [] stays linked with no event type selected, and one left out of the map loses access.
Event types come from Get a calendar. Send id, slug, title and length_in_minutes back as they were read, and add your own description to say when the receptionist should book that one rather than another.
Connecting a calendar to the workspace is an OAuth flow, done in the Allo app. This endpoint chooses among the connections that already exist.
Field limits
| Field | Limit |
|---|---|
name, business_name, business_email, business_website, business_industry | 64 characters |
business_address | 255 characters |
greeting_message, closing_message | 1000 characters |
transfer_rules[].description | 255 characters |
transfer_rules[].transfer_message | 1000 characters |
knowledge.text | 25000 characters |
Errors
400 UNKNOWN_FIELD: a field this endpoint does not accept, named inparam.400 INVALID_REQUEST_BODY: a declared field failed validation. The failing field is inerrors[].400 MISSING_FIELD: a required part of a collection is missing, named inparam.400 INVALID_AGENT_LANGUAGE/400 INVALID_AGENT_CAPABILITY: an unknown value. The allowed ones are listed in the message.400 INVALID_TIMEZONE:business_hours.timezoneis not an IANA identifier.400 INVALID_PHONE_NUMBER:business_phoneis not a usable number.400 AGENT_TRANSFER_RULE_TARGET_REQUIRED: a rule is missing the target its type requires.403 AGENT_TRANSFER_RULE_MEMBER_NO_LINE_ACCESS: the target teammate has no access to this line.404 AGENT_VOICE_NOT_FOUND: no voice with thatvoice_id. List them with List voices.404 AGENT_CALENDAR_NOT_FOUND: a calendar id in the map is not one you can see.404 PHONE_NUMBER_NOT_FOUND: the number is not one you have access to.
Authorizations
Path Parameters
Allo phone number in E.164 format
"+14155551234"
Body
Two merge rules apply. Single values are merged: omit one and it keeps its current value. The collections capabilities, business_hours, transfer_rules and scheduling.calendars are complete sets: send one and it replaces what was configured, omit it and it is left alone. An undeclared field is rejected with 400 UNKNOWN_FIELD rather than ignored.
64"Maya"
64"Acme Plumbing"
255E.164 format.
64"+14155551234"
646464fr, fr-CA, en-US, en-GB, es, de, hr "en-US"
An id from GET /v2/api/voices, listed under the receptionist's language.
"maya"
10001000FRIENDLY, PROFESSIONAL, NEUTRAL, ENTHUSIASTIC CONCISE, STANDARD, DETAILED The complete set of toggles. A capability left out of the map is turned off, so read the current ones first and send them all back.
Show child attributes
Show child attributes
{
"SCHEDULING": true,
"CALL_TRANSFER": true,
"WARM_TRANSFER": false
}
Replaces the whole week. schedule is required when this key is sent.
Show child attributes
Show child attributes
Replaces the whole rule set. Send [] to remove every rule.
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Only the free-text knowledge is writable here. Websites and files have their own endpoints.
Show child attributes
Show child attributes
Response
The configuration after the write
The whole configuration of one line's AI receptionist.
Show child attributes
Show child attributes
Was this page helpful?