# Connect an AI agent

> Let Claude Code, Codex, Cursor, Claude Desktop or any MCP client read your workspace, prepare work and draft replies, and send them if you allow it.

Source: https://sydbar.app/docs/agents

Sydbar is an MCP server. Once connected, your agent can see what needs you across every business, search, read conversations and clients, prepare invoices, set follow-ups, draft replies for you to approve and manage booking pages. It sends replies only if you allow its key, and then only through each business's [agent email](/docs/agent-email) rules. It never approves, pays or marks anything paid.

| | |
| --- | --- |
| Server | `https://sydbar.app/mcp` |
| Transport | Streamable HTTP |
| Auth | `Authorization: Bearer YOUR_KEY` |

## 1. Create a key

On a computer, go to **Settings → Agents**, name the key after where you'll use it (for example "Claude Code on my laptop") and choose **Create key**. The key is shown once. Below it, pick your agent and copy one thing: the key is already filled in.

You can have up to 10 active keys.

> **Warning: Keep the key private**
> A key acts as you in every business you belong to. Don't paste it into shared chats or commit it to a repo.
## 2. Add Sydbar to your agent

### Any agent: paste a prompt

The simplest way. In Settings → Agents, choose **Any agent** and **Copy prompt**, then paste it into Claude Code, Codex, Cursor or any agent on your computer that can edit its settings. It sets itself up and checks the connection. Here's the prompt with a placeholder:

**Connect your agent to Sydbar** (copy this to your agent):

```text
Connect yourself to my Sydbar workspace (an MCP server) so you can help with my client email, invoices and projects.

Server: https://sydbar.app/mcp (Streamable HTTP)
Header: Authorization: Bearer YOUR_KEY

- If you are Claude Code, run:
  claude mcp add --transport http sydbar https://sydbar.app/mcp --header "Authorization: Bearer YOUR_KEY"
- If you are Codex, add this to ~/.codex/config.toml:
  [mcp_servers.sydbar]
  url = "https://sydbar.app/mcp"
  http_headers = { Authorization = "Bearer YOUR_KEY" }
- Otherwise, add an HTTP MCP server named sydbar with that URL and header in your MCP settings.

Then call list_businesses to check the connection and tell me what needs me today (needs_you).
Draft replies for me to approve (draft_reply). Only send (send_reply) when I ask you to; Sydbar's rules decide whether it goes after a short undo window or waits for me.
```

### Claude Code

Run once in your terminal:

Terminal:

```bash
claude mcp add --transport http sydbar https://sydbar.app/mcp --header "Authorization: Bearer YOUR_KEY"
```

### Codex

Add to `~/.codex/config.toml`, then start a new Codex session:

~/.codex/config.toml:

```toml
[mcp_servers.sydbar]
url = "https://sydbar.app/mcp"
http_headers = { Authorization = "Bearer YOUR_KEY" }
```

### Cursor

Use **Add to Cursor** in Settings → Agents, or add this to `~/.cursor/mcp.json`:

~/.cursor/mcp.json:

```json
{
  "mcpServers": {
    "sydbar": {
      "url": "https://sydbar.app/mcp",
      "headers": { "Authorization": "Bearer YOUR_KEY" }
    }
  }
}
```

### Claude Desktop

Claude Desktop → Settings → Developer → Edit Config. Add this to `claude_desktop_config.json`, then restart Claude:

claude_desktop_config.json:

```json
{
  "mcpServers": {
    "sydbar": {
      "command": "npx",
      "args": ["-y", "mcp-remote", "https://sydbar.app/mcp", "--header", "Authorization:${AUTH_HEADER}"],
      "env": { "AUTH_HEADER": "Bearer YOUR_KEY" }
    }
  }
}
```

### Any other MCP client

Add a remote (HTTP) MCP server named `sydbar` with the URL `https://sydbar.app/mcp` and the header `Authorization: Bearer YOUR_KEY`.

## 3. Check it works

**First prompt** (copy this to your agent):

```text
Call list_businesses, then needs_you, and tell me what needs me today in each business.
```

## Teach your agent how Sydbar works

The help center is written for agents too. Point your agent at the index, or copy any page with **Copy page**.

**Give your agent the docs** (copy this to your agent):

```text
Read https://sydbar.app/llms.txt. It's the index of Sydbar's documentation. Use those pages when I ask about Sydbar, open the linked .md pages for detail, and tell me when the docs don't cover something.
```

## Let an agent send

Next to each key in Settings → Agents, **Can send** lets that agent use `send_reply`. Sending still follows the business's [agent email](/docs/agent-email) rules: agent email must be on (or in trial, where everything waits for you), and the email's situation and your level decide whether the reply goes after the undo window or waits for you. Off by default for every key.

## Revoke a key

Settings → Agents → **Revoke**. The agent loses access immediately. You can see and revoke keys on a phone too.

## Next

- [Agent tools](/docs/agent-tools): every tool, its inputs and what it returns.
- [Prompt library](/docs/agent-prompts): ready-to-paste prompts.
