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

# AI Protocol (MCP)

> Connect AI assistants and agents to your Blueprints using the Model Context Protocol.

The Model Context Protocol (MCP) is a standardized protocol that lets AI assistants and agents use external tools. Leapter exposes your published Blueprints as MCP tools, so any MCP-compatible AI client can call your logic directly.

## Get the endpoint URL

1. Open your Blueprint in the editor.
2. Click the **Share** button in the toolbar.
3. Select **Connect**.
4. In the Connect dialog, select the **AI Protocol (MCP)** tab.

<img src="https://mintcdn.com/leapter/sFmIRxFaV3bB8R9b/images/connect-mcp-tab.png?fit=max&auto=format&n=sFmIRxFaV3bB8R9b&q=85&s=3eb4f95ca52264e17dfbcb96b6f2da0a" alt="The Connect dialog showing the AI Protocol (MCP) tab with endpoint URLs" width="896" height="784" data-path="images/connect-mcp-tab.png" />

The dialog shows two endpoint URLs:

### Standard Endpoint

```
https://lab.leapter.com/runtime/api/v1/{appspace}/{project-id}/mcp
```

Use this for most MCP clients. It uses the standard MCP transport protocol.

### Real-Time Streaming Endpoint (SSE)

```
https://lab.leapter.com/runtime/api/v1/{appspace}/{project-id}/mcp/sse
```

Use this for clients that require Server-Sent Events (SSE) streaming, such as some older MCP integrations.

Click the **Copy** button next to either URL to copy it to your clipboard.

## Authentication

All MCP connections require an API key. Pass it as a header:

* **Header name:** `X-API-Key`
* **Header value:** your API key

See [API Keys](/fundamentals/api-keys) to create and manage your keys.

## Connect with Claude Desktop

1. Copy the **Standard Endpoint** URL from the Connect dialog.
2. Open Claude Desktop and go to **Settings** → **Developer** → **Edit Config**.
3. Add an MCP server entry in your `claude_desktop_config.json`:

```json theme={null}
{
  "mcpServers": {
    "leapter": {
      "url": "https://lab.leapter.com/runtime/api/v1/{appspace}/{project-id}/mcp",
      "headers": {
        "X-API-Key": "your-api-key"
      }
    }
  }
}
```

4. Replace `{appspace}`, `{project-id}`, and `your-api-key` with your actual values.
5. Restart Claude Desktop.

Your Blueprints now appear as available tools in Claude Desktop.

## Connect with Cursor

1. Copy the **Standard Endpoint** URL from the Connect dialog.
2. In Cursor, open **Settings** → **MCP**.
3. Add a new MCP server with:
   * **URL:** your Standard Endpoint
   * **Headers:** `X-API-Key: your-api-key`
4. Save and your Blueprints become available as tools in Cursor's AI features.

## Connect with other MCP clients

Any MCP-compatible client can connect to your Blueprints. You need:

* The **Standard Endpoint** or **SSE Streaming Endpoint** URL (depending on what the client supports)
* An **API key** passed as the `X-API-Key` header

Refer to your client's documentation for how to configure MCP server connections.

## What to do next

* **[Web API (OpenAPI)](/executing-blueprints/connect-rest-api)** — call your Blueprints through a REST API instead
* **[API Keys](/fundamentals/api-keys)** — create and manage API keys
* **[MCP Agent Workflow](/executing-blueprints/n8n-mcp-agent)** — use your Blueprints as tools in an n8n AI agent
