The OperatorAttachment resource represents the link between a specific Prebuilt or Custom Operator and a specific Voice Intelligence Service. When an Operator is attached to a Service, it is available for use in that Service.
The unique SID identifier of the Service.
^GA[0-9a-fA-F]{32}$
Min length: 34
Max length: 34
The unique SID identifier of the Operator.
^LY[0-9a-fA-F]{32}$
Min length: 34
Max length: 34
The URL of this resource.
POST https://intelligence.twilio.com/v2/Services/{ServiceSid}/Operators/{OperatorSid}
This endpoint attaches an Operator to a Service.
The unique SID identifier of the Service.
^GA[0-9a-fA-F]{32}$
Min length: 34
Max length: 34
The unique SID identifier of the Operator. Allows both Custom and Pre-built Operators.
^LY[0-9a-fA-F]{32}$
Min length: 34
Max length: 34
1// Download the helper library from https://www.twilio.com/docs/node/install2const twilio = require("twilio"); // Or, for ESM: import twilio from "twilio";34// Find your Account SID and Auth Token at twilio.com/console5// and set the environment variables. See http://twil.io/secure6const accountSid = process.env.TWILIO_ACCOUNT_SID;7const authToken = process.env.TWILIO_AUTH_TOKEN;8const client = twilio(accountSid, authToken);910async function createOperatorAttachment() {11const operatorAttachment = await client.intelligence.v212.operatorAttachment(13"GAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",14"LYaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"15)16.create();1718console.log(operatorAttachment.serviceSid);19}2021createOperatorAttachment();
1{2"operator_sid": "LYaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",3"service_sid": "GAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",4"url": "https://intelligence.twilio.com/v2/Services/GAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Operators/LYaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"5}
DELETE https://intelligence.twilio.com/v2/Services/{ServiceSid}/Operators/{OperatorSid}
This endpoint detaches an Operator from a Service.
The unique SID identifier of the Service.
^GA[0-9a-fA-F]{32}$
Min length: 34
Max length: 34
The unique SID identifier of the Operator. Allows both Custom and Pre-built Operators.
^LY[0-9a-fA-F]{32}$
Min length: 34
Max length: 34
1// Download the helper library from https://www.twilio.com/docs/node/install2const twilio = require("twilio"); // Or, for ESM: import twilio from "twilio";34// Find your Account SID and Auth Token at twilio.com/console5// and set the environment variables. See http://twil.io/secure6const accountSid = process.env.TWILIO_ACCOUNT_SID;7const authToken = process.env.TWILIO_AUTH_TOKEN;8const client = twilio(accountSid, authToken);910async function deleteOperatorAttachment() {11await client.intelligence.v212.operatorAttachment(13"GAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",14"LYaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"15)16.remove();17}1819deleteOperatorAttachment();