{ "openapi": "3.0.1", "info": { "title": "Twilio Conversational Intelligence API", "description": "The Conversational Intelligence API includes resources to create and manage intelligence configurations, define and run language operators, and retrieve processed conversations and operator results.\n\n* Use the Configurations resource to create and manage intelligence configurations and define rules that control how and when language operators analyze and transform conversations. \n* Use the Operators resource to create custom language operators or retrieve Twilio-author and custom operators.\n* Use the Conversations resource to retrieve conversations processed with an intelligence configuration, and the OperatorResults resource to retrieve language operator results for those conversations.\n", "termsOfService": "https://www.twilio.com/legal/tos", "contact": { "name": "Twilio Support", "url": "https://support.twilio.com", "email": "support@twilio.com" }, "license": { "name": "Apache 2.0", "url": "https://www.apache.org/licenses/LICENSE-2.0.html" }, "version": "v3", "x-twilio": { "apiStandards": "v1.0" } }, "security": [ { "basic_apikey_or_accountsid": [] } ], "components": { "examples": { "IntelligenceConfigurationExample": { "summary": "Intelligence Configuration Response", "value": { "accountId": "AC00000000000000000000000000000000", "id": "intelligence_configuration_01kermhm82e5mr98nbeh1hpmbn", "displayName": "real-time-intelligence-config", "description": "Intelligence configuration to trigger real-time script adherence operator", "version": 1, "rules": [ { "id": "intelligence_configurationrule_01kermhm81fwfvy7j0f7h7v5mr", "operators": [ { "id": "intelligence_operator_01kcgy1ew0e9x8re6jq542zt8b", "version": 4, "parameters": { "scale": 2 } } ], "triggers": [ { "on": "COMMUNICATION", "parameters": { "count": 3 } } ], "actions": [ { "type": "WEBHOOK", "method": "POST", "url": "https://my-webhook-endpoint.com/rule-action" } ], "context": { "memory": { "enabled": true }, "knowledge": { "bases": [ "knowledge_base_id" ] } } } ], "dateCreated": "2026-01-12T08:18:17Z", "dateUpdated": "2026-01-12T08:18:17Z" } }, "CreateConfigurationRequestExample": { "summary": "Create Intelligence Configuration Request", "value": { "displayName": "real-time-intelligence-config", "description": "Intelligence configuration to trigger real-time script adherence operator", "rules": [ { "operators": [ { "id": "intelligence_operator_01kcgy1ew0e9x8re6jq542zt8b", "version": 4, "parameters": { "scale": 2 } } ], "triggers": [ { "on": "COMMUNICATION", "parameters": { "count": 3 } } ], "actions": [ { "type": "WEBHOOK", "method": "POST", "url": "https://my-webhook-endpoint.com/rule-action" } ], "context": { "memory": { "enabled": true }, "knowledge": { "bases": [ "knowledge_base_id" ] } } } ] } }, "UpdateConfigurationRequestExample": { "summary": "Update Intelligence Configuration Request", "value": { "displayName": "real-time-intelligence-config", "description": "Intelligence configuration to trigger real-time script adherence operator", "rules": [ { "id": "intelligence_configurationrule_01kermhm81fwfvy7j0f7h7v5mr", "operators": [ { "id": "intelligence_operator_01kcgy1ew0e9x8re6jq542zt8b", "version": 4, "parameters": { "scale": 2 } } ], "triggers": [ { "on": "COMMUNICATION", "parameters": { "count": 2 } } ], "actions": [ { "type": "WEBHOOK", "method": "POST", "url": "https://my-webhook-endpoint.com/rule-action" } ], "context": { "memory": { "enabled": true }, "knowledge": { "bases": [ "knowledge_base_id" ] } } } ] } }, "PaginatedConfigurationResponseExample": { "summary": "Paginated Configuration Response", "value": { "items": [ { "accountId": "AC00000000000000000000000000000000", "id": "intelligence_configuration_01kermhm82e5mr98nbeh1hpmbn", "displayName": "real-time-intelligence-config", "description": "Intelligence configuration to trigger real-time script adherence operator", "version": 1, "rules": [ { "id": "intelligence_configurationrule_01kermhm81fwfvy7j0f7h7v5mr", "operators": [ { "id": "intelligence_operator_01kcgy1ew0e9x8re6jq542zt8b", "version": 4, "parameters": { "scale": 2 } } ], "triggers": [ { "on": "COMMUNICATION", "parameters": { "count": 3 } } ], "actions": [ { "type": "WEBHOOK", "method": "POST", "url": "https://my-webhook-endpoint.com/rule-action" } ], "context": { "memory": { "enabled": true }, "knowledge": { "bases": [ "knowledge_base_id" ] } } } ], "dateCreated": "2026-01-12T08:18:17Z", "dateUpdated": "2026-01-12T08:18:17Z" }, { "accountId": "AC00000000000000000000000000000000", "id": "intelligence_configuration_01kermhm92e5mr98nbeh1hpmbz", "displayName": "post-call-analytics-config", "description": "Intelligence configuration for post-call analytics", "version": 2, "rules": [ { "id": "intelligence_configurationrule_01kermhm91fwfvy7j0f7h7v5ms", "operators": [ { "id": "intelligence_operator_01kcgy1ew0e9x8re6jq542zt9c" } ], "triggers": [ { "on": "CONVERSATION_END" } ], "actions": [ { "type": "WEBHOOK", "method": "POST", "url": "https://my-webhook-endpoint.com/analytics" } ], "context": { "memory": { "enabled": false } } } ], "dateCreated": "2026-01-10T10:30:00Z", "dateUpdated": "2026-01-11T14:22:00Z" } ], "meta": { "key": "items", "pageSize": 2, "nextToken": "next_page_token_example" } } }, "ListOperatorVersionsResponseExample": { "summary": "List Operator Versions Response", "value": { "items": [ { "version": 5, "status": "PREVIEW", "dateCreated": "2026-02-10T14:00:00Z" }, { "version": 4, "status": "ACTIVE", "dateCreated": "2026-01-15T10:45:30Z" }, { "version": 3, "status": "DEPRECATED", "dateDeprecated": "2026-01-10T00:00:00Z", "retirementDate": "2026-04-10T00:00:00Z", "dateCreated": "2025-11-01T08:00:00Z" }, { "version": 2, "status": "RETIRED", "dateDeprecated": "2025-09-01T00:00:00Z", "dateRetired": "2025-12-01T00:00:00Z", "dateCreated": "2025-06-15T12:00:00Z" } ], "meta": { "key": "items", "pageSize": 4 } } }, "LanguageOperatorVersionExample": { "summary": "Language Operator Version Response", "value": { "id": "intelligence_operator_01aaaaaaaaaaaaaaaaaaaaaaaa", "version": "4", "status": "ACTIVE", "displayName": "Sentiment Analysis", "description": "Analyzes conversation sentiment", "author": "TWILIO", "outputFormat": "JSON", "outputSchema": {}, "context": {}, "parameters": {}, "trainingExamples": [], "dateCreated": "2026-01-15T10:45:30Z" } }, "ListOperatorsResponseExample": { "summary": "List Operators Response", "value": { "items": [ { "id": "intelligence_operator_01kcgy1ew0e9x8re6jq542zt8b", "displayName": "Script Adherence", "description": "Measuring whether the agent stuck to the script", "version": 1, "author": "SELF", "prompt": "Your job is to determine if a contact center agent sticks to the script. Fetch the script from Knowledge using the Knowledge tool. Rate the interaction from 0-{{parameters.scale}}.", "outputFormat": "JSON", "outputSchema": { "type": "object", "properties": { "score": { "type": "integer" }, "explanation": { "type": "string" } }, "required": [ "score", "explanation" ], "additionalProperties": false }, "trainingExamples": [ { "input": "This is an example sentence which qualifies the lead as HOT.", "output": "{\"score\": 5, \"explanation\": \"The agent followed the script closely and addressed all key points effectively.\"}" } ], "context": { "memory": { "enabled": true }, "knowledge": { "enabled": true } }, "parameters": { "scale": { "type": "integer", "default": 5, "description": "Maximum score for evaluating script adherence." } } }, { "id": "intelligence_operator_01kcgy1ew0e9x8re6jq542zt9c", "displayName": "Sentiment Analysis", "description": "Analyze customer sentiment throughout the conversation", "version": 2, "author": "TWILIO", "outputFormat": "CLASSIFICATION", "context": { "memory": { "enabled": false }, "knowledge": { "enabled": false } }, "parameters": {} } ], "meta": { "key": "items", "pageSize": 2, "nextToken": "next_page_token_example" } } }, "CreateOrUpdateOperatorRequestExample": { "summary": "Create or Update Operator Request", "value": { "displayName": "Script Adherence", "description": "Measuring whether the agent stuck to the script", "prompt": "Your job is to determine if a contact center agent sticks to the script. Fetch the script from Knowledge using the Knowledge tool. Rate the interaction from 0-{{parameters.scale}}.", "outputFormat": "JSON", "outputSchema": { "type": "object", "properties": { "score": { "type": "integer" }, "explanation": { "type": "string" } }, "required": [ "score", "explanation" ], "additionalProperties": false }, "trainingExamples": [ { "input": "This is an example sentence which qualifies the lead as HOT.", "output": "{\"score\": 5, \"explanation\": \"The agent followed the script closely and addressed all key points effectively.\"}" } ], "context": { "memory": { "enabled": true }, "knowledge": { "enabled": true } }, "parameters": { "scale": { "type": "integer", "default": 5, "description": "Maximum score for evaluating script adherence." } } } }, "LanguageOperatorExample": { "summary": "Language Operator Response", "value": { "id": "intelligence_operator_01kcgy1ew0e9x8re6jq542zt8b", "displayName": "Script Adherence", "description": "Measuring whether the agent stuck to the script", "version": 1, "author": "SELF", "prompt": "Your job is to determine if a contact center agent sticks to the script. Fetch the script from Knowledge using the Knowledge tool. Rate the interaction from 0-{{parameters.scale}}.", "outputFormat": "JSON", "outputSchema": { "type": "object", "properties": { "score": { "type": "integer" }, "explanation": { "type": "string" } }, "required": [ "score", "explanation" ], "additionalProperties": false }, "trainingExamples": [ { "input": "This is an example sentence which qualifies the lead as HOT.", "output": "{\"score\": 5, \"explanation\": \"The agent followed the script closely and addressed all key points effectively.\"}" } ], "context": { "memory": { "enabled": true }, "knowledge": { "enabled": true } }, "parameters": { "scale": { "type": "integer", "default": 5, "description": "Maximum score for evaluating script adherence." } } } }, "ConversationExample": { "summary": "Single Conversation Response", "value": { "id": "conv_conversation_01k1etk2y5f1y9fpe2epfdtvv2", "accountId": "AC00000000000000000000000000000000", "name": "Customer Support Call - Order #12345", "status": "CLOSED", "createdAt": "2026-01-15T10:30:00Z", "updatedAt": "2026-01-15T10:45:30Z", "intelligenceConfigurationIds": [ "intelligence_configuration_01kermhm82e5mr98nbeh1hpmbn" ], "conversationConfigurationId": "conv_configuration_00000000000000000000000000", "channels": [ "VOICE" ], "channelIds": [ "CA1234567890abcdef1234567890abcdef" ], "participants": [ { "id": "conv_participant_01k1etx3jbfx88476ccja0889c", "name": "John Customer", "type": "CUSTOMER", "addressValues": [ "+15551234567" ] }, { "id": "conv_participant_01k1etx3jbfx88476ccja0889d", "name": "Sarah Agent", "type": "HUMAN_AGENT", "addressValues": [ "agent-sarah@example.com" ] } ], "communications": [ { "id": "conv_communication_01k1etk2y5f1y9fpe2epfdtvv2", "participantId": "conv_participant_01k1etx3jbfx88476ccja0889d", "content": { "text": "Thank you for calling customer support. How can I help you today?" }, "createdAt": "2026-01-15T10:30:15Z" }, { "id": "conv_communication_01k1etk2y5f1y9fpe2epfdtvv3", "participantId": "conv_participant_01k1etx3jbfx88476ccja0889c", "content": { "text": "Hi, I need help tracking my order #12345." }, "createdAt": "2026-01-15T10:30:30Z" }, { "id": "conv_communication_01k1etk2y5f1y9fpe2epfdtvv9", "participantId": "conv_participant_01k1etx3jbfx88476ccja0889d", "content": { "text": "I'd be happy to help you with that. Let me look up your order." }, "createdAt": "2026-01-15T10:30:45Z" } ], "operatorResultIds": [ "intelligence_operatorresult_01k6fc25s7epm9qtk8rszbv3q5", "intelligence_operatorresult_01k6fc25s7epm9qtk8rszbv3q6" ] } }, "ConversationListExample": { "summary": "List of Conversations Response", "value": { "items": [ { "id": "conv_conversation_01k1etk2y5f1y9fpe2epfdtvv2", "accountId": "AC00000000000000000000000000000000", "name": "Customer Support Call - Order #12345", "status": "CLOSED", "createdAt": "2026-01-15T10:30:00Z", "updatedAt": "2026-01-15T10:45:30Z", "intelligenceConfigurationIds": [ "intelligence_configuration_01kermhm82e5mr98nbeh1hpmbn" ], "conversationConfigurationId": "conv_configuration_00000000000000000000000000", "channels": [ "VOICE" ], "channelIds": [ "CA1234567890abcdef1234567890abcdef" ], "participants": [ { "id": "conv_participant_01k1etx3jbfx88476ccja0889c", "name": "John Customer", "type": "CUSTOMER", "addressValues": [ "+15551234567" ] }, { "id": "conv_participant_01k1etx3jbfx88476ccja0889d", "name": "Sarah Agent", "type": "HUMAN_AGENT", "addressValues": [ "agent-sarah@example.com" ] } ], "operatorResultIds": [ "intelligence_operatorresult_01k6fc25s7epm9qtk8rszbv3q5" ] }, { "id": "conv_conversation_01k1etk2y5f1y9fpe2epfdtvv3", "accountId": "AC00000000000000000000000000000000", "name": "Sales Inquiry - WhatsApp", "status": "ACTIVE", "createdAt": "2026-01-15T14:20:00Z", "updatedAt": "2026-01-15T14:22:00Z", "intelligenceConfigurationIds": [ "intelligence_configuration_01kermhm82e5mr98nbeh1hpmbn" ], "conversationConfigurationId": "conv_configuration_00000000000000000000000000", "channels": [ "WHATSAPP" ], "channelIds": [ "SM9876543210fedcba9876543210fedcba" ], "participants": [ { "id": "conv_participant_01k1etx3jbfx88476ccja0889e", "name": "Maria Customer", "type": "CUSTOMER", "addressValues": [ "whatsapp:+15559876543" ] }, { "id": "conv_participant_01k1etx3jbfx88476ccja0889f", "name": "AI Sales Assistant", "type": "AI_AGENT", "addressValues": [ "bot-sales@example.com" ] } ], "operatorResultIds": [ "intelligence_operatorresult_01k6fc25s7epm9qtk8rszbv3q7" ] } ], "meta": { "key": "items", "pageSize": 2, "nextToken": "next_page_token_example" } } }, "OperatorResultExample": { "summary": "Single Operator Result Response", "value": { "id": "intelligence_operatorresult_01k6fc25s7epm9qtk8rszbv3q5", "accountId": "AC00000000000000000000000000000000", "outputFormat": "JSON", "intelligenceConfiguration": { "id": "intelligence_configuration_01kermhm82e5mr98nbeh1hpmbn", "ruleId": "intelligence_configurationrule_01kermhm81fwfvy7j0f7h7v5mr", "version": 1 }, "conversationId": "conv_conversation_01k1etk2y5f1y9fpe2epfdtvv2", "operator": { "id": "intelligence_operator_01kcgy1ew0e9x8re6jq542zt8b", "version": 1, "parameters": { "scale": 5 } }, "dateCreated": "2026-01-15T10:45:30Z", "referenceIds": [ "conv_communication_01k1etk2y5f1y9fpe2epfdtvv2", "conv_participant_01k1etx3jbfx88476ccja0889c" ], "executionDetails": { "trigger": { "on": "CONVERSATION_END", "timestamp": "2026-01-15T10:45:25Z" }, "communications": { "first": "conv_communication_01k1etk2y5f1y9fpe2epfdtvv2", "last": "conv_communication_01k1etk2y5f1y9fpe2epfdtvv9" }, "channels": [ "VOICE" ], "participants": [ { "id": "conv_participant_01k1etx3jbfx88476ccja0889c", "profileId": "mem_profile_01k6fbz0v4f4e9qtk8p8z7y3w1", "type": "CUSTOMER" }, { "id": "conv_participant_01k1etx3jbfx88476ccja0889d", "type": "HUMAN_AGENT" } ], "resolvedContext": { "memory": { "profileId": "mem_profile_00000000000000000000000000", "memoryStoreId": "mem_store_00000000000000000000000000" }, "knowledge": { "sources": [ { "baseId": "know_knowledgebase_00000000000000000000000000", "sourceId": "know_knowledge_00000000000000000000000000" } ] } } }, "result": { "score": 5, "explanation": "The agent followed the script closely and addressed all key points effectively." } } }, "OperatorResultListExample": { "summary": "List of Operator Results Response", "value": { "items": [ { "id": "intelligence_operatorresult_01k6fc25s7epm9qtk8rszbv3q5", "accountId": "AC00000000000000000000000000000000", "outputFormat": "JSON", "intelligenceConfiguration": { "id": "intelligence_configuration_01kermhm82e5mr98nbeh1hpmbn", "ruleId": "intelligence_configurationrule_01kermhm81fwfvy7j0f7h7v5mr", "version": 1 }, "conversationId": "conv_conversation_01k1etk2y5f1y9fpe2epfdtvv2", "operator": { "id": "intelligence_operator_01kcgy1ew0e9x8re6jq542zt8b", "version": 1, "parameters": { "scale": 5 } }, "dateCreated": "2026-01-15T10:45:30Z", "referenceIds": [ "conv_communication_01k1etk2y5f1y9fpe2epfdtvv2" ], "executionDetails": { "trigger": { "on": "CONVERSATION_END", "timestamp": "2026-01-15T10:45:25Z" }, "communications": { "first": "conv_communication_01k1etk2y5f1y9fpe2epfdtvv2", "last": "conv_communication_01k1etk2y5f1y9fpe2epfdtvv9" }, "channels": [ "VOICE" ], "participants": [ { "id": "conv_participant_01k1etx3jbfx88476ccja0889c", "profileId": "mem_profile_01k6fbz0v4f4e9qtk8p8z7y3w1", "type": "CUSTOMER" }, { "id": "conv_participant_01k1etx3jbfx88476ccja0889d", "type": "HUMAN_AGENT" } ], "resolvedContext": { "memory": { "profileId": "mem_profile_00000000000000000000000000", "memoryStoreId": "mem_store_00000000000000000000000000" }, "knowledge": { "sources": [ { "baseId": "know_knowledgebase_00000000000000000000000000", "sourceId": "know_knowledge_00000000000000000000000000" } ] } } }, "result": { "score": 5, "explanation": "The agent followed the script closely and addressed all key points effectively." } }, { "id": "intelligence_operatorresult_01k6fc25s7epm9qtk8rszbv3q6", "accountId": "AC00000000000000000000000000000000", "outputFormat": "CLASSIFICATION", "intelligenceConfiguration": { "id": "intelligence_configuration_01kermhm82e5mr98nbeh1hpmbn", "ruleId": "intelligence_configurationrule_01kermhm81fwfvy7j0f7h7v5mr", "version": 1 }, "conversationId": "conv_conversation_01k1etk2y5f1y9fpe2epfdtvv2", "operator": { "id": "intelligence_operator_01kcgy1ew0e9x8re6jq542zt9c", "version": 2, "parameters": {} }, "dateCreated": "2026-01-15T10:45:35Z", "referenceIds": [ "conv_communication_01k1etk2y5f1y9fpe2epfdtvv2" ], "executionDetails": { "trigger": { "on": "CONVERSATION_END", "timestamp": "2026-01-15T10:45:25Z" }, "communications": { "first": "conv_communication_01k1etk2y5f1y9fpe2epfdtvv2", "last": "conv_communication_01k1etk2y5f1y9fpe2epfdtvv9" }, "channels": [ "VOICE" ], "participants": [ { "id": "conv_participant_01k1etx3jbfx88476ccja0889c", "type": "CUSTOMER" }, { "id": "conv_participant_01k1etx3jbfx88476ccja0889d", "type": "HUMAN_AGENT" } ] }, "result": { "label": "POSITIVE" } } ], "meta": { "key": "items", "pageSize": 2, "nextToken": "next_page_token_example" } } } }, "securitySchemes": { "basic_apikey_or_accountsid": { "scheme": "basic", "type": "http", "description": "This API uses [basic authentication](https://www.twilio.com/docs/glossary/what-is-basic-authentication). Use an [API key](https://www.twilio.com/docs/iam/api-keys) as the username and the API key secret as the password. You can also use your account SID and auth token, but limit their use to local testing." } }, "schemas": { "OperatorResultsResponseV1": { "type": "object", "title": "Operator Results Response V1", "properties": { "outputFormat": { "$ref": "#/components/schemas/OutputFormat" } }, "discriminator": { "propertyName": "outputFormat", "mapping": { "TEXT": "#/components/schemas/TextResult", "JSON": "#/components/schemas/JSONResult", "CLASSIFICATION": "#/components/schemas/ClassificationResult", "EXTRACTION": "#/components/schemas/ExtractionResult" } }, "oneOf": [ { "$ref": "#/components/schemas/TextResult" }, { "$ref": "#/components/schemas/JSONResult" }, { "$ref": "#/components/schemas/ClassificationResult" }, { "$ref": "#/components/schemas/ExtractionResult" } ] }, "OutputFormat": { "type": "string", "title": "Output Format", "description": "The output format set on the Operator that generated this result. Determines the structure of the `result` object.", "pattern": "^(CLASSIFICATION|TEXT|EXTRACTION|JSON)$" }, "OperatorResultsResponseBase": { "type": "object", "title": "Operator Results Response Base", "properties": { "outputFormat": { "$ref": "#/components/schemas/OutputFormat" }, "id": { "type": "string", "nullable": false, "pattern": "^intelligence_operatorresult_[0-7][0-9a-z]{25}$", "description": "A unique identifier for the Operator Result. Assigned by Twilio (TTID).", "example": "intelligence_operatorresult_01k6fc25s7epm9qtk8rszbv3q5" }, "accountId": { "type": "string", "description": "The ID of the Account that created the Language Operator.", "pattern": "^AC[a-zA-Z0-9]{32}$" }, "intelligenceConfiguration": { "$ref": "#/components/schemas/IntelligenceConfigurationReference" }, "conversationId": { "type": "string", "nullable": false, "pattern": "^conv_conversation_[0-7][0-9a-z]{25}$", "description": "The `id` of the Conversation attached to the Operator Result.", "example": "conv_conversation_01k1etk2y5f1y9fpe2epfdtvv2" }, "operator": { "$ref": "#/components/schemas/OperatorReference" }, "dateCreated": { "type": "string", "format": "date-time", "description": "Timestamp for when the Operator Result was created." }, "referenceIds": { "type": "array", "description": "The `id`s of objects related to this Operator Result.", "items": { "type": "string", "example": "CA0fd5fb62ac7e24ce24f071041847aa92", "maxLength": 97 } }, "executionDetails": { "$ref": "#/components/schemas/ExecutionDetails" }, "metadata": { "type": "object", "properties": { "system": { "$ref": "#/components/schemas/SystemMetaData" } }, "required": [ "system" ] } }, "required": [ "id", "accountId", "intelligenceConfiguration", "conversationId", "operator", "dateCreated", "outputFormat", "referenceIds", "executionDetails", "metadata" ] }, "TextResult": { "title": "Text result", "type": "object", "properties": { "outputFormat": { "$ref": "#/components/schemas/OutputFormat" }, "id": { "type": "string", "nullable": false, "pattern": "^intelligence_operatorresult_[0-7][0-9a-z]{25}$", "description": "A unique identifier for the Operator Result. Assigned by Twilio (TTID).", "example": "intelligence_operatorresult_01k6fc25s7epm9qtk8rszbv3q5" }, "accountId": { "type": "string", "description": "The ID of the Account that created the Language Operator.", "pattern": "^AC[a-zA-Z0-9]{32}$" }, "intelligenceConfiguration": { "$ref": "#/components/schemas/IntelligenceConfigurationReference" }, "conversationId": { "type": "string", "nullable": false, "pattern": "^conv_conversation_[0-7][0-9a-z]{25}$", "description": "The `id` of the Conversation attached to the Operator Result.", "example": "conv_conversation_01k1etk2y5f1y9fpe2epfdtvv2" }, "operator": { "$ref": "#/components/schemas/OperatorReference" }, "dateCreated": { "type": "string", "format": "date-time", "description": "Timestamp for when the Operator Result was created." }, "referenceIds": { "type": "array", "description": "The `id`s of objects related to this Operator Result.", "items": { "type": "string", "example": "CA0fd5fb62ac7e24ce24f071041847aa92", "maxLength": 97 } }, "executionDetails": { "$ref": "#/components/schemas/ExecutionDetails" }, "metadata": { "type": "object", "properties": { "system": { "$ref": "#/components/schemas/SystemMetaData" } }, "required": [ "system" ] }, "result": { "type": "object", "description": "The actual result from executing the Language Operator with `TEXT` output format.", "required": [ "text" ], "properties": { "text": { "type": "string", "description": "The plaintext result produced by the Language Operator." } } } }, "required": [ "outputFormat", "dateCreated", "operator", "accountId", "conversationId", "executionDetails", "intelligenceConfiguration", "result", "metadata", "referenceIds", "id" ] }, "JSONResult": { "title": "JSON result", "type": "object", "properties": { "outputFormat": { "$ref": "#/components/schemas/OutputFormat" }, "id": { "type": "string", "nullable": false, "pattern": "^intelligence_operatorresult_[0-7][0-9a-z]{25}$", "description": "A unique identifier for the Operator Result. Assigned by Twilio (TTID).", "example": "intelligence_operatorresult_01k6fc25s7epm9qtk8rszbv3q5" }, "accountId": { "type": "string", "description": "The ID of the Account that created the Language Operator.", "pattern": "^AC[a-zA-Z0-9]{32}$" }, "intelligenceConfiguration": { "$ref": "#/components/schemas/IntelligenceConfigurationReference" }, "conversationId": { "type": "string", "nullable": false, "pattern": "^conv_conversation_[0-7][0-9a-z]{25}$", "description": "The `id` of the Conversation attached to the Operator Result.", "example": "conv_conversation_01k1etk2y5f1y9fpe2epfdtvv2" }, "operator": { "$ref": "#/components/schemas/OperatorReference" }, "dateCreated": { "type": "string", "format": "date-time", "description": "Timestamp for when the Operator Result was created." }, "referenceIds": { "type": "array", "description": "The `id`s of objects related to this Operator Result.", "items": { "type": "string", "example": "CA0fd5fb62ac7e24ce24f071041847aa92", "maxLength": 97 } }, "executionDetails": { "$ref": "#/components/schemas/ExecutionDetails" }, "metadata": { "type": "object", "properties": { "system": { "$ref": "#/components/schemas/SystemMetaData" } }, "required": [ "system" ] }, "result": { "type": "object", "description": "The actual result from executing the Language Operator with `JSON` output format. Its structure depends on the `outputSchema` defined on the Operator.", "additionalProperties": true } }, "required": [ "outputFormat", "dateCreated", "operator", "accountId", "conversationId", "executionDetails", "intelligenceConfiguration", "result", "metadata", "referenceIds", "id" ] }, "ClassificationResult": { "title": "Classification result", "type": "object", "properties": { "outputFormat": { "$ref": "#/components/schemas/OutputFormat" }, "id": { "type": "string", "nullable": false, "pattern": "^intelligence_operatorresult_[0-7][0-9a-z]{25}$", "description": "A unique identifier for the Operator Result. Assigned by Twilio (TTID).", "example": "intelligence_operatorresult_01k6fc25s7epm9qtk8rszbv3q5" }, "accountId": { "type": "string", "description": "The ID of the Account that created the Language Operator.", "pattern": "^AC[a-zA-Z0-9]{32}$" }, "intelligenceConfiguration": { "$ref": "#/components/schemas/IntelligenceConfigurationReference" }, "conversationId": { "type": "string", "nullable": false, "pattern": "^conv_conversation_[0-7][0-9a-z]{25}$", "description": "The `id` of the Conversation attached to the Operator Result.", "example": "conv_conversation_01k1etk2y5f1y9fpe2epfdtvv2" }, "operator": { "$ref": "#/components/schemas/OperatorReference" }, "dateCreated": { "type": "string", "format": "date-time", "description": "Timestamp for when the Operator Result was created." }, "referenceIds": { "type": "array", "description": "The `id`s of objects related to this Operator Result.", "items": { "type": "string", "example": "CA0fd5fb62ac7e24ce24f071041847aa92", "maxLength": 97 } }, "executionDetails": { "$ref": "#/components/schemas/ExecutionDetails" }, "metadata": { "type": "object", "properties": { "system": { "$ref": "#/components/schemas/SystemMetaData" } }, "required": [ "system" ] }, "result": { "type": "object", "description": "The actual result from executing the Language Operator with `CLASSIFICATION` output format.", "required": [ "label" ], "properties": { "label": { "type": "string", "description": "The predicted label assigned by the Language Operator." } } } }, "required": [ "outputFormat", "dateCreated", "operator", "accountId", "conversationId", "executionDetails", "intelligenceConfiguration", "result", "metadata", "referenceIds", "id" ] }, "ExtractionResult": { "title": "Extraction result", "type": "object", "properties": { "outputFormat": { "$ref": "#/components/schemas/OutputFormat" }, "id": { "type": "string", "nullable": false, "pattern": "^intelligence_operatorresult_[0-7][0-9a-z]{25}$", "description": "A unique identifier for the Operator Result. Assigned by Twilio (TTID).", "example": "intelligence_operatorresult_01k6fc25s7epm9qtk8rszbv3q5" }, "accountId": { "type": "string", "description": "The ID of the Account that created the Language Operator.", "pattern": "^AC[a-zA-Z0-9]{32}$" }, "intelligenceConfiguration": { "$ref": "#/components/schemas/IntelligenceConfigurationReference" }, "conversationId": { "type": "string", "nullable": false, "pattern": "^conv_conversation_[0-7][0-9a-z]{25}$", "description": "The `id` of the Conversation attached to the Operator Result.", "example": "conv_conversation_01k1etk2y5f1y9fpe2epfdtvv2" }, "operator": { "$ref": "#/components/schemas/OperatorReference" }, "dateCreated": { "type": "string", "format": "date-time", "description": "Timestamp for when the Operator Result was created." }, "referenceIds": { "type": "array", "description": "The `id`s of objects related to this Operator Result.", "items": { "type": "string", "example": "CA0fd5fb62ac7e24ce24f071041847aa92", "maxLength": 97 } }, "executionDetails": { "$ref": "#/components/schemas/ExecutionDetails" }, "metadata": { "type": "object", "properties": { "system": { "$ref": "#/components/schemas/SystemMetaData" } }, "required": [ "system" ] }, "result": { "type": "object", "description": "The actual result from executing the Language Operator with `EXTRACTION` output format.", "required": [ "entities" ], "properties": { "entities": { "type": "array", "description": "List of extracted entities from the Conversation.", "items": { "type": "object", "required": [ "text", "label" ], "properties": { "text": { "type": "string", "description": "The actual text of the extracted entity as it appears in the Conversation." }, "label": { "type": "string", "description": "The label for the extracted entity (e.g., `PERSON`, `LOCATION`)." } } } } } } }, "required": [ "outputFormat", "dateCreated", "operator", "accountId", "conversationId", "executionDetails", "intelligenceConfiguration", "result", "metadata", "referenceIds", "id" ] }, "ResolvedContext": { "type": "object", "description": "The context that was actually used by the operator during execution", "properties": { "memory": { "type": "object", "description": "The customer profile that was accessed. null if no memory was accessed.\n\nEither observations and/or traits from the profile were used by the LLM to generate the result.\n", "required": [ "profileId", "memoryStoreId" ], "properties": { "profileId": { "type": "string", "pattern": "^mem_profile_[0-7][0-9a-z]{25}$", "description": "Customer Memory Profile identifier", "example": "mem_profile_00000000000000000000000000" }, "memoryStoreId": { "type": "string", "description": "Customer Memory store identifier", "pattern": "^mem_(store|service)_[0-7][0-9a-z]{25}$", "example": "mem_store_00000000000000000000000000" } } }, "knowledge": { "type": "object", "description": "Knowledge source IDs with their respective knowledge base ID that was accessed and used by the LLM to generate the result.\n\nnull if no knowledge was accessed.\n", "nullable": true, "required": [ "sources" ], "properties": { "sources": { "type": "array", "items": { "type": "object", "required": [ "baseId", "sourceId" ], "properties": { "baseId": { "type": "string", "description": "Knowledge base identifier", "pattern": "^know_knowledgebase_[0-7][0-9a-z]{25}$", "example": "know_knowledgebase_00000000000000000000000000" }, "sourceId": { "type": "string", "description": "Knowledge source identifier", "pattern": "^know_knowledge_[0-7][0-9a-z]{25}$", "example": "know_knowledge_00000000000000000000000000" } } } } } } } }, "SystemMetaData": { "type": "object", "required": [ "latencyMs", "inputCharacters", "outputCharacters", "inputTruncated" ], "properties": { "resolvedModel": { "type": "string", "description": "The underlying LLM model used for this execution.", "example": "gpt-4.1-nano-2025-04-14" }, "latencyMs": { "type": "integer", "description": "Operator execution time in milliseconds." }, "inputCharacters": { "type": "integer", "description": "Number of characters in the input sent to the model. Aligns with the billing unit." }, "outputCharacters": { "type": "integer", "description": "Number of characters in the model's response. Aligns with the billing unit." }, "inputTruncated": { "type": "boolean", "description": "Whether the conversation input was truncated to fit the model's context window." } } }, "IntelligenceConfigurationReference": { "type": "object", "description": "Reference to the Intelligence Configuration that generated the Operator Result.", "required": [ "id", "ruleId", "version" ], "properties": { "id": { "type": "string", "nullable": false, "pattern": "^intelligence_configuration_[0-7][0-9a-z]{25}$", "description": "Unique identifier for a Intelligence Configuration that generated the Operator Result. Assigned by Twilio (TTID).", "example": "intelligence_configuration_01k6fc25s7epm9qtk8rszbv3q5" }, "ruleId": { "type": "string", "nullable": false, "pattern": "^intelligence_configurationrule_[0-7][0-9a-z]{25}$", "description": "Unique identifier of the rule of the Intelligence Configuration that triggered the result. Assigned by Twilio (TTID).", "example": "intelligence_configurationrule_01k6fc25s7epm9qtk8rszbv3q6" }, "version": { "type": "integer", "description": "Version of the Intelligence Configuration used to generate the Operator Result." } } }, "OperatorReference": { "type": "object", "description": "Reference to the Language Operator that generated the Operator Result.", "required": [ "id", "version", "parameters" ], "properties": { "id": { "type": "string", "description": "The `id` of the Language Operator." }, "version": { "type": "integer", "description": "Version of the Language Operator used to generate the Operator Result." }, "parameters": { "type": "object", "description": "Parameter values used for Operator execution, provided by the Rule at runtime. This object contains a dictionary of parameter keys and their corresponding values.", "additionalProperties": true } } }, "ExecutionDetails": { "type": "object", "description": "Details about the conditions under which the Operator executed.", "properties": { "trigger": { "type": "object", "description": "Metadata for the trigger that generated this Operator Result.", "required": [ "on", "timestamp" ], "properties": { "on": { "type": "string", "description": "The conversational lifecycle event that activated execution of the Rule. Available values are:\n- `COMMUNICATION`: Trigger the Rule on each communication within the Conversation.\n- `CONVERSATION_END`: Trigger the Rule when the Conversation moves to the `closed` state.\n- `CONVERSATION_INACTIVE`: Trigger the Rule when the Conversation moves to the `inactive` state.\n" }, "timestamp": { "type": "string", "format": "date-time", "description": "Timestamp of when the trigger was activated." } } }, "communications": { "type": "object", "description": "Range of first and last communications in the Conversation that were processed during this Operator execution.", "required": [ "first", "last" ], "properties": { "first": { "allOf": [ { "type": "string", "nullable": false, "pattern": "^conv_communication_[0-7][0-9a-z]{25}$", "description": "Communication `id` from the attached Conversation.", "example": "conv_communication_01k1etk2y5f1y9fpe2epfdtvv2" }, { "description": "Starting communication `id` from the attached Conversation." } ] }, "last": { "allOf": [ { "type": "string", "nullable": false, "pattern": "^conv_communication_[0-7][0-9a-z]{25}$", "description": "Communication `id` from the attached Conversation.", "example": "conv_communication_01k1etk2y5f1y9fpe2epfdtvv2" }, { "description": "Ending communication `id` from the attached Conversation." } ] } } }, "channels": { "type": "array", "description": "Communication channels included in the Conversation when this Operator was executed.", "items": { "type": "string" } }, "participants": { "type": "array", "description": "Metadata for the participants included in the Conversation when this Operator executed.", "items": { "type": "object", "required": [ "id" ], "properties": { "id": { "type": "string", "nullable": false, "pattern": "^conv_participant_[0-7][0-9a-z]{25}$", "description": "The `id` of the Participant in the Conversation.", "example": "conv_participant_01k1etx3jbfx88476ccja0889c" }, "profileId": { "type": "string", "pattern": "^mem_profile_[0-7][0-9a-z]{25}$", "description": "Customer Memory Profile identifier", "example": "mem_profile_00000000000000000000000000" }, "type": { "type": "string", "description": "Type of participant in the conversation. Available types:\n- `CUSTOMER`\n- `HUMAN_AGENT`\n- `AI_AGENT`\n- `AGENT`\n- `UNKNOWN`\n" } } } }, "resolvedContext": { "$ref": "#/components/schemas/ResolvedContext" } }, "required": [ "trigger", "communications", "channels", "participants" ] }, "OperatorResultContext": { "type": "object", "description": "Snapshot of the Operator's access to contextual data at runtime.\nIncludes whether Customer Memory and Knowledge Bases were made available to the Operator for use during execution.\n", "properties": { "customerMemory": { "$ref": "#/components/schemas/CustomerMemoryContext" }, "knowledge": { "$ref": "#/components/schemas/KnowledgeContext" } } }, "CustomerMemoryContext": { "type": "object", "description": "Customer Memory applied to this Operator execution.", "properties": { "profileId": { "type": "string", "description": "The customer profile `id` made available to the Language Operator for use during execution.", "example": "mem_profile_01k6fbz0v4f4e9qtk8p8z7y3w1" }, "memoryStoreId": { "type": "string", "description": "The memory store `id` associated with the customer profile resolved.", "example": "mem_store_01k6fbz0v4f4e9qtk8p8z7y3w2" } }, "required": [ "profileId", "memoryStoreId" ] }, "KnowledgeContext": { "type": "object", "description": "Knowledge applied to this Operator execution.", "properties": { "bases": { "type": "array", "description": "The `id`s of the Knowledge Base(s) made available to the Language Operator for use during execution.", "items": { "type": "string", "description": "The `id` of a Knowledge Base.", "example": "know_knowledgebase_00000000000000000000000000" } } }, "required": [ "bases" ] }, "IntelligenceConfiguration": { "type": "object", "description": "An Intelligence Configuration defines how and when Language Operators execute for a given conversation.\n\nTo activate an Intelligence Configuration and trigger Operator execution, two conditions must be met:\n1. The Intelligence Configuration must include at least one Rule.\n2. The Intelligence Configuration must be attached to a Conversations Configuration via the Conversations API.\n Conversation traffic received by that Conversations Configuration determines when Rules are evaluated\n and executed.\n\nAn Intelligence Configuration that has no Rules or is not attached to a Conversations Configuration will not execute.\n", "required": [ "accountId", "id", "displayName", "version", "rules", "dateCreated", "dateUpdated" ], "properties": { "accountId": { "type": "string", "example": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "x-jvm-type": "com.twilio.sids.AccountSid", "description": "The ID of the Account that created the Intelligence Configuration." }, "id": { "type": "string", "description": "The unique identifier for the Intelligence Configuration. Assigned by Twilio (TTID)." }, "displayName": { "type": "string", "description": "The display name of the Intelligence Configuration describing its purpose.", "minLength": 1, "maxLength": 128 }, "description": { "type": "string", "description": "The description of the Intelligence Configuration further explaining its purpose." }, "version": { "type": "integer", "description": "The numeric version of the Intelligence Configuration. Automatically incremented with each update on the resource, used to ensure integrity when updating the Configuration." }, "rules": { "type": "array", "items": { "$ref": "#/components/schemas/Rule" }, "maxItems": 5, "description": "List of Intelligence Configuration Rules that govern when and how Language Operators run.\nEach Rule represents a bundle of Operators, Triggers, Context, and Actions to be executed by\nthe Intelligence Configuration on a Conversation. A maximum of five (5) Rules are allowed per\nIntelligence Configuration.\n" }, "dateCreated": { "description": "Timestamp of when the Intelligence Configuration was created.", "type": "string", "format": "date-time" }, "dateUpdated": { "description": "Timestamp of when the Intelligence Configuration was last updated.", "type": "string", "format": "date-time" } } }, "Rule": { "type": "object", "required": [ "id", "operators", "triggers", "actions" ], "properties": { "id": { "type": "string", "description": "The unique identifier for the Rule. Assigned by Twilio (TTID)." }, "operators": { "type": "array", "items": { "$ref": "#/components/schemas/Operator" }, "maxItems": 5, "description": "List of Operators to be executed by the Rule. Maximum of five (5) Operators allowed per Rule." }, "triggers": { "type": "array", "items": { "$ref": "#/components/schemas/Trigger" }, "maxItems": 1, "description": "List of Triggers that determine when to activate the Rule. Maximum of one (1) Trigger allowed per Rule." }, "actions": { "type": "array", "items": { "$ref": "#/components/schemas/Action" }, "maxItems": 2, "description": "List of Actions to be performed after the Rule is triggered. Maximum of two (2) Actions allowed per Rule." }, "context": { "$ref": "#/components/schemas/Context" } } }, "Operator": { "type": "object", "required": [ "id" ], "properties": { "id": { "type": "string", "description": "The unique identifier for the Language Operator to be executed by the Rule. Assigned by Twilio (TTID)." }, "version": { "type": "integer", "description": "The specific version of the Language Operator to execute. When provided, the Rule will use this exact version of the Operator.\nWhen omitted, the latest active version of the Operator is used at execution time.\n" }, "parameters": { "type": "object", "description": "Key-value mapping for parameters defined as part of the Operator schema. The key and value passed by the Rule must match the name and data type of the parameter defined in the Operator, respectively.\nThese parameters will customize the behavior of the Operator when executed by the Rule via runtime substitution into the prompt.\nNote: For parameters of type `knowledge_base_and_source_ids`, the value must be passed in the following format: `knowledge_base_id:knowledge_source_id`.\n" } } }, "Trigger": { "type": "object", "required": [ "on" ], "properties": { "on": { "type": "string", "description": "The conversational lifecycle event that will activate execution of the Rule.\nAvailable values are:\n- `COMMUNICATION`: Trigger the Rule on each communication within the Conversation.\n- `CONVERSATION_END`: Trigger the Rule when the Conversation moves to the `closed` state\n- `CONVERSATION_INACTIVE`: Trigger the Rule when the Conversation moves to `inactive` state\n", "enum": [ "COMMUNICATION", "CONVERSATION_END", "CONVERSATION_INACTIVE" ] }, "parameters": { "type": "object", "description": "Additional configuration to modify Trigger behavior. Only applies to certain Trigger types.", "properties": { "count": { "type": "integer", "description": "When `on` is set to `COMMUNICATION`, this value controls how often the Rule should\nrun. A value of `1` executes the Rule for every communication event. Higher values\ndelay execution until the specified number of communications have occurred since the last execution.\n", "minimum": 1, "maximum": 20, "default": 1 } } } } }, "Action": { "type": "object", "required": [ "type", "method", "url" ], "properties": { "type": { "type": "string", "enum": [ "WEBHOOK" ], "description": "The type of Action to be performed after the Rule is triggered. Supported Actions are:\n- `WEBHOOK`: A webhook Action sends an HTTP request to a specified URL with Rule execution results.\n" }, "method": { "type": "string", "enum": [ "POST" ], "description": "The HTTP method to be used when performing the Action. Must be set to `POST`." }, "url": { "type": "string", "format": "uri", "description": "The URL endpoint where the Action will send the HTTP request containing the Rule execution results." } } }, "Context": { "type": "object", "description": "Controls what additional customer and enterprise context is made available to Language Operators when this Rule executes.", "properties": { "memory": { "type": "object", "description": "Configuration for passing Memory as context to Operators in this Rule (available only for Memory\u2013enabled accounts).", "properties": { "enabled": { "type": "boolean", "description": "When set to `true`, allows this Intelligence Configuration Rule to pass the Profile\ninto attached Language Operators. The profile is only passed to Language Operators\nthat have Memory as a context source enabled.\n" } } }, "knowledge": { "type": "object", "description": "Configuration for passing Enterprise Knowledge as context to Operators in this Rule (available only for Enterprise Knowledge\u2013enabled accounts).", "properties": { "bases": { "type": "array", "description": "Specifies the Knowledge Base(s) and corresponding Source(s) to pass to Language\nOperators in this Rule as context. Only applied to Language Operators that have\nKnowledge as a context source enabled.\n", "items": { "type": "string" }, "minItems": 1 } }, "required": [ "bases" ] } } }, "RuleCreationRequestPayload": { "type": "object", "required": [ "operators", "actions" ], "properties": { "operators": { "type": "array", "description": "List of Operators to be executed by the Rule. Minimum of one (1) and maximum of five (5) Operators allowed per Rule.", "items": { "$ref": "#/components/schemas/Operator" }, "minItems": 1, "maxItems": 5 }, "triggers": { "type": "array", "description": "List of Triggers that determine when to activate the Rule. Maximum of one (1) Trigger allowed per Rule.", "items": { "$ref": "#/components/schemas/Trigger" }, "maxItems": 1 }, "actions": { "type": "array", "description": "List of Actions to be performed after the Rule is triggered. Maximum of two (2) Actions allowed per Rule.", "items": { "$ref": "#/components/schemas/Action" }, "maxItems": 2 }, "context": { "$ref": "#/components/schemas/Context" } } }, "RuleUpdateRequestPayload": { "type": "object", "required": [ "operators", "actions" ], "properties": { "id": { "type": "string", "description": "Optional field used when updating an existing Rule within an Intelligence Configuration.\nWhen provided, the Rule with this `id` is updated; when omitted, a new Rule is created.\n" }, "operators": { "type": "array", "description": "List of Operators to be executed by the Rule. Minimum of one (1) and maximum of five (5) Operators allowed per Rule.", "items": { "$ref": "#/components/schemas/Operator" }, "minItems": 1, "maxItems": 5 }, "triggers": { "type": "array", "description": "List of Triggers that determine when to activate the Rule. Maximum of one (1) Trigger allowed per Rule.", "items": { "$ref": "#/components/schemas/Trigger" }, "maxItems": 1 }, "actions": { "type": "array", "description": "List of Actions to be performed after the Rule is triggered. Maximum of two (2) Actions allowed per Rule.", "items": { "$ref": "#/components/schemas/Action" }, "maxItems": 2 }, "context": { "$ref": "#/components/schemas/Context" } } }, "CreateConfigurationRequest": { "type": "object", "description": "Request body for creating a new Intelligence Configuration.", "properties": { "displayName": { "type": "string", "description": "The display name of the Intelligence Configuration describing its purpose.", "minLength": 1, "maxLength": 128 }, "description": { "type": "string", "description": "The description of the Intelligence Configuration further explaining its purpose." }, "rules": { "description": "List of Intelligence Configuration Rules that govern when and how Language Operators run.\nEach Rule represents a bundle of Operators, Triggers, Context, and Actions to be executed by\nthe Intelligence Configuration on a Conversation. A maximum of five (5) Rules are allowed per\nIntelligence Configuration.\n\nTo create an Intelligence Configuration without any Rules configured yet, pass an empty array\n(`\"rules\": []`). The Configuration will not execute any Language Operators until at least one Rule\nhas been added.\n", "type": "array", "items": { "$ref": "#/components/schemas/RuleCreationRequestPayload" }, "maxItems": 5 } }, "required": [ "displayName", "rules" ] }, "UpdateConfigurationRequest": { "type": "object", "required": [ "displayName", "rules" ], "properties": { "displayName": { "type": "string", "description": "The display name of the Intelligence Configuration describing its purpose.", "minLength": 1, "maxLength": 128 }, "description": { "type": "string", "description": "The description of the Intelligence Configuration further explaining its purpose." }, "rules": { "type": "array", "description": "List of Intelligence Configuration Rules that govern when and how Language Operators run.\nEach Rule represents a bundle of Operators, Triggers, Context, and Actions to be executed by\nthe Intelligence Configuration on a Conversation. A maximum of five (5) Rules are allowed per\nIntelligence Configuration.\n", "items": { "$ref": "#/components/schemas/RuleUpdateRequestPayload" }, "maxItems": 5 } } }, "PaginatedConfigurationResponse": { "type": "object", "description": "The response object returned when listing Intelligence Configurations.", "required": [ "items", "meta" ], "properties": { "items": { "type": "array", "description": "The list of Intelligence Configurations owned by this account.", "items": { "$ref": "#/components/schemas/IntelligenceConfiguration" } }, "meta": { "type": "object", "description": "The metadata for Pagination", "properties": { "key": { "description": "A key, sibling to the `meta` object that holds the actual list of resources", "type": "string" }, "pageSize": { "description": "The actual number of resources returned in the response", "type": "integer" }, "previousToken": { "type": "string" }, "nextToken": { "type": "string" } }, "required": [ "key", "pageSize" ] } } }, "ListOperatorsResponse": { "type": "object", "required": [ "items", "meta" ], "properties": { "items": { "type": "array", "description": "List of available Language Operators", "items": { "$ref": "#/components/schemas/LanguageOperator" } }, "meta": { "type": "object", "properties": { "key": { "description": "A key, sibling to the `meta` object that holds the actual list of resources", "type": "string" }, "pageSize": { "description": "The actual number of resources returned in the response", "type": "integer" }, "previousToken": { "type": "string" }, "nextToken": { "type": "string" } }, "required": [ "key", "pageSize" ] } } }, "OperatorVersionStatus": { "type": "string", "description": "The lifecycle status of an Operator version.\n\nAvailable values:\n- `PREVIEW`: Available but restricted to internal/testing visibility. Normal execution.\n- `ACTIVE`: Available for normal use.\n- `DEPRECATED`: Still executes normally, but a Warn event is emitted via the Watch product lifecycle system. Customers should migrate to a newer version.\n- `RETIRED`: Hard failure on execution. An Error is logged in Watch. Customers must manually update their Intelligence Configuration to a valid version.", "enum": [ "PREVIEW", "ACTIVE", "DEPRECATED", "RETIRED" ] }, "ListOperatorVersionsResponse": { "type": "object", "description": "Paginated list of Operator versions.", "required": [ "items", "meta" ], "properties": { "items": { "type": "array", "description": "List of Operator versions.", "items": { "type": "object", "required": [ "version", "status", "dateCreated" ], "properties": { "version": { "type": "integer", "description": "The numeric version number." }, "status": { "$ref": "#/components/schemas/OperatorVersionStatus" }, "dateCreated": { "type": "string", "format": "date-time", "description": "Timestamp of when this version was created." }, "dateDeprecated": { "type": "string", "format": "date-time", "description": "Timestamp of when this version was deprecated. Present when status is `DEPRECATED` or `RETIRED`." }, "retirementDate": { "type": "string", "format": "date-time", "description": "Scheduled retirement date for this version. Present when status is `DEPRECATED`." }, "dateRetired": { "type": "string", "format": "date-time", "description": "Timestamp of when this version was retired. Present when status is `RETIRED`." } } } }, "meta": { "type": "object", "properties": { "key": { "description": "A key, sibling to the `meta` object that holds the actual list of resources", "type": "string" }, "pageSize": { "description": "The actual number of resources returned in the response", "type": "integer" }, "previousToken": { "type": "string" }, "nextToken": { "type": "string" } }, "required": [ "key", "pageSize" ] } } }, "LanguageOperatorVersion": { "description": "Full detail of a specific Language Operator version.", "type": "object", "properties": { "id": { "$ref": "#/components/schemas/OperatorTtid" }, "displayName": { "type": "string", "description": "Display name of the Language Operator describing its purpose." }, "description": { "type": "string", "description": "Description of the Language Operator further explaining its purpose." }, "version": { "type": "integer", "readOnly": true, "description": "Numeric Operator version. Automatically incremented with each update on the resource, used to ensure integrity when updating the Operator." }, "author": { "$ref": "#/components/schemas/OperatorAuthorEnum" }, "prompt": { "type": "string", "description": "The natural language instructions used by the operator to analyze the conversation.\n\nWithin the prompt, users can reference parameters using the `{{parameters.[param_name]}}` syntax. Parameter values are provided to the Operator by the Intelligence Configuration Rule at runtime.\n\n**Note**: Prompts will only be exposed for Custom Operators (`author` = `SELF`). Twilio-authored Operators (`author` = `TWILIO`) will have their prompts omitted from the API." }, "outputFormat": { "$ref": "#/components/schemas/OperatorOutputFormat" }, "outputSchema": { "$ref": "#/components/schemas/OperatorOutputSchema" }, "trainingExamples": { "type": "array", "description": "An array of example input/output pairs used to illustrate the intended behavior of the Language Operator. These examples help guide the model's understanding of expected input\u2013output relationships and improve consistency during evaluation and testing.\n\n**Note**: Training examples will only be exposed for Custom Operators (`author` = `SELF`). Twilio-authored Operators (`author` = `TWILIO`) will have their training examples omitted from the API.", "items": { "$ref": "#/components/schemas/OperatorTrainingExample" } }, "context": { "$ref": "#/components/schemas/OperatorContext" }, "parameters": { "$ref": "#/components/schemas/OperatorParameters" }, "status": { "$ref": "#/components/schemas/OperatorVersionStatus" }, "dateCreated": { "type": "string", "format": "date-time", "description": "Timestamp of when this version was created." } }, "required": [ "dateCreated", "status" ] }, "CreateOrUpdateOperatorRequest": { "type": "object", "properties": { "id": { "$ref": "#/components/schemas/OperatorTtid" }, "displayName": { "type": "string", "description": "Display name of the Language Operator describing its purpose." }, "description": { "type": "string", "description": "Description of the Language Operator further explaining its purpose." }, "version": { "type": "integer", "readOnly": true, "description": "Numeric Operator version. Automatically incremented with each update on the resource, used to ensure integrity when updating the Operator." }, "author": { "$ref": "#/components/schemas/OperatorAuthorEnum" }, "prompt": { "type": "string", "description": "The natural language instructions used by the operator to analyze the conversation.\n\nWithin the prompt, users can reference parameters using the `{{parameters.[param_name]}}` syntax. Parameter values are provided to the Operator by the Intelligence Configuration Rule at runtime.\n\n**Note**: Prompts will only be exposed for Custom Operators (`author` = `SELF`). Twilio-authored Operators (`author` = `TWILIO`) will have their prompts omitted from the API." }, "outputFormat": { "$ref": "#/components/schemas/OperatorOutputFormat" }, "outputSchema": { "$ref": "#/components/schemas/OperatorOutputSchema" }, "trainingExamples": { "type": "array", "description": "An array of example input/output pairs used to illustrate the intended behavior of the Language Operator. These examples help guide the model's understanding of expected input\u2013output relationships and improve consistency during evaluation and testing.\n\n**Note**: Training examples will only be exposed for Custom Operators (`author` = `SELF`). Twilio-authored Operators (`author` = `TWILIO`) will have their training examples omitted from the API.", "items": { "$ref": "#/components/schemas/OperatorTrainingExample" } }, "context": { "$ref": "#/components/schemas/OperatorContext" }, "parameters": { "$ref": "#/components/schemas/OperatorParameters" } }, "required": [ "outputFormat", "prompt", "displayName" ] }, "LanguageOperator": { "description": "A Language Operator resource.", "type": "object", "properties": { "id": { "$ref": "#/components/schemas/OperatorTtid" }, "displayName": { "type": "string", "description": "Display name of the Language Operator describing its purpose." }, "description": { "type": "string", "description": "Description of the Language Operator further explaining its purpose." }, "version": { "type": "integer", "readOnly": true, "description": "Numeric Operator version. Automatically incremented with each update on the resource, used to ensure integrity when updating the Operator." }, "author": { "$ref": "#/components/schemas/OperatorAuthorEnum" }, "prompt": { "type": "string", "description": "The natural language instructions used by the operator to analyze the conversation.\n\nWithin the prompt, users can reference parameters using the `{{parameters.[param_name]}}` syntax. Parameter values are provided to the Operator by the Intelligence Configuration Rule at runtime.\n\n**Note**: Prompts will only be exposed for Custom Operators (`author` = `SELF`). Twilio-authored Operators (`author` = `TWILIO`) will have their prompts omitted from the API." }, "outputFormat": { "$ref": "#/components/schemas/OperatorOutputFormat" }, "outputSchema": { "$ref": "#/components/schemas/OperatorOutputSchema" }, "trainingExamples": { "type": "array", "description": "An array of example input/output pairs used to illustrate the intended behavior of the Language Operator. These examples help guide the model's understanding of expected input\u2013output relationships and improve consistency during evaluation and testing.\n\n**Note**: Training examples will only be exposed for Custom Operators (`author` = `SELF`). Twilio-authored Operators (`author` = `TWILIO`) will have their training examples omitted from the API.", "items": { "$ref": "#/components/schemas/OperatorTrainingExample" } }, "context": { "$ref": "#/components/schemas/OperatorContext" }, "parameters": { "$ref": "#/components/schemas/OperatorParameters" } } }, "OperatorAuthorEnum": { "type": "string", "readOnly": true, "description": "The creator and maintainer of the Language Operator. \n\nAvailable values:\n- `SELF` - Created and maintained by the customer (Custom Operator)\n- `TWILIO` - Created and maintained by Twilio (Twilio-Authored Operator)", "enum": [ "SELF", "TWILIO" ] }, "OperatorOutputFormat": { "type": "string", "description": "The structure of the result returned by the Language Operator (specific to what the LLM returns, not the entirety of the Operator Result resource).\n\nAvailable values:\n- `TEXT`: The Operator will return plaintext from the LLM.\n- `JSON`: the Operator will return a structured object with schema defined in `output_schema`\n- `CLASSIFICATION`: The Operator will return the determined classifier string.", "enum": [ "TEXT", "JSON", "CLASSIFICATION" ] }, "OperatorOutputSchema": { "type": "object", "description": "Required for `JSON` output only. this will be set to a JSON Schema object describing the properties & data types of the response. Please see https://platform.openai.com/docs/guides/structured-outputs#supported-schemas \n\nWill include the following keywords:\n- `type` : Must be set to `object`\n- `properties`: An object containing the property names and their data types you would like the LLM to return\n\nAdditional details on JSON output formatting:\n- The root level `type` of a JSON schema must be set to `object`\n- The following property data types are supported : `string`, `number`, `boolean`, `integer`, `object`, `array`, `anyOf`\n- Definitions with `$defs` / `$ref` are supported\n- Max 100 object properties and 10 levels of nesting are supported\n- Max 1000 enum values across all enum properties are supported\n- Notable JSON Schema keywords not supported include:\n - For `strings`: `minLength`, `maxLength`\n - For `objects`: `patternProperties`, `unevaluatedProperties`, `propertyNames`, `minProperties`, `maxProperties`\n - For `arrays`: `unevaluatedItems`, `contains`, `minContains`, `maxContains`, `uniqueItems`\n- Structured Operator Results will be returned in the same order as the ordering of keys in the schema\n- In the event an Operator execution request is refused for safety reasons the Operator Result API response will include a new field called `refusal` to indicate that the LLM refused to fulfill the request\n- Twilio will automatically set `additionalProperties` to false and specify all provided fields as required (constraints of Structured Outputs). You don't need to pass these fields as part of your JSON schema. Twilio will automatically overwrite any user-provided values for these fields." }, "OperatorTrainingExample": { "type": "object", "required": [ "input", "output" ], "properties": { "input": { "type": "string", "description": "A sample input text that demonstrates the type of content the Operator processes." }, "output": { "type": "string", "description": "The expected output corresponding to the provided input example.\nThis value must be consistent with the defined `output_format` and `output_schema` of the Operator." } } }, "OperatorContext": { "type": "object", "description": "Optionally specifies which contextual data sources (Memory, Knowledge) the operator can access during execution. Context objects will be passed in by the Intelligence Configuration Rule at runtime.\n\n**Note**: this simply gives the LLM access to these context objects \u2013 ultimately the LLM will determine whether to actually call for context at runtime.", "properties": { "memory": { "type": "object", "description": "Defines whether the Operator has access to Memory (past conversational memories and profile traits).", "properties": { "enabled": { "type": "boolean", "description": "Set to true to allow access to Memory at runtime." } } }, "knowledge": { "type": "object", "description": "Defines whether the Operator has access to organizational Knowledge Sources (e.g., policies, FAQs, scripts) at runtime.", "properties": { "enabled": { "type": "boolean", "description": "Set to true to allow access to Knowledge Sources at runtime." } } } } }, "OperatorParameters": { "type": "object", "description": "Defines the schema of the parameters that are provided when running the operator, including required and optional values that determine the operator's behavior.\nThe values of the parameters themselves are passed in by the attached Intelligence Configuration.", "additionalProperties": { "$ref": "#/components/schemas/OperatorParameter" } }, "OperatorParameter": { "type": "object", "required": [ "type" ], "properties": { "type": { "type": "string", "description": "The data type of the parameter (e.g., STRING, INTEGER).\nAvailable values: STRING, INTEGER, NUMBER, BOOLEAN, KNOWLEDGE_BASE_AND_SOURCE_IDS\n\nKNOWLEDGE_BASE_AND_SOURCE_IDS is a special type of parameter that refers to a Memora Knowledge Source, prefixed with its Knowledge Base container. Support for KB type = plaintext only.\nDuring Intelligence Configuration creation, this parameter is linked to a specific Knowledge Source. The operator receives the resolved plaintext at runtime and injects it into the prompt.\nThe value of this parameter is expected to be passed in the following format: knowledge_base_id:knowledge_source_id.", "enum": [ "STRING", "INTEGER", "NUMBER", "BOOLEAN", "KNOWLEDGE_BASE_AND_SOURCE_IDS" ] }, "default": { "description": "Default value to use in the prompt if no value is provided by the Intelligence Configuration.\nNote: knowledge_base_and_source_ids does not support the default attribute, but all other param types do allow for a default value." }, "required": { "type": "boolean", "description": "Whether this parameter must be set at Operator execution time. Defaults to false if not provided." }, "description": { "type": "string", "description": "A human-readable description of the parameter." } } }, "OperatorTtid": { "type": "string", "nullable": false, "readOnly": true, "pattern": "^intelligence_operator_[0-7][0-9a-z]{25}$", "description": "The unique identifier for the Language Operator. Assigned by Twilio (TTID).", "example": "intelligence_operator_01k6fc25s7epm9qtk8rszbv3q5" }, "OperatorResultTtid": { "type": "string", "nullable": false, "pattern": "^intelligence_operatorresult_[0-7][0-9a-z]{25}$", "description": "A unique identifier for the Operator Result. Assigned by Twilio (TTID).", "example": "intelligence_operatorresult_01k6fc25s7epm9qtk8rszbv3q5" }, "ConversationTtid": { "type": "string", "nullable": false, "pattern": "^conv_conversation_[0-7][0-9a-z]{25}$", "description": "The `id` of the Conversation attached to the Operator Result.", "example": "conv_conversation_01k1etk2y5f1y9fpe2epfdtvv2" }, "ParticipantTtid": { "type": "string", "nullable": false, "pattern": "^conv_participant_[0-7][0-9a-z]{25}$", "description": "The `id` of the Participant in the Conversation.", "example": "conv_participant_01k1etx3jbfx88476ccja0889c" }, "MemoryProfileTtid": { "type": "string", "pattern": "^mem_profile_[0-7][0-9a-z]{25}$", "description": "Customer Memory Profile identifier", "example": "mem_profile_00000000000000000000000000" }, "MemoryStoreTtid": { "type": "string", "description": "Customer Memory store identifier", "pattern": "^mem_(store|service)_[0-7][0-9a-z]{25}$", "example": "mem_store_00000000000000000000000000" }, "KnowledgeBaseTtid": { "type": "string", "description": "Knowledge base identifier", "pattern": "^know_knowledgebase_[0-7][0-9a-z]{25}$", "example": "know_knowledgebase_00000000000000000000000000" }, "KnowledgeSourceTtid": { "type": "string", "description": "Knowledge source identifier", "pattern": "^know_knowledge_[0-7][0-9a-z]{25}$", "example": "know_knowledge_00000000000000000000000000" }, "CommunicationTtid": { "type": "string", "nullable": false, "pattern": "^conv_communication_[0-7][0-9a-z]{25}$", "description": "Communication `id` from the attached Conversation.", "example": "conv_communication_01k1etk2y5f1y9fpe2epfdtvv2" }, "IntelligenceConfigurationTtid": { "type": "string", "nullable": false, "pattern": "^intelligence_configuration_[0-7][0-9a-z]{25}$", "description": "Unique identifier for a Intelligence Configuration that generated the Operator Result. Assigned by Twilio (TTID).", "example": "intelligence_configuration_01k6fc25s7epm9qtk8rszbv3q5" }, "IntelligenceConfigurationRuleTtid": { "type": "string", "nullable": false, "pattern": "^intelligence_configurationrule_[0-7][0-9a-z]{25}$", "description": "Unique identifier of the rule of the Intelligence Configuration that triggered the result. Assigned by Twilio (TTID).", "example": "intelligence_configurationrule_01k6fc25s7epm9qtk8rszbv3q6" }, "ConfigurationTtid": { "type": "string", "nullable": false, "description": "The `id` of the Configuration for a Conversation.", "example": "conv_configuration_00000000000000000000000000" }, "Content": { "type": "object", "description": "The content of the communication.", "properties": { "text": { "type": "string", "description": "The transcript of the communication." } } }, "Communication": { "type": "object", "required": [ "id", "participantId", "content", "createdAt" ], "properties": { "id": { "$ref": "#/components/schemas/CommunicationTtid" }, "participantId": { "$ref": "#/components/schemas/ParticipantTtid" }, "content": { "$ref": "#/components/schemas/Content" }, "createdAt": { "type": "string", "format": "date-time", "description": "The timestamp for when the Communication was created." } } }, "Participant": { "type": "object", "required": [ "id", "addressValues" ], "properties": { "id": { "$ref": "#/components/schemas/ParticipantTtid" }, "name": { "type": "string", "nullable": true, "description": "Participant display name." }, "type": { "type": "string", "nullable": true, "description": "Type of participant in the conversation. Available types:\n- `CUSTOMER`\n- `HUMAN_AGENT`\n- `AI_AGENT`\n- `AGENT`\n- `UNKNOWN`\n" }, "addressValues": { "type": "array", "items": { "type": "string" }, "description": "Participant address values (for example, a phone number or sender identifier)." } } }, "Channel": { "type": "string", "description": "Communication channel type.", "enum": [ "VOICE", "SMS", "RCS", "EMAIL", "WHATSAPP", "CHAT", "API", "SYSTEM" ] }, "ConversationStatus": { "type": "string", "description": "The status of the Conversation.", "enum": [ "ACTIVE", "INACTIVE", "CLOSED" ] }, "ConversationListItem": { "type": "object", "required": [ "id", "accountId", "name", "status", "createdAt", "updatedAt", "intelligenceConfigurationIds", "conversationConfigurationId", "channels", "channelIds", "participants", "operatorResultIds" ], "properties": { "id": { "$ref": "#/components/schemas/ConversationTtid" }, "accountId": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^AC[0-9a-fA-F]{32}$", "nullable": true, "description": "The ID of the account that owns the Conversation." }, "name": { "type": "string", "nullable": true, "description": "Display name of the Conversation." }, "status": { "$ref": "#/components/schemas/ConversationStatus" }, "createdAt": { "type": "string", "format": "date-time", "description": "Timestamp for when the Conversation was created." }, "updatedAt": { "type": "string", "format": "date-time", "description": "Timestamp for when the Conversation was last updated." }, "intelligenceConfigurationIds": { "type": "array", "description": "The Intelligence Configuration(s) associated with the Conversation.", "items": { "$ref": "#/components/schemas/IntelligenceConfigurationTtid" } }, "conversationConfigurationId": { "$ref": "#/components/schemas/ConfigurationTtid" }, "channels": { "type": "array", "description": "The communication channel(s) included in the Conversation.", "items": { "$ref": "#/components/schemas/Channel" } }, "channelIds": { "type": "array", "description": "The underlying channel resource `id`s associated with this Conversation, such as a Call ID or Message ID.", "items": { "type": "string" } }, "participants": { "type": "array", "description": "Metadata for Participants of the Conversation.", "items": { "$ref": "#/components/schemas/Participant" } }, "operatorResultIds": { "type": "array", "description": "List of Operator Result IDs generated from this Conversation.", "items": { "type": "string" } } } }, "Conversation": { "type": "object", "required": [ "id", "accountId", "name", "status", "createdAt", "updatedAt", "intelligenceConfigurationIds", "conversationConfigurationId", "channels", "channelIds", "participants", "communications", "operatorResultIds" ], "properties": { "id": { "$ref": "#/components/schemas/ConversationTtid" }, "accountId": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^AC[0-9a-fA-F]{32}$", "nullable": true, "description": "The ID of the account that owns the Conversation." }, "name": { "type": "string", "nullable": true, "description": "Display name of the Conversation." }, "status": { "$ref": "#/components/schemas/ConversationStatus" }, "createdAt": { "type": "string", "format": "date-time", "description": "Timestamp for when the Conversation was created." }, "updatedAt": { "type": "string", "format": "date-time", "description": "Timestamp for when the Conversation was last updated." }, "intelligenceConfigurationIds": { "type": "array", "description": "The Intelligence Configuration(s) associated with the Conversation.", "items": { "$ref": "#/components/schemas/IntelligenceConfigurationTtid" } }, "conversationConfigurationId": { "$ref": "#/components/schemas/ConfigurationTtid" }, "channels": { "type": "array", "description": "The communication channel(s) included in the Conversation.", "items": { "$ref": "#/components/schemas/Channel" } }, "channelIds": { "type": "array", "description": "The underlying channel resource `id`s associated with this Conversation, such as a Call ID or Message ID.", "items": { "type": "string" } }, "participants": { "type": "array", "description": "Metadata for Participants of the Conversation.", "items": { "$ref": "#/components/schemas/Participant" } }, "communications": { "type": "array", "description": "Metadata for the Communications that make up the Conversation.", "items": { "$ref": "#/components/schemas/Communication" } }, "operatorResultIds": { "type": "array", "description": "List of Operator Result IDs generated from this Conversation.", "items": { "type": "string" } } } }, "ListConversationsResponse": { "type": "object", "required": [ "items", "meta" ], "properties": { "items": { "type": "array", "items": { "$ref": "#/components/schemas/ConversationListItem" }, "description": "List of conversations." }, "meta": { "type": "object", "properties": { "key": { "description": "A key, sibling to the `meta` object that holds the actual list of resources", "type": "string" }, "pageSize": { "description": "The actual number of resources returned in the response", "type": "integer" }, "previousToken": { "type": "string" }, "nextToken": { "type": "string" } }, "required": [ "key", "pageSize" ] } } } } }, "servers": [ { "url": "https://intelligence.twilio.com", "description": "Twilio Intelligence API" } ], "tags": [ { "name": "Configurations", "description": "Define and manage intelligence configuration. The Configurations resource defines how and when\nlanguage operators execute on conversations via rules that encapsulate triggers, context, and actions.\n\nAn intelligence configuration is a container for one or more rules. Each rule specifies:\n\n- Which language operators to execute\n- Which conversation lifecycle event triggers the rule\n- Which contextual data language operators can access at runtime \n- Which action to take on the results\n\nConfigurations are evaluated automatically as conversation activity occurs, providing consistent,\nreusable intelligence logic across channels and over time.\n" }, { "name": "Operators", "description": "Define and manage language operators. Conversational Intelligence uses GenAI-powered language operators to transform conversation text into structured insights.\n\nLanguage operators produce structured outputs and can be reused across multiple intelligence configurations. Language operators are executed automatically according to rules you define.\n\nUse Twilio-authored language operators for common use cases (Sentiment, Summary, Next Best Response, and Script Adherence) or create custom language operators to meet your business needs.\n" }, { "name": "OperatorResults", "description": "Retrieve results produced by language operators after they run on conversations,\nincluding associated execution metadata generated at runtime. Use these results to support real-time agent augmentation, workflow automation, and aggregate conversational insights.\n\nResults are generated when Conversations are processed by intelligence configuration rules and can be\nqueried independently of the original conversation lifecycle.\n" }, { "name": "Conversations", "description": "Retrieve conversations processed by an intelligence configuration, including\nassociated execution metadata and contextual information.\n\nThe Conversations resource lets you to inspect conversations alongside their applied intelligence, including which\nrules were evaluated, which language operators ran, and what results were produced.\n\nUse this resource to understand how Conversational Intelligence was applied to a given interaction\nand to correlate conversation transcripts with language operator results.\n" } ], "paths": { "/v3/ControlPlane/Configurations": { "x-twilio": { "pathType": "list" }, "post": { "summary": "Create an Intelligence Configuration", "tags": [ "Configurations" ], "security": [ { "basic_apikey_or_accountsid": [] } ], "operationId": "CreateConfiguration", "description": "Create an Intelligence Configuration to control how and when language operators analyze conversations.\n\nYou must include the `rules` field in the request. You can pass an empty array (`\"rules\": []`), but an Intelligence Configuration with an empty `rules` array doesn't execute any language operators. To add rules later, make a `PUT /v3/ControlPlane/Configurations/{id}` request.\n\nAfter creating an Intelligence Configuration, you must attach it to a Conversations Configuration by using the Conversations API.\n", "requestBody": { "required": true, "content": { "application/json": { "schema": { "type": "object", "description": "Request body for creating a new Intelligence Configuration.", "properties": { "displayName": { "type": "string", "description": "The display name of the Intelligence Configuration describing its purpose.", "minLength": 1, "maxLength": 128 }, "description": { "type": "string", "description": "The description of the Intelligence Configuration further explaining its purpose." }, "rules": { "description": "List of Intelligence Configuration Rules that govern when and how Language Operators run.\nEach Rule represents a bundle of Operators, Triggers, Context, and Actions to be executed by\nthe Intelligence Configuration on a Conversation. A maximum of five (5) Rules are allowed per\nIntelligence Configuration.\n\nTo create an Intelligence Configuration without any Rules configured yet, pass an empty array\n(`\"rules\": []`). The Configuration will not execute any Language Operators until at least one Rule\nhas been added.\n", "type": "array", "items": { "$ref": "#/components/schemas/RuleCreationRequestPayload" }, "maxItems": 5 } }, "required": [ "displayName", "rules" ] }, "examples": { "createConfigurationRequest": { "$ref": "#/components/examples/CreateConfigurationRequestExample" } } } } }, "responses": { "201": { "description": "Intelligence Configuration resource created.", "content": { "application/json": { "schema": { "type": "object", "description": "An Intelligence Configuration defines how and when Language Operators execute for a given conversation.\n\nTo activate an Intelligence Configuration and trigger Operator execution, two conditions must be met:\n1. The Intelligence Configuration must include at least one Rule.\n2. The Intelligence Configuration must be attached to a Conversations Configuration via the Conversations API.\n Conversation traffic received by that Conversations Configuration determines when Rules are evaluated\n and executed.\n\nAn Intelligence Configuration that has no Rules or is not attached to a Conversations Configuration will not execute.\n", "required": [ "accountId", "id", "displayName", "version", "rules", "dateCreated", "dateUpdated" ], "properties": { "accountId": { "type": "string", "example": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "x-jvm-type": "com.twilio.sids.AccountSid", "description": "The ID of the Account that created the Intelligence Configuration." }, "id": { "type": "string", "description": "The unique identifier for the Intelligence Configuration. Assigned by Twilio (TTID)." }, "displayName": { "type": "string", "description": "The display name of the Intelligence Configuration describing its purpose.", "minLength": 1, "maxLength": 128 }, "description": { "type": "string", "description": "The description of the Intelligence Configuration further explaining its purpose." }, "version": { "type": "integer", "description": "The numeric version of the Intelligence Configuration. Automatically incremented with each update on the resource, used to ensure integrity when updating the Configuration." }, "rules": { "type": "array", "items": { "$ref": "#/components/schemas/Rule" }, "maxItems": 5, "description": "List of Intelligence Configuration Rules that govern when and how Language Operators run.\nEach Rule represents a bundle of Operators, Triggers, Context, and Actions to be executed by\nthe Intelligence Configuration on a Conversation. A maximum of five (5) Rules are allowed per\nIntelligence Configuration.\n" }, "dateCreated": { "description": "Timestamp of when the Intelligence Configuration was created.", "type": "string", "format": "date-time" }, "dateUpdated": { "description": "Timestamp of when the Intelligence Configuration was last updated.", "type": "string", "format": "date-time" } } }, "examples": { "createConfigurationResponse": { "$ref": "#/components/examples/IntelligenceConfigurationExample" } } } } }, "400": { "description": "Bad request", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "429": { "description": "Too Many requests (rate limit exceeded for request originating from public API)", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } }, "headers": { "X-RateLimit-Limit": { "schema": { "type": "string" } }, "X-RateLimit-Remaining": { "schema": { "type": "string" } }, "X-RateLimit-Reset": { "schema": { "type": "string" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } }, "get": { "summary": "Retrieve a list of Intelligence Configurations", "tags": [ "Configurations" ], "security": [ { "basic_apikey_or_accountsid": [] } ], "operationId": "ListConfigurations", "parameters": [ { "name": "pageSize", "in": "query", "description": "The maximum number of resources to return", "required": false, "schema": { "type": "integer", "minimum": 1, "maximum": 1000, "default": 50 } }, { "name": "pageToken", "in": "query", "description": "Token for pagination", "required": false, "schema": { "type": "string" } } ], "responses": { "200": { "description": "An array of Intelligence Configurations.", "content": { "application/json": { "schema": { "type": "object", "description": "The response object returned when listing Intelligence Configurations.", "required": [ "items", "meta" ], "properties": { "items": { "type": "array", "description": "The list of Intelligence Configurations owned by this account.", "items": { "$ref": "#/components/schemas/IntelligenceConfiguration" } }, "meta": { "type": "object", "description": "The metadata for Pagination", "properties": { "key": { "description": "A key, sibling to the `meta` object that holds the actual list of resources", "type": "string" }, "pageSize": { "description": "The actual number of resources returned in the response", "type": "integer" }, "previousToken": { "type": "string" }, "nextToken": { "type": "string" } }, "required": [ "key", "pageSize" ] } } }, "examples": { "listConfigurationsResponse": { "$ref": "#/components/examples/PaginatedConfigurationResponseExample" } } } } }, "429": { "description": "Too Many requests (rate limit exceeded for request originating from public API)", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } }, "headers": { "X-RateLimit-Limit": { "schema": { "type": "string" } }, "X-RateLimit-Remaining": { "schema": { "type": "string" } }, "X-RateLimit-Reset": { "schema": { "type": "string" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } } }, "/v3/ControlPlane/Configurations/{id}": { "x-twilio": { "pathType": "instance" }, "parameters": [ { "name": "id", "in": "path", "required": true, "description": "The unique identifier of the Intelligence Configuration.", "schema": { "type": "string", "nullable": false, "pattern": "^intelligence_configuration_[0-7][0-9a-z]{25}$", "description": "Unique identifier for a Intelligence Configuration that generated the Operator Result. Assigned by Twilio (TTID).", "example": "intelligence_configuration_01k6fc25s7epm9qtk8rszbv3q5" } } ], "get": { "summary": "Retrieve an Intelligence Configuration", "tags": [ "Configurations" ], "security": [ { "basic_apikey_or_accountsid": [] } ], "operationId": "FetchConfiguration", "responses": { "200": { "description": "A single Intelligence Configuration resource.", "content": { "application/json": { "schema": { "type": "object", "description": "An Intelligence Configuration defines how and when Language Operators execute for a given conversation.\n\nTo activate an Intelligence Configuration and trigger Operator execution, two conditions must be met:\n1. The Intelligence Configuration must include at least one Rule.\n2. The Intelligence Configuration must be attached to a Conversations Configuration via the Conversations API.\n Conversation traffic received by that Conversations Configuration determines when Rules are evaluated\n and executed.\n\nAn Intelligence Configuration that has no Rules or is not attached to a Conversations Configuration will not execute.\n", "required": [ "accountId", "id", "displayName", "version", "rules", "dateCreated", "dateUpdated" ], "properties": { "accountId": { "type": "string", "example": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "x-jvm-type": "com.twilio.sids.AccountSid", "description": "The ID of the Account that created the Intelligence Configuration." }, "id": { "type": "string", "description": "The unique identifier for the Intelligence Configuration. Assigned by Twilio (TTID)." }, "displayName": { "type": "string", "description": "The display name of the Intelligence Configuration describing its purpose.", "minLength": 1, "maxLength": 128 }, "description": { "type": "string", "description": "The description of the Intelligence Configuration further explaining its purpose." }, "version": { "type": "integer", "description": "The numeric version of the Intelligence Configuration. Automatically incremented with each update on the resource, used to ensure integrity when updating the Configuration." }, "rules": { "type": "array", "items": { "$ref": "#/components/schemas/Rule" }, "maxItems": 5, "description": "List of Intelligence Configuration Rules that govern when and how Language Operators run.\nEach Rule represents a bundle of Operators, Triggers, Context, and Actions to be executed by\nthe Intelligence Configuration on a Conversation. A maximum of five (5) Rules are allowed per\nIntelligence Configuration.\n" }, "dateCreated": { "description": "Timestamp of when the Intelligence Configuration was created.", "type": "string", "format": "date-time" }, "dateUpdated": { "description": "Timestamp of when the Intelligence Configuration was last updated.", "type": "string", "format": "date-time" } } }, "examples": { "fetchConfigurationResponse": { "$ref": "#/components/examples/IntelligenceConfigurationExample" } } } } }, "404": { "description": "Resource not found", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } }, "put": { "summary": "Update an Intelligence Configuration", "description": "Update an Intelligence Configuration, including its metadata and rules. The request must include all required fields.", "tags": [ "Configurations" ], "security": [ { "basic_apikey_or_accountsid": [] } ], "operationId": "UpdateConfiguration", "requestBody": { "required": true, "content": { "application/json": { "schema": { "type": "object", "required": [ "displayName", "rules" ], "properties": { "displayName": { "type": "string", "description": "The display name of the Intelligence Configuration describing its purpose.", "minLength": 1, "maxLength": 128 }, "description": { "type": "string", "description": "The description of the Intelligence Configuration further explaining its purpose." }, "rules": { "type": "array", "description": "List of Intelligence Configuration Rules that govern when and how Language Operators run.\nEach Rule represents a bundle of Operators, Triggers, Context, and Actions to be executed by\nthe Intelligence Configuration on a Conversation. A maximum of five (5) Rules are allowed per\nIntelligence Configuration.\n", "items": { "$ref": "#/components/schemas/RuleUpdateRequestPayload" }, "maxItems": 5 } } }, "examples": { "updateConfigurationRequest": { "$ref": "#/components/examples/UpdateConfigurationRequestExample" } } } } }, "responses": { "200": { "description": "Intelligence configuration resource updated.", "content": { "application/json": { "schema": { "type": "object", "description": "An Intelligence Configuration defines how and when Language Operators execute for a given conversation.\n\nTo activate an Intelligence Configuration and trigger Operator execution, two conditions must be met:\n1. The Intelligence Configuration must include at least one Rule.\n2. The Intelligence Configuration must be attached to a Conversations Configuration via the Conversations API.\n Conversation traffic received by that Conversations Configuration determines when Rules are evaluated\n and executed.\n\nAn Intelligence Configuration that has no Rules or is not attached to a Conversations Configuration will not execute.\n", "required": [ "accountId", "id", "displayName", "version", "rules", "dateCreated", "dateUpdated" ], "properties": { "accountId": { "type": "string", "example": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "x-jvm-type": "com.twilio.sids.AccountSid", "description": "The ID of the Account that created the Intelligence Configuration." }, "id": { "type": "string", "description": "The unique identifier for the Intelligence Configuration. Assigned by Twilio (TTID)." }, "displayName": { "type": "string", "description": "The display name of the Intelligence Configuration describing its purpose.", "minLength": 1, "maxLength": 128 }, "description": { "type": "string", "description": "The description of the Intelligence Configuration further explaining its purpose." }, "version": { "type": "integer", "description": "The numeric version of the Intelligence Configuration. Automatically incremented with each update on the resource, used to ensure integrity when updating the Configuration." }, "rules": { "type": "array", "items": { "$ref": "#/components/schemas/Rule" }, "maxItems": 5, "description": "List of Intelligence Configuration Rules that govern when and how Language Operators run.\nEach Rule represents a bundle of Operators, Triggers, Context, and Actions to be executed by\nthe Intelligence Configuration on a Conversation. A maximum of five (5) Rules are allowed per\nIntelligence Configuration.\n" }, "dateCreated": { "description": "Timestamp of when the Intelligence Configuration was created.", "type": "string", "format": "date-time" }, "dateUpdated": { "description": "Timestamp of when the Intelligence Configuration was last updated.", "type": "string", "format": "date-time" } } }, "examples": { "updateConfigurationResponse": { "$ref": "#/components/examples/IntelligenceConfigurationExample" } } } } }, "400": { "description": "Bad request", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "404": { "description": "Resource not found", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } }, "delete": { "summary": "Delete an Intelligence Configuration", "tags": [ "Configurations" ], "security": [ { "basic_apikey_or_accountsid": [] } ], "operationId": "DeleteConfiguration", "responses": { "204": { "description": "Intelligence Configuration resource deleted." }, "404": { "description": "Resource not found", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } } }, "/v3/ControlPlane/Operators": { "x-twilio": { "pathType": "list" }, "get": { "tags": [ "Operators" ], "summary": "Retrieve a list of Operators", "description": "Retrieve a list of Operators for the account, including those not attached to an Intelligence Configuration. This request returns both Twilio-authored and custom language operators.", "operationId": "ListOperators", "parameters": [ { "name": "pageSize", "in": "query", "description": "The maximum number of resources to return", "required": false, "schema": { "type": "integer", "minimum": 1, "maximum": 1000, "default": 50 } }, { "name": "pageToken", "in": "query", "description": "Token for pagination", "required": false, "schema": { "type": "string" } } ], "responses": { "200": { "description": "List of available Language Operators", "content": { "application/json": { "schema": { "type": "object", "required": [ "items", "meta" ], "properties": { "items": { "type": "array", "description": "List of available Language Operators", "items": { "$ref": "#/components/schemas/LanguageOperator" } }, "meta": { "type": "object", "properties": { "key": { "description": "A key, sibling to the `meta` object that holds the actual list of resources", "type": "string" }, "pageSize": { "description": "The actual number of resources returned in the response", "type": "integer" }, "previousToken": { "type": "string" }, "nextToken": { "type": "string" } }, "required": [ "key", "pageSize" ] } } }, "examples": { "listOperatorsResponse": { "$ref": "#/components/examples/ListOperatorsResponseExample" } } } } }, "429": { "description": "Too Many requests (rate limit exceeded for request originating from public API)", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } }, "headers": { "X-RateLimit-Limit": { "schema": { "type": "string" } }, "X-RateLimit-Remaining": { "schema": { "type": "string" } }, "X-RateLimit-Reset": { "schema": { "type": "string" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } }, "post": { "tags": [ "Operators" ], "summary": "Create an Operator", "description": "Create a custom language operator. You can define a reusable, programmable conversational analysis task tailored to your business needs.", "operationId": "CreateOperator", "requestBody": { "description": "Create Language Operator request", "required": true, "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/LanguageOperator" }, { "required": [ "displayName", "prompt", "outputFormat" ] } ] }, "examples": { "createOperatorRequest": { "$ref": "#/components/examples/CreateOrUpdateOperatorRequestExample" } } } } }, "responses": { "201": { "description": "Language Operator resource created.", "content": { "application/json": { "schema": { "description": "A Language Operator resource.", "type": "object", "properties": { "id": { "$ref": "#/components/schemas/OperatorTtid" }, "displayName": { "type": "string", "description": "Display name of the Language Operator describing its purpose." }, "description": { "type": "string", "description": "Description of the Language Operator further explaining its purpose." }, "version": { "type": "integer", "readOnly": true, "description": "Numeric Operator version. Automatically incremented with each update on the resource, used to ensure integrity when updating the Operator." }, "author": { "$ref": "#/components/schemas/OperatorAuthorEnum" }, "prompt": { "type": "string", "description": "The natural language instructions used by the operator to analyze the conversation.\n\nWithin the prompt, users can reference parameters using the `{{parameters.[param_name]}}` syntax. Parameter values are provided to the Operator by the Intelligence Configuration Rule at runtime.\n\n**Note**: Prompts will only be exposed for Custom Operators (`author` = `SELF`). Twilio-authored Operators (`author` = `TWILIO`) will have their prompts omitted from the API." }, "outputFormat": { "$ref": "#/components/schemas/OperatorOutputFormat" }, "outputSchema": { "$ref": "#/components/schemas/OperatorOutputSchema" }, "trainingExamples": { "type": "array", "description": "An array of example input/output pairs used to illustrate the intended behavior of the Language Operator. These examples help guide the model's understanding of expected input\u2013output relationships and improve consistency during evaluation and testing.\n\n**Note**: Training examples will only be exposed for Custom Operators (`author` = `SELF`). Twilio-authored Operators (`author` = `TWILIO`) will have their training examples omitted from the API.", "items": { "$ref": "#/components/schemas/OperatorTrainingExample" } }, "context": { "$ref": "#/components/schemas/OperatorContext" }, "parameters": { "$ref": "#/components/schemas/OperatorParameters" } } }, "examples": { "createOperatorResponse": { "$ref": "#/components/examples/LanguageOperatorExample" } } } }, "headers": { "ETag": { "description": "The version for this resource, used for PUT requests in concert with the IF-MATCH header.", "schema": { "type": "integer", "minimum": 1, "example": 1 } } } }, "400": { "description": "Bad request", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "429": { "description": "Too Many requests (rate limit exceeded for request originating from public API)", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } }, "headers": { "X-RateLimit-Limit": { "schema": { "type": "string" } }, "X-RateLimit-Remaining": { "schema": { "type": "string" } }, "X-RateLimit-Reset": { "schema": { "type": "string" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } } }, "/v3/ControlPlane/Operators/{id}": { "x-twilio": { "pathType": "instance" }, "parameters": [ { "name": "id", "in": "path", "required": true, "description": "The unique identifier (TTID) of the Language Operator.", "schema": { "type": "string", "nullable": false, "readOnly": true, "pattern": "^intelligence_operator_[0-7][0-9a-z]{25}$", "description": "The unique identifier for the Language Operator. Assigned by Twilio (TTID).", "example": "intelligence_operator_01k6fc25s7epm9qtk8rszbv3q5" } } ], "get": { "tags": [ "Operators" ], "summary": "Retrieve an Operator", "operationId": "FetchOperator", "responses": { "200": { "description": "A Language Operator resource.", "content": { "application/json": { "schema": { "description": "A Language Operator resource.", "type": "object", "properties": { "id": { "$ref": "#/components/schemas/OperatorTtid" }, "displayName": { "type": "string", "description": "Display name of the Language Operator describing its purpose." }, "description": { "type": "string", "description": "Description of the Language Operator further explaining its purpose." }, "version": { "type": "integer", "readOnly": true, "description": "Numeric Operator version. Automatically incremented with each update on the resource, used to ensure integrity when updating the Operator." }, "author": { "$ref": "#/components/schemas/OperatorAuthorEnum" }, "prompt": { "type": "string", "description": "The natural language instructions used by the operator to analyze the conversation.\n\nWithin the prompt, users can reference parameters using the `{{parameters.[param_name]}}` syntax. Parameter values are provided to the Operator by the Intelligence Configuration Rule at runtime.\n\n**Note**: Prompts will only be exposed for Custom Operators (`author` = `SELF`). Twilio-authored Operators (`author` = `TWILIO`) will have their prompts omitted from the API." }, "outputFormat": { "$ref": "#/components/schemas/OperatorOutputFormat" }, "outputSchema": { "$ref": "#/components/schemas/OperatorOutputSchema" }, "trainingExamples": { "type": "array", "description": "An array of example input/output pairs used to illustrate the intended behavior of the Language Operator. These examples help guide the model's understanding of expected input\u2013output relationships and improve consistency during evaluation and testing.\n\n**Note**: Training examples will only be exposed for Custom Operators (`author` = `SELF`). Twilio-authored Operators (`author` = `TWILIO`) will have their training examples omitted from the API.", "items": { "$ref": "#/components/schemas/OperatorTrainingExample" } }, "context": { "$ref": "#/components/schemas/OperatorContext" }, "parameters": { "$ref": "#/components/schemas/OperatorParameters" } } }, "examples": { "fetchOperatorResponse": { "$ref": "#/components/examples/LanguageOperatorExample" } } } }, "headers": { "ETag": { "description": "The version for this resource, used for PUT requests in concert with the IF-MATCH header.", "schema": { "type": "integer", "minimum": 1, "example": 1 } } } }, "404": { "description": "Resource not found", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "429": { "description": "Too Many requests (rate limit exceeded for request originating from public API)", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } }, "headers": { "X-RateLimit-Limit": { "schema": { "type": "string" } }, "X-RateLimit-Remaining": { "schema": { "type": "string" } }, "X-RateLimit-Reset": { "schema": { "type": "string" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } }, "put": { "tags": [ "Operators" ], "summary": "Update an Operator", "operationId": "UpdateOperator", "parameters": [ { "name": "If-Match", "in": "header", "required": false, "description": "Current ETag/version required for conditional update", "schema": { "type": "string" } } ], "requestBody": { "description": "Full replacement of a Language Operator configuration", "required": true, "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/LanguageOperator" }, { "required": [ "displayName", "prompt", "outputFormat" ] } ] }, "examples": { "updateOperatorRequest": { "$ref": "#/components/examples/CreateOrUpdateOperatorRequestExample" } } } } }, "responses": { "200": { "description": "Updated Language Operator resource.", "content": { "application/json": { "schema": { "description": "A Language Operator resource.", "type": "object", "properties": { "id": { "$ref": "#/components/schemas/OperatorTtid" }, "displayName": { "type": "string", "description": "Display name of the Language Operator describing its purpose." }, "description": { "type": "string", "description": "Description of the Language Operator further explaining its purpose." }, "version": { "type": "integer", "readOnly": true, "description": "Numeric Operator version. Automatically incremented with each update on the resource, used to ensure integrity when updating the Operator." }, "author": { "$ref": "#/components/schemas/OperatorAuthorEnum" }, "prompt": { "type": "string", "description": "The natural language instructions used by the operator to analyze the conversation.\n\nWithin the prompt, users can reference parameters using the `{{parameters.[param_name]}}` syntax. Parameter values are provided to the Operator by the Intelligence Configuration Rule at runtime.\n\n**Note**: Prompts will only be exposed for Custom Operators (`author` = `SELF`). Twilio-authored Operators (`author` = `TWILIO`) will have their prompts omitted from the API." }, "outputFormat": { "$ref": "#/components/schemas/OperatorOutputFormat" }, "outputSchema": { "$ref": "#/components/schemas/OperatorOutputSchema" }, "trainingExamples": { "type": "array", "description": "An array of example input/output pairs used to illustrate the intended behavior of the Language Operator. These examples help guide the model's understanding of expected input\u2013output relationships and improve consistency during evaluation and testing.\n\n**Note**: Training examples will only be exposed for Custom Operators (`author` = `SELF`). Twilio-authored Operators (`author` = `TWILIO`) will have their training examples omitted from the API.", "items": { "$ref": "#/components/schemas/OperatorTrainingExample" } }, "context": { "$ref": "#/components/schemas/OperatorContext" }, "parameters": { "$ref": "#/components/schemas/OperatorParameters" } } }, "examples": { "updateOperatorResponse": { "$ref": "#/components/examples/LanguageOperatorExample" } } } }, "headers": { "ETag": { "description": "The version for this resource, used for PUT requests in concert with the IF-MATCH header.", "schema": { "type": "integer", "minimum": 1, "example": 1 } } } }, "404": { "description": "Resource not found", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "412": { "description": "Precondition failed (e.g., ETag mismatch)", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "429": { "description": "Too Many requests (rate limit exceeded for request originating from public API)", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } }, "headers": { "X-RateLimit-Limit": { "schema": { "type": "string" } }, "X-RateLimit-Remaining": { "schema": { "type": "string" } }, "X-RateLimit-Reset": { "schema": { "type": "string" } } } }, "400": { "description": "Bad request", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } }, "delete": { "tags": [ "Operators" ], "summary": "Delete an Operator", "operationId": "DeleteOperator", "responses": { "204": { "description": "Language Operator deleted" }, "404": { "description": "Resource not found", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "429": { "description": "Too Many requests (rate limit exceeded for request originating from public API)", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } }, "headers": { "X-RateLimit-Limit": { "schema": { "type": "string" } }, "X-RateLimit-Remaining": { "schema": { "type": "string" } }, "X-RateLimit-Reset": { "schema": { "type": "string" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } } }, "/v3/ControlPlane/Operators/{id}/Versions": { "x-twilio": { "pathType": "list" }, "parameters": [ { "name": "id", "in": "path", "required": true, "description": "The unique identifier (TTID) of the Language Operator.", "schema": { "type": "string", "nullable": false, "readOnly": true, "pattern": "^intelligence_operator_[0-7][0-9a-z]{25}$", "description": "The unique identifier for the Language Operator. Assigned by Twilio (TTID).", "example": "intelligence_operator_01k6fc25s7epm9qtk8rszbv3q5" } } ], "get": { "tags": [ "Operators" ], "summary": "Retrieve a list of Operator Versions", "description": "Retrieve a paginated list of all versions for a given Language Operator.", "operationId": "ListOperatorVersions", "parameters": [ { "name": "pageSize", "in": "query", "description": "The maximum number of resources to return", "required": false, "schema": { "type": "integer", "minimum": 1, "maximum": 1000, "default": 50 } }, { "name": "pageToken", "in": "query", "description": "Token for pagination", "required": false, "schema": { "type": "string" } } ], "responses": { "200": { "description": "A paginated list of Operator versions.", "content": { "application/json": { "schema": { "type": "object", "description": "Paginated list of Operator versions.", "required": [ "items", "meta" ], "properties": { "items": { "type": "array", "description": "List of Operator versions.", "items": { "type": "object", "required": [ "version", "status", "dateCreated" ], "properties": { "version": { "type": "integer", "description": "The numeric version number." }, "status": { "$ref": "#/components/schemas/OperatorVersionStatus" }, "dateCreated": { "type": "string", "format": "date-time", "description": "Timestamp of when this version was created." }, "dateDeprecated": { "type": "string", "format": "date-time", "description": "Timestamp of when this version was deprecated. Present when status is `DEPRECATED` or `RETIRED`." }, "retirementDate": { "type": "string", "format": "date-time", "description": "Scheduled retirement date for this version. Present when status is `DEPRECATED`." }, "dateRetired": { "type": "string", "format": "date-time", "description": "Timestamp of when this version was retired. Present when status is `RETIRED`." } } } }, "meta": { "type": "object", "properties": { "key": { "description": "A key, sibling to the `meta` object that holds the actual list of resources", "type": "string" }, "pageSize": { "description": "The actual number of resources returned in the response", "type": "integer" }, "previousToken": { "type": "string" }, "nextToken": { "type": "string" } }, "required": [ "key", "pageSize" ] } } }, "examples": { "listOperatorVersionsResponse": { "$ref": "#/components/examples/ListOperatorVersionsResponseExample" } } } } }, "404": { "description": "Resource not found", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "429": { "description": "Too Many requests (rate limit exceeded for request originating from public API)", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } }, "headers": { "X-RateLimit-Limit": { "schema": { "type": "string" } }, "X-RateLimit-Remaining": { "schema": { "type": "string" } }, "X-RateLimit-Reset": { "schema": { "type": "string" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } } }, "/v3/ControlPlane/Operators/{id}/Versions/{version}": { "x-twilio": { "pathType": "instance" }, "parameters": [ { "name": "id", "in": "path", "required": true, "description": "The unique identifier (TTID) of the Language Operator.", "schema": { "type": "string", "nullable": false, "readOnly": true, "pattern": "^intelligence_operator_[0-7][0-9a-z]{25}$", "description": "The unique identifier for the Language Operator. Assigned by Twilio (TTID).", "example": "intelligence_operator_01k6fc25s7epm9qtk8rszbv3q5" } }, { "name": "version", "in": "path", "required": true, "description": "The numeric version number of the Language Operator.", "schema": { "type": "integer" } } ], "get": { "tags": [ "Operators" ], "summary": "Retrieve a specific Operator Version", "operationId": "FetchOperatorVersion", "responses": { "200": { "description": "A specific Language Operator version.", "content": { "application/json": { "schema": { "description": "Full detail of a specific Language Operator version.", "type": "object", "properties": { "id": { "$ref": "#/components/schemas/OperatorTtid" }, "displayName": { "type": "string", "description": "Display name of the Language Operator describing its purpose." }, "description": { "type": "string", "description": "Description of the Language Operator further explaining its purpose." }, "version": { "type": "integer", "readOnly": true, "description": "Numeric Operator version. Automatically incremented with each update on the resource, used to ensure integrity when updating the Operator." }, "author": { "$ref": "#/components/schemas/OperatorAuthorEnum" }, "prompt": { "type": "string", "description": "The natural language instructions used by the operator to analyze the conversation.\n\nWithin the prompt, users can reference parameters using the `{{parameters.[param_name]}}` syntax. Parameter values are provided to the Operator by the Intelligence Configuration Rule at runtime.\n\n**Note**: Prompts will only be exposed for Custom Operators (`author` = `SELF`). Twilio-authored Operators (`author` = `TWILIO`) will have their prompts omitted from the API." }, "outputFormat": { "$ref": "#/components/schemas/OperatorOutputFormat" }, "outputSchema": { "$ref": "#/components/schemas/OperatorOutputSchema" }, "trainingExamples": { "type": "array", "description": "An array of example input/output pairs used to illustrate the intended behavior of the Language Operator. These examples help guide the model's understanding of expected input\u2013output relationships and improve consistency during evaluation and testing.\n\n**Note**: Training examples will only be exposed for Custom Operators (`author` = `SELF`). Twilio-authored Operators (`author` = `TWILIO`) will have their training examples omitted from the API.", "items": { "$ref": "#/components/schemas/OperatorTrainingExample" } }, "context": { "$ref": "#/components/schemas/OperatorContext" }, "parameters": { "$ref": "#/components/schemas/OperatorParameters" }, "status": { "$ref": "#/components/schemas/OperatorVersionStatus" }, "dateCreated": { "type": "string", "format": "date-time", "description": "Timestamp of when this version was created." } }, "required": [ "dateCreated", "status" ] }, "examples": { "fetchOperatorVersionResponse": { "$ref": "#/components/examples/LanguageOperatorVersionExample" } } } } }, "404": { "description": "Resource not found", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "429": { "description": "Too Many requests (rate limit exceeded for request originating from public API)", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } }, "headers": { "X-RateLimit-Limit": { "schema": { "type": "string" } }, "X-RateLimit-Remaining": { "schema": { "type": "string" } }, "X-RateLimit-Reset": { "schema": { "type": "string" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } } }, "/v3/OperatorResults": { "x-twilio": { "pathType": "list" }, "get": { "tags": [ "OperatorResults" ], "security": [ { "basic_apikey_or_accountsid": [] } ], "summary": "Retrieve a list of OperatorResults", "operationId": "ListOperatorResults", "parameters": [ { "name": "conversationId", "in": "query", "required": false, "schema": { "type": "string", "nullable": false, "pattern": "^conv_conversation_[0-7][0-9a-z]{25}$", "description": "The `id` of the Conversation attached to the Operator Result.", "example": "conv_conversation_01k1etk2y5f1y9fpe2epfdtvv2" }, "description": "Filter Operator Results by attached Conversation `id`." }, { "name": "intelligenceConfigurationId", "in": "query", "required": false, "schema": { "type": "string", "nullable": false, "pattern": "^intelligence_configuration_[0-7][0-9a-z]{25}$", "description": "Unique identifier for a Intelligence Configuration that generated the Operator Result. Assigned by Twilio (TTID).", "example": "intelligence_configuration_01k6fc25s7epm9qtk8rszbv3q5" }, "description": "Filter Operator Results by Intelligence Configuration `id` used to generate them." }, { "name": "operatorId", "in": "query", "required": false, "schema": { "type": "string", "nullable": false, "readOnly": true, "pattern": "^intelligence_operator_[0-7][0-9a-z]{25}$", "description": "The unique identifier for the Language Operator. Assigned by Twilio (TTID).", "example": "intelligence_operator_01k6fc25s7epm9qtk8rszbv3q5" }, "description": "Filter Operator Results by Language Operator `id`." }, { "name": "pageSize", "in": "query", "description": "The maximum number of resources to return", "required": false, "schema": { "type": "integer", "minimum": 1, "maximum": 1000, "default": 50 } }, { "name": "pageToken", "in": "query", "description": "Token for pagination", "required": false, "schema": { "type": "string" } } ], "responses": { "200": { "description": "An array of Operator Results.", "content": { "application/json": { "schema": { "type": "object", "required": [ "items", "meta" ], "properties": { "items": { "type": "array", "description": "List of Operator Results matching the query.", "items": { "$ref": "#/components/schemas/OperatorResultsResponseV1" } }, "meta": { "type": "object", "properties": { "key": { "description": "A key, sibling to the `meta` object that holds the actual list of resources", "type": "string" }, "pageSize": { "description": "The actual number of resources returned in the response", "type": "integer" }, "previousToken": { "type": "string" }, "nextToken": { "type": "string" } }, "required": [ "key", "pageSize" ] } } }, "examples": { "operatorResultList": { "$ref": "#/components/examples/OperatorResultListExample" } } } } }, "400": { "description": "Bad request", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "429": { "description": "Too Many requests (rate limit exceeded for request originating from public API)", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } }, "headers": { "X-RateLimit-Limit": { "schema": { "type": "string" } }, "X-RateLimit-Remaining": { "schema": { "type": "string" } }, "X-RateLimit-Reset": { "schema": { "type": "string" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } } }, "/v3/OperatorResults/{operatorResultId}": { "x-twilio": { "pathType": "instance" }, "parameters": [ { "name": "operatorResultId", "in": "path", "required": true, "description": "Operator Result id (TTID)", "schema": { "type": "string", "nullable": false, "pattern": "^intelligence_operatorresult_[0-7][0-9a-z]{25}$", "description": "A unique identifier for the Operator Result. Assigned by Twilio (TTID).", "example": "intelligence_operatorresult_01k6fc25s7epm9qtk8rszbv3q5" } } ], "get": { "tags": [ "OperatorResults" ], "security": [ { "basic_apikey_or_accountsid": [] } ], "summary": "Retrieve an OperatorResult", "operationId": "FetchOperatorResult", "responses": { "200": { "description": "Operator Result object.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/OperatorResultsResponseV1" }, "examples": { "operatorResult": { "$ref": "#/components/examples/OperatorResultExample" } } } } }, "404": { "description": "Resource not found", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "429": { "description": "Too Many requests (rate limit exceeded for request originating from public API)", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } }, "headers": { "X-RateLimit-Limit": { "schema": { "type": "string" } }, "X-RateLimit-Remaining": { "schema": { "type": "string" } }, "X-RateLimit-Reset": { "schema": { "type": "string" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } }, "delete": { "tags": [ "OperatorResults" ], "summary": "Delete an OperatorResult", "operationId": "DeleteOperatorResult", "responses": { "204": { "description": "Operator result deleted successfully" }, "404": { "description": "Resource not found", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "429": { "description": "Too Many requests (rate limit exceeded for request originating from public API)", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } }, "headers": { "X-RateLimit-Limit": { "schema": { "type": "string" } }, "X-RateLimit-Remaining": { "schema": { "type": "string" } }, "X-RateLimit-Reset": { "schema": { "type": "string" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } } }, "/v3/Conversations": { "x-twilio": { "pathType": "list" }, "description": "Intelligence Conversations resource to retrieve conversations that have been processed by an Intelligence Configuration.", "get": { "description": "Retrieve a list of Conversations processed by an Intelligence Configuration.", "summary": "Retrieve a list of Conversations", "operationId": "ListConversations", "tags": [ "Conversations" ], "parameters": [ { "name": "pageSize", "in": "query", "description": "The maximum number of resources to return", "required": false, "schema": { "type": "integer", "minimum": 1, "maximum": 1000, "default": 50 } }, { "name": "pageToken", "in": "query", "description": "Token for pagination", "required": false, "schema": { "type": "string" } }, { "name": "createdAtBefore", "in": "query", "description": "Filter by Conversations created before this timestamp.", "required": false, "schema": { "type": "string", "format": "date-time" } }, { "name": "createdAtAfter", "in": "query", "description": "Filter by Conversations created after this timestamp.", "required": false, "schema": { "type": "string", "format": "date-time" } }, { "name": "status", "in": "query", "description": "Filter by Conversation status.", "required": false, "schema": { "type": "string", "description": "The status of the Conversation.", "enum": [ "ACTIVE", "INACTIVE", "CLOSED" ] } }, { "name": "channelId", "in": "query", "description": "Filters Conversations by the underlying channel resource ID, such as a Call ID or Message ID.", "required": false, "schema": { "type": "string" } }, { "name": "channels", "in": "query", "description": "Filters Conversations that include one or more of the specified communication channels (`OR` match).", "required": false, "schema": { "type": "array", "items": { "type": "string", "description": "Communication channel type.", "enum": [ "VOICE", "SMS", "RCS", "EMAIL", "WHATSAPP", "CHAT", "API", "SYSTEM" ] } } }, { "name": "conversationConfigurationId", "in": "query", "description": "The configuration `id` used to generate the Conversation.", "required": false, "schema": { "type": "string", "nullable": false, "description": "The `id` of the Configuration for a Conversation.", "example": "conv_configuration_00000000000000000000000000" } }, { "name": "intelligenceConfigurationIds", "in": "query", "description": "Filters Conversations activated by one or more of the specified Intelligence Configuration IDs (`OR` match).", "required": false, "schema": { "type": "array", "items": { "type": "string", "nullable": false, "pattern": "^intelligence_configuration_[0-7][0-9a-z]{25}$", "description": "Unique identifier for a Intelligence Configuration that generated the Operator Result. Assigned by Twilio (TTID).", "example": "intelligence_configuration_01k6fc25s7epm9qtk8rszbv3q5" } } }, { "name": "operatorIds", "in": "query", "description": "Filters Conversations to those where at least one of the specified Language Operators was executed (`OR` match).", "required": false, "schema": { "type": "array", "items": { "type": "string", "nullable": false, "readOnly": true, "pattern": "^intelligence_operator_[0-7][0-9a-z]{25}$", "description": "The unique identifier for the Language Operator. Assigned by Twilio (TTID).", "example": "intelligence_operator_01k6fc25s7epm9qtk8rszbv3q5" } } } ], "responses": { "200": { "description": "An array of Conversations.", "content": { "application/json": { "schema": { "type": "object", "required": [ "items", "meta" ], "properties": { "items": { "type": "array", "items": { "$ref": "#/components/schemas/ConversationListItem" }, "description": "List of conversations." }, "meta": { "type": "object", "properties": { "key": { "description": "A key, sibling to the `meta` object that holds the actual list of resources", "type": "string" }, "pageSize": { "description": "The actual number of resources returned in the response", "type": "integer" }, "previousToken": { "type": "string" }, "nextToken": { "type": "string" } }, "required": [ "key", "pageSize" ] } } }, "examples": { "conversationList": { "$ref": "#/components/examples/ConversationListExample" } } } } }, "400": { "description": "Bad request", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "401": { "description": "Unauthorized request", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "403": { "description": "Forbidden request", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "404": { "description": "Resource not found", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "429": { "description": "Too Many requests (rate limit exceeded for request originating from public API)", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } }, "headers": { "X-RateLimit-Limit": { "schema": { "type": "string" } }, "X-RateLimit-Remaining": { "schema": { "type": "string" } }, "X-RateLimit-Reset": { "schema": { "type": "string" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } } }, "/v3/Conversations/{id}": { "x-twilio": { "pathType": "instance" }, "description": "Intelligence Conversation resource to retrieve a specific conversation by ID", "get": { "summary": "Retrieve a Conversation", "operationId": "FetchConversation", "tags": [ "Conversations" ], "parameters": [ { "name": "id", "in": "path", "description": "The unique identifier of the conversation.", "required": true, "schema": { "type": "string", "nullable": false, "pattern": "^conv_conversation_[0-7][0-9a-z]{25}$", "description": "The `id` of the Conversation attached to the Operator Result.", "example": "conv_conversation_01k1etk2y5f1y9fpe2epfdtvv2" } } ], "responses": { "200": { "description": "Conversation object.", "content": { "application/json": { "schema": { "type": "object", "required": [ "id", "accountId", "name", "status", "createdAt", "updatedAt", "intelligenceConfigurationIds", "conversationConfigurationId", "channels", "channelIds", "participants", "communications", "operatorResultIds" ], "properties": { "id": { "$ref": "#/components/schemas/ConversationTtid" }, "accountId": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^AC[0-9a-fA-F]{32}$", "nullable": true, "description": "The ID of the account that owns the Conversation." }, "name": { "type": "string", "nullable": true, "description": "Display name of the Conversation." }, "status": { "$ref": "#/components/schemas/ConversationStatus" }, "createdAt": { "type": "string", "format": "date-time", "description": "Timestamp for when the Conversation was created." }, "updatedAt": { "type": "string", "format": "date-time", "description": "Timestamp for when the Conversation was last updated." }, "intelligenceConfigurationIds": { "type": "array", "description": "The Intelligence Configuration(s) associated with the Conversation.", "items": { "$ref": "#/components/schemas/IntelligenceConfigurationTtid" } }, "conversationConfigurationId": { "$ref": "#/components/schemas/ConfigurationTtid" }, "channels": { "type": "array", "description": "The communication channel(s) included in the Conversation.", "items": { "$ref": "#/components/schemas/Channel" } }, "channelIds": { "type": "array", "description": "The underlying channel resource `id`s associated with this Conversation, such as a Call ID or Message ID.", "items": { "type": "string" } }, "participants": { "type": "array", "description": "Metadata for Participants of the Conversation.", "items": { "$ref": "#/components/schemas/Participant" } }, "communications": { "type": "array", "description": "Metadata for the Communications that make up the Conversation.", "items": { "$ref": "#/components/schemas/Communication" } }, "operatorResultIds": { "type": "array", "description": "List of Operator Result IDs generated from this Conversation.", "items": { "type": "string" } } } }, "examples": { "conversation": { "$ref": "#/components/examples/ConversationExample" } } } } }, "400": { "description": "Bad request", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "401": { "description": "Unauthorized request", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "403": { "description": "Forbidden request", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "404": { "description": "Resource not found", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } }, "429": { "description": "Too Many requests (rate limit exceeded for request originating from public API)", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } }, "headers": { "X-RateLimit-Limit": { "schema": { "type": "string" } }, "X-RateLimit-Remaining": { "schema": { "type": "string" } }, "X-RateLimit-Reset": { "schema": { "type": "string" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "type": "object", "properties": { "code": { "description": "Twilio-specific error code", "type": "integer", "format": "int32" }, "message": { "description": "A human readable error message", "type": "string" }, "httpStatusCode": { "description": "HTTP response status code", "type": "integer", "format": "int32" }, "userError": { "description": "Whether the error is a user error (true) or a system error (false)", "type": "boolean" }, "params": { "description": "A map of parameters related to the error, for example, a `params.twilioErrorCodeUrl` might hold a URL or link to additional information", "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "code", "message", "httpStatusCode" ] } } } } } } } } }