curl --request PATCH \
--url http://localhost:8080/integrations/twilio-flex/settings \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"ai_queue_sid": "<string>",
"ai_worker_email_domain": "<string>",
"internal_notes_enabled": true,
"interactions_handoff_enabled": true,
"contact_synced_task_attributes": [
"<string>"
]
}
'import requests
url = "http://localhost:8080/integrations/twilio-flex/settings"
payload = {
"ai_queue_sid": "<string>",
"ai_worker_email_domain": "<string>",
"internal_notes_enabled": True,
"interactions_handoff_enabled": True,
"contact_synced_task_attributes": ["<string>"]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
ai_queue_sid: '<string>',
ai_worker_email_domain: '<string>',
internal_notes_enabled: true,
interactions_handoff_enabled: true,
contact_synced_task_attributes: ['<string>']
})
};
fetch('http://localhost:8080/integrations/twilio-flex/settings', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "8080",
CURLOPT_URL => "http://localhost:8080/integrations/twilio-flex/settings",
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([
'ai_queue_sid' => '<string>',
'ai_worker_email_domain' => '<string>',
'internal_notes_enabled' => true,
'interactions_handoff_enabled' => true,
'contact_synced_task_attributes' => [
'<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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 := "http://localhost:8080/integrations/twilio-flex/settings"
payload := strings.NewReader("{\n \"ai_queue_sid\": \"<string>\",\n \"ai_worker_email_domain\": \"<string>\",\n \"internal_notes_enabled\": true,\n \"interactions_handoff_enabled\": true,\n \"contact_synced_task_attributes\": [\n \"<string>\"\n ]\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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("http://localhost:8080/integrations/twilio-flex/settings")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"ai_queue_sid\": \"<string>\",\n \"ai_worker_email_domain\": \"<string>\",\n \"internal_notes_enabled\": true,\n \"interactions_handoff_enabled\": true,\n \"contact_synced_task_attributes\": [\n \"<string>\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:8080/integrations/twilio-flex/settings")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"ai_queue_sid\": \"<string>\",\n \"ai_worker_email_domain\": \"<string>\",\n \"internal_notes_enabled\": true,\n \"interactions_handoff_enabled\": true,\n \"contact_synced_task_attributes\": [\n \"<string>\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"connected": true,
"settings": {
"account_sid": "<string>",
"workspace_sid": "<string>",
"ai_queue_sid": "<string>",
"ai_worker_sids": [
"<string>"
],
"ai_chat_capacity": 0,
"ai_worker_email_domain": "<string>",
"enabled": true,
"internal_notes_enabled": true,
"interactions_handoff_enabled": true,
"contact_synced_task_attributes": [
"<string>"
]
},
"unusable_contact_sync_attributes": [
{
"name": "<string>",
"reason": "invalid"
}
]
}{
"statusCode": 123,
"message": "<string>",
"error": "<string>"
}Update Twilio Flex integration settings
Change the Twilio Flex AI queue, worker email domain, handoff toggles, or synced task attributes.
curl --request PATCH \
--url http://localhost:8080/integrations/twilio-flex/settings \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"ai_queue_sid": "<string>",
"ai_worker_email_domain": "<string>",
"internal_notes_enabled": true,
"interactions_handoff_enabled": true,
"contact_synced_task_attributes": [
"<string>"
]
}
'import requests
url = "http://localhost:8080/integrations/twilio-flex/settings"
payload = {
"ai_queue_sid": "<string>",
"ai_worker_email_domain": "<string>",
"internal_notes_enabled": True,
"interactions_handoff_enabled": True,
"contact_synced_task_attributes": ["<string>"]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
ai_queue_sid: '<string>',
ai_worker_email_domain: '<string>',
internal_notes_enabled: true,
interactions_handoff_enabled: true,
contact_synced_task_attributes: ['<string>']
})
};
fetch('http://localhost:8080/integrations/twilio-flex/settings', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "8080",
CURLOPT_URL => "http://localhost:8080/integrations/twilio-flex/settings",
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([
'ai_queue_sid' => '<string>',
'ai_worker_email_domain' => '<string>',
'internal_notes_enabled' => true,
'interactions_handoff_enabled' => true,
'contact_synced_task_attributes' => [
'<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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 := "http://localhost:8080/integrations/twilio-flex/settings"
payload := strings.NewReader("{\n \"ai_queue_sid\": \"<string>\",\n \"ai_worker_email_domain\": \"<string>\",\n \"internal_notes_enabled\": true,\n \"interactions_handoff_enabled\": true,\n \"contact_synced_task_attributes\": [\n \"<string>\"\n ]\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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("http://localhost:8080/integrations/twilio-flex/settings")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"ai_queue_sid\": \"<string>\",\n \"ai_worker_email_domain\": \"<string>\",\n \"internal_notes_enabled\": true,\n \"interactions_handoff_enabled\": true,\n \"contact_synced_task_attributes\": [\n \"<string>\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:8080/integrations/twilio-flex/settings")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"ai_queue_sid\": \"<string>\",\n \"ai_worker_email_domain\": \"<string>\",\n \"internal_notes_enabled\": true,\n \"interactions_handoff_enabled\": true,\n \"contact_synced_task_attributes\": [\n \"<string>\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"connected": true,
"settings": {
"account_sid": "<string>",
"workspace_sid": "<string>",
"ai_queue_sid": "<string>",
"ai_worker_sids": [
"<string>"
],
"ai_chat_capacity": 0,
"ai_worker_email_domain": "<string>",
"enabled": true,
"internal_notes_enabled": true,
"interactions_handoff_enabled": true,
"contact_synced_task_attributes": [
"<string>"
]
},
"unusable_contact_sync_attributes": [
{
"name": "<string>",
"reason": "invalid"
}
]
}{
"statusCode": 123,
"message": "<string>",
"error": "<string>"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
Optional AI queue SID for routing AI-handled conversations
Optional email domain for AI workers. When set, each worker gets an email like opencx{N}-{random}@{domain} on its Twilio attributes. Set to empty string or null to clear.
1^[a-z0-9.-]+\.[a-z]{2,}$Whether to post internal notes (e.g. the AI handoff summary) to the Flex conversation. Twilio Conversations has no internal-note concept — notes are delivered to ALL participants including the customer — so this is disabled by default. Notes are stamped with an internal_note message attribute so client apps can filter them. Omitting the field keeps the stored value.
Whether OpenCX drives the handoff routing itself via the Flex Interactions API (inviting a human into the interaction). Disabled by default: most customers listen to the OpenCX conversation-handoff webhook and run their own Interactions transfer — enabling this on top of that produces duplicate chat requests. Omitting the field keeps the stored value.
Task attribute names to promote from the session onto the contact, written as your Flex workflow sends them (e.g. "user_id", "is_hvc", "customers.name"). Empty (the default) syncs nothing. Only durable, customer-level attributes belong here — per-conversation values like an order id would be overwritten on every new session. Omitting the field keeps the stored value.
1Response
Default Response
Was this page helpful?