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

# MCP Server

> Connect Claude, Cursor, Codex and other agents to your Cleve workspace via the Model Context Protocol

## Overview

Cleve exposes an MCP (Model Context Protocol) server at:

```
https://app.cleve.ai/mcp
```

Once connected, your agent gets read/write access to the same workspace your team uses — notes, folders, skills, memory, and org context.

Authentication is handled via OAuth on the first connection. You'll be prompted to sign in with your Cleve account; no manual token management required.

## Quick Start

<Tabs>
  <Tab title="Claude Code">
    Run this in your terminal:

    ```bash theme={null}
    claude mcp add cleve --transport http https://app.cleve.ai/mcp
    ```
  </Tab>

  <Tab title="Cursor">
    Add to your `.cursor/mcp.json`:

    ```json theme={null}
    {
      "mcpServers": {
        "cleve": {
          "type": "http",
          "url": "https://app.cleve.ai/mcp"
        }
      }
    }
    ```
  </Tab>

  <Tab title="Claude Desktop">
    Add to your Claude Desktop configuration file:

    ```json theme={null}
    {
      "mcpServers": {
        "cleve": {
          "type": "http",
          "url": "https://app.cleve.ai/mcp"
        }
      }
    }
    ```
  </Tab>

  <Tab title="Codex">
    Run this in your terminal:

    ```bash theme={null}
    codex mcp add cleve --transport http https://app.cleve.ai/mcp
    ```
  </Tab>
</Tabs>

After the first connection, you'll be redirected through the Cleve OAuth flow. Once authorised, the token is stored by your client and reused automatically.

<Note>
  You can also find these snippets in **Settings → Developer → MCP Server** inside the Cleve app.
</Note>

## Available Tools

### Notes

| Tool                         | Description                                   | Parameters                                                      |
| ---------------------------- | --------------------------------------------- | --------------------------------------------------------------- |
| `cleve_search_notes`         | Search notes by keyword                       | `query` (required), `limit`                                     |
| `cleve_read_note`            | Read a note by ID                             | `noteId` (required)                                             |
| `cleve_list_recent_notes`    | List recently updated notes                   | `limit`                                                         |
| `cleve_list_notes_in_folder` | List notes in a specific folder               | `folderId` (required)                                           |
| `cleve_count_notes`          | Get total and pinned note counts              | `folderId`                                                      |
| `cleve_cite`                 | Get citation metadata for specific note IDs   | `noteIds[]` (required)                                          |
| `cleve_create_note`          | Create a new note                             | `title`, `content`, `folderId`, `isPinned`                      |
| `cleve_edit_note`            | Update a note's title, content, or properties | `noteId` (required), `title`, `content`, `folderId`, `isPinned` |
| `cleve_move_note`            | Move a note to a different folder             | `noteId` (required), `folderId` (required, `null` = unfiled)    |
| `cleve_pin_note`             | Pin a note                                    | `noteId` (required)                                             |
| `cleve_unpin_note`           | Unpin a note                                  | `noteId` (required)                                             |
| `cleve_publish_note`         | Publish a note publicly                       | `noteId` (required)                                             |
| `cleve_unpublish_note`       | Unpublish a note                              | `noteId` (required)                                             |
| `cleve_share_note`           | Enable or disable link sharing for a note     | `noteId` (required), `isPublic` (required)                      |
| `cleve_delete_note`          | Delete a note permanently                     | `noteId` (required)                                             |

### Folders

| Tool                  | Description                                 | Parameters                               |
| --------------------- | ------------------------------------------- | ---------------------------------------- |
| `cleve_list_folders`  | List all folders                            | —                                        |
| `cleve_create_folder` | Create a new folder (optionally nested)     | `name` (required), `parentId`            |
| `cleve_rename_folder` | Rename a folder                             | `folderId` (required), `name` (required) |
| `cleve_delete_folder` | Delete a folder (its notes move to unfiled) | `folderId` (required)                    |

### Skills Marketplace

| Tool                       | Description                                | Parameters                                                                 |
| -------------------------- | ------------------------------------------ | -------------------------------------------------------------------------- |
| `cleve_list_skills`        | List your created and installed skills     | —                                                                          |
| `cleve_search_marketplace` | Browse published skills in the marketplace | `query`, `category`                                                        |
| `cleve_create_skill`       | Create a new AI skill                      | `name` (required), `prompt` (required), `description`, `category`, `model` |
| `cleve_update_skill`       | Update an existing skill                   | `skillId` (required), `name`, `prompt`, `description`, `category`, `model` |
| `cleve_publish_skill`      | Publish a skill to the marketplace         | `skillId` (required)                                                       |
| `cleve_unpublish_skill`    | Remove a skill from the marketplace        | `skillId` (required)                                                       |
| `cleve_delete_skill`       | Delete a skill permanently                 | `skillId` (required)                                                       |
| `cleve_install_skill`      | Install a skill from the marketplace       | `skillId` (required)                                                       |
| `cleve_uninstall_skill`    | Uninstall a skill                          | `skillId` (required)                                                       |

### Memory

| Tool                        | Description                         | Parameters           |
| --------------------------- | ----------------------------------- | -------------------- |
| `cleve_get_memory`          | Read the current AI memory note     | —                    |
| `cleve_get_memory_settings` | Read memory feature settings        | —                    |
| `cleve_toggle_memory`       | Enable or disable memory            | `enabled` (required) |
| `cleve_clear_memory`        | Wipe memory content and start fresh | —                    |

### Organizations

These tools are available when you belong to one or more Cleve organizations.

| Tool               | Description                                                      | Parameters         |
| ------------------ | ---------------------------------------------------------------- | ------------------ |
| `cleve_list_orgs`  | List organizations you belong to (active org is marked with `*`) | —                  |
| `cleve_switch_org` | Switch the active organization for this session                  | `orgId` (required) |

Org context persists for 30 minutes after switching, then resets to your default.

## Authentication Details

The MCP server uses **OAuth 2.0** via Clerk. On first connect:

1. Your client opens the Cleve authorization URL
2. You sign in with your Cleve account
3. Your client stores the access token and sends it as a Bearer header on every request

The server reads your user identity and active organization from the token. You do not need an API key for MCP — it's separate from the REST API key system.

If you belong to multiple organizations, use `cleve_list_orgs` to see them and `cleve_switch_org` to change context mid-session.

## Example Prompts

```
Search my notes for anything related to "product roadmap" and summarize the key themes.
```

```
Create a folder called "2026 Planning" and move all notes with "Q1" in the title into it.
```

```
Read my memory note and tell me what context you already have about me.
```

```
Find the brand guide note and quote the tone-of-voice rules verbatim.
```
