Hi there.

I'm trying to get the call duration in seconds using ESL, but it looks like the channel variables are not being set correctly.

In CHANNEL_HANGUP events, I see the following variables:

  'Caller-Profile-Created-Time' => '1420586926995761',
  'Caller-Channel-Created-Time' => '1420586926995761',
  'Caller-Channel-Answered-Time' => '1420586929503733',
  'Caller-Channel-Progress-Time' => '0',
  'Caller-Channel-Progress-Media-Time' => '1420586929203735',
  'Caller-Channel-Hangup-Time' => '0',

I would expect to generate the duration of the call by subtracting Caller-Channel-Answered-Time from Caller-Channel-Hangup-Time, but the hangup time is 0.  The actual call in this case was 45 seconds long.

What can I do use Freeswitch events to compute call duration?

Thanks!