> ## Documentation Index
> Fetch the complete documentation index at: https://www.voiceflow.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Track resolution and escalation

> Measure Voiceflow conversation outcomes in your monitoring platform using clear definitions, complete coverage and verified escalation evidence.

Start with a completed conversation cohort, a CX owner who can review its outcomes, and an application developer who can export approved records. This guide turns that evidence into resolution and escalation rates in an external monitoring platform.

The worked example reviews **24 fictional Northstar conversations**. It uses Datadog Logs as the destination; the measurement definitions can carry to another platform after its connection and query mapping are verified.

## Before you begin

- Complete [Datadog connection setup](/docs/guides/integrations/datadog/overview#connecting-datadog). Its lifecycle receiver supplies timing and IDs; it does not classify business outcomes.
- Agree the project, Environment, channel, timezone and complete review window. Obtain the full set of completed conversation IDs from your application or approved conversation records.
- Download the [CX worked examples](/docs/examples/monitoring/cx-guides.zip). Extract the archive and open its `cx` directory. Node.js 22 or later is needed for the optional validation/publishing commands.

**Note:** 
The `cx_*` fields below are the example export contract, **not native Voiceflow webhook fields**. Your developer maps source evidence into these records. Keep credentials, customer contact details and message text out of the export.

## Define and collect the outcomes

### 1. Choose one classification rule

Have the CX owner agree what each outcome means before reviewing conversations:

| Outcome | Evidence required |
| --- | --- |
| `resolved` | A reviewer verifies a usable answer against the approved policy, or the destination confirms the requested action completed. |
| `escalated` | The receiving system confirms the intended human hand-off was accepted. A requested transfer or created ticket alone does not establish live hand-off. |
| `unresolved` | The in-scope request remains unfinished under the agreed rule. |
| `abandoned` | The customer left before a usable result, based on conversation evidence. An idle timeout alone cannot classify it. |
| `unrelated` | The request falls outside the agent's approved scope. |
| `unknown` | The evidence is insufficient to choose another outcome. |

The example uses human-reviewed labels. Keep `cx_evidence:review` distinct from `system` events, and document the review rule. Voiceflow's [outcome criteria](/docs/documentation/measure/evaluations#default-evaluations) provide useful context; an automated Evaluation remains a judgment under its criteria.

### 2. Produce one record per conversation

Ask the developer or review owner to supply `outcomes.json`, with one final row for **every** completed conversation in the cohort, including unknown and unrelated cases. Include an opaque conversation ID, project, Environment, release, channel, intent, review ID and evidence reference.

The sample's `returns-after` cohort contains this record:

```json
{
  "event_id": "returns-after:outcome:b001",
  "cx_kind": "outcome",
  "cx_review_id": "returns-after",
  "cx_project_id": "northstar",
  "cx_environment": "main",
  "cx_release": "r2",
  "cx_channel": "web",
  "cx_intent": "returns",
  "cx_conversation_id": "b001",
  "cx_outcome": "resolved",
  "cx_evidence": "review",
  "cx_evidence_ref": "review-001"
}
```

The application keeps the mapping back to the permitted source record. Do not use a session credential or customer email as the correlation ID. If a label changes, create a corrected review ID instead of adding a contradictory row to the original review.

### 3. Validate and publish the approved review

From the examples' `cx` directory, run:

```bash
node --test records.test.mjs
node publish.mjs outcomes.json
```

Validation prints `sent:false` and makes no network request. The file includes before and after reviews, each with 24 records. After checking the data, your developer can submit it using the server-held Datadog configuration from the provider manual:

```bash
node publish.mjs outcomes.json --send
```

Use an isolated staging destination for the fictional records. In your own export, preserve event IDs on a transport retry. The publisher removes identical retries and rejects a second final outcome for the same project, Environment, review and conversation, even under a new event ID. This check applies within one file; your source system must enforce it across exports. Datadog intake is not an upsert.

### 4. Build the rates from the same population

In Datadog **Logs → Explorer**, use:

```text
service:voiceflow-agent env:staging @cx_environment:main @cx_project_id:northstar @cx_review_id:"returns-after" @cx_kind:outcome
```

Set each query to **count unique of `cx_conversation_id`**. If the field is absent from the selector, [create a string facet](https://docs.datadoghq.com/logs/explorer/facets/) from that log attribute. Query **a** selects `resolved`; query **b** selects `resolved`, `escalated`, `unresolved` or `abandoned`. Use `100 * a / b` for resolution rate. Replace a's filter with `escalated` for the escalation rate. Keep unrelated and unknown records visible as separate counts.

The worked review gives:

| Measure | Result |
| --- | --- |
| Completed conversations | 24 |
| Classified / total coverage | 24 / 24 = 100% |
| Eligible in-scope conversations | 20 |
| Resolution rate | 12 / 20 = **60%** |
| Escalation rate | 4 / 20 = **20%** |
| Unresolved / abandoned | 3 / 20 = 15%; 1 / 20 = 5% |
| Unrelated / unknown counts | 4 unrelated; 0 unknown |

## Verify the finding

Open one resolved and one escalated conversation through your authorized source mapping. Confirm the answer/action evidence and the receiving hand-off record. Classification coverage is known outcomes / all completed conversations; unknown and missing rows remain outside the numerator. Compare the exported count with the complete source cohort.

Save the review definition and query with the result. Continue with [answer quality](/docs/guides/integrations/monitoring/monitor-answer-quality) to explain weak outcomes, or [CX regression alerts](/docs/guides/integrations/monitoring/alert-on-cx-regressions) to watch for changes.

## Troubleshoot the measurement

### The rate improves after records disappear

Check coverage and scope before interpreting a change.

Compare the expected completed-conversation set with the export. Restore missing rows as unknown until reviewed. Check Environment, channel, time window and review rule; a smaller or differently selected denominator can change the rate without improving the experience.

### A retry or correction changes the counts

Keep immutable records and count unique conversations within one review.

An intake retry can append the same log. Use unique IDs rather than raw log count. A changed classification belongs in a new review ID; select that review explicitly in the dashboard. Do not combine the old and corrected labels.
