Git Product home page Git Product logo

plivoframework's Issues

Dial Verb Timeout

Using the following XML, I'd expect the b leg to terminate after 20 seconds, however the line remains intact:

<?xml version="1.0"?>
<Response>
    <Speak loop="1" voice="slt">Dialing User</Speak>
    <Dial callbackUrl="http://127.0.0.1:8000/_plivo/b-leg/callback" callerId="1949266xxxx" dialMusic="/usr/local/freeswitch/sounds/music/8000/ponce-preludio-in-e-major.wav" hangupOnStar="false" method="POST" timeLimit="20" timeout="30">
        <Number gateways="sofia/gateway/flowroute,user">+1732838xxxx</Number>
    </Dial>
    <Speak loop="1" voice="slt">The call failed or the remote party hung up. Goodbye</Speak>
</Response>

Need to escape quote for speak

The following XML should speak the entire sentence "To speak with a real person, press 1. Press 2 to 'record a message. Press any other key to start over." However it only says "To speak with a real person, press 1. Press 2 to 'record". I put the ' in to replicate a bug in another XML we have. It seems the single quote makes it stop speaking the text. A double quote is ok.

<?xml version="1.0"?>
<Response>
    <Record bothLegs="true" fileFormat="mp3" finishOnKey="#" maxLength="3600" playBeep="true" timeout="5"/>
    <Play loop="1">http://dl.dropbox.com/u/14573179/Audio/Freeswitch/sounds/en/us/callie/ivr/mp3/ivr-thank_you_for_calling.mp3</Play>
    <GetDigits action="http://127.0.0.1:8000/_plivo/got_digits/GET/L2l2ci9oZWxsby1wZXJzb24vaGFuZGxlLWdhdGhlcg==" finishOnKey="#" method="GET" numDigits="1" timeout="5">
        <Speak loop="1" voice="slt">To speak with a real person, press 1. Press 2 to 'record a message. Press any other key to start over.</Speak>
    </GetDigits>
</Response>

Here's what it looks like in the plivo log

2011-07-27 21:47:55,169 outboundserver[18605]: INFO: (6) GetDigits Started ["say:flite:slt:'To speak with a real person, press 1. Press 2 to 'record a message. Press any other key to start over.'"]

And freeswitch:

EXECUTE sofia/internal/[email protected] play_and_get_digits(1 1 1 5000 '#' file_string://silence_stream://1!say:flite:slt:'To speak with a real person, press 1. Press 2 to 'record a message. Press any other key to start over.' silence_stream://150 pagd_input (0|1|2|3|4|5|6|7|8|9|\*|#)+ 5000)
2011-07-27 21:47:55.188345 [DEBUG] switch_ivr_play_say.c:1279 Codec Activated L16@8000hz 1 channels 20ms
2011-07-27 21:47:55.458699 [DEBUG] switch_ivr_play_say.c:1649 done playing file
2011-07-27 21:47:55.727835 [DEBUG] switch_ivr_play_say.c:2376 OPEN TTS flite
2011-07-27 21:47:55.727835 [DEBUG] switch_ivr_play_say.c:2385 Raw Codec Activated
2011-07-27 21:47:55.831325 [DEBUG] switch_ivr_play_say.c:2076 Speaking text: To speak with a real person, press 1. Press 2 to record

Record with bothLegs=false doesn't trigger `record_post_process_exec_api`

When using the following XML I can use the record_post_process_exec_api callback to trigger a python script and upload the recording file to Amazon. If I change to bothLegs=False the record_post_process_exec_api is not triggered.

<?xml version="1.0" encoding="utf-8"?>
<Response>
    <Say>Record your message after the beep.</Say>
    <Record action="/ivr/record/callback" beep="True" bothLegs="True"/>
    <Play>http://dl.dropbox.com/u/14573179/Audio/Bugle/Tattoo.mp3</Play>
</Response>

Here is my FS config:

<action application="set" data="record_post_process_exec_api=pyrun:my_app_freeswitch.post_process $${base_dir}/recordings/,${uuid}"/>
<action application="enable_heartbeat" data="60"/>
<action application="socket" data="127.0.0.1:8084 async full"/>

Here's what I see in the FS logs for bothLegs:

EXECUTE sofia/internal/[email protected] set(record_post_process_exec_api=pyrun:my_app_freeswitch.post_process  /usr/local/freeswitch/recordings/,7c304780-5ea5-4ca6-b538-c4d610c46b84)
2011-08-04 18:03:42.278126 [DEBUG] mod_dptools.c:1063 sofia/internal/[email protected] SET [record_post_process_exec_api]=[pyrun:my_app_freeswitch.post_process  /usr/local/freeswitch/recordings/,7c304780-5ea5-4ca6-b538-c4d610c46b84]
EXECUTE sofia/internal/[email protected] enable_heartbeat(60)
...
EXECUTE sofia/internal/[email protected] record(/usr/local/freeswitch/recordings/20110804-180345_7c304780-5ea5-4ca6-b538-c4d610c46b84.mp3 3600 500 5)
...
2011-08-04 18:10:40.289726 [DEBUG] mod_python.c:183 Call python script
...
2011-08-04 18:10:40.648268 [DEBUG] mod_python.c:186 Finished calling python script

and when it's false:

EXECUTE sofia/internal/[email protected] set(record_post_process_exec_api=pyrun:my_app_freeswitch.post_process  /usr/local/freeswitch/recordings/,934d6786-676a-4180-b37f-6b54616c2020)
2011-08-04 18:10:25.255307 [DEBUG] mod_dptools.c:1063 sofia/internal/[email protected] SET [record_post_process_exec_api]=[pyrun:my_app_freeswitch.post_process  /usr/local/freeswitch/recordings/,934d6786-676a-4180-b37f-6b54616c2020]


2011-08-04 18:10:28.895591 [DEBUG] switch_ivr.c:576 sofia/internal/[email protected] Command Execute record_session(/usr/local/freeswitch/recordings/20110804-181028_934d6786-676a-4180-b37f-6b54616c2020.mp3)
EXECUTE sofia/internal/[email protected] record_session(/usr/local/freeswitch/recordings/20110804-181028_934d6786-676a-4180-b37f-6b54616c2020.mp3)

Callback from Record verb

It would be useful to get a callback from the Record verb, much like with Twilio's Record verb.

The useful data returned by twilio is:

  • RecordingUrl - a url where the recording can be retrieved
  • RecordingDuration - the number of seconds the recording lasted
  • Digits - any number key the caller pressed to end recording or 'hangup' if they hung up

For plivo, I think it would make sense to return:

  • RecordingFilePath - the directory where the recording was stored
  • RecordingFilename - the name of the file created
  • RecordingFileFormat - mp3 or wav
  • RecordingDuration - the number of seconds the recording lasted
  • Digits - the key pressed to end recording, or hangup

The following attributes would also need to be added to the Record verb:

  • action
  • method

This will alter the behaviour of the Record verb. If the recording fails, the next verb should be executed, but if the recording succeeds, then the callback should be made to ask for the next step. In this way, it would be possible to create a script like:

In this way, I can cover both the success and failure of the recording, and with the Record callback, I can store details about where the file of the recording has been saved, and so on. The recording callback would also let me have plivo choose a unique filename for the call, and then I only store it in my application if the recording was successful. Otherwise, I send a Record filename, the recording fails, but my application still has that filename stored somewhere and does not know it is non existent.

AnswerUrl not called on origination

Call origination doesn't work because AnswerUrl is never called.

Sequence of events:

  1. Originate call to my cell phone
  2. Ringing URL is called
  3. Answer cell phone
  4. Call immediately hangs up
  5. Hangup URL is called

Application log:

[I 110819 00:40:27 web:1398] 200 POST /dialing (127.0.0.1) 32.37ms
[I 110819 00:40:27 app2:84] uuid: 4e6318c8-c9da-11e0-a7b2-ebaa5909aa51
[I 110819 00:40:28 web:1398] 200 POST /ringing (127.0.0.1) 0.99ms
[I 110819 00:40:38 web:1398] 200 POST /hangup (127.0.0.1) 1.02ms

I've tested this with my own application using the plivohelper-python library. Also tested directly against the Plivo REST API. Further tested with plivohelper-python/examples/example-call.py. Answer URL is never POSTed to on outbound calls. However, it's worth noting that Answer URL is POSTed to on inbound calls.

FreeSWITCH console below:

http://pastebin.com/rmgSgtWn

Play API failure

2011-08-19 11:09:37,896 plivo-outbound[5312]: INFO: (21) Sent to POST http://127.0.0.1:5002/answered with {'To': '503xxxxxxx', 'Direction': 'outbound', 'From': '503xxxxxxx', 'ALegUUID': '2e1f9052-ca32-11e0-9708-e5799a9acb0f', 'ALegRequestUUID': '2da9bd5a-ca32-11e0-a511-df5689b29830', 'CallUUID': '2e1f9052-ca32-11e0-9708-e5799a9acb0f', 'CallStatus': 'in-progress'} -- Result: 
            <?xml version="1.0" encoding="UTF-8" ?>
            <Response>
                <Play>/usr/local/freeswitch/sounds/en/us/callie/ivr/8000/ivr-hello.wav</Play>
            </Response>

2011-08-19 11:09:37,897 plivo-outbound[5312]: INFO: (21) Requested RESTXML to http://127.0.0.1:5002/answered with {'To': '503xxxxxxx', 'Direction': 'outbound', 'From': '503xxxxxxx', 'ALegUUID': '2e1f9052-ca32-11e0-9708-e5799a9acb0f', 'ALegRequestUUID': '2da9bd5a-ca32-11e0-a511-df5689b29830', 'CallUUID': '2e1f9052-ca32-11e0-9708-e5799a9acb0f', 'CallStatus': 'in-progress'}
2011-08-19 11:09:37,922 plivo-outbound[5312]: ERROR: (21) Processing Call Failure !
2011-08-19 11:09:37,922 plivo-outbound[5312]: ERROR: (21) local variable 'audio_path' referenced before assignment
2011-08-19 11:09:37,987 plivo-outbound[5312]: ERROR: (21) Traceback (most recent call last):
2011-08-19 11:09:37,987 plivo-outbound[5312]: ERROR: (21)   File "/usr/local/plivo/src/plivo/src/plivo/rest/freeswitch/outboundsocket.py", line 388, in _run
2011-08-19 11:09:37,987 plivo-outbound[5312]: ERROR: (21)     self.process_call()
2011-08-19 11:09:37,988 plivo-outbound[5312]: ERROR: (21)   File "/usr/local/plivo/src/plivo/src/plivo/rest/freeswitch/outboundsocket.py", line 425, in process_call
2011-08-19 11:09:37,988 plivo-outbound[5312]: ERROR: (21)     self.execute_xml()
2011-08-19 11:09:37,988 plivo-outbound[5312]: ERROR: (21)   File "/usr/local/plivo/src/plivo/src/plivo/rest/freeswitch/outboundsocket.py", line 554, in execute_xml
2011-08-19 11:09:37,988 plivo-outbound[5312]: ERROR: (21)     element_instance.prepare(self)
2011-08-19 11:09:37,988 plivo-outbound[5312]: ERROR: (21)   File "/usr/local/plivo/src/plivo/src/plivo/rest/freeswitch/elements.py", line 1202, in prepare
2011-08-19 11:09:37,989 plivo-outbound[5312]: ERROR: (21)     self.sound_file_path = get_resource(outbound_socket, url)
2011-08-19 11:09:37,989 plivo-outbound[5312]: ERROR: (21)   File "/usr/local/plivo/src/plivo/src/plivo/rest/freeswitch/helpers.py", line 445, in get_resource
2011-08-19 11:09:37,989 plivo-outbound[5312]: ERROR: (21)     full_file_name = "shout://%s" % audio_path
2011-08-19 11:09:37,989 plivo-outbound[5312]: ERROR: (21) UnboundLocalError: local variable 'audio_path' referenced before assignment

Dial ring back tone not working

When using the following XML, I don't hear a ringing sound on the origination side before the callee answers.

<?xml version="1.0"?>
<Response>
    <Speak loop="1" voice="slt">Dialing User</Speak>
    <Dial action="http://goliath:8000/_plivo/redirect/POST/aHR0cDovL2xvY2FsaG9zdDo4MDAwL2l2ci9xdWljay1kaWFsL2hhbmctdXA=" callbackMethod="POST" callbackUrl="http://goliath:8000/_plivo/b-leg/callback/POST/aHR0cDovL2xvY2FsaG9zdDo4MDAwL2l2ci9oZWFydGJlYXQ=" callerId="12024561414" digitsMatch="1,2,3" hangupOnStar="false" method="POST" timeLimit="120" timeout="30">
        <Number extraDialString="sip_h_Diversion=18007779999" gateways="sofia/gateway/flowroute,user">1005</Number>
    </Dial>
</Response>

I see this representation in the plivo logs:

2011-09-15 10:04:58,900 plivo-outbound[5437]: INFO: (1) [Dial]  {'redirect': 'true', 'callerId': '12024561414', 'confirmSound': '', 'digitsMatch': '1,2,3', 'callbackMethod': 'POST', 'timeLimit': '120', 'dialMusic': '', 'timeout': '30', 'action': 'http://goliath:8000/_plivo/redirect/POST/aHR0cDovL2xvY2FsaG9zdDo4MDAwL2l2ci9xdWljay1kaWFsL2hhbmctdXA=', 'confirmKey': '', 'hangupOnStar': 'false', 'method': 'POST', 'callbackUrl': 'http://goliath:8000/_plivo/b-leg/callback/POST/aHR0cDovL2xvY2FsaG9zdDo4MDAwL2l2ci9oZWFydGJlYXQ='}

Event-Date-Timestamp is not changing

I added Event-Date-Timestamp to EXTRA_FS_VARS in config.
Here is part of application log, for every request Event-Date-Timestamp has same value.

Started POST "/inbound_call/answered/" for 127.0.0.1 at 2011-07-12 11:20:31 +0200
  Processing by InboundCallController#answered as HTML
  Parameters: {"Direction"=>"inbound", "Channel-Read-Codec-Bit-Rate"=>"64000", "From"=>"101", "Caller-Channel-Hangup-Time"=>"0", "variable_user_context"=>"default", "Caller-Channel-Transfer-Time"=>"0", "Event-Date-Timestamp"=>"1310462431180366", "Caller-Channel-Created-Time"=>"1310462431160365", "To"=>"756", "Event-Date-Local"=>"2011-07-12 11:20:31", "CallUUID"=>"30860c28-ac68-11e0-8460-ebaccda30856", "Caller-Channel-Answered-Time"=>"0", "CallStatus"=>"ringing"}

===================== RESPONSE answered================
<Response><GetDigits action="http://127.0.0.1:5000/inbound_call/digits" timeout="25" numDigits="3" playBeep="false"></GetDigits></Response>
===============================================

Started POST "/inbound_call/digits" for 127.0.0.1 at 2011-07-12 11:20:37 +0200
  Processing by InboundCallController#digits as HTML
  Parameters: {"Digits"=>"100", "Direction"=>"inbound", "Channel-Read-Codec-Bit-Rate"=>"64000", "From"=>"101", "Caller-Channel-Hangup-Time"=>"0", "variable_user_context"=>"default", "Caller-Channel-Transfer-Time"=>"0", "Event-Date-Timestamp"=>"1310462431180366", "Caller-Channel-Created-Time"=>"1310462431160365", "To"=>"756", "Event-Date-Local"=>"2011-07-12 11:20:31", "CallUUID"=>"30860c28-ac68-11e0-8460-ebaccda30856", "Caller-Channel-Answered-Time"=>"0", "CallStatus"=>"ringing"}

===================== RESPONSE digits================
<Response><Dial action="http://127.0.0.1:5000/inbound_call/after_dial" timeLimit="100"><Number gateways="sofia/10.2.11.1">100</Number></Dial><Redirect>http://127.0.0.1:5000/inbound_call/answered</Redirect></Response>
===============================================

Started POST "/inbound_call/after_dial" for 127.0.0.1 at 2011-07-12 11:20:40 +0200
  Processing by InboundCallController#after_dial as HTML
  Parameters: {"Direction"=>"inbound", "Channel-Read-Codec-Bit-Rate"=>"64000", "From"=>"101", "Caller-Channel-Hangup-Time"=>"0", "variable_user_context"=>"default", "Caller-Channel-Transfer-Time"=>"0", "Event-Date-Timestamp"=>"1310462431180366", "HangupCause"=>"NORMAL_CLEARING", "Caller-Channel-Created-Time"=>"1310462431160365", "To"=>"756", "Event-Date-Local"=>"2011-07-12 11:20:31", "RingStatus"=>"true", "CallUUID"=>"30860c28-ac68-11e0-8460-ebaccda30856", "Caller-Channel-Answered-Time"=>"0", "CallStatus"=>"ringing"}

Issue with FS originate

The plivo-rest.log file is showing the following command is being sent to FS.

originate {plivo_request_uuid=c9e25272-e085-11e0-b505-12313b0c4557,plivo_answer_url=http://testurl.com,plivo_ring_url=,plivo_hangup_url=http://testurl.com,origination_caller_id_number=5555555555,bridge_early_media=true,api_on_answer_1='sched_api +798860 c9e256c8-e085-11e0-b505-12313b0c4557 'hupall ALLOTTED_TIMEOUT plivo_request_uuid c9e25272-e085-11e0-b505-12313b0c4557'',plivo_sched_hangup_id=c9e256c8-e085-11e0-b505-12313b0c4557,plivo_app=true,originate_timeout=60,ignore_early_media=true}sofia/gateway/sip1/+15555555555 'socket:127.0.0.1:8084 async full' inline

The issue is that FS is coming back with

2011-09-16 13:04:24.446990 [ERR] switch_ivr_originate.c:1887 Parse Error!
2011-09-16 13:04:24.446990 [DEBUG] switch_ivr_originate.c:3346 Originate Resulted in Error Cause: 27 [DESTINATION_OUT_OF_ORDER]

However when I remove ALLOTTED_TIMEOUT plivo_request_uuid c9e25272-e085-11e0-b505-12313b0c4557 from the originate when I do it manually in the cli, it works fine.

Please advise.

Play rest method not working (500 - Internal Server Error)

After I initiate a call (I've tried with a dial verb and with a pause verb) I try to call the REST method to play a sound as follows:

curl http://dragoon:8088/v0.1/Play/ -d "CallUUID=d2f3b5aa-c91e-11e0-a8e3-00112f379114&Legs=both&Sounds=http://dl.dropbox.com/u/14573179/Audio/Freeswitch/sounds/en/us/callie/ivr/mp3/ivr-you_are_number_one.wav.mp3" -u "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY"

In the REST API logs I see

2011-08-17 18:19:26,796 plivo-rest[589]: INFO: 192.168.1.77 - - [2011-08-17 18:19:26] "POST /v0.1/Play/ HTTP/1.1" 500 21 "-" "curl/7.21.6 (x86_64-apple-darwin10.7.0) libcurl/7.21.6 OpenSSL/1.0.0d zlib/1.2.5 libidn/1.20"

and nothing more.

Gateway Failover while calling

Dial and Call try the next 2 gateways simultaneously after fail over from first one. Also would be effecting bulk calls.

Plivo signature header change

Hi,

Apparently, the header Plivo sets in the HttpRequest class is not being passed correctly when using this to talk to nginx in a reverse proxy configuration. nginx passes this header correctly when you use dashes instead of underscores:

helpers.py line 182

        request.add_header("X_PLIVO_SIGNATURE", "%s" % signature)

Should change to:

request.add_header("X-PLIVO-SIGNATURE", "%s" % signature)

I would send a pull request but I made other changes that I think might mess other things up.

Recorded File Name

It would be nice to have access to the recently recorded file after using restxml record element;

In the scenario where you would want to

  1. Answer The Call
  2. Request the person Speak their name;
  3. Dial a Remote Party
    4 Play the recorded file to the end user
  4. etc...

I think this would be great if you could access it as a channel_var or post_var;

Need B Leg Answer Callback

In order to properly rate calls from dial verbs, we need to have a callback when the b leg is answered. The same format as the b leg hangup would be perfect.

Outgoing Calls Not Working

The bridge command is not being generated properly for the call verb.

XML:

<?xml version="1.0"?>
<Response>
    <Record bothLegs="true" fileFormat="mp3" finishOnKey="#" maxLength="3600" playBeep="true" timeout="5"/>
    <Dial hangupOnStar="false" method="POST" timeLimit="14400" timeout="20">
        <Number gateways="sofia/gateway/sip1">+1908xxxxxxx</Number>
    </Dial>
    <Hangup schedule="0"/>
</Response>

Plivo:

EXECUTE sofia/internal/[email protected] bridge(<>sofia/gateway/sip1/+1908xxxxxxx)
2011-07-11 11:53:54.022303 [DEBUG] switch_ivr_originate.c:1869 Parsing global variables
2011-07-11 11:53:54.022303 [ERR] switch_core_session.c:413 Could not locate channel type <>sofia
2011-07-11 11:53:54.022303 [NOTICE] switch_ivr_originate.c:2443 Cannot create outgoing channel of type [<>sofia] cause: [CHAN_NOT_IMPLEMENTED]

I'm pretty sure it should be {} instead of <> in bridge(<>sofia/gateway/sip1/+1908xxxxxxx)

Basic Auth Doesn't Work for REST server

I am trying to call the Play method from another server, where it would be impractical to add it the the plivo whitelist. I set the sid and token as authentication but I always get a 401 access denied. There's nothing useful in the plivo log. Here's the output of netcat as the server. I'm using the plivo python helper library. It does work when the server is added to the whitelist.

POST /v0.1/Play/ HTTP/1.1
Accept-Encoding: identity
Content-Length: 195
Host: localhost:9099
User-Agent: Python-urllib/2.6
Connection: close
Content-Type: application/x-www-form-urlencoded
Authorization: Basic MWY3NDYwNzgwOGNmNDYwYmFjMTMwYjg2YWU5ODdhNDI6Yzg0Njk2MmIwZWYxNGFiNzk4MWU3ZTI4ZjYxYjcyZjg=

Sounds=http%3A%2F%2Fdl.dropbox.com%2Fu%2F14573179%2FAudio%2FFreeswitch%2Fsounds%2Fen%2Fus%2Fcallie%2Fivr%2Fmp3%2Fivr-you_are_number_one.wav.mp3&Legs=aleg&Call=970502ec-1758-4c68-a469-125ac7be48a9

Here's the python usage:

import plivohelper
import settings
sounds = 'http://dl.dropbox.com/u/14573179/Audio/Freeswitch/sounds/en/us/callie/ivr/mp3/ivr-you_are_number_one.wav.mp3'
p = plivohelper.REST(settings.PLIVO_API_URL, settings.PLIVO_SID, settings.PLIVO_TOKEN, settings.PLIVO_API_VERSION)
p.play({'Sounds': sounds, 'Legs': 'aleg', 'Call': '970502ec-1758-4c68-a469-125ac7be48a9'})

Play not streaming MP3s

2011-05-31 15:55:13,614 outboundserver[4055]: INFO: (12) [Play] http://demo.twilio.com/hellomonkey/monkey.mp3 {'loop': '1'}
2011-05-31 15:55:13,614 outboundserver[4055]: DEBUG: (12) Execute: set args=playback_terminators=none, uuid='', lock=True, loops=1
2011-05-31 15:55:13,631 outboundserver[4055]: DEBUG: (12) Response: <CommandResponse headers={'Content-Type': 'command/reply', 'Reply-Text': '+OK'}, body=>
2011-05-31 15:55:13,632 outboundserver[4055]: DEBUG: (12) Execute: playback args=shout://demo.twilio.com/hellomonkey/monkey.mp3, uuid='', lock=True, loops=1
2011-05-31 15:55:13,634 outboundserver[4055]: DEBUG: (12) Response: <CommandResponse headers={'Content-Type': 'command/reply', 'Reply-Text': '+OK'}, body=>
2011-05-31 15:55:13,634 outboundserver[4055]: DEBUG: (12) Playing 1 times ...
2011-05-31 15:55:13,665 outboundserver[4055]: DEBUG: (12) Play 1 times done (FILE NOT FOUND)
2011-05-31 15:55:13,675 outboundserver[4055]: INFO: (12) Play Finished
2011-05-31 15:55:13,675 outboundserver[4055]: INFO: (12) [Play] Done

Caller ID Not Being Overrirdden with Dial Verb

The following XML is executed when I dial a DID from a SIP phone which sends it's caller id as (732) 276-1300. Instead of the caller id coming up as 17328381916, it comes up as 7322761300, the number dialing from.

<?xml version="1.0"?>
<Response>
    <Dial action="None" callerId="17328381916" hangupOnStar="false" method="POST" timeLimit="14400" timeout="30">
        <Number gateways="sofia/gateway/sip1">+18457026652</Number>
    </Dial>
    <Speak loop="1" voice="slt">The call failed or the remote party hung up. Goodbye</Speak>
</Response>

REST XML not being rendered properly

When I initiate a call via the REST server, I should hear some TTS but I hear silence instead. Freeswitch shows nothing in regards to the Speak command being sent.

Here's the API call using the plivohelper-python lib:

call_params = {
    'From'              : source_address,
    'To'                : destination_address,
    'Gateways'          : DEFAULT_GATEWAYS,
    'ExtraDialString'   : extra_dial_string,
    'AnswerUrl'         : request.build_absolute_uri(reverse('plivo_api.views.outgoing_answered')),
    'HangupUrl'         : request.build_absolute_uri(reverse('plivo_api.views.outgoing_hung_up')),
    'RingUrl'           : "http://api.telapia.com/_plivo/outgoing/ringing/",
    'TimeLimit'         : str(call.allowed_units)
}

result = plivo.call(call_params)

Plivo Log:

2011-06-30 17:29:20,154 plivo-outbound[26161]: INFO: (9) New request from ('127.0.0.1', 48507)
2011-06-30 17:29:20,155 plivo-outbound[26161]: DEBUG: (9) Execute: connect args=''
2011-06-30 17:29:20,160 plivo-outbound[26161]: DEBUG: (9) Response: <CommandResponse headers={'variable_sip_use_codec_rate': '8000', 'Channel-Channel-Progress-Media-Time': '1309469368081094', 'variable_sip_use_codec_ptime': '20', 'Caller-Screen-Bit': 'true', 'variable_is_outbound': 'true', 'Call-Direction': 'outbound', 'Channel-Read-Codec-Bit-Rate': '64000', 'Event-Calling-Line-Number': '1843', 'variable_sip_req_uri': '[email protected]', 'variable_sip_full_from': '"" <sip:[email protected];transport=udp>;tag=v8Kc5vejeF49p', 'Reply-Text': '+OK\n', 'variable_call_uuid': '25797b6d-f590-428a-92df-98d4d4825af3', 'variable_sip_contact_uri': '[email protected]:5060', 'variable_sip_from_params': 'transport=udp', 'Channel-Channel-Created-Time': '1309469365996956', 'Event-Date-Timestamp': '1309469369765254', 'Event-Name': 'CHANNEL_DATA', 'FreeSWITCH-Switchname': 'plivo1.teltechsys.com', 'variable_sip_contact_params': 'transport=udp', 'Unique-ID': '78896797-1785-46c2-bb42-24d9391d46ae', 'variable_originate_early_media': 'false', 'Control': 'full', 'variable_plivo_sched_hangup_id': '01d47060-a360-11e0-8e69-12313b0c4557', 'Caller-Caller-ID-Number': '17328381916', 'variable_ignore_early_media': 'true', 'Caller-Privacy-Hide-Number': 'false', 'variable_sip_audio_recv_pt': '0', 'Channel-Write-Codec-Bit-Rate': '64000', 'Content-Type': 'command/reply', 'Channel-Write-Codec-Rate': '8000', 'variable_sip_to_user': '+17328381916', 'Event-Date-Local': '2011-06-30 17:29:29', 'Channel-Channel-Answered-Time': '1309469369745191', 'Event-Calling-Function': 'parse_command', 'variable_socket_host': '127.0.0.1', 'Caller-Destination-Number': '+17328381916', 'variable_sip_local_sdp_str': 'v=0\no=FreeSWITCH 1309439515 1309439516 IN IP4 50.17.206.81\ns=FreeSWITCH\nc=IN IP4 50.17.206.81\nt=0 0\nm=audio 29850 RTP/AVP 0 8 3 101 13\na=rtpmap:101 telephone-event/8000\na=fmtp:101 0-16\na=ptime:20\na=sendrecv\n', 'Caller-Profile-Index': '2', 'Channel-State': 'CS_EXECUTE', 'variable_plivo_app': 'true', 'variable_sip_contact_port': '5060', 'Caller-Caller-ID-Name': '17328381916', 'Core-UUID': '728288a5-efc6-44e0-8d58-f0753dcabdab', 'Caller-Profile-Created-Time': '1309469369765254', 'variable_sip_call_id': 'd9332edc-1e02-122f-6eac-12313b0c4557', 'variable_channel_name': 'sofia/external/+17328381916', 'Caller-Channel-Answered-Time': '1309469369745191', 'variable_switch_r_sdp': 'v=0\r\no=- 6755 11954 IN IP4 208.93.227.13\r\ns=-\r\nc=IN IP4 208.93.227.13\r\nt=0 0\r\nm=audio 16252 RTP/AVP 0 101\r\na=rtpmap:101 telephone-event/8000\r\na=fmtp:101 0-15\r\na=ptime:20\r\n', 'Answer-State': 'answered', 'Caller-Privacy-Hide-Name': 'false', 'variable_plivo_answer_url': 'http://api.telapia.com/_plivo/outgoing/answered', 'variable_remote_media_ip': '208.93.227.13', 'variable_write_codec': 'PCMU', 'Caller-Context': 'default', 'variable_max_forwards': '70', 'variable_sip_to_uri': '[email protected]', 'variable_sip_reply_port': '5060', 'variable_read_codec': 'PCMU', 'Channel-Channel-Progress-Time': '0', 'Caller-Channel-Created-Time': '1309469365996956', 'variable_endpoint_disposition': 'ANSWER', 'Channel-Context': 'default', 'variable_sip_from_tag': 'v8Kc5vejeF49p', 'Channel-Channel-Transfer-Time': '0', 'variable_sip_from_uri': '[email protected]', 'Channel-Channel-Hangup-Time': '0', 'Event-Date-GMT': 'Thu, 30 Jun 2011 21:29:29 GMT', 'Caller-Channel-Progress-Media-Time': '1309469368081094', 'variable_sip_full_via': 'SIP/2.0/UDP 50.17.206.81:5080;rport=5080;branch=z9hG4bKXNSa9vcQ7XQZg', 'Channel-Read-Codec-Rate': '8000', 'Channel-Profile-Index': '2', 'Channel-Direction': 'outbound', 'Channel-Name': 'sofia/external/+17328381916', 'variable_sip_reply_host': '75.101.162.138', 'variable_sofia_profile_name': 'external', 'Channel-Privacy-Hide-Name': 'false', 'Channel-State-Number': '4', 'variable_sip_destination_url': 'sip:[email protected]', 'Channel-Call-UUID': '25797b6d-f590-428a-92df-98d4d4825af3', 'variable_bridge_early_media': 'true', 'Channel-Caller-ID-Name': '17328381916', 'Caller-Dialplan': 'inline', 'variable_local_media_ip': '50.17.206.81', 'variable_rtp_use_ssrc': '75530', 'Caller-Source': 'src/switch_ivr_originate.c', 'variable_sip_network_ip': '75.101.162.138', 'Caller-Channel-Name': 'sofia/external/+17328381916', 'FreeSWITCH-IPv4': '10.98.70.165', 'FreeSWITCH-IPv6': '::1', 'Channel-Network-Addr': '75.101.162.138', 'variable_sip_full_to': '<sip:[email protected]>;tag=7KctBp3U43X1p', 'Channel-Dialplan': 'inline', 'variable_local_media_port': '29850', 'variable_sip_gateway_name': 'sip1', 'Caller-Channel-Transfer-Time': '0', 'variable_current_application': 'socket', 'variable_sip_profile_name': 'gateway', 'Event-Calling-File': 'mod_event_socket.c', 'Channel-Destination-Number': '+17328381916', 'variable_remote_media_port': '16252', 'Channel-Write-Codec-Name': 'PCMU', 'variable_current_application_data': '127.0.0.1:8084 async full', 'Channel-Source': 'src/switch_ivr_originate.c', 'Channel-Profile-Created-Time': '1309469369765254', 'variable_sip_network_port': '5060', 'Caller-Unique-ID': '78896797-1785-46c2-bb42-24d9391d46ae', 'variable_sip_to_host': 'sip1.teltechsys.com', 'Channel-Screen-Bit': 'true', 'variable_origination_caller_id_number': '555', 'Presence-Call-Direction': 'outbound', 'variable_pre_transfer_caller_id_number': '555', 'Channel-Read-Codec-Name': 'PCMU', 'variable_write_rate': '8000', 'variable_sip_contact_user': '7328381916', 'variable_sip_contact_host': '75.127.90.67', 'variable_sip_local_network_addr': '50.17.206.81', 'variable_plivo_request_uuid': '01d46c32-a360-11e0-8e69-12313b0c4557', 'variable_sip_cseq': '14398614', 'variable_read_rate': '8000', 'variable_sip_from_host': 'sip1.teltechsys.com', 'variable_sip_to_tag': '7KctBp3U43X1p', 'Caller-Channel-Hangup-Time': '0', 'Channel-Caller-ID-Number': '17328381916', 'Channel-Channel-Name': 'sofia/external/+17328381916', 'variable_sip_use_pt': '0', 'Channel-Privacy-Hide-Number': 'false', 'Caller-Direction': 'outbound', 'variable_uuid': '78896797-1785-46c2-bb42-24d9391d46ae', 'variable_direction': 'outbound', 'variable_sip_outgoing_contact_uri': '<sip:[email protected]:5080;transport=udp;gw=sip1>', 'Caller-Network-Addr': '75.101.162.138', 'Channel-Unique-ID': '78896797-1785-46c2-bb42-24d9391d46ae', 'variable_originate_timeout': '60', 'variable_sip_from_user': 'kamailio', 'Socket-Mode': 'async', 'variable_sip_use_codec_name': 'PCMU', 'Caller-Channel-Progress-Time': '0', 'FreeSWITCH-Hostname': 'plivo1.teltechsys.com', 'Channel-Call-State': 'ACTIVE', 'variable_api_on_answer': 'sched_api 01d47060-a360-11e0-8e69-12313b0c4557 +34602 hupall ALLOTTED_TIMEOUT plivo_request_uuid 01d46c32-a360-11e0-8e69-12313b0c4557'}, body=>
2011-06-30 17:29:20,160 plivo-outbound[26161]: DEBUG: (9) Execute: resume args=''
2011-06-30 17:29:20,221 plivo-outbound[26161]: DEBUG: (9) Response: <CommandResponse headers={'Content-Type': 'command/reply', 'Reply-Text': '+OK'}, body=>
2011-06-30 17:29:20,222 plivo-outbound[26161]: DEBUG: (9) Execute: linger args=''
2011-06-30 17:29:20,222 plivo-outbound[26161]: DEBUG: (9) Response: <CommandResponse headers={'Content-Type': 'command/reply', 'Reply-Text': '+OK will linger'}, body=>
2011-06-30 17:29:20,222 plivo-outbound[26161]: DEBUG: (9) Execute: myevents json args=''
2011-06-30 17:29:20,223 plivo-outbound[26161]: DEBUG: (9) Response: <CommandResponse headers={'Content-Type': 'command/reply', 'Reply-Text': '+OK Events Enabled'}, body=>
2011-06-30 17:29:20,223 plivo-outbound[26161]: DEBUG: (9) Execute: event json args='CUSTOM conference::maintenance'
2011-06-30 17:29:20,223 plivo-outbound[26161]: DEBUG: (9) Response: <CommandResponse headers={'Content-Type': 'command/reply', 'Reply-Text': '+OK event listener enabled json'}, body=>
2011-06-30 17:29:20,224 plivo-outbound[26161]: DEBUG: (9) Execute: set args=plivo_app=true, uuid='', lock=True, loops=1
2011-06-30 17:29:20,224 plivo-outbound[26161]: DEBUG: (9) Response: <CommandResponse headers={'Content-Type': 'command/reply', 'Reply-Text': '+OK'}, body=>
2011-06-30 17:29:20,225 plivo-outbound[26161]: DEBUG: (9) Execute: set args=hangup_after_bridge=false, uuid='', lock=True, loops=1
2011-06-30 17:29:20,225 plivo-outbound[26161]: DEBUG: (9) Response: <CommandResponse headers={'Content-Type': 'command/reply', 'Reply-Text': '+OK'}, body=>
2011-06-30 17:29:20,225 plivo-outbound[26161]: INFO: (9) Using AnswerUrl http://api.telapia.com/_plivo/outgoing/answered
2011-06-30 17:29:20,226 plivo-outbound[26161]: DEBUG: (9) Execute: unset args=plivo_sched_hangup_id, uuid='', lock=True, loops=1
2011-06-30 17:29:20,226 plivo-outbound[26161]: DEBUG: (9) Response: <CommandResponse headers={'Content-Type': 'command/reply', 'Reply-Text': '+OK'}, body=>
2011-06-30 17:29:20,226 plivo-outbound[26161]: INFO: (9) Processing Call
2011-06-30 17:29:20,227 plivo-outbound[26161]: INFO: (9) Fetching RESTXML from http://api.telapia.com/_plivo/outgoing/answered with {}
2011-06-30 17:29:20,378 plivo-outbound[26161]: INFO: (9) Sent to POST http://api.telapia.com/_plivo/outgoing/answered with {'Direction': 'outbound', 'From': '17328381916', 'ALegUUID': '78896797-1785-46c2-bb42-24d9391d46ae', 'CallStatus': 'in-progress', 'To': '17328381916', 'ALegRequestUUID': '01d46c32-a360-11e0-8e69-12313b0c4557', 'CallUUID': '78896797-1785-46c2-bb42-24d9391d46ae', 'ScheduledHangupId': '01d47060-a360-11e0-8e69-12313b0c4557'} -- Result: <Response><Speak loop="1" voice="slt">Hello</Speak></Response>
2011-06-30 17:29:20,378 plivo-outbound[26161]: INFO: (9) Requested RESTXML to http://api.telapia.com/_plivo/outgoing/answered with {'Direction': 'outbound', 'From': '17328381916', 'ALegUUID': '78896797-1785-46c2-bb42-24d9391d46ae', 'CallStatus': 'in-progress', 'To': '17328381916', 'ALegRequestUUID': '01d46c32-a360-11e0-8e69-12313b0c4557', 'CallUUID': '78896797-1785-46c2-bb42-24d9391d46ae', 'ScheduledHangupId': '01d47060-a360-11e0-8e69-12313b0c4557'}
2011-06-30 17:29:20,378 plivo-outbound[26161]: INFO: (9) [Speak] Hello {'engine': 'flite', 'language': 'en', 'voice': 'slt', 'type': '', 'method': '', 'loop': '1'}
2011-06-30 17:29:20,378 plivo-outbound[26161]: DEBUG: (9) Execute: speak args=flite|slt|Hello, uuid='', lock=True, loops=1
2011-06-30 17:29:20,386 plivo-outbound[26161]: DEBUG: (9) Response: <CommandResponse headers={'Content-Type': 'command/reply', 'Reply-Text': '+OK'}, body=>
2011-06-30 17:29:20,386 plivo-outbound[26161]: DEBUG: (9) Speaking 1 times ...
2011-06-30 17:29:20,398 plivo-outbound[26161]: INFO: (9) Event: channel 78896797-1785-46c2-bb42-24d9391d46ae has hung up (ALLOTTED_TIMEOUT)
2011-06-30 17:29:20,398 plivo-outbound[26161]: WARNING: (9) Speak Break (empty event)
2011-06-30 17:29:20,398 plivo-outbound[26161]: INFO: (9) [Speak] Done
2011-06-30 17:29:20,398 plivo-outbound[26161]: INFO: (9) End of RESTXML
2011-06-30 17:29:20,398 plivo-outbound[26161]: INFO: (9) Processing Call Ended
2011-06-30 17:29:20,399 plivo-outbound[26161]: DEBUG: (9) Releasing Connection ...
2011-06-30 17:29:20,399 plivo-outbound[26161]: DEBUG: (9) Releasing Connection Done
2011-06-30 17:29:20,399 plivo-outbound[26161]: INFO: (9) End request from ('127.0.0.1', 48507)

Freeswitch log:

2011-06-30 17:29:25.996956 [DEBUG] switch_ivr_originate.c:1869 Parsing global variables
2011-06-30 17:29:25.996956 [DEBUG] switch_event.c:1423 Parsing variable [plivo_request_uuid]=[01d46c32-a360-11e0-8e69-12313b0c4557]
2011-06-30 17:29:25.996956 [DEBUG] switch_event.c:1423 Parsing variable [plivo_answer_url]=[http://api.telapia.com/_plivo/outgoing/answered]
2011-06-30 17:29:25.996956 [DEBUG] switch_event.c:1423 Parsing variable [origination_caller_id_number]=[555]
2011-06-30 17:29:25.996956 [DEBUG] switch_event.c:1423 Parsing variable [bridge_early_media]=[true]
2011-06-30 17:29:25.996956 [DEBUG] switch_event.c:1423 Parsing variable [api_on_answer]=[sched_api 01d47060-a360-11e0-8e69-12313b0c4557 +34602 hupall ALLOTTED_TIMEOUT plivo_request_uuid 01d46c32-a360-11e0-8e69-12313b0c4557]
2011-06-30 17:29:25.996956 [DEBUG] switch_event.c:1423 Parsing variable [plivo_sched_hangup_id]=[01d47060-a360-11e0-8e69-12313b0c4557]
2011-06-30 17:29:25.996956 [DEBUG] switch_event.c:1423 Parsing variable [plivo_app]=[true]
2011-06-30 17:29:25.996956 [DEBUG] switch_event.c:1423 Parsing variable [originate_timeout]=[60]
2011-06-30 17:29:25.996956 [DEBUG] switch_event.c:1423 Parsing variable [ignore_early_media]=[true]
2011-06-30 17:29:25.996956 [NOTICE] switch_channel.c:890 New Channel sofia/external/+17328381916 [78896797-1785-46c2-bb42-24d9391d46ae]
2011-06-30 17:29:25.996956 [DEBUG] mod_sofia.c:4412 (sofia/external/+17328381916) State Change CS_NEW -> CS_INIT
2011-06-30 17:29:25.996956 [DEBUG] switch_core_session.c:1118 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:25.996956 [DEBUG] switch_core_state_machine.c:325 (sofia/external/+17328381916) Running State Change CS_INIT
2011-06-30 17:29:25.996956 [DEBUG] switch_core_state_machine.c:364 (sofia/external/+17328381916) State INIT
2011-06-30 17:29:25.996956 [DEBUG] mod_sofia.c:85 sofia/external/+17328381916 SOFIA INIT
2011-06-30 17:29:25.996956 [DEBUG] mod_sofia.c:125 (sofia/external/+17328381916) State Change CS_INIT -> CS_ROUTING
2011-06-30 17:29:25.996956 [DEBUG] switch_core_session.c:773 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:25.996956 [DEBUG] switch_core_session.c:1118 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:25.996956 [DEBUG] switch_core_state_machine.c:364 (sofia/external/+17328381916) State INIT going to sleep
2011-06-30 17:29:25.996956 [DEBUG] switch_core_state_machine.c:325 (sofia/external/+17328381916) Running State Change CS_ROUTING
2011-06-30 17:29:25.996956 [DEBUG] switch_channel.c:1805 (sofia/external/+17328381916) Callstate Change DOWN -> RINGING
2011-06-30 17:29:25.996956 [DEBUG] switch_core_state_machine.c:373 (sofia/external/+17328381916) State ROUTING
2011-06-30 17:29:25.996956 [DEBUG] mod_sofia.c:148 sofia/external/+17328381916 SOFIA ROUTING
2011-06-30 17:29:25.996956 [DEBUG] switch_ivr_originate.c:66 (sofia/external/+17328381916) State Change CS_ROUTING -> CS_CONSUME_MEDIA
2011-06-30 17:29:25.996956 [DEBUG] switch_core_session.c:1118 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:25.996956 [DEBUG] switch_core_state_machine.c:373 (sofia/external/+17328381916) State ROUTING going to sleep
2011-06-30 17:29:25.996956 [DEBUG] switch_core_state_machine.c:325 (sofia/external/+17328381916) Running State Change CS_CONSUME_MEDIA
2011-06-30 17:29:25.996956 [DEBUG] switch_core_state_machine.c:392 (sofia/external/+17328381916) State CONSUME_MEDIA
2011-06-30 17:29:25.996956 [DEBUG] switch_core_state_machine.c:392 (sofia/external/+17328381916) State CONSUME_MEDIA going to sleep
2011-06-30 17:29:25.996956 [DEBUG] sofia.c:5074 Channel sofia/external/+17328381916 entering state [calling][0]
2011-06-30 17:29:28.081094 [DEBUG] switch_core_session.c:773 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:28.081094 [DEBUG] switch_core_session.c:773 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:28.081094 [INFO] sofia.c:761 sofia/external/+17328381916 Update Callee ID to "17328381916" <17328381916>
2011-06-30 17:29:28.081094 [DEBUG] sofia.c:5074 Channel sofia/external/+17328381916 entering state [proceeding][183]
2011-06-30 17:29:28.081094 [DEBUG] sofia.c:5085 Remote SDP:
v=0
o=- 6755 11954 IN IP4 208.93.227.13
s=-
c=IN IP4 208.93.227.13
t=0 0
m=audio 16252 RTP/AVP 0 101
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=ptime:20

2011-06-30 17:29:28.081094 [DEBUG] sofia_glue.c:4711 Audio Codec Compare [PCMU:0:8000:20:64000]/[PCMU:0:8000:20:64000]
2011-06-30 17:29:28.081094 [DEBUG] sofia_glue.c:2819 Set Codec sofia/external/+17328381916 PCMU/8000 20 ms 160 samples 64000 bits
2011-06-30 17:29:28.081094 [DEBUG] sofia_glue.c:4819 Set 2833 dtmf send payload to 101
2011-06-30 17:29:28.081094 [DEBUG] sofia_glue.c:3072 AUDIO RTP [sofia/external/+17328381916] 10.98.70.165 port 29850 -> 208.93.227.13 port 16252 codec: 0 ms: 20
2011-06-30 17:29:28.081094 [DEBUG] switch_rtp.c:1636 Starting timer [soft] 160 bytes per 20ms
2011-06-30 17:29:28.081094 [DEBUG] sofia_glue.c:3334 Set 2833 dtmf send payload to 101
2011-06-30 17:29:28.081094 [DEBUG] sofia_glue.c:3339 Set 2833 dtmf receive payload to 101
2011-06-30 17:29:28.081094 [NOTICE] sofia_glue.c:3843 Pre-Answer sofia/external/+17328381916!
2011-06-30 17:29:28.081094 [DEBUG] switch_channel.c:2799 (sofia/external/+17328381916) Callstate Change RINGING -> EARLY
2011-06-30 17:29:29.745191 [DEBUG] switch_core_session.c:773 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:29.745191 [DEBUG] switch_core_session.c:773 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:29.745191 [DEBUG] switch_core_session.c:773 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:29.745191 [DEBUG] sofia.c:5074 Channel sofia/external/+17328381916 entering state [ready][200]
2011-06-30 17:29:29.745191 [DEBUG] sofia.c:5082 Duplicate SDP
v=0
o=- 6755 11954 IN IP4 208.93.227.13
s=-
c=IN IP4 208.93.227.13
t=0 0
m=audio 16252 RTP/AVP 0 101
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=ptime:20

2011-06-30 17:29:29.745191 [DEBUG] switch_channel.c:2990 (sofia/external/+17328381916) Callstate Change EARLY -> ACTIVE
2011-06-30 17:29:29.745191 [NOTICE] sofia.c:5679 Channel [sofia/external/+17328381916] has been answered
2011-06-30 17:29:29.745191 [DEBUG] switch_scheduler.c:214 Added task 20 sched_api_function (+34602) to run at 1
2011-06-30 17:29:29.745191 [DEBUG] switch_channel.c:3051 sofia/external/+17328381916 api on answer: sched_api(01d47060-a360-11e0-8e69-12313b0c4557 +34602 hupall ALLOTTED_TIMEOUT plivo_request_uuid 01d46c32-a360-11e0-8e69-12313b0c4557)
+OK Added: 20

2011-06-30 17:29:29.765254 [DEBUG] switch_ivr_originate.c:3214 Originate Resulted in Success: [sofia/external/+17328381916]
2011-06-30 17:29:29.765254 [DEBUG] switch_ivr.c:1622 (sofia/external/+17328381916) State Change CS_CONSUME_MEDIA -> CS_ROUTING
2011-06-30 17:29:29.765254 [DEBUG] switch_core_session.c:1118 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:29.765254 [DEBUG] switch_core_session.c:711 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:29.765254 [NOTICE] switch_ivr.c:1628 Transfer sofia/external/+17328381916 to inline[socket:127.0.0.1:8084 async full@default]
2011-06-30 17:29:29.765254 [DEBUG] switch_core_state_machine.c:325 (sofia/external/+17328381916) Running State Change CS_ROUTING
2011-06-30 17:29:29.765254 [DEBUG] switch_channel.c:1805 (sofia/external/+17328381916) Callstate Change ACTIVE -> RINGING
2011-06-30 17:29:29.765254 [DEBUG] switch_core_state_machine.c:373 (sofia/external/+17328381916) State ROUTING
2011-06-30 17:29:29.765254 [DEBUG] mod_sofia.c:148 sofia/external/+17328381916 SOFIA ROUTING
2011-06-30 17:29:29.765254 [DEBUG] switch_core_state_machine.c:77 sofia/external/+17328381916 Standard ROUTING
2011-06-30 17:29:29.765254 [INFO] switch_channel.c:2607 sofia/external/+17328381916 Flipping CID from "" <555> to "17328381916" <17328381916>
2011-06-30 17:29:29.765254 [DEBUG] switch_core_state_machine.c:119 (sofia/external/+17328381916) State Change CS_ROUTING -> CS_EXECUTE
2011-06-30 17:29:29.765254 [DEBUG] switch_core_session.c:1118 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:29.765254 [DEBUG] switch_core_state_machine.c:373 (sofia/external/+17328381916) State ROUTING going to sleep
2011-06-30 17:29:29.765254 [DEBUG] switch_core_state_machine.c:325 (sofia/external/+17328381916) Running State Change CS_EXECUTE
2011-06-30 17:29:29.765254 [DEBUG] switch_channel.c:1807 (sofia/external/+17328381916) Callstate Change RINGING -> ACTIVE
2011-06-30 17:29:29.765254 [DEBUG] switch_core_state_machine.c:380 (sofia/external/+17328381916) State EXECUTE
2011-06-30 17:29:29.765254 [DEBUG] mod_sofia.c:241 sofia/external/+17328381916 SOFIA EXECUTE
2011-06-30 17:29:29.765254 [DEBUG] switch_core_state_machine.c:157 sofia/external/+17328381916 Standard EXECUTE
EXECUTE sofia/external/+17328381916 socket(127.0.0.1:8084 async full)
2011-06-30 17:29:29.765254 [DEBUG] switch_core_session.c:956 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:29.765254 [DEBUG] switch_core_session.c:956 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:29.765254 [DEBUG] switch_core_session.c:956 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:29.893827 [DEBUG] switch_ivr.c:576 sofia/external/+17328381916 Command Execute set(plivo_app=true)
EXECUTE sofia/external/+17328381916 set(plivo_app=true)
2011-06-30 17:29:29.893827 [DEBUG] mod_dptools.c:1063 sofia/external/+17328381916 SET [plivo_app]=[true]
2011-06-30 17:29:29.893827 [DEBUG] switch_ivr.c:576 sofia/external/+17328381916 Command Execute set(hangup_after_bridge=false)
EXECUTE sofia/external/+17328381916 set(hangup_after_bridge=false)
2011-06-30 17:29:29.893827 [DEBUG] mod_dptools.c:1063 sofia/external/+17328381916 SET [hangup_after_bridge]=[false]
2011-06-30 17:29:29.893827 [DEBUG] switch_ivr.c:576 sofia/external/+17328381916 Command Execute unset(plivo_sched_hangup_id)
EXECUTE sofia/external/+17328381916 unset(plivo_sched_hangup_id)
2011-06-30 17:29:29.893827 [DEBUG] mod_dptools.c:1180 UNSET [plivo_sched_hangup_id]
2011-06-30 17:29:29.933264 [DEBUG] switch_rtp.c:3104 Correct ip/port confirmed.
2011-06-30 17:29:29.993280 [DEBUG] switch_core_session.c:956 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:29.993280 [DEBUG] switch_ivr.c:576 sofia/external/+17328381916 Command Execute speak(flite|slt|Hello)
EXECUTE sofia/external/+17328381916 speak(flite|slt|Hello)
2011-06-30 17:29:29.993280 [DEBUG] switch_ivr_play_say.c:2392 OPEN TTS flite
2011-06-30 17:29:29.993280 [DEBUG] switch_ivr_play_say.c:2401 Raw Codec Activated
2011-06-30 17:29:29.993280 [WARNING] switch_scheduler.c:114 Task was executed late by 1309469368 seconds 20 sched_api_function (+34602)
2011-06-30 17:29:29.993280 [DEBUG] switch_channel.c:2723 (sofia/external/+17328381916) Callstate Change ACTIVE -> HANGUP
2011-06-30 17:29:29.993280 [NOTICE] switch_core_session.c:223 Hangup sofia/external/+17328381916 [CS_EXECUTE] [ALLOTTED_TIMEOUT]
2011-06-30 17:29:29.993280 [DEBUG] switch_channel.c:2739 Send signal sofia/external/+17328381916 [KILL]
2011-06-30 17:29:29.993280 [DEBUG] switch_core_session.c:1118 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:29.993280 [DEBUG] mod_commands.c:3584 Command hupall(ALLOTTED_TIMEOUT plivo_request_uuid 01d46c32-a360-11e0-8e69-12313b0c4557):
+OK hangup all channels matching [plivo_request_uuid]=[01d46c32-a360-11e0-8e69-12313b0c4557] with cause: ALLOTTED_TIMEOUT

2011-06-30 17:29:29.993280 [DEBUG] switch_scheduler.c:138 Deleting task 20 sched_api_function (+34602)
2011-06-30 17:29:30.013272 [DEBUG] switch_ivr_play_say.c:2092 Speaking text: Hello
2011-06-30 17:29:30.033269 [DEBUG] switch_ivr_play_say.c:2284 done speaking text
2011-06-30 17:29:30.033269 [DEBUG] switch_core_session.c:2090 sofia/external/+17328381916 skip receive message [APPLICATION_EXEC_COMPLETE] (channel is hungup already)
2011-06-30 17:29:30.033269 [DEBUG] switch_core_session.c:2090 sofia/external/+17328381916 skip receive message [APPLICATION_EXEC_COMPLETE] (channel is hungup already)
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:380 (sofia/external/+17328381916) State EXECUTE going to sleep
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:325 (sofia/external/+17328381916) Running State Change CS_HANGUP
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:575 (sofia/external/+17328381916) State HANGUP
2011-06-30 17:29:30.033269 [DEBUG] mod_sofia.c:458 Channel sofia/external/+17328381916 hanging up, cause: ALLOTTED_TIMEOUT
2011-06-30 17:29:30.033269 [DEBUG] mod_sofia.c:501 Sending BYE to sofia/external/+17328381916
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:46 sofia/external/+17328381916 Standard HANGUP, cause: ALLOTTED_TIMEOUT
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:575 (sofia/external/+17328381916) State HANGUP going to sleep
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:356 (sofia/external/+17328381916) State Change CS_HANGUP -> CS_REPORTING
2011-06-30 17:29:30.033269 [DEBUG] switch_core_session.c:1118 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:325 (sofia/external/+17328381916) Running State Change CS_REPORTING
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:635 (sofia/external/+17328381916) State REPORTING
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:53 sofia/external/+17328381916 Standard REPORTING, cause: ALLOTTED_TIMEOUT
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:635 (sofia/external/+17328381916) State REPORTING going to sleep
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:350 (sofia/external/+17328381916) State Change CS_REPORTING -> CS_DESTROY
2011-06-30 17:29:30.033269 [DEBUG] switch_core_session.c:1118 Send signal sofia/external/+17328381916 [BREAK]
2011-06-30 17:29:30.033269 [DEBUG] switch_core_session.c:1290 Session 199 (sofia/external/+17328381916) Locked, Waiting on external entities
2011-06-30 17:29:30.033269 [NOTICE] switch_core_session.c:1308 Session 199 (sofia/external/+17328381916) Ended
2011-06-30 17:29:30.033269 [NOTICE] switch_core_session.c:1310 Close Channel sofia/external/+17328381916 [CS_DESTROY]
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:464 (sofia/external/+17328381916) Callstate Change HANGUP -> DOWN
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:467 (sofia/external/+17328381916) Running State Change CS_DESTROY
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:477 (sofia/external/+17328381916) State DESTROY
2011-06-30 17:29:30.033269 [DEBUG] mod_sofia.c:363 sofia/external/+17328381916 SOFIA DESTROY
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:60 sofia/external/+17328381916 Standard DESTROY
2011-06-30 17:29:30.033269 [DEBUG] switch_core_state_machine.c:477 (sofia/external/+17328381916) State DESTROY going to sleep

Need B Leg Hangup Callback

Something like <Dial blegHangupUrl="..."> so we can be notified when the dial verb terminates for rating and such.

I think you meant... (outbound_socket.get_var())

On line 1120 of Elements.py

ERROR: (3) File "/usr/local/plivo2/lib/python2.6/site-packages/plivo-0.1.0-py2.6.egg/plivo/rest/freeswitch/outboundsocket.py", line 386, in _run
2011-07-07 16:19:38,952 plivo-outbound[17471]: ERROR: (3) self.process_call()
2011-07-07 16:19:38,952 plivo-outbound[17471]: ERROR: (3) File "/usr/local/plivo2/lib/python2.6/site-packages/plivo-0.1.0-py2.6.egg/plivo/rest/freeswitch/outboundsocket.py", line 414, in process_call
2011-07-07 16:19:38,952 plivo-outbound[17471]: ERROR: (3) self.execute_xml()
2011-07-07 16:19:38,952 plivo-outbound[17471]: ERROR: (3) File "/usr/local/plivo2/lib/python2.6/site-packages/plivo-0.1.0-py2.6.egg/plivo/rest/freeswitch/outboundsocket.py", line 549, in execute_xml
2011-07-07 16:19:38,952 plivo-outbound[17471]: ERROR: (3) element_instance.run(self)
2011-07-07 16:19:38,953 plivo-outbound[17471]: ERROR: (3) File "/usr/local/plivo2/lib/python2.6/site-packages/plivo-0.1.0-py2.6.egg/plivo/rest/freeswitch/elements.py", line 128, in run
2011-07-07 16:19:38,953 plivo-outbound[17471]: ERROR: (3) result = execute(outbound_socket)
2011-07-07 16:19:38,953 plivo-outbound[17471]: ERROR: (3) File "/usr/local/plivo2/lib/python2.6/site-packages/plivo-0.1.0-py2.6.egg/plivo/rest/freeswitch/elements.py", line 1120, in execute
2011-07-07 16:19:38,953 plivo-outbound[17471]: ERROR: (3) record_digits = self.get_var("playback_terminator_used")

Call verb dials all gateways at once instead of sequentially

Note the gateways attribute in the dial element. That will result in two simultaneous calls to the same number. In my case they both went to my cell's voicemail.

<?xml version="1.0"?>
<Response>
    <Dial action="" callerId="" hangupOnStar="false" method="POST" timeLimit="14400" timeout="30">
        <Number gateways="sofia/gateway/flowroute,sofia/gateway/flowroute">1732838XXXX</Number>
    </Dial>
    <Speak loop="1" voice="slt">The call failed or the remote party hung up. Goodbye</Speak>
</Response>

ujson 1.6 breaking installer

On ubuntu, the installer is crashing when it tries to easy_install ujson. The fix is to change the plivo setup.py file from ujson to ujson==1.4

Here's the error:

  Running setup.py egg_info for package ujson
    /usr/lib/python2.7/distutils/extension.py:133: UserWarning: Unknown Extension options: 'headers'
      warnings.warn(msg)
    Traceback (most recent call last):
      File "<string>", line 14, in <module>
      File "/usr/local/plivo/build/ujson/setup.py", line 31, in <module>
        version = get_version(),
      File "/usr/local/plivo/build/ujson/setup.py", line 21, in get_version
        file = open(filename)
    IOError: [Errno 2] No such file or directory: '/usr/local/plivo/build/ujson/version.h'
    Complete output from command python setup.py egg_info:
    /usr/lib/python2.7/distutils/extension.py:133: UserWarning: Unknown Extension options: 'headers'

  warnings.warn(msg)

Traceback (most recent call last):

  File "<string>", line 14, in <module>

  File "/usr/local/plivo/build/ujson/setup.py", line 31, in <module>

    version = get_version(),

  File "/usr/local/plivo/build/ujson/setup.py", line 21, in get_version

    file = open(filename)

IOError: [Errno 2] No such file or directory: '/usr/local/plivo/build/ujson/version.h'

Couldn't Terminate a Call

This is the log in the REST server:

2011-05-27 17:51:54,588 apiserver[34070]: INFO: Executed Call hangup for RequestUUID dc196591-5433-488b-ae6b-e4f2ca794b2b
2011-05-27 17:51:54,588 apiserver[34070]: INFO: 127.0.0.1 - - [2011-05-27 17:51:54] "POST /v0.1/HangupCall/ HTTP/1.1" 200 58 "-" "Python-urllib/2.6"

No error, but call kept going.

Setting Plivo hangup_url from Channel Var.

Since we have plivo_answer_url we should also have plivo_hangup_url and even perhaps xfer_url?

I noticed I am not getting post backs on hangup to the right url it is going to the default URL...

GetDigits not receiving DTMF

My action URL is called inconsistently, but even when it is called, it never receives digits, even thought Freeswitch appears to be queuing them:

plivo-outbound:

2011-08-23 22:28:21,657 plivo-outbound[8003]: INFO: (1) Processing Call
2011-08-23 22:28:21,657 plivo-outbound[8003]: INFO: (1) Fetching RESTXML from http://127.0.0.1:5000/inbound/answered with {}
2011-08-23 22:28:21,713 plivo-outbound[8003]: INFO: (1) Sent to POST http://127.0.0.1:5000/inbound/answered with {'To': '9711231234', 'Direction': 'inbound', 'From': '5031231234', 'CallUUID': 'ae2e093c-cdb5-11e0-9c64-d9ad09e6366b', 'CallStatus': 'ringing'} -- Result: <Response><GetDigits action="http://127.0.0.1:5000/inbound/getdigits"><Play>/usr/local/freeswitch/scripts/jovan-welcome.wav</Play></GetDigits></Response>
2011-08-23 22:28:21,714 plivo-outbound[8003]: INFO: (1) Requested RESTXML to http://127.0.0.1:5000/inbound/answered with {'To': '9711231234', 'Direction': 'inbound', 'From': '5031231234', 'CallUUID': 'ae2e093c-cdb5-11e0-9c64-d9ad09e6366b', 'CallStatus': 'ringing'}
2011-08-23 22:28:21,863 plivo-outbound[8003]: DEBUG: (1) Answering because Element GetDigits need it
2011-08-23 22:28:21,863 plivo-outbound[8003]: DEBUG: (1) Execute: answer args=, uuid='', lock=True, loops=1
2011-08-23 22:28:21,868 plivo-outbound[8003]: DEBUG: (1) Response: <CommandResponse headers={'Content-Type': 'command/reply', 'Reply-Text': '+OK'}, body=>
2011-08-23 22:28:21,868 plivo-outbound[8003]: INFO: (1) [GetDigits]  {'finishOnKey': '#', 'retries': 1, 'timeout': 5, 'validDigits': '0123456789*#', 'invalidDigitsSound': '', 'playBeep': 'false', 'action': 'http://127.0.0.1:5000/inbound/getdigits', 'method': 'POST', 'numDigits': 99}
2011-08-23 22:28:21,868 plivo-outbound[8003]: INFO: (1) GetDigits Started ['/usr/local/freeswitch/scripts/jovan-welcome.wav']
2011-08-23 22:28:21,868 plivo-outbound[8003]: DEBUG: (1) Execute: set args=playback_delimiter=!, uuid='', lock=True, loops=1
2011-08-23 22:28:21,871 plivo-outbound[8003]: DEBUG: (1) Response: <CommandResponse headers={'Content-Type': 'command/reply', 'Reply-Text': '+OK'}, body=>
2011-08-23 22:28:21,872 plivo-outbound[8003]: DEBUG: (1) Execute: play_and_get_digits args=1 99 1 5000 '#' file_string://silence_stream://1!/usr/local/freeswitch/scripts/jovan-welcome.wav silence_stream://150 pagd_input (0|1|2|3|4|5|6|7|8|9|\*|#)+ 5000, uuid='', lock=True, loops=1
2011-08-23 22:28:21,875 plivo-outbound[8003]: DEBUG: (1) Response: <CommandResponse headers={'Content-Type': 'command/reply', 'Reply-Text': '+OK'}, body=>
2011-08-23 22:28:35,298 plivo-outbound[8003]: DEBUG: (1) Execute: api args='uuid_getvar ae2e093c-cdb5-11e0-9c64-d9ad09e6366b pagd_input'
2011-08-23 22:28:35,302 plivo-outbound[8003]: DEBUG: (1) Response: <ApiResponse headers={'Content-Length': '7', 'Content-Type': 'api/response'}, body=_undef_>
2011-08-23 22:28:35,303 plivo-outbound[8003]: INFO: (1) GetDigits, No Digits Received
2011-08-23 22:28:35,303 plivo-outbound[8003]: INFO: (1) [GetDigits] Done
2011-08-23 22:28:35,303 plivo-outbound[8003]: DEBUG: (1) Execute: api args='uuid_getvar ae2e093c-cdb5-11e0-9c64-d9ad09e6366b plivo_transfer_progress'
2011-08-23 22:28:35,305 plivo-outbound[8003]: DEBUG: (1) Response: <ApiResponse headers={'Content-Length': '7', 'Content-Type': 'api/response'}, body=_undef_>
2011-08-23 22:28:35,305 plivo-outbound[8003]: INFO: (1) No more Elements, Hangup Now !
2011-08-23 22:28:35,306 plivo-outbound[8003]: DEBUG: (1) Execute: hangup args=, uuid='', lock=True, loops=1

Freeswitch console:

2011-08-23 11:28:21.905651 [DEBUG] switch_ivr.c:551 FreeTDM/1:14/9711231234 Command Execute play_and_get_digits(1 99 1 5000 '#' file_string://silence_stream://1!/usr/local/freeswitch/scripts/jovan-welcome.wav silence_stream://150 pagd_input (0|1|2|3|4|5|6|7|8|9|\*|#)+ 5000)
EXECUTE FreeTDM/1:14/9711231234 play_and_get_digits(1 99 1 5000 '#' file_string://silence_stream://1!/usr/local/freeswitch/scripts/jovan-welcome.wav silence_stream://150 pagd_input (0|1|2|3|4|5|6|7|8|9|\*|#)+ 5000)
2011-08-23 11:28:21.905651 [DEBUG] switch_ivr_play_say.c:1162 Codec Activated L16@8000hz 1 channels 20ms
2011-08-23 11:28:22.076658 [DEBUG] switch_ivr_play_say.c:1476 done playing file
2011-08-23 11:28:30.746081 [DEBUG] ftdm_io.c:2868 [s1c14][1:14] Queuing DTMF 1
2011-08-23 11:28:30.746081 [DEBUG] mod_freetdm.c:698 Queuing DTMF [1] in channel FreeTDM/1:14/9711231234
2011-08-23 11:28:30.746081 [DEBUG] switch_ivr_play_say.c:1476 done playing file

When hanging up A-leg, call doesn't hangup

Here's an example:

  • I call a DID which returns an XML documents containing a dial verb.
  • The destination number begins to ring
  • I hang up the A-leg
  • The destination phone continues to ring
  • If I answer the phone, it will then hangup

Shouldn't the recording result be sent even after hangup?

Hi,

I'm trying to implement voicemail functionality using Plivo, but when a recording is made and the caller hangs up before reaching the time limit, it doesn't send the result to the action url specified.

Browsing through the code, I found this:
elements.py line 1346

            # don't send record result if call has hangup
            self.fetch_rest_xml(self.action, params, method=self.method)

If this can't be changed, is there a work around I could implement?

Dial element action URL attribute not working

Hi,

I was hoping for some clarification on how this works. So, according to the documentation this is what the action url attribute does:

Once the call ends, Plivo makes a GET or POST request to the ‘action’ URL if provided. The call flow will continue 
using the RESTXML received in response to that request.

Now, by setting the action url attribute, once the bridge is complete when the called party hangs up or the number doesn't exist, the call shouldn't end and REST XML should be fetched from the action url and call processing should continue. However, if what I stated is the proper use of the action url, then it doesn't work. The call just ends, although a request is made to the action URL but the response XML is not processed.

Anyway, I looked through the code and I found this:
elements.py

                if self.redirect:
                    self.fetch_rest_xml(self.action, params, method=self.method)
                else:
                    spawn_raw(outbound_socket.send_to_url, self.action, params, method=self.method)

Here's the definition of fetch_rest_xml:

    def fetch_rest_xml(self, url, params={}, method='POST'):
        raise RESTRedirectException(url, params, method)

So, am I doing something incredibly stupid here or is this feature not fully implemented?

Logging error on hangup

I think this is during GetDigits and the call is hung up (this is low priority)

011-05-31 15:52:01,224 outboundserver[4055]: ERROR: (11) Processing Call Failure !
2011-05-31 15:52:01,225 outboundserver[4055]: ERROR: (11) not all arguments converted during string formatting
2011-05-31 15:52:01,225 outboundserver[4055]: ERROR: (11) Traceback (most recent call last):
2011-05-31 15:52:01,226 outboundserver[4055]: ERROR: (11)   File "/Library/Python/2.6/site-packages/plivo-0.1.0-py2.6.egg/plivo/rest/freeswitch/outboundsocket.py", line 303, in run
2011-05-31 15:52:01,226 outboundserver[4055]: ERROR: (11)     self.process_call()
2011-05-31 15:52:01,226 outboundserver[4055]: ERROR: (11)   File "/Library/Python/2.6/site-packages/plivo-0.1.0-py2.6.egg/plivo/rest/freeswitch/outboundsocket.py", line 331, in process_call
2011-05-31 15:52:01,227 outboundserver[4055]: ERROR: (11)     self.execute_xml()
2011-05-31 15:52:01,229 outboundserver[4055]: ERROR: (11)   File "/Library/Python/2.6/site-packages/plivo-0.1.0-py2.6.egg/plivo/rest/freeswitch/outboundsocket.py", line 466, in execute_xml
2011-05-31 15:52:01,229 outboundserver[4055]: ERROR: (11)     element_instance.run(self)
2011-05-31 15:52:01,230 outboundserver[4055]: ERROR: (11)   File "/Library/Python/2.6/site-packages/plivo-0.1.0-py2.6.egg/plivo/rest/freeswitch/elements.py", line 119, in run
2011-05-31 15:52:01,230 outboundserver[4055]: ERROR: (11)     result = execute(outbound_socket)
2011-05-31 15:52:01,230 outboundserver[4055]: ERROR: (11)   File "/Library/Python/2.6/site-packages/plivo-0.1.0-py2.6.egg/plivo/rest/freeswitch/elements.py", line 722, in execute
2011-05-31 15:52:01,230 outboundserver[4055]: ERROR: (11)     outbound_socket.log.info("GetDigits, No Digits Pressed" % str(digits))
2011-05-31 15:52:01,231 outboundserver[4055]: ERROR: (11) TypeError: not all arguments converted during string formatting

Consistency filename parameter

Recently added filename should be consistent with other names like filePath; so I propose fileName

:)

Hope that does not bother anyone.

force using proxy_url for some requests

action in elements, url in redirect and callbackurl in dial and conference should use proxy_url by default. all restxmls which are fetched should also use proxy_url.

just blindly set to use proxy for items above, so even if there is no proxy url mentioned in config, it will continue to work correctly, as this is already handled in code.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.