Exotel
App · 17 actions
Connect calls and send SMS through Exotel, read call and SMS records and the account balance, look up Indian numbers, list ExoPhones, manage contact center users and pause or resume campaigns.
Actions
| Action | What it does |
|---|---|
| Connect two numbers | Call a number (such as an agent's) and, once they answer, connect them to a customer, showing your ExoPhone as the caller ID. |
| Create user | Add a user to the contact center, with the phone they take calls on. |
| Delete user | Remove a user from the contact center. |
| Get balance | Get the account's wallet balance, currency and pricing plan. |
| Get call | Get a call's status, numbers, times, duration, price and recording, with each leg's details. |
| Get campaign | Get a campaign with its settings and current statistics. |
| Get ExoPhone | Get an ExoPhone's number, capabilities and the flow it runs. |
| Get SMS | Get a text message's delivery status and price. |
| Get user | Get a contact center user and their devices. |
| List calls | List calls, newest first, filtered by date, status, direction or number. |
| List campaigns | List outbound call campaigns, by name or status. |
| List ExoPhones | List the account's ExoPhones (virtual numbers) and what each can do. |
| List users | List the contact center's users and, if asked, their devices. |
| Look up Indian number | Get an Indian phone number's operator, telecom circle, type (mobile or landline) and Do Not Disturb status. |
| Pause, resume or end campaign | Pause or resume a campaign, complete a paused one, or archive a completed one. |
| Send SMS | Send a text message from an ExoPhone or approved sender ID. |
| Update user | Change a user's name, or add their email address if they have none. |
Connect two numbers
Call a number (such as an agent's) and, once they answer, connect them to a customer, showing your ExoPhone as the caller ID.
Inputs
- Call first
from_numbertextRequired - The number called first, such as your agent's, with the country code.
- Then connect to
totextRequired - The customer's number, with the country code.
- Caller
caller_idtextRequired - The ExoPhone to call from.
- Record
recordtrue/false - Record the conversation.
- Time limit
time_limitnumber - The longest the call may last, in seconds (up to 14400).From 1 to 14400.
- Ring for
time_outnumber - How long each number may ring, in seconds.At least 1.
- Reference
custom_fieldtext - Your own reference for the call (up to 128 characters).
- Status callback
status_callbacktext - An address Exotel posts the call's outcome to.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"AccountSid": "example",
"AnsweredBy": "example",
"DateCreated": "example",
"DateUpdated": "example",
"Details": {
"ConversationDuration": 1,
"Leg1Status": "example",
"Leg2Status": "example",
"Legs": [
{}
]
},
"Direction": "example",
"Duration": "example",
"EndTime": "example",
"From": "example",
"ParentCallSid": "example",
"PhoneNumberSid": "example",
"Price": "example",
"RecordingUrl": "example",
"Sid": "example",
"StartTime": "example",
"Status": "example",
"To": "example"
}
}Create user
Add a user to the contact center, with the phone they take calls on.
Inputs
- First name
first_nametextRequired - Their first name, 3 to 20 characters.
- Last name
last_nametextRequired - Their last name, 3 to 20 characters.
- Email
emailtext - Their email address.
- Phone
device_contact_uritext - The phone number they take calls on, with the country code.
- Phone name
device_nametext - A name for that phone.
- Role
roletext - What they can do. Defaults to user.One of:
user,supervisor,admin.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"date_created": "example",
"date_updated": "example",
"devices": [
{
"available": true,
"contact_uri": "example",
"id": 1,
"name": "example",
"status": "example",
"type": "example",
"verified": true
}
],
"email": "example",
"email_verified": true,
"first_name": "example",
"id": "example",
"last_login": "example",
"last_name": "example",
"role": "example"
}
}Delete user
Remove a user from the contact center.
Inputs
- User
exotel_user_idtextRequired - The user's ID, from List users.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"deleted": true,
"user_id": "example"
}
}Get balance
Get the account's wallet balance, currency and pricing plan.
Inputs
None.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"AccountSid": "example",
"BalanceData": {
"Balance": "example",
"Currency": "example",
"DateUpdated": "example",
"PricingPlan": "example"
}
}
}Get call
Get a call's status, numbers, times, duration, price and recording, with each leg's details.
Inputs
- Call SID
call_sidtextRequired - The call's SID.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"AccountSid": "example",
"AnsweredBy": "example",
"DateCreated": "example",
"DateUpdated": "example",
"Details": {
"ConversationDuration": 1,
"Leg1Status": "example",
"Leg2Status": "example",
"Legs": [
{}
]
},
"Direction": "example",
"Duration": "example",
"EndTime": "example",
"From": "example",
"ParentCallSid": "example",
"PhoneNumberSid": "example",
"Price": "example",
"RecordingUrl": "example",
"Sid": "example",
"StartTime": "example",
"Status": "example",
"To": "example"
}
}Get campaign
Get a campaign with its settings and current statistics.
Inputs
- Campaign
campaign_idtextRequired - The campaign's ID, from List campaigns.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"campaign": {}
}
}Get ExoPhone
Get an ExoPhone's number, capabilities and the flow it runs.
Inputs
- ExoPhone
exophone_sidtextRequired - The ExoPhone.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"capabilities": {
"sms": true,
"voice": true
},
"country": "example",
"friendly_name": "example",
"phone_number": "example",
"region": "example",
"sid": "example",
"sms_url": "example",
"voice_url": "example"
}
}Get SMS
Get a text message's delivery status and price.
Inputs
- SMS SID
sms_sidtextRequired - The message's SID.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"AccountSid": "example",
"Body": "example",
"DateCreated": "example",
"DateSent": "example",
"DateUpdated": "example",
"DetailedStatus": "example",
"DetailedStatusCode": "example",
"Direction": "example",
"From": "example",
"Price": "example",
"Sid": "example",
"SmsUnits": 1,
"Status": "example",
"To": "example",
"Uri": "example"
}
}Get user
Get a contact center user and their devices.
Inputs
- User
exotel_user_idtextRequired - The user's ID, from List users.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"date_created": "example",
"date_updated": "example",
"devices": [
{
"available": true,
"contact_uri": "example",
"id": 1,
"name": "example",
"status": "example",
"type": "example",
"verified": true
}
],
"email": "example",
"email_verified": true,
"first_name": "example",
"id": "example",
"last_login": "example",
"last_name": "example",
"role": "example"
}
}List calls
List calls, newest first, filtered by date, status, direction or number. Exotel keeps six months, up to a month per request.
Inputs
- From
created_fromdate and time - Only calls made on or after this time.
- To
created_todate and time - Only calls made on or before this time.
- Status
statustext - Only calls that ended this way.One of:
completed,failed,busy,no-answer(Not answered). - Direction
directiontext - Only incoming or outgoing calls.One of:
inbound,outbound-dial(Outbound (dialled)),outbound-api(Outbound (API)). - To number
totext - Only calls to these numbers (up to 5, separated by commas).
- From number
from_numbertext - Only calls from these numbers (up to 5, separated by commas).
- ExoPhone
exophonetext - Only calls on these ExoPhones (up to 5, separated by commas).
- Page size
page_sizenumber - How many per page, up to 100. Exotel's default is 50.From 1 to 100.
- Order
sorttext - Newest or oldest first. Newest unless chosen.One of:
DateCreated:desc(Newest first),DateCreated:asc(Oldest first). - Next page
aftertext - The next_page from an earlier page.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"Calls": [
{
"AccountSid": "example",
"AnsweredBy": "example",
"DateCreated": "example",
"DateUpdated": "example",
"Details": {
"ConversationDuration": 1,
"Leg1Status": "example",
"Leg2Status": "example",
"Legs": [
{}
]
},
"Direction": "example",
"Duration": "example",
"EndTime": "example",
"From": "example",
"ParentCallSid": "example",
"PhoneNumberSid": "example",
"Price": "example",
"RecordingUrl": "example",
"Sid": "example",
"StartTime": "example",
"Status": "example",
"To": "example"
}
],
"Metadata": {
"FirstPageUri": "example",
"NextPageUri": "example",
"PageSize": 1,
"PrevPageUri": "example",
"Total": 1
},
"next_page": "example"
}
}List campaigns
List outbound call campaigns, by name or status.
Inputs
- Name
nametext - Only campaigns with this name.
- Statuses
statustext - Only campaigns in these statuses, separated by commas, such as InProgress,Paused.
- Skip
offsetnumber - How many to skip.At least 0.
- How many
limitnumber - How many to return, up to 500. Exotel's default is 20.From 1 to 500.
- Order
sort_bytext - How to sort, such as date_created:desc.One of:
date_created:asc(Date created:asc),date_created:desc(Date created:desc),name:asc,name:desc.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"items": [
{}
],
"metadata": {
"count": 1,
"limit": 1,
"offset": 1,
"total": 1
}
}
}List ExoPhones
List the account's ExoPhones (virtual numbers) and what each can do.
Inputs
None.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"incoming_phone_numbers": [
{
"capabilities": {
"sms": true,
"voice": true
},
"country": "example",
"friendly_name": "example",
"phone_number": "example",
"region": "example",
"sid": "example",
"sms_url": "example",
"voice_url": "example"
}
],
"page": 1,
"page_size": 1
}
}List users
List the contact center's users and, if asked, their devices.
Inputs
- Email
emailtext - Only the user with this email address.
- Include
fieldstext - Extra details to include, separated by commas: devices, active_call, last_login.
- Skip
offsetnumber - How many to skip.At least 0.
- How many
limitnumber - How many to return, up to 50. Exotel's default is 20.From 1 to 50.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"items": [
{
"date_created": "example",
"date_updated": "example",
"devices": [
{
"available": true,
"contact_uri": "example",
"id": 1,
"name": "example",
"status": "example",
"type": "example",
"verified": true
}
],
"email": "example",
"email_verified": true,
"first_name": "example",
"id": "example",
"last_login": "example",
"last_name": "example",
"role": "example"
}
],
"metadata": {
"count": 1,
"limit": 1,
"offset": 1,
"total": 1
}
}
}Look up Indian number
Get an Indian phone number's operator, telecom circle, type (mobile or landline) and Do Not Disturb status.
Inputs
- Phone number
phone_numbertextRequired - The Indian phone number.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"Circle": "example",
"CircleName": "example",
"DND": "example",
"Operator": "example",
"OperatorName": "example",
"PhoneNumber": "example",
"Type": "example"
}
}Pause, resume or end campaign
Pause or resume a campaign, complete a paused one, or archive a completed one.
Inputs
- Campaign
campaign_idtextRequired - The campaign's ID, from List campaigns.
- Action
campaign_actiontextRequired - What to do with it.One of:
pause,resume,complete,archive.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"campaign": {}
}
}Send SMS
Send a text message from an ExoPhone or approved sender ID. In India, DLT registration is required.
Inputs
- From
from_numbertextRequired - The ExoPhone or approved sender ID to send from.
- To
totextRequired - The mobile number to send to, with the country code.
- Message
bodytextRequired - The message, up to 2,000 characters.
- DLT entity ID
dlt_entity_idtext - Your DLT entity ID (required for numbers in India).
- DLT template ID
dlt_template_idtext - The DLT-approved template's ID.
- Type
sms_typetext - What kind of message it is.One of:
transactional(Transactional (OTP, service)),transactional_opt_in(Transactional, opted in),promotional. - Encoding
encodingtext - Plain or Unicode. Detected when left empty.One of:
plain,unicode. - Reference
custom_fieldtext - Your own reference, such as an order ID.
- Status callback
status_callbacktext - An address Exotel posts the delivery status to.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"AccountSid": "example",
"Body": "example",
"DateCreated": "example",
"DateSent": "example",
"DateUpdated": "example",
"DetailedStatus": "example",
"DetailedStatusCode": "example",
"Direction": "example",
"From": "example",
"Price": "example",
"Sid": "example",
"SmsUnits": 1,
"Status": "example",
"To": "example",
"Uri": "example"
}
}Update user
Change a user's name, or add their email address if they have none.
Inputs
- User
exotel_user_idtextRequired - The user's ID, from List users.
- First name
first_nametext - Their first name, 3 to 20 characters.
- Last name
last_nametext - Their last name, 3 to 20 characters.
- Email
emailtext - Their email address, if they have none yet.
Outputs
dataobject- The response from Exotel.
Example output
{
"data": {
"date_created": "example",
"date_updated": "example",
"devices": [
{
"available": true,
"contact_uri": "example",
"id": 1,
"name": "example",
"status": "example",
"type": "example",
"verified": true
}
],
"email": "example",
"email_verified": true,
"first_name": "example",
"id": "example",
"last_login": "example",
"last_name": "example",
"role": "example"
}
}