Skip to content
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

Event-Date-Timestamp is not changing #19

Closed
huk opened this issue Jul 12, 2011 · 4 comments
Closed

Event-Date-Timestamp is not changing #19

huk opened this issue Jul 12, 2011 · 4 comments

Comments

@huk
Copy link

huk commented Jul 12, 2011

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"}
@mike-plivo
Copy link
Member

ok now is changing on answer url and hangup url for all calls .

But for now, be carefull, EXTRA_FS_VARS will never be added to others http request like action/method in GetDigits, Dial, ...
So you can only use EXTRA_FS_VARS in answer url and hangup url.

@huk
Copy link
Author

huk commented Jul 25, 2011

Thanks, it works good. But why only in answer and hangup?

@mike-plivo
Copy link
Member

Because variables like 'Event-Date-Timestamp' are extracted from events (in eventsocket) and there is no garantee that you have an events linked to each http request :
like for GetDigits, when you set action + method, and you press digits, http request is sent with Digits but there is no event associated with it, so you can't get/extract extra variables from an event.

@huk
Copy link
Author

huk commented Jul 25, 2011

Ok, i understand.

@huk huk closed this as completed Jul 25, 2011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants