Confluence Data Center MCP server

Integrates with Confluence Data Center to enable direct access to content through operations like searching, retrieving, creating, updating, and deleting pages without switching contexts.
Back to servers
Provider
Tariq Iqbal
Release date
May 06, 2025
Language
TypeScript
Stats
1 star

The Confluence MCP Server allows AI models to interact with Confluence Data Center through REST API operations like searching, retrieving, creating, updating, and deleting pages. This server bridges the gap between AI capabilities and your Confluence content management system.

Installation and Setup

To get started with the Confluence MCP Server:

  1. Clone the repository to your local machine
  2. Install the required dependencies:
pip install -r requirements.txt

Configuration

Create a .env file in the project root directory with your Confluence credentials:

CONFLUENCE_API_BASE=http://localhost:8090/rest/api
CONFLUENCE_USERNAME=your_username
CONFLUENCE_PASSWORD=your_password

Be sure to modify these values to match your specific Confluence instance.

Running the Server

Development Mode

The recommended way to run the MCP server is using the MCP CLI tool in development mode:

mcp dev confluence.py

This launches the MCP Inspector UI at http://127.0.0.1:6274, which provides a convenient environment for testing and debugging.

Installing in Claude Desktop

To make the server available in Claude Desktop:

mcp install confluence.py

Available Operations

Searching Pages

Execute CQL (Confluence Query Language) searches to find content:

Parameters:
- cql: CQL query string
- limit: Number of results to return (default: 10)

Retrieving Page Content

Get page content by ID:

Parameters:
- pageId: Confluence Page ID

Or retrieve a page with its complete body content:

Parameters:
- pageId: Confluence Page ID

Finding Pages

Find pages by space key:

Parameters:
- spaceKey: Confluence Space Key
- limit: Maximum number of results (default: 10)
- expand: Optional comma-separated list of properties to expand

Find a specific page by title and space:

Parameters:
- title: Page title
- spaceKey: Confluence Space Key

Creating and Modifying Content

Create a new page:

Parameters:
- title: Page title
- spaceKey: Confluence Space Key
- content: Page content in storage format (HTML)
- parentId: Optional parent page ID

Update an existing page:

Parameters:
- pageId: Confluence Page ID
- content: New page content in storage format (HTML)
- title: Optional new title
- spaceKey: Optional space key (only if changing space)

Delete a page:

Parameters:
- pageId: Confluence Page ID

Usage Examples

Once connected to an AI model, you can interact with Confluence using natural language commands such as:

  • "Find all pages in the DOCS space"
  • "Get the content of page with ID 123456"
  • "Create a new page titled 'Meeting Notes' in the TEAM space with content '

    Notes from our meeting

    '"
  • "Update page with ID 123456 to have the content '

    Updated meeting notes

    '"
  • "Update the title of page 123456 to 'Revised Meeting Notes'"

How to add this MCP server to Cursor

There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.

If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > MCP and click "Add new global MCP server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "cursor-rules-mcp": {
            "command": "npx",
            "args": [
                "-y",
                "cursor-rules-mcp"
            ]
        }
    }
}

Adding an MCP server to a project

To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.

How to use the MCP server

Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.

The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.

You can also explictly ask the agent to use the tool by mentioning the tool name and describing what the function does.

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later