02-07-2013 - UPDATE on Say verb - using alice, the latest Twilio voice engine, our app can speak in 26 dialects.

conference - api conference

The Dial verb’s Conference noun allows you to connect to a conference room.

sample code:

<tf:client method="POST" url="client.twiml" value="flower" />
Table 1. client tag attributes
attr. name attr. descr. required type

muted

Allowed Values:true,false. Default Value:false

false

java.lang.String

beep

Allowed Values:true, false. Default Value:true

false

java.lang.String

startConferenceOnEnter

Allowed Values:true, false. Default Value:true

false

java.lang.String

endConferenceOnExit

Allowed Values:true, false. Default Value:false

false

java.lang.String

waitUrl

Allowed Values:TwiML url, empty string. Default Value:default Twilio hold music

false

java.lang.String

waitMethod

Allowed Values:GET or POST. Default Value:POST

false

java.lang.String

maxParticipants

Allowed Values:positive integer <= 40. Default Value:40

false

java.lang.String

value

Example:moderated-conference-room or Room 1234. You can wrap inside open and close tag.

false

java.lang.String

dial - api dial

The Dial verb connects the current caller to another phone.

sample code:

<tf:client method="POST" url="client.twiml" value="flower" />
Table 2. dial tag attributes
attr. name attr. descr. required type

action

false

Allowed Values:relative or absolute URL. Default Value:no default action for Dial

java.lang.String

method

Allowed Values:GET, POST. Default Value:POST

false

java.lang.String

timeout

Allowed Values:positive integer. Default Value:30 seconds

false

java.lang.String

hangupOnStar

Allowed Values:true, false. Default Value:false

false

java.lang.String

timeLimit

Allowed Values:positive integer (seconds). Default Value:14400 seconds (4 hours)

false

java.lang.String

callerId

Allowed Values:a valid phone number, or client identifier if you are dialing a Client. Default Value:Caller’s callerId

false

java.lang.String

record

Allowed Values:true, false. Default Value:false

false

java.lang.String

value

Example: 415-123-4567. You can wrap inside open and close tag.

false

java.lang.String

enqueue - api enqueue

The Enqueue verb enqueues the current call in a call queue.

sample code:

<tf:enqueue method="POST" url="client.twiml" value="flower" />
Table 3. dial tag attributes
attr. name attr. descr. required type

action

Allowed Values:relative or absolute URL. Default Value:none

false

java.lang.String

method

Allowed Values:GET, POST. Default Value:POST

false

java.lang.String

waitUrl

Allowed Values:relative or absolute URL. Default Value:http://s3.amazonaws.com/com.twilio.sounds.music/index.xml.

false

java.lang.String

waitUrlMethod

Allowed Values:GET, POST. Default Value:POST

false

java.lang.String

value

Example:support. You can wrap inside open and close tag.

true

java.lang.String

gather - api gather

The Gather verb collects digits that a caller enters into his or her telephone keypad.

sample code:

<tf:gather method="POST" url="client.twiml" value="flower" />
Table 4. dial tag attributes
attr. name attr. descr. required type

action

false

Allowed Values:relative or absolute URL. Default Value:no default action for Dial

java.lang.String

method

Allowed Values:GET, POST. Default Value:POST

false

java.lang.String

timeout

Allowed Values:positive integer. Default Value:30 seconds

false

java.lang.String

finishOnKey

Allowed Values:any digit,,*. Default Value:

false

java.lang.String

numDigits

Allowed Values: integer <= 1. Default Value:unlimited

false

java.lang.String

hangup - api hangup

The Hangup verb ends a call.

sample code:

<tf:hangup />

jsClient - api twilio-js

Twilio.js allows you to establish audio connections between a web browser and a Twilio Application.

sample code:

<tf:jsClient />
Table 5. jsClient tag attributes
attr. name attr. descr. required type

token

true

Initialize Twilio.Device with a capability token

java.lang.String

debug

Allowed Values:true, false. Default Value:false

false

java.lang.String

rtc

Allowed Values:true, false. Default Value:false

false

java.lang.String

params

The optional params argument is a JavaScript object where configuration settings can be passed in to .setup. Use the format: key1:value1,key2:value2..

false

java.lang.String

withoutJs

Use withoutJs attribute for not writing twilio.js and jquery.js. Allowed Values:true, false. Default Value:false

false

java.lang.String

leave - api leave

The Leave verb transfers control of a call that is in a queue so that the caller exits the queue and execution continues with the next verb after the original Enqueue

sample code:

<tf:leave />

number - api number

The Dial verb’s Number noun specifies a phone number to dial.

sample code:

<tf:jsClient />
Table 6. jsClient tag attributes
attr. name attr. descr. required type

sendDigits

Allowed Values:any digits. Default Value:none. If you want to wait before sending the extension, so you add a few leading 'w' characters. Each 'w' character tells Twilio to wait 0.5 seconds instead of playing a digit.

false

java.lang.String

url

Allowed Values:any url. Default Value:none

false

java.lang.String

method

Allowed Values:GET or POST. Default Value:POST

false

java.lang.String

value

Example:415-123-4567. You can wrap inside open and close tag.

true

java.lang.String

pause - api pause

The Pause verb waits silently for a specific number of seconds.

sample code:

<tf:pause />
Table 7. pause tag attributes
attr. name attr. descr. required type

length

false

Allowed Values:integer < 0. Default Value:1 second

java.lang.String

play - api play

The Play verb plays an audio file back to the caller. Twilio retrieves the file from a URL that you provide.

sample code:

<tf:play />
Table 8. play tag attributes
attr. name attr. descr. required type

loop

Allowed Values:integer <= 0. Default Value:1

false

java.lang.String

value

Example:https://api.twilio.com/cowbell.mp3. You can wrap inside open and close tag.

true

java.lang.String

queue - api queue

The Dial verb’s Queue noun specifies a queue to dial.

sample code:

<tf:queue />
Table 9. queue tag attributes
attr. name attr. descr. required type

url

Allowed Values:relative or absolute URL. Default Value:none

false

java.lang.String

method

Allowed Values:GET, POST. Default Value:POST

false

java.lang.String

value

Example:support. You can wrap inside open and close tag.

true

java.lang.String

record - api record

The Record verb records the caller’s voice and returns to you the URL of a file containing the audio recording.

sample code:

<tf:record />
Table 10. record tag attributes
attr. name attr. descr. required type

action

false

Allowed Values:relative or absolute URL. Default Value:current document URL

java.lang.String

method

Allowed Values:GET, POST. Default Value:POST

false

java.lang.String

timeout

Allowed Values:positive integer. Default Value:5 seconds

false

java.lang.String

finishOnKey

Allowed Values:any digit,,. Default Value:1234567890

false

java.lang.String

maxLength

Allowed Values:integer < 1. Default Value:3600 (1 hour)

false

java.lang.String

transcribe

Allowed Values:relative or absolute URL. Default Value:none

false

java.lang.String

playBeep

Allowed Values:true, false. Default Value:true

false

java.lang.String

redirect - api redirect

The Redirect verb transfers control of a call to the TwiML at a different URL.

sample code:

<tf:redirect />
Table 11. redirect tag attributes
attr. name attr. descr. required type

method

false

Allowed Values:GET, POST. Default Value:POST

java.lang.String

value

Example:http://pigeons.com/twiml.xml. You can wrap inside open and close tag.

true

java.lang.String

reject - api reject

The Reject verb rejects an incoming call to your Twilio number without billing you.

sample code:

<tf:reject />
Table 12. reject tag attributes
attr. name attr. descr. required type

reason

false

Allowed Values:rejected, busy. Default Value:rejected

java.lang.String

response - api response

The root element of Twilio’s XML Markup is the Response element.

sample code:

<tf:response />

say - api say

The Say verb converts text to speech that is read back to the caller. Say is useful for development or saying dynamic text that is difficult to pre-record.

sample code:

<tf:say />
Table 13. say tag attributes
attr. name attr. descr. required type

voice

Allowed Values:man, woman, alice. Default Value:man

false

java.lang.String

language

Allowed Values - if you use man, woman:en, en-gb, es, fr, de, it. if you use alice:da-DK, de-DE, en-AU, en-CA, en-GB, en-IN, en-US, ca-ES, es-ES, es-MX, fi-FI, fr-CA, fr-FR, it-IT, ja-JP, ko-KR, nb-NO, nl-NL, pl-PL, pt-BR, pt-PT, ru-RU, sv-SE, zh-CN, zh-HK, zh-TW Default Value:en

false

java.lang.String

loop

Allowed Values:integer <= 0. Default Value:1

false

java.lang.String

value

Example:Chapeau! You can wrap inside open and close tag.

true

java.lang.String

sip - api say

The Dial verb’s Sip noun lets you set up VoIP sessions by using SIP - Session Initiation Protocol.

sample code:

<tf:sip />
Table 14. sip tag attributes
attr. name attr. descr. required type

url

Allowed Values:call screening url. Default Value:none.

false

java.lang.String

method

Allowed Values:GET, POST. Default Value:POST

false

java.lang.String

username

Username for SIP authentication

false

java.lang.String

passowrd

Password for SIP authentication.

true

java.lang.String

sms - api sms

The Sms verb sends an SMS message to a phone number during a phone call.

sample code:

<tf:sms />
Table 15. sms tag attributes
attr. name attr. descr. required type

to

Allowed Values:phone number.

false

java.lang.String

from

Allowed Values:phone number.

false

java.lang.String

action

Allowed Values:relative or absolute URL. Default Value:none.

false

java.lang.String

method

Allowed Values:GET, POST. Default Value:POST

false

java.lang.String

statusCallback

Allowed Values:relative or absolute URL. Default Value:none

false

java.lang.String

value

Example:The king stay the king. You can wrap inside open and close tag.

true

java.lang.String

comments powered by Disqus

Contact

Do you want collaborate with us?
Do you like this project?
Questions?
Please send me an email!

fiorenzo.pizza@gmail.com

Github code

Fork the twiliofaces repository on GitHub
and clone it to your local PC.

Get Started

Copy the Twiliofaces JAR file into your /WEB-INF/lib directory, or include all required Maven dependencies in your pom.xml!