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

# Retell AI webhooks

> Receive and verify Retell AI webhooks with Trigger.dev. Check the HMAC-SHA256 signature in x-retell-signature and run a task for each Retell AI event, filtered on event.event.

**`webhooks.retell()` verifies the HMAC-SHA256 signature Retell AI sends in `x-retell-signature` on every request.**

```ts /trigger/retell.ts theme={"theme":"css-variables"}
import { webhook, webhooks } from "@trigger.dev/sdk";

export const retell = webhooks.endpoint.define({
  id: "retell",
  source: webhooks.retell(),
});

export const retellEvents = webhook({
  id: "retell-events",
  endpoint: retell,
  onEvent: async ({ event }) => {
    console.log(event);
  },
});
```

To run a subscriber only for some events, add a [filter](https://trigger.dev/docs/webhooks/filters.md) on `event.event`.

| Setting | Value |
| - | - |
| Source | `webhooks.retell()` |
| Verification | HMAC-SHA256 in `x-retell-signature` |
| Credential | The Retell AI API key with the webhook badge |
| Event type | `event.event` |
| Retell AI docs | [Retell AI webhook docs](https://docs.retellai.com/features/secure-webhook) |

## Set up Retell AI

1. Start `trigger dev` or deploy, then copy the endpoint's **Webhook URL** from the **Webhooks** page.
2. In Retell AI, set the webhook URL as the account-level webhook in the system settings' **Webhooks** tab, or as an agent's **Agent Level Webhook URL** under **Webhook settings** in the agent editor. An agent-level URL replaces the account-level one for that agent.
3. Retell AI signs with an API key, not a per-webhook secret. Copy the API key that has the webhook badge next to it, then choose **Set signing secret** on the Trigger.dev endpoint and paste it.
4. Send a test event from Retell AI, or use the endpoint's **Test** tab, and check the endpoint's **Deliveries** tab. See [Verify the connection](https://trigger.dev/docs/webhooks/connect.md#verify-the-connection) if nothing arrives.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.