> For the complete documentation index, see [llms.txt](https://eraya.gitbook.io/eraya-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://eraya.gitbook.io/eraya-docs/mcp-server/claude.md).

# Claude

The Eraya MCP Server can be integrated with both **Claude Desktop** and **Claude Code**. See the applicable instructions below.

> **Note:** Using Eraya AI Analyst requires an active Eraya **Pro plan**. [Upgrade at app.eraya.ai](https://app.eraya.ai).

***

### Claude Desktop

#### Install

1. Open the [Claude Desktop](https://claude.ai/download) app.
2. Click **Customize** in the top-left navigation.
3. Go to the **Connectors** tab.
4. Click the **"+"** button → **"Add custom connector"**.

> **Don't see "Add Custom Connector"?** Custom Connectors require a Claude Pro, Max, Team, or Enterprise plan.

5. Title it `Eraya` and set the URL to `https://api.eraya.ai/mcp`. **Leave the OAuth field empty.** Then click **Add**.

> **Important:** Leave the OAuth field empty — Eraya handles authentication automatically through its own OAuth flow.

6. Once the connector is added, click the **Connect** button to authenticate. You will receive a magic-link email — click the link to complete login.
7. When starting a new chat, confirm that **Eraya** is toggled on in the options menu (the "+" or tools icon near the message box).

> **Tip:** To avoid clicking "Allow" every time Claude reads from Eraya, go to **Settings → Customize → Connectors → Eraya** and switch the dropdown next to "Read-only tools" to **Always allow**.

***

### Claude Code

Add the Eraya MCP Server using the CLI:

```bash
# Add with HTTP transport (recommended)
claude mcp add --transport http eraya https://api.eraya.ai/mcp
```

When you first use the server, Claude Code will open a browser-based OAuth login. Enter your Eraya account email, then click the magic link you receive to complete authentication. Tokens are stored securely and are valid for **365 days**.

Alternatively, add the server to your `.mcp.json` in your project root, or `~/.claude.json` for user-wide access:

```json
{
  "mcpServers": {
    "eraya": {
      "type": "http",
      "url": "https://api.eraya.ai/mcp"
    }
  }
}
```

Management commands:

```bash
claude mcp list          # View all configured servers
claude mcp get eraya     # Get server details
claude mcp remove eraya  # Remove the server
```
