developing sip applications
DESCRIPTION
How can you best develop applications using the Session Initiation Protocol? At this presentation at the Communications Developer Conference on September 16, 2008, Voxeo CTO RJ Auburn explained building blocks used to build voice applications, discussed VoiceXML, CCXML and JSR 289 SIP Servlets and then gave a demonstration of voice mashups with Twitter using first CCXML and then SIP Servlets (in Java).TRANSCRIPT
© Voxeo Corporation
Sep 16th, 2008
TMC Communication Developer Conference
Developing SIP Applications
© Voxeo Corporation
Telephony
© Voxeo Corporation - Confidential
Sucks
© Voxeo Corporation
Complex
© Voxeo Corporation
Arcane
© Voxeo Corporation
Proprietary
© Voxeo Corporation
This is not how it should be...
© Voxeo Corporation
Simple
© Voxeo Corporation
Ubiquitous
© Voxeo Corporation
Open
© Voxeo Corporation
What to do?
© Voxeo Corporation
Leverage The Web Model
© Voxeo Corporation
Utilize Standards
© Voxeo Corporation - Confidential
SOAP/REST
© Voxeo Corporation
What Does It Look Like?
© Voxeo Corporation16
Application
Platform
API XML Tools
© Voxeo Corporation17
Application
Prophecy
JSR289, REST, SOAP
CCXML&
VoiceXMLDesigner
© Voxeo Corporation18
ApplicationApplication
Platform
API XML Tools
© Voxeo Corporation
Building Blocks
© Voxeo Corporation
Session Initiation Protocol
- Session Initiation Protocol (SIP)defines how to establish a communication session betweentwo endpoints
- Primarily used for voice, but can for IM or virtually any other protocol
- Almost always used in client/server configuration with "SIP proxies" in control of "SIP endpoints"- Work going on in P2PSIP - see www.p2psip.org
- Text-based protocol, originally modeled on HTTP
© Voxeo Corporation
SIP Communication
Alice Bob
RTP (voice)
INVITE
180 RINGING200 OK
ACK
BYE200 OK
© Voxeo Corporation
Alice Bob
ProxyA
ProxyBSIP
SIP
RTP
SIP
© Voxeo Corporation
SIP Resources
- Internet Engineering Task Force (IETF)- RFC 3261- Hitchhiker’s Guide to SIP
- Open Source Info- VoIP Info Wiki: www.voip-info.org
- Industry Sites- SIP Forum: www.sipforum.org- SIP Foundry: www.sipfoundry.org- OpenSBC: www.opensourcesip.org
© Voxeo Corporation
Open Source SIP Software
- Systems- Asterisk: www.asterisk.org- sipXecs: www.sipfoundry.org- FreeSWITCH: www.freeswitch.org- OpenSER: www.openser.org
- SIP Stacks- reSIProcate: www.resiprocate.org
- Phones:- Gizmo: www.gizmoproject.org
- MANY, many more: www.voip-info.org
© Voxeo Corporation
Religion
© Voxeo Corporation
XML
© Voxeo Corporation
CCXML
- Call Control XML (CCXML) is the W3C standard for call control using XML
- Sister standard to VoiceXML- Integrates with VoiceXML for dialog control- Provides a framework for issuing call control commands and handling call control events
- http://www.w3.org/TR/ccxml/
© Voxeo Corporation
© Voxeo Corporation
CCXML Hello World<?xml version="1.0" encoding="UTF-8"?><ccxml version="1.0"> <eventprocessor>
<transition event="connection.alerting"> <log expr="'***** CONNECTION ALERTING *****'"/> <if cond="event$.connection.remote == '8315551234'"> <reject/> <else/> <accept/> </if> </transition>
<transition event="connection.connected"> <log expr="'***** CALL WAS ANSWERED *****'"/> </transition>
<transition event=”connection.disconnected”> <log expr=”‘*** Call was disconnected ***’”/> <exit/> </transition>
<transition event="error.*"> <log expr="'an error has occured (' + event$.reason + ')'"/> <exit/> </transition> </eventprocessor></ccxml>
© Voxeo Corporation
Java?
© Voxeo Corporation
SIP Servlets
- Standard Java based API for writing SIP applications.
- 1.0 standardized as JSR-116. - 2.0 just released as JSR-289- Extends the HTTP Servlet model to support SIP and telephony applications
- http://www.sipservlet.com/- Supported by a large number of application servers including Oracle (BEA), IBM, Sun, Voxeo.
31
© Voxeo Corporation
Converged Applications
© Voxeo Corporation
JSR-309
- Java Media Server API- Based on the CCXML media model - Still in draft stage- Provides dialog resources, conferencing, media routing to Java applications
33
© Voxeo Corporation
Example Application
© Voxeo Corporation
Sample Application Overview
- Caller dials in to the application
- Caller is bridged to the subscriber
- Results of the call attempt are posted to Twitter via their REST API
35
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
36
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
37
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
38
<?xml version="1.0" encoding="UTF-8"?><ccxml version="1.0" xmlns="http://www.w3.org/2002/09/ccxml"></ccxml>
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
39
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
40
<var name="state" expr="'init'"/><var name="incomingcall"/><var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/>
<eventprocessor statevariable="state"></eventprocessor>
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
41
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
42
<transition event="connection.alerting" state="init"> <accept/></transition>
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
43
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
44
<transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/></transition>
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
45
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
46
<transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/></transition>
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
47
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
48
<transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/></transition>
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
49
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
50
<transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/></transition>
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
51
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
52
<transition event="send.successful" state="done"> <exit/></transition>
© Voxeo Corporation
<?xml version="1.0" encoding="UTF-8"?><ccxml xmlns="http://www.w3.org/2002/09/ccxml" version="1.0"> <var name="state" expr="'init'"/> <var name="incomingcall"/> <var name="tURL" expr="'http://zscgeek:[email protected]/statuses/update.xml'"/> <eventprocessor statevariable="state"> <transition event="connection.alerting" state="init"> <accept/> </transition> <transition event="connection.connected" state="init"> <assign name="state" expr="'calling'"/> <assign name="incomingcall" expr="event$.connectionid"/> <createcall dest="'tel:+18312392883'"/> </transition> <transition event="connection.connected" state="calling"> <assign name="state" expr="'connected'"/> <join id1="event$.connectionid" id2="incomingcall"/> <var name="status" expr="'RJ is on the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.failed" state="calling"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is not answering his phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="connection.disconnected" state="connected"> <assign name="state" expr="'done'"/> <var name="status" expr="'RJ is off the phone'"/> <send targettype="'basichttp'" name="'update'" target="tURL" namelist="status"/> </transition> <transition event="send.successful" state="done"> <exit/> </transition> </eventprocessor></ccxml>
Follow Me/Find Me + Twitter
53
© Voxeo Corporation
We Got Java Bean!
© Voxeo Corporation
package com.voxeo.rj.fmdemo;
import java.io.IOException;import java.util.ArrayList;import java.util.List;import javax.servlet.ServletException;import javax.servlet.sip.*;import net.unto.twitter.Api;import net.unto.twitter.TwitterException;
public class FMServlet extends SipServlet { Api twitter_api; List<URI> targets; public void init() throws ServletException { twitter_api = new Api("zscgeek", "password"); SipFactory sipFactory = (SipFactory)getServletContext().getAttribute(SIP_FACTORY); targets = new ArrayList<URI>(); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); }
protected void doInvite(SipServletRequest req) throws ServletException, IOException { if (req.isInitial()) { Proxy proxy = req.getProxy(); proxy.setRecordRoute(true); proxy.setParallel(true); proxy.proxyTo(targets); } }
protected void doSuccessResponse(SipServletResponse resp) throws IOException { if (resp.getMethod().equalsIgnoreCase("invite")) { try { twitter_api.updateStatus("RJ is taking a phone call from " + resp.getRequest().getRequestURI()); } catch (TwitterException e) {log("failed to update twitter",e);} } }}
Follow Me/Find Me + Twitter
55
© Voxeo Corporation
package com.voxeo.rj.fmdemo;
import java.io.IOException;import java.util.ArrayList;import java.util.List;import javax.servlet.ServletException;import javax.servlet.sip.*;import net.unto.twitter.Api;import net.unto.twitter.TwitterException;
public class FMServlet extends SipServlet { Api twitter_api; List<URI> targets; public void init() throws ServletException { twitter_api = new Api("zscgeek", "password"); SipFactory sipFactory = (SipFactory)getServletContext().getAttribute(SIP_FACTORY); targets = new ArrayList<URI>(); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); }
protected void doInvite(SipServletRequest req) throws ServletException, IOException { if (req.isInitial()) { Proxy proxy = req.getProxy(); proxy.setRecordRoute(true); proxy.setParallel(true); proxy.proxyTo(targets); } }
protected void doSuccessResponse(SipServletResponse resp) throws IOException { if (resp.getMethod().equalsIgnoreCase("invite")) { try { twitter_api.updateStatus("RJ is taking a phone call from " + resp.getRequest().getRequestURI()); } catch (TwitterException e) {log("failed to update twitter",e);} } }}
Follow Me/Find Me + Twitter
56
© Voxeo Corporation
package com.voxeo.rj.fmdemo;
import java.io.IOException;import java.util.ArrayList;import java.util.List;import javax.servlet.ServletException;import javax.servlet.sip.*;import net.unto.twitter.Api;import net.unto.twitter.TwitterException;
public class FMServlet extends SipServlet { Api twitter_api; List<URI> targets; public void init() throws ServletException { twitter_api = new Api("zscgeek", "password"); SipFactory sipFactory = (SipFactory)getServletContext().getAttribute(SIP_FACTORY); targets = new ArrayList<URI>(); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); }
protected void doInvite(SipServletRequest req) throws ServletException, IOException { if (req.isInitial()) { Proxy proxy = req.getProxy(); proxy.setRecordRoute(true); proxy.setParallel(true); proxy.proxyTo(targets); } }
protected void doSuccessResponse(SipServletResponse resp) throws IOException { if (resp.getMethod().equalsIgnoreCase("invite")) { try { twitter_api.updateStatus("RJ is taking a phone call from " + resp.getRequest().getRequestURI()); } catch (TwitterException e) {log("failed to update twitter",e);} } }}
Follow Me/Find Me + Twitter
57
package com.voxeo.rj.fmdemo;
import java.io.IOException;import java.util.ArrayList;import java.util.List;import javax.servlet.ServletException;import javax.servlet.sip.*;import net.unto.twitter.Api;import net.unto.twitter.TwitterException;
© Voxeo Corporation
package com.voxeo.rj.fmdemo;
import java.io.IOException;import java.util.ArrayList;import java.util.List;import javax.servlet.ServletException;import javax.servlet.sip.*;import net.unto.twitter.Api;import net.unto.twitter.TwitterException;
public class FMServlet extends SipServlet { Api twitter_api; List<URI> targets; public void init() throws ServletException { twitter_api = new Api("zscgeek", "password"); SipFactory sipFactory = (SipFactory)getServletContext().getAttribute(SIP_FACTORY); targets = new ArrayList<URI>(); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); }
protected void doInvite(SipServletRequest req) throws ServletException, IOException { if (req.isInitial()) { Proxy proxy = req.getProxy(); proxy.setRecordRoute(true); proxy.setParallel(true); proxy.proxyTo(targets); } }
protected void doSuccessResponse(SipServletResponse resp) throws IOException { if (resp.getMethod().equalsIgnoreCase("invite")) { try { twitter_api.updateStatus("RJ is taking a phone call from " + resp.getRequest().getRequestURI()); } catch (TwitterException e) {log("failed to update twitter",e);} } }}
Follow Me/Find Me + Twitter
58
© Voxeo Corporation
package com.voxeo.rj.fmdemo;
import java.io.IOException;import java.util.ArrayList;import java.util.List;import javax.servlet.ServletException;import javax.servlet.sip.*;import net.unto.twitter.Api;import net.unto.twitter.TwitterException;
public class FMServlet extends SipServlet { Api twitter_api; List<URI> targets; public void init() throws ServletException { twitter_api = new Api("zscgeek", "password"); SipFactory sipFactory = (SipFactory)getServletContext().getAttribute(SIP_FACTORY); targets = new ArrayList<URI>(); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); }
protected void doInvite(SipServletRequest req) throws ServletException, IOException { if (req.isInitial()) { Proxy proxy = req.getProxy(); proxy.setRecordRoute(true); proxy.setParallel(true); proxy.proxyTo(targets); } }
protected void doSuccessResponse(SipServletResponse resp) throws IOException { if (resp.getMethod().equalsIgnoreCase("invite")) { try { twitter_api.updateStatus("RJ is taking a phone call from " + resp.getRequest().getRequestURI()); } catch (TwitterException e) {log("failed to update twitter",e);} } }}
Follow Me/Find Me + Twitter
59
public class FMServlet extends SipServlet { public void init() throws ServletException { }
protected void doInvite(SipServletRequest req) throws ServletException, IOException { }
protected void doSuccessResponse(SipServletResponse resp) throws IOException { }}
© Voxeo Corporation
package com.voxeo.rj.fmdemo;
import java.io.IOException;import java.util.ArrayList;import java.util.List;import javax.servlet.ServletException;import javax.servlet.sip.*;import net.unto.twitter.Api;import net.unto.twitter.TwitterException;
public class FMServlet extends SipServlet { Api twitter_api; List<URI> targets; public void init() throws ServletException { twitter_api = new Api("zscgeek", "password"); SipFactory sipFactory = (SipFactory)getServletContext().getAttribute(SIP_FACTORY); targets = new ArrayList<URI>(); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); }
protected void doInvite(SipServletRequest req) throws ServletException, IOException { if (req.isInitial()) { Proxy proxy = req.getProxy(); proxy.setRecordRoute(true); proxy.setParallel(true); proxy.proxyTo(targets); } }
protected void doSuccessResponse(SipServletResponse resp) throws IOException { if (resp.getMethod().equalsIgnoreCase("invite")) { try { twitter_api.updateStatus("RJ is taking a phone call from " + resp.getRequest().getRequestURI()); } catch (TwitterException e) {log("failed to update twitter",e);} } }}
Follow Me/Find Me + Twitter
60
© Voxeo Corporation
package com.voxeo.rj.fmdemo;
import java.io.IOException;import java.util.ArrayList;import java.util.List;import javax.servlet.ServletException;import javax.servlet.sip.*;import net.unto.twitter.Api;import net.unto.twitter.TwitterException;
public class FMServlet extends SipServlet { Api twitter_api; List<URI> targets; public void init() throws ServletException { twitter_api = new Api("zscgeek", "password"); SipFactory sipFactory = (SipFactory)getServletContext().getAttribute(SIP_FACTORY); targets = new ArrayList<URI>(); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); }
protected void doInvite(SipServletRequest req) throws ServletException, IOException { if (req.isInitial()) { Proxy proxy = req.getProxy(); proxy.setRecordRoute(true); proxy.setParallel(true); proxy.proxyTo(targets); } }
protected void doSuccessResponse(SipServletResponse resp) throws IOException { if (resp.getMethod().equalsIgnoreCase("invite")) { try { twitter_api.updateStatus("RJ is taking a phone call from " + resp.getRequest().getRequestURI()); } catch (TwitterException e) {log("failed to update twitter",e);} } }}
Follow Me/Find Me + Twitter
61
Api twitter_api;List<URI> targets;
public void init() throws ServletException { twitter_api = new Api("zscgeek", "password"); SipFactory sipFactory = (SipFactory)getServletContext().getAttribute(SIP_FACTORY); targets = new ArrayList<URI>(); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]"));}
© Voxeo Corporation
package com.voxeo.rj.fmdemo;
import java.io.IOException;import java.util.ArrayList;import java.util.List;import javax.servlet.ServletException;import javax.servlet.sip.*;import net.unto.twitter.Api;import net.unto.twitter.TwitterException;
public class FMServlet extends SipServlet { Api twitter_api; List<URI> targets; public void init() throws ServletException { twitter_api = new Api("zscgeek", "password"); SipFactory sipFactory = (SipFactory)getServletContext().getAttribute(SIP_FACTORY); targets = new ArrayList<URI>(); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); }
protected void doInvite(SipServletRequest req) throws ServletException, IOException { if (req.isInitial()) { Proxy proxy = req.getProxy(); proxy.setRecordRoute(true); proxy.setParallel(true); proxy.proxyTo(targets); } }
protected void doSuccessResponse(SipServletResponse resp) throws IOException { if (resp.getMethod().equalsIgnoreCase("invite")) { try { twitter_api.updateStatus("RJ is taking a phone call from " + resp.getRequest().getRequestURI()); } catch (TwitterException e) {log("failed to update twitter",e);} } }}
Follow Me/Find Me + Twitter
62
© Voxeo Corporation
package com.voxeo.rj.fmdemo;
import java.io.IOException;import java.util.ArrayList;import java.util.List;import javax.servlet.ServletException;import javax.servlet.sip.*;import net.unto.twitter.Api;import net.unto.twitter.TwitterException;
public class FMServlet extends SipServlet { Api twitter_api; List<URI> targets; public void init() throws ServletException { twitter_api = new Api("zscgeek", "password"); SipFactory sipFactory = (SipFactory)getServletContext().getAttribute(SIP_FACTORY); targets = new ArrayList<URI>(); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); }
protected void doInvite(SipServletRequest req) throws ServletException, IOException { if (req.isInitial()) { Proxy proxy = req.getProxy(); proxy.setRecordRoute(true); proxy.setParallel(true); proxy.proxyTo(targets); } }
protected void doSuccessResponse(SipServletResponse resp) throws IOException { if (resp.getMethod().equalsIgnoreCase("invite")) { try { twitter_api.updateStatus("RJ is taking a phone call from " + resp.getRequest().getRequestURI()); } catch (TwitterException e) {log("failed to update twitter",e);} } }}
Follow Me/Find Me + Twitter
63
protected void doInvite(SipServletRequest req) throws ServletException, IOException { if (req.isInitial()) { Proxy proxy = req.getProxy(); proxy.setRecordRoute(true); proxy.setParallel(true); proxy.proxyTo(targets); }}
© Voxeo Corporation
package com.voxeo.rj.fmdemo;
import java.io.IOException;import java.util.ArrayList;import java.util.List;import javax.servlet.ServletException;import javax.servlet.sip.*;import net.unto.twitter.Api;import net.unto.twitter.TwitterException;
public class FMServlet extends SipServlet { Api twitter_api; List<URI> targets; public void init() throws ServletException { twitter_api = new Api("zscgeek", "password"); SipFactory sipFactory = (SipFactory)getServletContext().getAttribute(SIP_FACTORY); targets = new ArrayList<URI>(); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); }
protected void doInvite(SipServletRequest req) throws ServletException, IOException { if (req.isInitial()) { Proxy proxy = req.getProxy(); proxy.setRecordRoute(true); proxy.setParallel(true); proxy.proxyTo(targets); } }
protected void doSuccessResponse(SipServletResponse resp) throws IOException { if (resp.getMethod().equalsIgnoreCase("invite")) { try { twitter_api.updateStatus("RJ is taking a phone call from " + resp.getRequest().getRequestURI()); } catch (TwitterException e) {log("failed to update twitter",e);} } }}
Follow Me/Find Me + Twitter
64
© Voxeo Corporation
package com.voxeo.rj.fmdemo;
import java.io.IOException;import java.util.ArrayList;import java.util.List;import javax.servlet.ServletException;import javax.servlet.sip.*;import net.unto.twitter.Api;import net.unto.twitter.TwitterException;
public class FMServlet extends SipServlet { Api twitter_api; List<URI> targets; public void init() throws ServletException { twitter_api = new Api("zscgeek", "password"); SipFactory sipFactory = (SipFactory)getServletContext().getAttribute(SIP_FACTORY); targets = new ArrayList<URI>(); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); }
protected void doInvite(SipServletRequest req) throws ServletException, IOException { if (req.isInitial()) { Proxy proxy = req.getProxy(); proxy.setRecordRoute(true); proxy.setParallel(true); proxy.proxyTo(targets); } }
protected void doSuccessResponse(SipServletResponse resp) throws IOException { if (resp.getMethod().equalsIgnoreCase("invite")) { try { twitter_api.updateStatus("RJ is taking a phone call from " + resp.getRequest().getRequestURI()); } catch (TwitterException e) {log("failed to update twitter",e);} } }}
Follow Me/Find Me + Twitter
65
protected void doSuccessResponse(SipServletResponse resp) throws IOException { if (resp.getMethod().equalsIgnoreCase("invite")) { try { twitter_api.updateStatus("RJ is taking a phone call from " + resp.getRequest().getRequestURI()); } catch(TwitterException e){log("failed to update twitter",e);} }}
© Voxeo Corporation
package com.voxeo.rj.fmdemo;
import java.io.IOException;import java.util.ArrayList;import java.util.List;import javax.servlet.ServletException;import javax.servlet.sip.*;import net.unto.twitter.Api;import net.unto.twitter.TwitterException;
public class FMServlet extends SipServlet { Api twitter_api; List<URI> targets; public void init() throws ServletException { twitter_api = new Api("zscgeek", "password"); SipFactory sipFactory = (SipFactory)getServletContext().getAttribute(SIP_FACTORY); targets = new ArrayList<URI>(); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); targets.add(sipFactory.createURI("sip:[email protected]")); }
protected void doInvite(SipServletRequest req) throws ServletException, IOException { if (req.isInitial()) { Proxy proxy = req.getProxy(); proxy.setRecordRoute(true); proxy.setParallel(true); proxy.proxyTo(targets); } }
protected void doSuccessResponse(SipServletResponse resp) throws IOException { if (resp.getMethod().equalsIgnoreCase("invite")) { try { twitter_api.updateStatus("RJ is taking a phone call from " + resp.getRequest().getRequestURI()); } catch (TwitterException e) {log("failed to update twitter",e);} } }}
Follow Me/Find Me + Twitter
66
© Voxeo Corporation
So why is this important?
© Voxeo Corporation
Web Developers
Phone Developers Web Developers
© Voxeo Corporation
Web
© Voxeo Corporation
Ideas We have Never Thought Of
© Voxeo Corporation
Standards Matter
© Voxeo Corporation
Example Usage
© Voxeo Corporation
Project Green Phone
- By Mark Headd- http://www.voiceingov.org/blog/?p=135- VoiceXML, JavaScript, CCXML, PHP- Application:
- Caller dials in to app- App uses ANI/Caller ID and makes web service query to a database to determine location
- Makes another web service query to find location of nearest E85/Biodiesel stations
- Relays information to caller- Sends caller a SMS text msg with info
© Voxeo Corporation
Rocketsource.org
- www.rocketsource.org
- Vox-Attendant- A VoiceXML-based, speech-driven auto attendant that can connect callers
with any person or group with an enterprise, via their desk, cellular, or VoIP phones.
- Vox-Mail- A VoiceXML-based, speech-driven voicemail application that can store
messages locally or integrate with any IMAP email server to provide basic unified messaging.
- Voice Conference Manager- A VoiceXML and CCXML-based, speech-driven conference manager that
features both phone and web-based conference call creation, access, and management.
- VoiceXML, CCXML, grXML, JavaScript, Java, and Python
© Voxeo Corporation
Wrapping Up
© Voxeo Corporation
Look at the big picture
http://flickr.com/photos/txd/100437832
© Voxeo Corporation
More then one way to skin a cat!
© Voxeo Corporation
Avoid the Mouse Trap
© Voxeo Corporation
Be ready to scale
© Voxeo Corporation
© Voxeo Corporation
http://www.voxeo.com/prophecyhttp://evolution.voxeo.com