# AI and agents

Connect your coding agent to Unhandled in one copy-paste, then let it set up a service, fix issues and verify deploys.

Unhandled works with the coding agent you already pay for. Connect it to the [MCP server](/docs/features/mcp-server) once, and it can set up a service, read an issue's exception, frames, trace and logs, fix the bug in your repository and check that the fix held. Unhandled calls no model for any of this. Your agent runs on your machine, under your plan with its vendor.

> **Note: Looking for LLM telemetry?**
>
> This section is about agents that work on your code. To monitor the AI features of your own application, see [AI Agents](/docs/features/ai-agents).

## Connect your agent

Pick your agent and run its one command. Every agent connects to the same server URL, `https://unhandled.net/mcp/x/debug`, the `debug` [toolset](/docs/features/mcp-server#toolsets) for finding and fixing errors. The first tool call opens Unhandled's consent page in your browser, where you pick the organization and the scopes.

```bash [Claude Code]
claude mcp add --transport http --scope user unhandled https://unhandled.net/mcp/x/debug
```
```bash [Codex]
codex mcp add unhandled --url https://unhandled.net/mcp/x/debug
```
```bash [VS Code]
code --add-mcp '{"name":"unhandled","type":"http","url":"https://unhandled.net/mcp/x/debug"}'
```
```bash [CLI]
npx @unhandled/cli mcp install --agent cursor
```

Cursor has an install link, and the CLI writes the config file for any agent in the table below. If you host your own Unhandled, use the same path on your domain.

To set up every agent on your machine at once, with the skills that fix production errors, run the installer. It detects Claude Code, Cursor, Codex, VS Code and Windsurf, adds the server at `/mcp/x/skills` and writes each client's skills, changes nothing that is already in place, and takes `--dry-run` to preview:

```bash
npx @unhandled/agent install
```

| Agent | Setup |
| --- | --- |
| Claude Code | [Set up with Claude Code](/docs/agents/setup-with-claude-code), with an optional plugin that adds skills |
| Cursor | [Set up with Cursor](/docs/agents/setup-with-cursor), with a one-click install link |
| Codex | [Set up with Codex](/docs/agents/setup-with-codex) |
| VS Code | [Set up with VS Code](/docs/agents/setup-with-vscode), with a one-click install link |
| GitHub Copilot | [Set up with GitHub Copilot](/docs/agents/setup-with-copilot), for the cloud agent |
| opencode, Gemini CLI, Amp, Zed, Windsurf | [Set up with other agents](/docs/agents/setup-with-other-agents) |

**Settings > Agent setup** in the app, at `/o/<org>/settings/agents`, shows the same commands with your server URL filled in. The MCP tool `get_agent_setup` returns them too, so an agent that is already connected can set up another.

## Let your agent do it

With the server connected, paste this into the agent in your project's root. It sets up the service, sends one request and loops on `verify_setup` until every check passes.

```text
Set up Unhandled for this repository. Use the unhandled MCP server. Call get_setup_guide for this project's stack, then setup_service, apply the guide's steps, start the app and send one request that fails. Then call verify_setup and work through each failing check's nextStep until none fails. Never print the DSN.
```

[Prompts](/docs/agents/prompts) has the prompts for fixing an issue and verifying a deploy, and the `AGENTS.md` section that makes every agent behave the same way. [Quickstart](/docs/quickstart) shows the same step next to the setup by hand.

## What your agent can do

- [Fix issues](/docs/agents/fix-issues): Fix an issue from the issue page or the CLI, hand it off to an agent running elsewhere, or watch for new ones.
- [Verify a deploy](/docs/agents/verify-a-deploy): Check that a deploy is healthy and that the fixes it shipped held.
- [Prompts](/docs/agents/prompts): Copy-paste prompts and the `AGENTS.md` section.
- [Security](/docs/agents/security): Telemetry is untrusted text. What your agent may do, and who approves the rest.

## Agent-readable docs

Every docs page is also available as Markdown, so an agent can read the docs without parsing HTML:

- `/llms.txt` lists every page with its description, agent pages first, each linking to the Markdown version.
- `/llms-full.txt` is every page in one Markdown file.
- `/docs/raw/<page>.md` returns one page, for example `/docs/raw/agents.md`.
- Any docs URL returns Markdown instead of HTML when the request sends `Accept: text/markdown`.

**Copy page** at the top of each docs page copies the same Markdown, and **View as Markdown** in its menu opens it.

## Related

- [MCP server](/docs/features/mcp-server): Scopes, approvals and every tool your agent can call.
- [Fix prompts and AI summaries](/docs/features/ai-summaries): What the fix prompt contains and how it is redacted.
- [Issues](/docs/features/issues): How exceptions become issues, and when an issue regresses.
- [CLI](/docs/sdks/cli): The `unhandled` binary for deployments and source maps.
