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

# Connect MCP

> Step-by-step setup of the Loice MCP server in Claude, ChatGPT, Claude Code, Cursor, VS Code, Gemini CLI, MCP Inspector and any other MCP client.

## Connect MCP

Every client connects to the same URL:

```text theme={null}
https://app.loice.ai/mcp
```

There are two ways to authenticate:

* **OAuth sign-in** for AI assistants and editors. You add the URL, a browser window opens, you
  sign in to Loice and approve. Nothing to choose, copy or store.
* **API key** for automations, scripts and your own agents (n8n, Make, a server with no browser).
  You create a key in the app and send it in a header.

How both work is described on [MCP server → Sign-in and permissions](https://docs.loice.ai/mcp-server.md#sign-in-and-permissions).

| Client | OAuth sign-in | API key |
| - | - | - |
| [Claude](#claude-claude-ai-and-claude-desktop) | Yes | — |
| [ChatGPT](#chatgpt) | Yes | — |
| [Claude Code](#claude-code) | Yes | — |
| [Cursor](#cursor) | Yes | — |
| [VS Code](#vs-code-github-copilot) | Yes | — |
| [Gemini CLI](#gemini-cli) | Yes | — |
| [MCP Inspector](#mcp-inspector) | Yes | — |
| [Other clients](#other-clients) (n8n, Make, scripts, your own agent) | Yes, if the client supports MCP authorization | Yes |

> [!TIP]
>
> An OAuth connection belongs to one person, works in one workspace and can be revoked on its
> own. Prefer it for anything a person uses interactively; keep API
> keys for unattended automations.

## Create an account and start the trial

Do this once, before you connect any client. Every billed tool spends points from your
workspace, so a workspace that cannot pay has its billed calls refused (uncharged).

**1. Create a Loice account**

Sign up at [app.loice.ai](https://app.loice.ai) with **Continue with Google** or a work email
and password. Personal mailboxes (Gmail, Outlook…) are not accepted.

**2. Set up your workspace**

Answer **Tell us about your company** — company name and website. The workspace is what a
connection works in and what its calls are billed to.

**3. Start the free trial**

A new workspace starts with no points. Click **Add payment method and start trial** under
[Settings → Billing](https://app.loice.ai/settings/account?tab=billing) — or add a payment method
when your first paid action asks for it. The workspace receives **500 welcome points** straight
away for a 14-day trial, and nothing is charged today. Only an Owner or Admin can start the trial. See
[Plans and points](https://docs.loice.ai/plans-and-points.md).

## Before you start

* **The server is public.** Claude and ChatGPT connect from their own cloud, so the URL has to be
  reachable from the internet — `https://app.loice.ai/mcp` is.
* **OAuth sign-in** uses OAuth 2.1 with PKCE. Clients that identify themselves with a Client ID
  Metadata Document are shown with their verified domain; others register themselves
  automatically (dynamic client registration). If a client asks whether to register
  automatically or use a pre-registered identity, choose **register automatically**. There is no
  client ID or secret to enter.
* **An API key** is created under [Settings → API](https://app.loice.ai/settings/account?tab=api)
  and sent as `Authorization: Bearer loice_sk_…`. Keep it out of files you commit: read it from an
  environment variable or a secret manager. Never put it in the URL — Loice refuses it there.
* **Your role decides what it can do.** Approving grants every permission your role in that
  workspace allows; there is nothing to pick. See [Workspace and team](https://docs.loice.ai/workspace-and-team.md).

## Claude (claude.ai and Claude Desktop)

Custom connectors are available on Free (one connector), Pro, Max, Team and Enterprise plans.

**1. Add the connector**

Open **Customize → Connectors**, click **+ Add**, choose **Add custom connector**, name it
`Loice`, paste the server URL and click **Continue**.

```text Remote MCP server URL theme={null}
https://app.loice.ai/mcp
```

If Claude asks how to identify itself to the server, choose **Register automatically**. Leave
any client ID and secret empty.

**2. Sign in**

Click **Connect**. Sign in to Loice in the window that opens, and approve.

**3. Use it in a chat**

In a conversation, click **+** at the lower left → **Connectors** and switch Loice on, then
ask for the leads or contacts you need — for example *"Find 50 heads of sales at German SaaS
companies with 51–200 employees and save them to a list called DACH Sales"*.

> [!NOTE]
>
> On Team and Enterprise plans an Owner adds the connector once under **Organization settings →
> Connectors** (**Add**, hover **Custom**, choose **Web**). Members then open **Customize →
> Connectors**, find Loice marked **Custom** and click **Connect** to sign in with their own
> account.

A connector added on claude.ai is also available in Claude Desktop and the Claude mobile apps on
the same account. To change a connector, remove it and add it again.

## ChatGPT

ChatGPT supports OAuth sign-in only.

**1. Add the server**

Open **ChatGPT Plugins**, click the **+** button and choose **Add custom MCP server**. Enter
the name `Loice` and a short description. Under **Connection**, enter the server URL.

**2. Set authentication**

Choose **OAuth** and leave the client credentials empty — Loice supports dynamic client
registration. Read the risk warning, confirm, and click **Create as a plugin**.

```text Connector settings theme={null}
Name:            Loice
MCP server URL:  https://app.loice.ai/mcp
Authentication:  OAuth
```

**3. Sign in and use it**

Sign in to Loice and approve.
In a new conversation type `@` in the prompt box and select Loice.

> [!NOTE]
>
> Account and workspace policies apply to custom MCP servers. If you don't see **Add custom MCP
> server**, ask a workspace admin to allow it. ChatGPT may ask you to confirm a call before it
> runs.

## Claude Code

**1. Add the server**

```bash Terminal theme={null}
claude mcp add --transport http loice https://app.loice.ai/mcp
```

**2. Sign in**

Start `claude`, run `/mcp`, select `loice` and follow the browser sign-in.

By default the server is added for the current project only (`--scope local`). Add
`--scope user` to make it available in every project, or `--scope project` to share it with your
team through `.mcp.json`.

## Cursor

Servers are configured in `~/.cursor/mcp.json` (all projects) or `.cursor/mcp.json` (one
project).

**1. Add the server to mcp.json**

```json ~/.cursor/mcp.json theme={null}
{
  "mcpServers": {
    "loice": {
      "url": "https://app.loice.ai/mcp"
    }
  }
}
```

**2. Enable it and sign in**

Open **Customize** in the sidebar and enable Loice. Sign in to Loice in the browser window
Cursor opens and approve access.

Cursor asks for approval before running MCP tools unless you allow them.

## VS Code (GitHub Copilot)

Run **MCP: Add Server** from the Command Palette and choose **HTTP**, or write the entry yourself
in `.vscode/mcp.json` (workspace) or in your user configuration (**MCP: Open User
Configuration**).

**1. Add the server**

```json .vscode/mcp.json theme={null}
{
  "servers": {
    "loice": {
      "type": "http",
      "url": "https://app.loice.ai/mcp"
    }
  }
}
```

**2. Start it and sign in**

Run **MCP: List Servers**, pick `loice` and choose **Start Server**. When VS Code prompts you
to sign in, finish the Loice sign-in in the browser.

The tools then appear in Copilot Chat; use the tools picker in the chat input to choose which
ones are active.

## Gemini CLI

Servers are configured in `~/.gemini/settings.json`. Use `httpUrl` for a Streamable HTTP server —
a bare `url` is treated as SSE.

**1. Add the server**

From the command line:

```bash Terminal theme={null}
gemini mcp add --transport http loice https://app.loice.ai/mcp
```

or write the entry yourself:

```json ~/.gemini/settings.json theme={null}
{
  "mcpServers": {
    "loice": {
      "httpUrl": "https://app.loice.ai/mcp"
    }
  }
}
```

**2. Sign in**

Start `gemini` and run `/mcp auth loice`. Gemini CLI finds Loice's sign-in on its own and
registers itself, so no `oauth` block is needed.

The OAuth sign-in needs a browser on the same machine. On a remote shell or inside a container,
connect as described under [Other clients](#other-clients) with an API key.

## MCP Inspector

Use the MCP Inspector to browse and test the tools interactively.

**1. Start the Inspector**

```bash Terminal theme={null}
npx @modelcontextprotocol/inspector
```

The command prints a link with a session token; open that link.

**2. Choose the transport**

Choose **Streamable HTTP** and enter `https://app.loice.ai/mcp`.

**3. Sign in and connect**

Run the OAuth flow from the Inspector's authentication settings, then connect.

Every request needs a sign-in, listing the tools included.

## Other clients

Any client that speaks MCP's Streamable HTTP transport works — n8n, Make, an agent framework or
your own code.

> [tab] OAuth sign-in
>
> **1. Point the client at the server URL**
>
> ```text Streamable HTTP theme={null}
> https://app.loice.ai/mcp
> ```
>
> **2. Sign in**
>
> If the client supports MCP authorization (OAuth 2.1 with PKCE and dynamic client
> registration), it offers to sign in. There is no client ID or secret to enter.

> [tab] API key
>
> **1. Create a key**
>
> Create a workspace API key under
> [Settings → API](https://app.loice.ai/settings/account?tab=api). It is shown once; copy
> it into your secret store.
>
> **2. Point the client at the server URL**
>
> ```text Streamable HTTP theme={null}
> https://app.loice.ai/mcp
> ```
>
> **3. Set the header**
>
> ```text Header theme={null}
> Authorization: Bearer loice_sk_…
> ```
>
> Never put the key in the URL: Loice refuses it.

Clients that only speak SSE or stdio can reach the server through an MCP proxy such as
`mcp-remote`.

## Disconnect a client

* **OAuth sign-in.** Every assistant that signed in is listed in the app under **MCP → Connected
  apps**. Revoke it to cut it off immediately. Removing the server from the client alone does not
  revoke its access. A connection also ends when you leave the workspace, when your role no
  longer allows a permission it holds, or when you change your password.
* **API key.** A key is listed under [Settings → API](https://app.loice.ai/settings/account?tab=api)
  under its own label. Revoke it there, and every assistant, script or pipeline using it stops
  working at once.

## Troubleshooting

| Symptom | What to check |
| - | - |
| The client can't sign in or "can't register" | Make sure the URL is exactly `https://app.loice.ai/mcp`. |
| Every call fails with `401` | The credential was revoked, expired or is wrong. For a sign-in connection, remove the server from the client and add it again. For an API key, create a new one under **Settings → API** and update the header. |
| The browser sign-in never opens | The client may not support MCP authorization, or you are on a remote machine without a browser. Connect with an API key as described under [Other clients](#other-clients). |
| A call says `card_required` | No payment method is added yet, so paid tools are off. Add one under [Settings → Billing](https://app.loice.ai/settings/account?tab=billing) to start the free trial; nothing is charged today. |
| A call says `trial_ended` | The trial is over and the workspace does not have enough points. Choose a plan under [Settings → Billing](https://app.loice.ai/settings/account?tab=billing); the refused call was not charged. |
| A call says `insufficient_credits` | The workspace does not have enough points for the call. Buy points or change the plan under [Settings → Billing](https://app.loice.ai/settings/account?tab=billing); the refused call was not charged. |
| A call says `insufficient_scope` | Your role in the workspace does not allow that tool, or the client asked for less than it needs. Remove the server from the client and add it again, or ask a workspace owner about your role. |
| A tool is missing | The client caps or filters tools, or the connection lacks the permission for it. Check the client's tools picker. |

Tools, prices, permissions and errors are described on [MCP server](https://docs.loice.ai/mcp-server.md).


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