Skip to main content
Glama
doccler-app

Doccler MCP Server

by doccler-app
README.md
# Doccler MCP Server

šŸš€ **Connect your IDE to Doccler** - Use AI-powered documentation directly from your development environment.

[![npm version](https://badge.fury.io/js/@doccler%2Fmcp-server.svg)](https://www.npmjs.com/package/@doccler/mcp-server)

## What is MCP?

The Model Context Protocol (MCP) is an open standard that allows AI assistants (like Claude, Cursor, VS Code with AI extensions) to connect to external tools and data sources. Doccler's MCP server enables you to:

- **Query your documentation** as a single source of truth
- **Create documentation** directly from your IDE
- **Search documentation** with semantic search
- **Generate documentation** from code using AI
- **Publish/unpublish** documents
- **Organize** documents into spaces

## Quick Start

### 1. Get Your Doccler API Key

1. Log in to [Doccler](https://doccler.app)
2. Go to **Settings** → **API Keys**
3. Click **Create New API Key**
4. Copy the key (it's only shown once!)

### 2. Configure Your IDE

Choose your IDE and add the configuration:

#### Cursor (`~/.cursor/mcp.json`)

```json
{
  "mcpServers": {
    "doccler": {
      "command": "npx",
      "args": ["-y", "@doccler/mcp-server@latest"],
      "env": {
        "DOCCLER_API_KEY": "doccler_xxxxxxxx_yyyyyyyyyyyyyyyyyyyy"
      }
    }
  }
}
```

#### Claude Desktop

**macOS:** `~/Library/Application Support/Claude/claude_desktop_config.json`
**Windows:** `%APPDATA%\Claude\claude_desktop_config.json`

```json
{
  "mcpServers": {
    "doccler": {
      "command": "npx",
      "args": ["-y", "@doccler/mcp-server@latest"],
      "env": {
        "DOCCLER_API_KEY": "doccler_xxxxxxxx_yyyyyyyyyyyyyyyyyyyy"
      }
    }
  }
}
```

#### VS Code / Antigravity

Add to your MCP settings:

```json
{
  "mcp": {
    "servers": {
      "doccler": {
        "command": "npx",
        "args": ["-y", "@doccler/mcp-server@latest"],
        "env": {
          "DOCCLER_API_KEY": "doccler_xxxxxxxx_yyyyyyyyyyyyyyyyyyyy"
        }
      }
    }
  }
}
```

### 3. Restart Your IDE

After adding the configuration, restart your IDE. The Doccler MCP server will be downloaded and started automatically.

## Alternative: Global Installation

If you prefer to install globally instead of using `npx`:

```bash
npm install -g @doccler/mcp-server
```

Then configure your IDE with:

```json
{
  "mcpServers": {
    "doccler": {
      "command": "doccler-mcp",
      "env": {
        "DOCCLER_API_KEY": "doccler_xxxxxxxx_yyyyyyyyyyyyyyyyyyyy"
      }
    }
  }
}
```

## Available Tools

| Tool | Description |
|------|-------------|
| `hello_doccler` | Verify your connection to Doccler |
| `search_docs` | Search your documentation (keyword + semantic) |
| `create_doc` | Create new documentation with optional space |
| `generate_doc` | Generate documentation from code using AI |
| `publish_doc` | Publish or unpublish a document |
| `get_doc` | Get the content of a specific document |
| `list_spaces` | List all available spaces |

## Usage Examples

### Search Documentation
```
"Search my documentation for authentication"
"Find docs about API endpoints"
```

### Create Documentation
```
"Create documentation titled 'Getting Started' about how to install the app"
"Create a doc in the API space explaining the user endpoint"
```

### Generate from Code
```
"Generate documentation for this code: [paste your code]"
"Document this function with examples"
```

### Publish/Unpublish
```
"Publish the document with slug 'getting-started'"
"Unpublish my-api-guide"
```

## Environment Variables

| Variable | Description | Default |
|----------|-------------|---------|
| `DOCCLER_API_KEY` | Your Doccler API key | **(required)** |
| `DOCCLER_API_URL` | API URL (for self-hosted) | `https://doccler.app/api` |

> **Note:** `DOCCLER_API_URL` is only needed for self-hosted instances or development. Production users can omit it.

## Troubleshooting

### "API Key not configured"

Make sure `DOCCLER_API_KEY` is set in your IDE's MCP configuration.

### "Unauthorized" errors

1. Check that your API key is valid
2. Go to Settings → API Keys in Doccler to verify
3. Create a new key if needed

### Server not starting

1. Ensure Node.js 18+ is installed
2. Try running manually: `npx @doccler/mcp-server`
3. Check your IDE's MCP logs

## Support

- **Documentation:** [doccler.app/en/docs](https://doccler.app/en/docs)
- **Email:** help@doccler.app

## License

MIT Ā© Doccler

TDQS

A3.8/5.0

Scored across 7 tools

Disambiguation5/5

All tools have clear, distinct purposes. The health check, search, CRUD for docs, spaces listing, and publishing are each unique and non-overlapping.

Naming Consistency5/5

All tool names follow a consistent verb_noun snake_case pattern (e.g., search_docs, create_doc, list_spaces), making them predictable and easy to navigate.

Tool Count5/5

With 7 tools covering health check, search, CRUD, AI generation, and space management, the count is well-scoped for a documentation server without being excessive or sparse.

Completeness4/5

The tool set covers most core documentation operations but is missing explicit update and delete tools, which are minor but notable gaps that an agent would need to work around.

Maintenance

ActivityInactive
ResponsivenessNo issues