I am getting “No call found for the record handle” error when I am sending “UpdateCallCompletionStats” after call is transferred. It works for same campaign in preview dialing mode but in predictive dialing mode I am getting above error.
I tried in with “AgentWorkMode” as “AutoIn” or “ManualIn” while logging in but result is same
sequence is, once call is transferred send “UpdateCallCompletionStats” and once I get acknowledment for “UpdateCallCompletionStats” then I send “recordProcessed” request.
I am not making agent to ready until I get recordProcessed acknowledge. I tried two step transfer also but result is same. I thing which I noticed in two step transfer is if I initiate transfer den I send “UpdateCallCompletionStats” and “recordProcessed” its works fine. If i complete transfer den it fails with above error.
At that OCS returns the error you’ve mentioned, however, this is as per design. From the documentation, in fact, when record_processed is set to true:
===
If an agent changes his or her state (such as EventAgentReady or
EventAgentLogout), OCS treats the agent state as ReleaseNextCall
or LoggedOut. The change in agent state informs OCS that the
agent has finished with this call record, and that OCS can update
the database with the final information about the call record. OCS
can change an internal agent state after it receives EventReleased
from the T-Server.
OCS interprets the agent status change as an indication that the agent has finished processing the call:
If an agent changes his or her state (such as EventAgentReady or
EventAgentLogout), OCS treats the agent state as ReleaseNextCall
or LoggedOut. The change in agent state informs OCS that the
agent has finished with this call record, and that OCS can update
the database with the final information about the call record. OCS
can change an internal agent state after it receives EventReleased
from the T-Server.
Hence you need to send the Updates / RecordProcessed prior to transferring the call.
I hadn’t noticed that your softphone actually sends a RequestNotReady, workmode ACW, prior to transferring the call, which is the good practise to ensure that the record doesn’t get processed by OCS upon releasing the call.
Can you please just check the ACW configuration for the DN you used? As the request to set the agent to ACW had already been accepted by SIPS, I believe that’s not needed and may be triggering a weird behaviour in OCS.
Also, can you check what value the OCS option outbound_answer_action is set to?
Finally I had to change call flow as suggested by FRA. And now flow looks like below.
[ol]- UpdateCallCompletionStats
RecordProcessed
RequestSingleStepTransfer[/ol]
But If its to another agent then I am not sending “RecordProcessed”. In that case sequence is below and other agent is going to send “RecordProcessed” on call finish.