Discussions

Ask a Question
Back to All

DIsposition retrieval

Hey team, have been enjoying the API, works great, but I am having issues with the disposition data.

I am trying to enhance all the calls with their dispositions and am seeing unexpected results. The process I am following is this one:

  1. Calling the stats endpoint to get all the call records, waiting for the result and downloading the file.

Body used:

{ "days_ago_end": 30, "days_ago_start": 1, "export_type": "records", "stat_type": "calls", "timezone": "UTC", "coaching_group": false, "coaching_team": false }

  1. Calling the stats endpoint to get all the dispositions, per callCenter for all the callCenter ids that appear in the calls, waiting for the result and downloading all the files and uniting them.

Body used:

{ "days_ago_end": 30, "days_ago_start": 1, "export_type": "records", "stat_type": "dispositions", "timezone": "UTC", "coaching_group": false, "coaching_team": false, "target_type": "callcenter", "target_id": "some_id" }

Once I get both files, I join them in a database. But it seems that I am missing some dispositions I can see in the UI. So questions:

  1. Is looping through all the call centers no enough to get all the dispositions?
  2. Is there a better way to do this that without using webhooks?
  3. Have you considered adding an optional dispositions column to the call records stat result? that would sole all the issues my team is having.

Thank you so much for your time!