Question

I need the recent call data from call History after the call is ended

  • 7 November 2020
  • 1 reply
  • 466 views

Hi,


We are facing an issue - missing call data like duration etc after the call is ended. We are suggested by RC to get the data from phone.callHistory.calls after the call is ended.


I like to know when will [event/component/function] the call data be updated to phone.callHistory.calls after the call is ended and in which component/event/function I need to fetch the detail.


note: As per my analysis, the data is updated after "webphone.onCallEnd" & near to the case statement "case 'rc-call-end-notify':" in event "_onMessage" in component "Adapter". However, in the "_onMessage" I could not able to access the "phone" [could not fetch the data].


Anyone/@Embbnux Ji Please advise.


Thanks

John Gladson Moses


1 reply

Userlevel 1

I don't know where do you look at. In my test, I see all the inbound/outbound call in the history (almost instantly after a call is disconnected. If you want to receive telephonyStatus programmatically, add this JS code to your web page

window.addEventListener('message', (e) => {
  const data = e.data;
  if (data) {
    switch (data.type) {
      case 'rc-telephony-session-notify':
        console.log("SESSION")
        console.log(JSON.stringify(data.telephonySession))
        break
      default:
        console.log("OTHERS...")
        console.log(JSON.stringify(data))
        break;
    }
  }
});

screen-shot-2020-11-09-at-103705-am.png

Reply