Reevaluate Calls API

Trigger a reevaluation of metrics for specified calls

API Endpoint

MethodEndpoint
POSThttps://new-prod.vocera.ai/observability/v1/call-logs-external/rerun_evaluation/

Authentication

Include your API key in the request headers:

HeaderDescription
X-VOCERA-API-KEYYour API key obtained from the dashboard

Request Body

ParameterTypeRequiredDescription
call_logsarray|string|integerYesArray of call log IDs to run OR "all" to run all OR number to run first N calls
agent_idintegerYes*Unique identifier of the agent
assistant_idstringYes*The assistant ID associated with agent

* Required only when call_logs is “all” OR is number of first N calls. Only either of agent_id or assistant_id is required

Example Requests

{

    "agent_id": 1,

    "call_logs": 2

}
{

    "call_logs": [123, 456, 789]

}
{

    "agent_id": 1,

    "call_logs": "all"

}

Response Format

The API returns an array of call objects. Please note the evaluation is run in background.

Response Fields

FieldTypeDescription
idintegerThe call log ID
timestampstringISO 8601 timestamp of when the call occurred
durationstringDuration of the call in MM:SS format
successbooleanWhether the call was successful (null if evaluation pending)
call_ended_reasonstringReason for call termination
customer_numberstringCustomer’s phone number
agentintegerID of the agent handling the call
call_idstringExternal reference ID for the call

Example Response

[

    {

        "id": 668,

        "timestamp": "2024-12-19T19:50:18.678545Z",

        "duration": "00:39",

        "success": null,

        "call_ended_reason": "",

        "customer_number": "",

        "agent": 1,

        "call_id": "1000001"

    },

    {

        "id": 667,

        "timestamp": "2024-12-19T19:47:15.000673Z",

        "duration": "00:11",

        "success": null,

        "call_ended_reason": "",

        "customer_number": "",

        "agent": 1,

        "call_id": "1000002"

    }

]

Code Examples

curl -X POST https://new-prod.vocera.ai/observability/v1/call-logs-external/rerun_evaluation/ \

  -H "X-VOCERA-API-KEY: <your-api-key-here>" \

  -H "Content-Type: application/json" \

  -d '{

    "agent_id": 1,

    "call_logs": 2

  }'