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

> ## Agent Instructions
> Leap's API is at https://api.tryleap.ai. Send the key in the x-api-key header or as Authorization: Bearer; keys start with leap_.
> Take model IDs and input schemas from GET /v1/models/{creator}/{name}, or from https://api.tryleap.ai/v1/public/models without a key. Never guess an input field: unknown fields are a 400.
> Model inputs take uploaded file IDs (file_...), never URLs.
> To give a coding agent the whole API, install the Leap skill: curl -fsSL https://www.tryleap.ai/install.sh | sh
> To make media from ChatGPT, Claude or another MCP client without code, connect Leap's MCP server at https://app.tryleap.ai/api/mcp; see https://www.tryleap.ai/docs/mcp.
> The full OpenAPI 3.1 spec is at https://www.tryleap.ai/docs/openapi.json.

# Connect a client

> Add Leap's MCP server to ChatGPT, Claude, Claude Code, Codex, Cursor, Visual Studio Code or any other MCP client, and sign in with your Leap account.

Every client connects to the same server URL:

```text theme={"theme":"css-variables"}
https://app.tryleap.ai/api/mcp
```

The first time you use it, the client opens Leap in your browser. Sign in, or create an account on the same page, and select **Allow**. The client never sees your password or an API key. [Sign-in and scopes](/docs/mcp/authentication) explains what you allow.

<CardGroup cols={3}>
  <Card title="ChatGPT" icon={<><img noZoom className="size-6 m-0 block dark:hidden" src="https://mintcdn.com/leap-0e8117eb/FNuWVDVj0aypejvv/images/clients/openai.svg?fit=max&auto=format&n=FNuWVDVj0aypejvv&q=85&s=84db3432906e593dc3b32d9d0b345d5b" alt="" /><img noZoom className="size-6 m-0 hidden dark:block" src="https://mintcdn.com/leap-0e8117eb/FNuWVDVj0aypejvv/images/clients/openai-dark.svg?fit=max&auto=format&n=FNuWVDVj0aypejvv&q=85&s=ec30112b40e1fc42c704511e9a4d00ac" alt="" /></>} href="/mcp/connect#chatgpt">
    Add Leap as a custom MCP server on chatgpt.com.
  </Card>

  <Card title="Claude" icon="https://mintcdn.com/leap-0e8117eb/FNuWVDVj0aypejvv/images/clients/claude.svg?fit=max&auto=format&n=FNuWVDVj0aypejvv&q=85&s=80f7cf6b4de6f2827a5881558b35195b" href="/docs/mcp/connect#claude" width="24" height="24" data-path="images/clients/claude.svg">
    One link adds Leap as a connector on the web, desktop and mobile.
  </Card>

  <Card title="Claude Code" icon="https://mintcdn.com/leap-0e8117eb/FNuWVDVj0aypejvv/images/clients/claude-code.svg?fit=max&auto=format&n=FNuWVDVj0aypejvv&q=85&s=673cc17f9e594a0203bded8f80f7124f" href="/docs/mcp/connect#claude-code" width="24" height="24" data-path="images/clients/claude-code.svg">
    One command, then `/mcp` to sign in.
  </Card>

  <Card title="Codex" icon={<><img noZoom className="size-6 m-0 block dark:hidden" src="https://mintcdn.com/leap-0e8117eb/FNuWVDVj0aypejvv/images/clients/openai.svg?fit=max&auto=format&n=FNuWVDVj0aypejvv&q=85&s=84db3432906e593dc3b32d9d0b345d5b" alt="" /><img noZoom className="size-6 m-0 hidden dark:block" src="https://mintcdn.com/leap-0e8117eb/FNuWVDVj0aypejvv/images/clients/openai-dark.svg?fit=max&auto=format&n=FNuWVDVj0aypejvv&q=85&s=ec30112b40e1fc42c704511e9a4d00ac" alt="" /></>} href="/mcp/connect#codex">
    The CLI, the IDE extension and the ChatGPT desktop app.
  </Card>

  <Card title="Cursor" icon={<><img noZoom className="size-6 m-0 block dark:hidden" src="https://mintcdn.com/leap-0e8117eb/FNuWVDVj0aypejvv/images/clients/cursor.svg?fit=max&auto=format&n=FNuWVDVj0aypejvv&q=85&s=40593e72d27103208373065bf482a5fd" alt="" /><img noZoom className="size-6 m-0 hidden dark:block" src="https://mintcdn.com/leap-0e8117eb/FNuWVDVj0aypejvv/images/clients/cursor-dark.svg?fit=max&auto=format&n=FNuWVDVj0aypejvv&q=85&s=f872922a482dbf7c747b9d70b1d48f47" alt="" /></>} href="/mcp/connect#cursor">
    Install from a link, with an API key.
  </Card>

  <Card title="Visual Studio Code" icon="https://mintcdn.com/leap-0e8117eb/FNuWVDVj0aypejvv/images/clients/vscode.svg?fit=max&auto=format&n=FNuWVDVj0aypejvv&q=85&s=87cab9b8d39a17d881ddccfc622c24d1" href="/docs/mcp/connect#visual-studio-code" width="100" height="100" data-path="images/clients/vscode.svg">
    Install from a link, or add it to `mcp.json`.
  </Card>
</CardGroup>

## ChatGPT

Add Leap to ChatGPT as a custom MCP server, on [chatgpt.com](https://chatgpt.com).

<Steps>
  <Step title="Add the server">
    Go to [chatgpt.com/plugins](https://chatgpt.com/plugins), select the plus button, then **Add custom MCP server**. Name it `Leap`, and enter the server URL `https://app.tryleap.ai/api/mcp`.

    If you don't see that option, turn on developer mode in ChatGPT's settings first. In a work or school workspace, an admin may have to allow custom servers.
  </Step>

  <Step title="Choose OAuth">
    For authentication, choose **OAuth**. Leave the client ID and secret empty: Leap reads ChatGPT's published client details, so there's nothing to register. Read the warning, select **I understand and want to continue**, then **Create as a plugin**.
  </Step>

  <Step title="Install it and sign in">
    Install the plugin, then sign in to Leap and select **Allow** when ChatGPT opens the sign-in page.
  </Step>

  <Step title="Use it in a chat">
    Type `@` in the message box, pick Leap, and ask for what you want.
  </Step>
</Steps>

ChatGPT asks you to confirm each call that changes something, such as a run or an upload, and shows what it will send. You can let it remember your answer for the rest of the conversation. A file you attach in the chat goes straight to Leap when the agent needs it as an input.

OpenAI's plugin rules don't allow links to a checkout, so in ChatGPT and Codex, when you're out of credit, the agent points you to [Leap's prices](https://www.tryleap.ai/pricing). Add credits in the studio at [app.tryleap.ai/go/settings/credits](https://app.tryleap.ai/go/settings/credits).

## Claude

Leap is a custom connector in Claude. Claude's connector directory doesn't list apps that generate images, video or audio, so you add Leap by its URL. This link opens Claude with the name and URL filled in:

<Card title="Add Leap to Claude" icon="https://mintcdn.com/leap-0e8117eb/FNuWVDVj0aypejvv/images/clients/claude.svg?fit=max&auto=format&n=FNuWVDVj0aypejvv&q=85&s=80f7cf6b4de6f2827a5881558b35195b" href="https://claude.ai/customize/connectors?modal=add-custom-connector&connectorName=Leap&connectorUrl=https%3A%2F%2Fapp.tryleap.ai%2Fapi%2Fmcp" width="24" height="24" data-path="images/clients/claude.svg">
  Opens Claude's connector settings with Leap ready to add.
</Card>

<Steps>
  <Step title="Add the connector">
    Open the link above and select **Add**. To do it by hand, go to **Customize**, **Connectors**, select **Add custom connector**, and enter `Leap` and `https://app.tryleap.ai/api/mcp`. Keep the default sign-in settings.
  </Step>

  <Step title="Connect">
    Select **Connect**, sign in to Leap and select **Allow**.
  </Step>

  <Step title="Use it in a chat">
    Ask for what you want. If Claude doesn't reach for Leap, check that it's on under the **+** button, **Connectors**, or start with "Use Leap to".
  </Step>
</Steps>

Once added, Leap works on claude.ai, in Claude Desktop and in the Claude mobile apps. The mobile apps show connectors you added on the web or on desktop; you can't add one from a phone. The Free plan allows one custom connector. On a Team or Enterprise plan, an Owner adds Leap under **Organization settings**, **Connectors** (**Add**, then **Custom**), and each member then connects with their own Leap account.

Claude asks before each tool call until you choose **Always allow** for that tool. To stop Claude from spending at all, open Leap under **Customize**, **Connectors** and set `generate` and `generate_batch` to **Blocked**.

Claude can't hand Leap a picture you attach in the chat, so give it a public link to the photo instead.

## Claude Code

```bash theme={"theme":"css-variables"}
claude mcp add --transport http leap https://app.tryleap.ai/api/mcp
```

Then run `/mcp` in Claude Code, choose `leap`, and select **Authenticate**. Your browser opens to sign in.

The command adds Leap to the current project only. Add `--scope user` to have it in every project, or `--scope project` to write it to the project's `.mcp.json` so everyone who clones the repository gets it. If you already added Leap on claude.ai with the same Claude account, it's in `/mcp` as `claude.ai Leap` and needs no command.

To install the [Leap skill](/docs/agents#install-the-leap-skill) and connect the server in one go:

```bash theme={"theme":"css-variables"}
curl -fsSL https://www.tryleap.ai/install.sh | sh -s -- --mcp
```

Claude Code shows results as text, with thumbnails it can look at and links to the files. It can read a photo on your computer and pass a small one to `upload_file` as base64.

## Codex

```bash theme={"theme":"css-variables"}
codex mcp add leap --url https://app.tryleap.ai/api/mcp
codex mcp login leap
```

`codex mcp login` opens your browser to sign in. Or add the server to `~/.codex/config.toml` yourself, then run `codex mcp login leap`:

```toml theme={"theme":"css-variables"}
[mcp_servers.leap]
url = "https://app.tryleap.ai/api/mcp"
```

The Codex CLI, the IDE extension and the ChatGPT desktop app share this file, so you set Leap up once for all three. In the Codex TUI, `/mcp` lists your servers. As in ChatGPT, the agent points you to Leap's prices when you need credit, and you add it in the studio.

## Cursor

Cursor can't sign in with your Leap account yet, so it connects with an [API key](/docs/authentication). Create one at [app.tryleap.ai/go/api](https://app.tryleap.ai/go/api) and set it as `LEAP_API_KEY` in your environment, then add the server:

<Card title="Add Leap to Cursor" icon={<><img noZoom className="size-6 m-0 block dark:hidden" src="https://mintcdn.com/leap-0e8117eb/FNuWVDVj0aypejvv/images/clients/cursor.svg?fit=max&auto=format&n=FNuWVDVj0aypejvv&q=85&s=40593e72d27103208373065bf482a5fd" alt="" /><img noZoom className="size-6 m-0 hidden dark:block" src="https://mintcdn.com/leap-0e8117eb/FNuWVDVj0aypejvv/images/clients/cursor-dark.svg?fit=max&auto=format&n=FNuWVDVj0aypejvv&q=85&s=f872922a482dbf7c747b9d70b1d48f47" alt="" /></>} href="cursor://anysphere.cursor-deeplink/mcp/install?name=leap&config=eyJ1cmwiOiJodHRwczovL2FwcC50cnlsZWFwLmFpL2FwaS9tY3AiLCJoZWFkZXJzIjp7IkF1dGhvcml6YXRpb24iOiJCZWFyZXIgJHtlbnY6TEVBUF9BUElfS0VZfSJ9fQ%3D%3D">
  Opens Cursor and installs Leap with the settings below.
</Card>

Or add this to `~/.cursor/mcp.json` for every project, or to `.cursor/mcp.json` for one:

```json theme={"theme":"css-variables"}
{
  "mcpServers": {
    "leap": {
      "url": "https://app.tryleap.ai/api/mcp",
      "headers": { "Authorization": "Bearer ${env:LEAP_API_KEY}" }
    }
  }
}
```

Cursor reads the key from the environment it started in, so restart it after you set the variable. With a key, the agent works in the key's workspace and can do what the key can.

## Visual Studio Code

<Card title="Add Leap to VS Code" icon="https://mintcdn.com/leap-0e8117eb/FNuWVDVj0aypejvv/images/clients/vscode.svg?fit=max&auto=format&n=FNuWVDVj0aypejvv&q=85&s=87cab9b8d39a17d881ddccfc622c24d1" href="vscode:mcp/install?%7B%22name%22%3A%22leap%22%2C%22type%22%3A%22http%22%2C%22url%22%3A%22https%3A%2F%2Fapp.tryleap.ai%2Fapi%2Fmcp%22%7D" width="100" height="100" data-path="images/clients/vscode.svg">
  Opens VS Code and installs Leap for your user.
</Card>

Or add it to one project, in `.vscode/mcp.json`:

```json theme={"theme":"css-variables"}
{
  "servers": {
    "leap": { "type": "http", "url": "https://app.tryleap.ai/api/mcp" }
  }
}
```

VS Code asks you to sign in to Leap the first time it starts the server. Use Leap from Copilot Chat in agent mode.

## Any other client

Leap's server speaks MCP over Streamable HTTP and is stateless, so any client that supports remote servers can use it. It signs clients in with OAuth 2.1, or takes an API key.

| | |
| - | - |
| Server | `https://app.tryleap.ai/api/mcp` (Streamable HTTP) |
| Resource metadata | `https://app.tryleap.ai/.well-known/oauth-protected-resource/api/mcp` |
| Authorization server | `https://app.tryleap.ai/api/auth` |
| Client registration | A Client ID Metadata Document: your client ID is the HTTPS URL of a JSON document that describes your client. Dynamic client registration is off. |
| Scopes | `workspace:read media:generate offline_access` |
| Without OAuth | A Leap API key in the `x-api-key` header, or as `Authorization: Bearer leap_...` |

A request without credentials gets a `401` whose `WWW-Authenticate` header points to the resource metadata and names the scopes to ask for, so a client that follows the MCP authorization spec signs in on its own. Use PKCE, and ask for `offline_access` to get a refresh token: an access token lasts 15 minutes.

To check a key, list the tools:

```bash theme={"theme":"css-variables"}
curl https://app.tryleap.ai/api/mcp \
  -H "Authorization: Bearer $LEAP_API_KEY" \
  -H "content-type: application/json" \
  -H "accept: application/json, text/event-stream" \
  -H "mcp-protocol-version: 2025-06-18" \
  -d '{"jsonrpc": "2.0", "id": 1, "method": "tools/list"}'
```

The server refuses requests that a web page on another site sends from a browser (any `Origin` it doesn't trust gets a `403`), so call it from a server, a desktop app or a CLI.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.