Skip to contentSkip to navigationSkip to topbar
Rate this page:
On this page

Operator Resource


The Operator resource represents a Prebuilt or Custom Operator.


Operator Properties

operator-properties page anchor
Property nameTypePIIDescription
account_sidSID<AC>
Not PII

The unique SID identifier of the Account the Operator belongs to.

Pattern: ^AC[0-9a-fA-F]{32}$Min length: 34Max length: 34

sidSID<LY>

A 34 character string that uniquely identifies this Operator.

Pattern: ^LY[0-9a-fA-F]{32}$Min length: 34Max length: 34

friendly_namestring

A human-readable name of this resource, up to 64 characters.


descriptionstring

A human-readable description of this resource, longer than the friendly name.


authorstring

The creator of the Operator. Either Twilio or the creating Account.


operator_typestring

Operator Type for this Operator. References an existing Operator Type resource.


versioninteger

Numeric Operator version. Incremented with each update on the resource, used to ensure integrity when updating the Operator.


availabilityenum<string>

Operator availability status. Possible values: internal, beta, public, retired.

Possible values:
internalbetapublicretired

configobject

Operator configuration, following the schema defined by the Operator Type. Only available on Custom Operators created by the Account.


date_createdstring<date-time>

The date that this Operator was created, given in ISO 8601 format.


date_updatedstring<date-time>

The date that this Operator was updated, given in ISO 8601 format.


urlstring<uri>

The URL of this resource.


GET https://intelligence.twilio.com/v2/Operators/{Sid}

This endpoint retrieves the details of a Prebuilt or Custom Operator using its SID.

Path parameters

path-parameters page anchor
Property nameTypeRequiredPIIDescription
SidSID<LY>required

A 34 character string that uniquely identifies this Operator.

Pattern: ^LY[0-9a-fA-F]{32}$Min length: 34Max length: 34

Fetch an Operator

fetch-an-operator-1 page anchor
Node.js
Python
C#
Java
Go
PHP
Ruby
twilio-cli
curl

_14
// Download the helper library from https://www.twilio.com/docs/node/install
_14
import twilio from "twilio";
_14
_14
// Find your Account SID and Auth Token at twilio.com/console
_14
// and set the environment variables. See http://twil.io/secure
_14
const accountSid = process.env.TWILIO_ACCOUNT_SID;
_14
const authToken = process.env.TWILIO_AUTH_TOKEN;
_14
const client = twilio(accountSid, authToken);
_14
_14
const operator = await client.intelligence.v2
_14
.operators("LYaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")
_14
.fetch();
_14
_14
console.log(operator.accountSid);

Output

_18
{
_18
"account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
_18
"sid": "LYaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
_18
"friendly_name": "My New Operator",
_18
"description": "New Operator",
_18
"author": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
_18
"operator_type": "operator-type-name",
_18
"version": 1,
_18
"availability": "public",
_18
"config": {
_18
"configuration": {
_18
"field": "value"
_18
}
_18
},
_18
"date_created": "2010-08-31T20:36:28Z",
_18
"date_updated": "2010-08-31T20:36:28Z",
_18
"url": "https://intelligence.twilio.com/v2/Operators/LYaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
_18
}


GET https://intelligence.twilio.com/v2/Operators

This endpoint lists all available Prebuilt and Custom Operators for an Account, with optional filtering.

Property nameTypeRequiredPIIDescription
Availabilityenum<string>Optional

Returns Operators with the provided availability type. Possible values: internal, beta, public, retired.

Possible values:
internalbetapublicretired

LanguageCodestringOptional

Returns Operators that support the provided language code.


PageSizeintegerOptional

How many resources to return in each list page. The default is 50, and the maximum is 1000.

Minimum: 1Maximum: 1000

PageintegerOptional

The page index. This value is simply for client state.

Minimum: 0

PageTokenstringOptional

The page token. This is provided by the API.

Node.js
Python
C#
Java
Go
PHP
Ruby
twilio-cli
curl

_12
// Download the helper library from https://www.twilio.com/docs/node/install
_12
import twilio from "twilio";
_12
_12
// Find your Account SID and Auth Token at twilio.com/console
_12
// and set the environment variables. See http://twil.io/secure
_12
const accountSid = process.env.TWILIO_ACCOUNT_SID;
_12
const authToken = process.env.TWILIO_AUTH_TOKEN;
_12
const client = twilio(accountSid, authToken);
_12
_12
const operators = await client.intelligence.v2.operators.list({ limit: 20 });
_12
_12
operators.forEach((o) => console.log(o.accountSid));

Output

_31
{
_31
"operators": [
_31
{
_31
"account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
_31
"sid": "LYaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
_31
"friendly_name": "My New Operator",
_31
"description": "New Operator",
_31
"author": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
_31
"operator_type": "operator-type-name",
_31
"version": 1,
_31
"availability": "public",
_31
"config": {
_31
"configuration": {
_31
"field": "value"
_31
}
_31
},
_31
"date_created": "2010-08-31T20:36:28Z",
_31
"date_updated": "2010-08-31T20:36:28Z",
_31
"url": "https://intelligence.twilio.com/v2/Operators/LYaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
_31
}
_31
],
_31
"meta": {
_31
"first_page_url": "https://intelligence.twilio.com/v2/Operators?LanguageCode=en&Availability=public&PageSize=50&Page=0",
_31
"key": "operators",
_31
"next_page_url": null,
_31
"page": 0,
_31
"page_size": 50,
_31
"previous_page_url": null,
_31
"url": "https://intelligence.twilio.com/v2/Operators?LanguageCode=en&Availability=public&PageSize=50&Page=0"
_31
}
_31
}


Rate this page: