-
Notifications
You must be signed in to change notification settings - Fork 179
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AnswerUrl not called on origination #35
Comments
Also, here's the relevant snippet from plivo-rest.log: 2011-08-19 01:24:27,435 plivo-rest[13530]: INFO: 127.0.0.1 - - [2011-08-19 01:24:27] "POST /v0.1/Call/ HTTP/1.1" 200 118 "-" "-" 2011-08-19 01:24:28,297 plivo-rest[13530]: INFO: Call from 5031231234 to 5551231234 in EarlyMedia for RequestUUID 73d4d276-c9e0-11e0-a7b2-ebaa5909aa51 2011-08-19 01:24:28,302 plivo-rest[13530]: INFO: Sent to POST http://127.0.0.1:5000/ringing with {'Direction': 'outbound', 'From': '5031231234', 'To': '5551231234', 'RequestUUID': '73d4d276-c9e0-11e0-a7b2-ebaa5909aa51', 'CallUUID': '74585a9c-c9e0-11e0-88df-0bed8a011e6b', 'CallStatus': 'ringing'} -- Result: OK 2011-08-19 01:24:36,509 plivo-rest[13530]: INFO: Hangup for Outgoing CallUUID 74585a9c-c9e0-11e0-88df-0bed8a011e6b Completed, HangupCause NORMAL_CLEARING, RequestUUID 73d4d276-c9e0-11e0-a7b2-ebaa5909aa51 2011-08-19 01:24:36,515 plivo-rest[13530]: INFO: Sent to POST http://127.0.0.1:5000/hangup with {'Direction': 'outbound', 'From': '', 'ALegUUID': '74585a9c-c9e0-11e0-88df-0bed8a011e6b', 'HangupCause': 'NORMAL_CLEARING', 'To': '5551231234', 'CallUUID': '74585a9c-c9e0-11e0-88df-0bed8a011e6b', 'ALegRequestUUID': '73d4d276-c9e0-11e0-a7b2-ebaa5909aa51', 'RequestUUID': '73d4d276-c9e0-11e0-a7b2-ebaa5909aa51', 'CallStatus': 'completed'} -- Result: OK |
Let's find the issue :
In one terminal : In a second terminal : Now try to make call using REST api and check if you have any python traceback or if AnswerUrl is ok . |
Okay, I followed your steps. Logs are below.
|
Okay, I reviewed the code at the point of the exception and I see
Before you spend a lot of time debugging this, let me verify that this variable isn't getting stripped out by our Sangoma drivers (Sangoma has omitted standard variables on us before). I've discovered in the past that some versions of Sangoma drivers would omit the CID on inbound calls, but I suppose it's also possible they are dropping it on outbound as well (although I'm surprised FreeSWITCH wouldn't keep track of it). If this is the case, do you think it would be possible to repopulate this variable in the dialplan (assuming they have it stuffed in some other variable)? |
We dont have access to Sangoma drivers. Can you check this at your end and report back which variable does the caller id come when using sangoma? |
I inserted
at the appropriate point and got this output. 5551111111 is the outbound caller id, 5552222222 is the callee's number.
In the case of originating an outbound call, am I assuming correctly that Caller-Caller-Id-Number should be 5551111111 (the originating ANI)? |
Also, just to verify, I changed the code to this:
and this resolves my issue. That being said, this is clearly not the right solution. Sangoma has no plans to fix their current stack as they plan to release a new one "real soon now" (we've been hearing that for over a year). This being the case, and assuming that there will be other broken implementations, perhaps the best, most generic solution would be a configuration option to define these variable names (or at least a FreeSWITCH recipe for getting the variables populated, assuming that's possible). |
Checked FS code, seems 'origination_caller_id_number' variable is set in originate command regardless of the endpoint type. It's may be a problem in freetdm endpoint in Freeswitch ? |
Maybe. Sangoma is largely responsible for freetdm as well, although they'd be much more likely to commit a fix, since freetdm is included in their future direction. I'll report the issue and see if I can get any attention. Thanks for your help in tracking this down. |
Closing this for now. |
Call origination doesn't work because AnswerUrl is never called.
Sequence of events:
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
The text was updated successfully, but these errors were encountered: