# AI agents (https://unmissed.dev/docs/agents)

Ask your agent what failed overnight and why, then have it resend the lot once your app is fixed. Every Unmissed has an MCP server built in, at `/mcp` on your [`APP_URL`](/docs/settings). There's nothing extra to run.

## Connect Claude Code [#connect-claude-code]

```sh
claude mcp add --transport http unmissed https://hooks.example.com/mcp
```

Claude Code opens Unmissed in your browser to sign in. If it doesn't, run `/mcp` in Claude Code and pick `unmissed`. On the consent screen, choose what it can do, then click **Allow**:

- **Full access:** everything you can do, like resending webhooks.
- **Read-only:** it can look and change nothing.

Then ask away:

- "What failed in the last hour, and why?"
- "Which webhooks are held for billing?"
- "Resend the failed Stripe webhooks from today."
- "Add a GitHub source that sends to https://app.example.com/webhooks/github."

## Other agents [#other-agents]

Any MCP client that connects over HTTP can use `<APP_URL>/mcp`. Clients that support MCP sign-in find the consent screen on their own.

An agent that can't open a browser, like one running on a server, can send an [API token](/docs/api#sign-in) from the CLI page instead:

```sh
claude mcp add --transport http unmissed https://hooks.example.com/mcp \
  --header "Authorization: Bearer unm_..."
```

Browser-based clients on other sites can't use `/mcp` for now: Unmissed turns away requests from other sites' pages. Agents on your machine or a server are fine.

## What it can do [#what-it-can-do]

The same as the [API](/docs/api), with the same rules:

| Tool | What it does |
| --- | --- |
| `list_webhooks` | Find webhooks by source, destination, status, time or text |
| `show_webhook` | One webhook, with every attempt and what your app answered |
| `summarize_failures` | What's failing, grouped by destination and why |
| `resend_webhook` | Send one webhook again |
| `resend_webhooks` | Send everything that matches again, up to 1,000 at a time |
| `list_sources`, `show_source` | Sources and the destinations each sends to |
| `create_source`, `update_source`, `delete_source` | Set up sources |
| `list_destinations`, `show_destination` | Destinations and the sources sending to each |
| `create_destination`, `update_destination`, `delete_destination` | Set up destinations |
| `connect_destination`, `update_filter`, `disconnect_destination` | Choose which source sends where |

A bulk resend always says whether it's a dry run, and the agent is told to count first and check the number with you. Tools that delete something for good, like deleting a source or shortening how long it keeps webhooks, are marked as such, so your agent asks before it runs them.

## It acts as you [#it-acts-as-you]

The agent can do what you can do in the app, and nothing more. See [Your team](/docs/concepts#your-team) for the roles.

- **Members** can look and resend. Only admins can set up sources and destinations.
- **Viewers** can connect agents read-only.
- **Read-only** agents can use the tools that look. A tool that changes something answers `403` with `insufficient_scope`, so Claude Code can ask you for full access and try again. If your role couldn't do it anyway, it just says no.

Every change and resend shows in the [audit log](/docs/audit-log) with the app's or token's name:

> dana@example.com, via Claude Code over MCP, resent 12 webhooks from Stripe.

The agent shares your [rate limits](/docs/api#rate-limits) with the API: 120 requests a minute, and 10 bulk resends a minute.

## Safe to hand to an agent [#safe-to-hand-to-an-agent]

Webhook bodies are written by whoever sent the webhook, and your app's answers by your app. Unmissed tells the agent to treat them as data, never as instructions, and keeps secrets out of what it hands back:

- Bodies are the first 4 KB unless the agent asks for all of it. Lists have no bodies at all.
- Headers that look like credentials or signatures come back as `hidden`. So does a credential your app echoes back in its answer.
- Signing secrets can be set but never come back.
- Viewers never get a receiving URL.
- Destination URLs show only the host, like `https://app.example.com/…`, since the path often holds a token.

## Disconnect it [#disconnect-it]

On your **Account** page, under [Connected apps](/docs/concepts#connected-apps), click **Disconnect**. It stops working right away. An agent unused for 90 days disconnects on its own.

An agent using an API token stops when you revoke the token on the CLI page.

## Building a client [#building-a-client]

The server follows MCP 2026-07-28: stateless, with plain JSON answers. It also answers clients that start with `initialize` on 2025-06-18 or 2025-11-25. A request without a token gets a `401` that points the client at how to sign in. See [Connect an app](/docs/api#connect-an-app) for the details.