Skip to main content
Glama
Atlassian Confluence MCP Server

Atlassian Confluence MCP Server

by aashari

Сервер Atlassian Confluence MCP

Сервер Node.js/TypeScript Model Context Protocol (MCP) для Atlassian Confluence Cloud. Позволяет системам ИИ (например, LLM, таким как Claude или Cursor AI) безопасно взаимодействовать с вашими пространствами, страницами и контентом Confluence в режиме реального времени.

Версия НПМ Статус сборки

Зачем использовать этот сервер?

  • Минимальный ввод, максимальный вывод : простые идентификаторы предоставляют исчерпывающую информацию без необходимости дополнительных флагов.

  • Полный доступ к базе знаний : предоставьте помощникам на базе искусственного интеллекта доступ к документации, вики-страницам и содержимому базы знаний.

  • Расширенное форматирование контента : автоматическое преобразование формата документов Atlassian в читаемый Markdown.

  • Безопасная локальная аутентификация : работайте локально с вашими учетными данными, никогда не храня токены на удаленных серверах.

  • Интуитивно понятные ответы Markdown : хорошо структурированное, единообразное форматирование Markdown для всех выходных данных.

Related MCP server: MCP Atlassian Server

Что такое МКП?

Model Context Protocol (MCP) — открытый стандарт для безопасного подключения систем ИИ к внешним инструментам и источникам данных. Этот сервер реализует MCP для Confluence Cloud, позволяя помощникам ИИ взаимодействовать с вашим контентом Confluence программным способом.

Предпосылки

  • Node.js (>=18.x): Загрузить

  • Аккаунт Atlassian с доступом к Confluence Cloud

Настраивать

Шаг 1: Получите свой токен API Atlassian

  1. Перейдите на страницу управления токенами API Atlassian: https://id.atlassian.com/manage-profile/security/api-tokens

  2. Нажмите Создать токен API .

  3. Дайте ему описательную метку (например, mcp-confluence-access ).

  4. Нажмите «Создать» .

  5. Скопируйте сгенерированный API-токен немедленно. Вы больше не сможете его увидеть.

Шаг 2: Настройте учетные данные

Вариант A: Файл конфигурации MCP (рекомендуется)

Отредактируйте или создайте ~/.mcp/configs.json :

{
	"confluence": {
		"environments": {
			"ATLASSIAN_SITE_NAME": "<YOUR_SITE_NAME>",
			"ATLASSIAN_USER_EMAIL": "<YOUR_ATLASSIAN_EMAIL>",
			"ATLASSIAN_API_TOKEN": "<YOUR_COPIED_API_TOKEN>"
		}
	}
}
  • <YOUR_SITE_NAME> : Имя вашего сайта Confluence (например, mycompany для mycompany.atlassian.net ).

  • <YOUR_ATLASSIAN_EMAIL> : адрес электронной почты вашей учетной записи Atlassian.

  • <YOUR_COPIED_API_TOKEN> : токен API из шага 1.

Вариант B: Переменные среды

export ATLASSIAN_SITE_NAME="<YOUR_SITE_NAME>"
export ATLASSIAN_USER_EMAIL="<YOUR_EMAIL>"
export ATLASSIAN_API_TOKEN="<YOUR_API_TOKEN>"

Шаг 3: Установка и запуск

Быстрый старт с npx

npx -y @aashari/mcp-server-atlassian-confluence ls-spaces

Глобальная установка

npm install -g @aashari/mcp-server-atlassian-confluence
mcp-atlassian-confluence ls-spaces

Шаг 4: Подключитесь к AI Assistant

Настройте MCP-совместимый клиент (например, Claude, Cursor AI):

{
	"mcpServers": {
		"confluence": {
			"command": "npx",
			"args": ["-y", "@aashari/mcp-server-atlassian-confluence"]
		}
	}
}

Инструменты МКП

Инструменты MCP используют имена snake_case , параметры camelCase и возвращают ответы в формате Markdown.

  • conf_ls_spaces : Список доступных пространств Confluence ( type : str opt, status : str opt, limit : num opt, cursor : str opt). Использование: Просмотр доступных пространств.

  • conf_get_space : Получает подробную информацию о пространстве ( spaceKey : str req). Использование: Доступ к содержимому пространства и метаданным.

  • conf_ls_pages : Список страниц с фильтрацией ( spaceIds : str[] opt, spaceKeys : str[] opt, title : str opt, status : str[] opt, sort : str opt, limit : num opt, cursor : str opt). Использование: Поиск страниц, соответствующих критериям.

  • conf_get_page : Получает полное содержимое страницы ( pageId : str req). Использование: Просмотр полного содержимого страницы в формате Markdown.

  • conf_ls_page_comments : Список комментариев на странице ( pageId : str req). Использование: Чтение обсуждений страницы.

  • conf_search : Поиск контента Confluence ( cql : str opt, query : str opt, title : str opt, spaceKey : str opt, labels : str[] opt, contentType : str opt, limit : num opt, cursor : str opt). Использование: Поиск определенного контента.

conf_ls_spaces

Список глобальных пространств:

{ "type": "global", "status": "current", "limit": 10 }

conf_get_space

Получить подробную информацию о пространстве:

{ "spaceKey": "DEV" }

conf_ls_pages

Список страниц по пространству и названию:

{
	"spaceKeys": ["DEV"],
	"title": "API Documentation",
	"status": ["current"],
	"sort": "-modified-date"
}

Список страниц из нескольких пространств:

{
	"spaceKeys": ["DEV", "HR", "MARKETING"],
	"limit": 15,
	"sort": "-modified-date"
}

conf_get_page

Получить содержимое страницы:

{ "pageId": "12345678" }

conf_ls_page_comments

Комментарии к странице списка:

{ "pageId": "12345678" }

Простой поиск:

{
	"query": "release notes Q1",
	"spaceKey": "PRODUCT",
	"contentType": "page",
	"limit": 5
}

Расширенный поиск CQL:

{ "cql": "space = DEV AND label = api AND created >= '2023-01-01'" }

Команды CLI

Команды CLI используют kebab-case . Запустите --help для получения подробной информации (например, mcp-atlassian-confluence ls-spaces --help ).

  • ls-spaces : Выводит список пространств ( --type , --status , --limit , --cursor ). Пример: mcp-atlassian-confluence ls-spaces --type global .

  • get-space : Получает сведения о пространстве ( --space-key ). Пример: mcp-atlassian-confluence get-space --space-key DEV .

  • ls-pages : Выводит список страниц ( --space-keys , --title , --status , --sort , --limit , --cursor ). Пример: mcp-atlassian-confluence ls-pages --space-keys DEV .

  • get-page : Получает содержимое страницы ( --page-id ). Пример: mcp-atlassian-confluence get-page --page-id 12345678 .

  • ls-page-comments : Выводит список комментариев ( --page-id ). Пример: mcp-atlassian-confluence ls-page-comments --page-id 12345678 .

  • search : Поиск контента ( --cql , --query , --space-key , --label , --type , --limit , --cursor ). Пример: mcp-atlassian-confluence search --query "security" .

Список пробелов

Список глобальных пространств:

mcp-atlassian-confluence ls-spaces --type global --status current --limit 10

Получить пространство

mcp-atlassian-confluence get-space --space-key DEV

Список страниц

С помощью нескольких клавиш пробела:

mcp-atlassian-confluence ls-pages --space-keys DEV HR MARKETING --limit 15 --sort "-modified-date"

С фильтром по названию:

mcp-atlassian-confluence ls-pages --space-keys DEV --title "API Documentation" --status current

Получить страницу

mcp-atlassian-confluence get-page --page-id 12345678

Список комментариев к странице

mcp-atlassian-confluence ls-page-comments --page-id 12345678

Поиск

Простой поиск:

mcp-atlassian-confluence search --query "security best practices" --space-key DOCS --type page --limit 5

Поиск CQL:

mcp-atlassian-confluence search --cql "label = official-docs AND creator = currentUser()"

Формат ответа

Все ответы отформатированы в формате Markdown, включая:

  • Название : Тип и название контента.

  • Контент : полное содержимое страницы, результаты поиска или список элементов.

  • Метаданные : создатель, дата, метки и другая соответствующая информация.

  • Пагинация : навигационная информация для постраничных результатов.

  • Ссылки : ссылки на связанные ресурсы, если применимо.

Ответ на список пробелов

# Confluence Spaces

Showing **5** global spaces (current)

| Key | Name | Description |
|---|---|---|
| [DEV](#) | Development | Engineering and development documentation |
| [HR](#) | Human Resources | Employee policies and procedures |
| [MARKETING](#) | Marketing | Brand guidelines and campaign materials |
| [PRODUCT](#) | Product | Product specifications and roadmaps |
| [SALES](#) | Sales | Sales processes and resources |

*Retrieved from mycompany.atlassian.net on 2025-05-19 14:22 UTC*

Use `cursor: "next-page-token-123"` to see more spaces.

Ответ на содержание страницы

# API Authentication Guide

**Space:** [DEV](#) (Development)
**Created by:** Jane Smith on 2025-04-01
**Last updated:** John Doe on 2025-05-15
**Labels:** api, security, authentication

## Overview

This document outlines the authentication approaches supported by our API platform.

## Authentication Methods

### OAuth 2.0

We support the following OAuth 2.0 flows:

1. **Authorization Code Flow** - For web applications
2. **Client Credentials Flow** - For server-to-server
3. **Implicit Flow** - For legacy clients only

### API Keys

Static API keys are supported but discouraged for production use due to security limitations:

| Key Type | Use Case | Expiration |
|---|---|---|
| Development | Testing | 30 days |
| Production | Live systems | 90 days |

## Implementation Examples

  import requests

  def get_oauth_token():
      return requests.post(
          'https://api.example.com/oauth/token',
          data={
              'client_id': 'YOUR_CLIENT_ID',
              'client_secret': 'YOUR_CLIENT_SECRET',
              'grant_type': 'client_credentials'
          }
      ).json()['access_token']

*Retrieved from mycompany.atlassian.net on 2025-05-19 14:25 UTC*

Разработка

# Clone repository
git clone https://github.com/aashari/mcp-server-atlassian-confluence.git
cd mcp-server-atlassian-confluence

# Install dependencies
npm install

# Run in development mode
npm run dev:server

# Run tests
npm test

Внося вклад

Вклады приветствуются! Пожалуйста:

  1. Создайте форк репозитория.

  2. Создайте ветку функций ( git checkout -b feature/xyz ).

  3. Зафиксируйте изменения ( git commit -m "Add xyz feature" ).

  4. Отправьте изменения в ветку ( git push origin feature/xyz ).

  5. Откройте запрос на извлечение.

Подробности смотрите на сайте CONTRIBUTING.md .

Лицензия

Лицензия ISC

Available Tools

5 tools
conf_deleteConfluence DELETE RequestA

Delete Confluence resources. Returns TOON format by default.

Output format: TOON (default) or JSON (outputFormat: "json")

Common operations:

  • /wiki/api/v2/pages/{id} - Delete page

  • /wiki/api/v2/blogposts/{id} - Delete blog post

  • /wiki/api/v2/pages/{id}/labels/{label-id} - Remove label

  • /wiki/api/v2/footer-comments/{id} - Delete comment

  • /wiki/api/v2/attachments/{id} - Delete attachment

Note: Most DELETE endpoints return 204 No Content on success.

API reference: https://developer.atlassian.com/cloud/confluence/rest/v2/

Inputs: path (required), queryParams, jq, outputFormat.

conf_getConfluence GET RequestA

Read any Confluence data. Returns TOON format by default (30-60% fewer tokens than JSON).

IMPORTANT - Cost Optimization:

  • ALWAYS use jq param to filter response fields. Unfiltered responses are very expensive!

  • Use limit query param to restrict result count (e.g., limit: "5")

  • If unsure about available fields, first fetch ONE item with limit: "1" and NO jq filter to explore the schema, then use jq in subsequent calls

Schema Discovery Pattern:

  1. First call: path: "/wiki/api/v2/spaces", queryParams: {"limit": "1"} (no jq) - explore available fields

  2. Then use: jq: "results[*].{id: id, key: key, name: name}" - extract only what you need

Output format: TOON (default, token-efficient) or JSON (outputFormat: "json")

Common paths:

  • /wiki/api/v2/spaces - list spaces

  • /wiki/api/v2/pages - list pages (use space-id query param)

  • /wiki/api/v2/pages/{id} - get page details

  • /wiki/api/v2/pages/{id}/body - get page body (body-format: storage, atlas_doc_format, view)

  • /wiki/rest/api/search - search content (cql query param)

JQ examples: results[*].id, results[0], results[*].{id: id, title: title}

API reference: https://developer.atlassian.com/cloud/confluence/rest/v2/

Inputs: path (required), queryParams, jq, outputFormat.

conf_patchConfluence PATCH RequestA

Partially update Confluence resources. Returns TOON format by default.

IMPORTANT - Cost Optimization: Use jq param to filter response fields.

Output format: TOON (default) or JSON (outputFormat: "json")

Common operations:

  1. Update space: /wiki/api/v2/spaces/{id} body: {"name": "New Name", "description": {"plain": {"value": "Desc", "representation": "plain"}}}

  2. Update comment: /wiki/api/v2/footer-comments/{id}

Note: Confluence v2 API primarily uses PUT for updates.

API reference: https://developer.atlassian.com/cloud/confluence/rest/v2/

Inputs: path (required), body (required), queryParams, jq, +1 more.

conf_postConfluence POST RequestA

Create Confluence resources. Returns TOON format by default (token-efficient).

IMPORTANT - Cost Optimization:

  • Use jq param to extract only needed fields from response (e.g., jq: "{id: id, title: title}")

  • Unfiltered responses include all metadata and are expensive!

Output format: TOON (default) or JSON (outputFormat: "json")

Common operations:

  1. Create page: /wiki/api/v2/pages body: {"spaceId": "123456", "status": "current", "title": "Page Title", "parentId": "789", "body": {"representation": "storage", "value": "<p>Content</p>"}}

  2. Create blog post: /wiki/api/v2/blogposts body: {"spaceId": "123456", "status": "current", "title": "Blog Title", "body": {"representation": "storage", "value": "<p>Content</p>"}}

  3. Add label: /wiki/api/v2/pages/{id}/labels - body: {"name": "label-name"}

  4. Add comment: /wiki/api/v2/pages/{id}/footer-comments

API reference: https://developer.atlassian.com/cloud/confluence/rest/v2/

Inputs: path (required), body (required), queryParams, jq, +1 more.

conf_putConfluence PUT RequestA

Replace Confluence resources (full update). Returns TOON format by default.

IMPORTANT - Cost Optimization:

  • Use jq param to extract only needed fields from response

  • Example: jq: "{id: id, version: version.number}"

Output format: TOON (default) or JSON (outputFormat: "json")

Common operations:

  1. Update page: /wiki/api/v2/pages/{id} body: {"id": "123", "status": "current", "title": "Updated Title", "spaceId": "456", "body": {"representation": "storage", "value": "<p>Content</p>"}, "version": {"number": 2}} Note: version.number must be incremented

  2. Update blog post: /wiki/api/v2/blogposts/{id}

Note: PUT replaces entire resource. Version number must be incremented.

API reference: https://developer.atlassian.com/cloud/confluence/rest/v2/

Inputs: path (required), body (required), queryParams, jq, +1 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.3/5.0

    Scored across 5 tools

    Disambiguation5/5

    Each tool corresponds to a distinct HTTP method (DELETE, GET, PATCH, POST, PUT), clearly differentiating their purpose. There is no overlap in functionality between tools.

    Naming Consistency5/5

    All tools follow the consistent pattern 'conf_' followed by the HTTP method verb in lowercase (e.g., conf_delete, conf_get). This pattern is uniform and predictable.

    Tool Count5/5

    With 5 tools covering the essential CRUD operations plus partial update, the count is well-scoped for a Confluence API server. It is not too few or too many.

    Completeness5/5

    The tools provide full coverage of basic resource lifecycle operations (create, read, update, partial update, delete). The descriptions include common API paths for pages, spaces, blog posts, etc., and the GET tool supports search via query parameters, leaving no obvious gaps.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      A Model Context Protocol server that connects AI assistants like Cline to Atlassian Jira and Confluence, enabling them to query data and perform actions through a standardized interface.
      15 npm
      52
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      Model Context Protocol server that integrates with Atlassian Confluence and Jira, enabling AI assistants to search, create, and update content in these platforms through natural language interactions.
      1
      MIT