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

# Post-Call Webhook

> Receive a summary of every Voice call once it has ended and been analyzed.

## Overview

When a Voice call ends, Reach analyzes it and sends one `call.completed` webhook carrying the call, its summary, and its transcript. It arrives after analysis, seconds to minutes behind the hangup.

## Registration

Webhook setup is not self-serve. Send your Reach contact the URL that should receive calls, and a bearer token for Reach to present on each request.

<Note>
  You issue the token. Reach stores it and sends it back to you on every request so you can authenticate the caller. Reach does not generate it for you.
</Note>

## The request

```http theme={null}
POST /your/webhook/path HTTP/1.1
Content-Type: application/json
Authorization: Bearer <the token you gave Reach>
```

## The payload

```ts theme={null}
{
  eventType: 'call.completed';
  eventId: string;           // stable across retries — deduplicate on this
  tenantExternalId: string;  // your own ID for the tenant
  timestamp: string;         // ISO 8601, when Reach built the payload
  data: {
    id: string;                                    // Reach call ID; same value as eventId
    call_title: string | null;
    from_number: string | null;                    // E.164; null on web calls
    to_number: string | null;                      // E.164; null on web calls
    direction: 'inbound' | 'outbound';
    call_type: 'phone_call' | 'web_call';
    started_at: string | null;                     // ISO 8601
    ended_at: string | null;                       // ISO 8601
    duration_secs: number | null;
    summary: string | null;
    transcript: string | null;
    partner_user: { external_id: string } | null;  // null when the caller matched no customer you shared
  };
}
```

`partner_user.external_id` is your own customer ID, set when Reach matched the caller to a customer you shared. A `null` is a caller you have no record of, not an error.

## Responding

Answer `2xx` within 5 seconds, once the event is stored or queued. Reach aborts the request at 5 seconds.

| Your response            | What Reach does                                  |
| ------------------------ | ------------------------------------------------ |
| Any `2xx`                | Marks the call delivered. Never re-sent.         |
| `429` or any `5xx`       | Retries.                                         |
| Timeout or network error | Retries.                                         |
| Any other `4xx`          | Gives up permanently. The call is never re-sent. |

<Warning>
  A `400` or `422` is read as a final rejection. Return `503` for anything temporary on your side, or the call is lost.
</Warning>

Delivery is at-least-once, up to 5 attempts roughly five minutes apart. The same call can arrive more than once, so key your writes on `eventId`.
