Логотип Ambient Code Platform MCP Server

Ambient Code Platform MCP Server

Организация
ambient-code

MCP server for ACP (Ambient Code Platform)

Издательambient-code
Репозиторийmcp
ЯзыкPython
Форки
3
Звёзды
0
Доступные инструменты
0
Тип транспортаstdio
Категории
Ссылки
  • Подключайте инструменты к рабочим процессам с ИИ

    Ambient Code Platform MCP Server предоставляет возможности MCP, доступные совместимым ИИ-клиентам и агентам.

  • Доступные инструменты: 0

    Ниже представлены доступные для вызова действия с названиями и описаниями, если сервер их предоставляет.

  • Готовая конфигурация для копирования

    Используйте примеры конфигурации, чтобы настроить этот сервер в предпочитаемом MCP-клиенте.

  • Показатели интереса к открытому проекту

    Звёзды: 0, форки: 3 — в связанном репозитории.

MCP ACP Server

A Model Context Protocol (MCP) server for managing Ambient Code Platform (ACP) sessions via the public-api gateway.


Table of Contents


Quick Start

bash
# Install
git clone https://github.com/ambient-code/mcp
cd mcp
pip install .    # installs the 'mcp-acp' command

# Configure
mkdir -p ~/.config/acp
cat > ~/.config/acp/clusters.yaml <<EOF
clusters:
  my-cluster:
    server: https://public-api-ambient.apps.your-cluster.example.com
    token: your-bearer-token-here
    default_project: my-workspace
default_cluster: my-cluster
EOF
chmod 600 ~/.config/acp/clusters.yaml

Then add to your MCP client (Claude Desktop, Claude Code, or uvx) and try:

List my ACP sessions

Features

Session Management

ToolDescription
acp_list_sessionsList/filter sessions by status, age, with sorting and limits
acp_get_sessionGet detailed session information by ID
acp_create_sessionCreate sessions with custom prompts, repos, model selection, and timeout
acp_create_session_from_templateCreate sessions from predefined templates (triage/bugfix/feature/exploration)
acp_delete_sessionDelete sessions with dry-run preview
acp_restart_sessionRestart a stopped session
acp_clone_sessionClone an existing session's configuration into a new session
acp_update_sessionUpdate session metadata (display name, timeout)

Observability

ToolDescription
acp_get_session_logsRetrieve container logs for a session
acp_get_session_transcriptRetrieve conversation history (JSON or Markdown)
acp_get_session_metricsGet usage statistics (tokens, duration, tool calls)

Labels

ToolDescription
acp_label_resourceAdd labels to a session for organizing and filtering
acp_unlabel_resourceRemove labels from a session by key
acp_list_sessions_by_labelList sessions matching label selectors
acp_bulk_label_resourcesAdd labels to multiple sessions (max 3)
acp_bulk_unlabel_resourcesRemove labels from multiple sessions (max 3)

Bulk Operations

ToolDescription
acp_bulk_delete_sessionsDelete multiple sessions (max 3) with confirmation and dry-run
acp_bulk_stop_sessionsStop multiple running sessions (max 3)
acp_bulk_restart_sessionsRestart multiple stopped sessions (max 3)
acp_bulk_delete_sessions_by_labelDelete sessions matching label selectors (max 3 matches)
acp_bulk_stop_sessions_by_labelStop sessions matching label selectors (max 3 matches)
acp_bulk_restart_sessions_by_labelRestart sessions matching label selectors (max 3 matches)

Cluster Management

ToolDescription
acp_list_clustersList configured cluster aliases
acp_whoamiCheck current configuration and authentication status
acp_switch_clusterSwitch between configured clusters
acp_loginAuthenticate to a cluster with a Bearer token

Safety Features:

  • Dry-Run Mode — All mutating operations support dry_run for safe preview before executing
  • Bulk Operation Limits — Maximum 3 items per bulk operation with confirmation requirement
  • Label Validation — Labels must be 1-63 alphanumeric characters, dashes, dots, or underscores

Installation

From Source (end users)

bash
git clone https://github.com/ambient-code/mcp
cd mcp
pip install .    # installs the 'mcp-acp' command

From Wheel

Requires make to be installed.

bash
# "make install" sets up the dev environment (.venv + dependencies),
# which "make build" then uses to produce the wheel in dist/
make install
make build
pip install dist/mcp_acp-*.whl

Development Install (contributors)

bash
git clone https://github.com/ambient-code/mcp
cd mcp
uv venv
uv pip install -e ".[dev]"

Virtual Environment Install

On some Linux distributions (Debian, Ubuntu, Fedora 38+), PEP 668 prevents pip install into the system Python. If you get an "externally-managed-environment" error, install into a virtual environment instead:

bash
git clone https://github.com/ambient-code/mcp
cd mcp
python3 -m venv .venv
source .venv/bin/activate
pip install .

Note that the mcp-acp command will only be available inside the venv. To use it from an MCP client like Claude Code, reference the full path:

bash
claude mcp add mcp-acp -t stdio /full/path/to/mcp/.venv/bin/mcp-acp

Requirements:

  • Python 3.12+
  • Bearer token for the ACP public-api gateway
  • Access to an ACP cluster

Configuration

Cluster Config

Create ~/.config/acp/clusters.yaml:

yaml
clusters:
  vteam-stage:
    server: https://public-api-ambient.apps.vteam-stage.example.com
    token: your-bearer-token-here
    description: "V-Team Staging Environment"
    default_project: my-workspace

  vteam-prod:
    server: https://public-api-ambient.apps.vteam-prod.example.com
    token: your-bearer-token-here
    description: "V-Team Production"
    default_project: my-workspace

default_cluster: vteam-stage

Then secure the file:

bash
chmod 600 ~/.config/acp/clusters.yaml

Authentication

Add your Bearer token to each cluster entry under the token field, or set the ACP_TOKEN environment variable:

bash
export ACP_TOKEN=your-bearer-token-here

Get your token from the ACP platform administrator or the gateway's authentication endpoint.

Claude Desktop

Edit your configuration file:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Linux: ~/.config/claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
json
{
  "mcpServers": {
    "acp": {
      "command": "mcp-acp",
      "args": [],
      "env": {
        "ACP_CLUSTER_CONFIG": "${HOME}/.config/acp/clusters.yaml"
      }
    }
  }
}

After editing, completely quit and restart Claude Desktop (not just close the window).

Claude Code (CLI)

bash
claude mcp add mcp-acp -t stdio mcp-acp

Using uvx

uvx provides zero-install execution — no global Python pollution, auto-caching, and fast startup.

bash
# Install uv (if needed)
curl -LsSf https://astral.sh/uv/install.sh | sh

Claude Desktop config for uvx:

json
{
  "mcpServers": {
    "acp": {
      "command": "uvx",
      "args": ["mcp-acp"]
    }
  }
}

For a local wheel (before PyPI publish):

json
{
  "mcpServers": {
    "acp": {
      "command": "uvx",
      "args": ["--from", "/full/path/to/dist/mcp_acp-0.3.0-py3-none-any.whl", "mcp-acp"]
    }
  }
}

Usage

Examples

# List sessions
List my ACP sessions
Show running sessions in my-workspace
List sessions older than 7 days in my-workspace
List sessions sorted by creation date, limit 20

# Session details
Get details for ACP session session-name
Show AgenticSession session-name in my-workspace

# Create a session
Create a new ACP session with prompt "Run all unit tests and report results"

# Create from template
Create an ACP session from the bugfix template called "fix-auth-issue"

# Restart / clone
Restart ACP session my-stopped-session
Clone ACP session my-session as "my-session-v2"

# Update session metadata
Update ACP session my-session display name to "Production Test Runner"

# Observability
Show logs for ACP session my-session
Get transcript for ACP session my-session in markdown format
Show metrics for ACP session my-session

# Labels
Label ACP session my-session with env=staging and team=platform
Remove label env from ACP session my-session
List ACP sessions with label team=platform

# Delete with dry-run (safe!)
Delete test-session from my-workspace in dry-run mode

# Actually delete
Delete test-session from my-workspace

# Bulk operations (dry-run first)
Delete these sessions: session-1, session-2, session-3 from my-workspace (dry-run first)
Stop all sessions with label env=test
Restart sessions with label team=platform

# Cluster operations
Check my ACP authentication
List my ACP clusters
Switch to ACP cluster vteam-prod
Login to ACP cluster vteam-stage with token

Trigger Keywords

Include one of these keywords so your MCP client routes the request to ACP: ACP, ambient, AgenticSession, or use tool names directly (e.g., acp_list_sessions, acp_whoami). Without a keyword, generic phrases like "list sessions" may not trigger the server.

Quick Reference

TaskCommand Pattern
Check authUse acp_whoami
List allList ACP sessions in PROJECT
Filter statusList running sessions in PROJECT
Filter ageList sessions older than 7d in PROJECT
Get detailsGet details for ACP session SESSION
CreateCreate ACP session with prompt "..."
Create from templateCreate ACP session from bugfix template
RestartRestart ACP session SESSION
CloneClone ACP session SESSION as "new-name"
UpdateUpdate ACP session SESSION timeout to 1800
View logsShow logs for ACP session SESSION
View transcriptGet transcript for ACP session SESSION
View metricsShow metrics for ACP session SESSION
Add labelsLabel ACP session SESSION with env=test
Remove labelsRemove label env from ACP session SESSION
Filter by labelList ACP sessions with label team=platform
Delete (dry)Delete SESSION in PROJECT (dry-run)
Delete (real)Delete SESSION in PROJECT
Bulk deleteDelete session-1, session-2 in PROJECT
Bulk by labelStop sessions with label env=test
List clustersUse acp_list_clusters
LoginLogin to ACP cluster CLUSTER

Tool Reference

For complete API specifications including input schemas, output formats, and behavior details, see API_REFERENCE.md.

CategoryToolDescription
Sessionacp_list_sessionsList/filter sessions
acp_get_sessionGet session details
acp_create_sessionCreate session with prompt
acp_create_session_from_templateCreate from template
acp_delete_sessionDelete with dry-run support
acp_restart_sessionRestart stopped session
acp_clone_sessionClone session configuration
acp_update_sessionUpdate display name or timeout
Observabilityacp_get_session_logsRetrieve container logs
acp_get_session_transcriptGet conversation history
acp_get_session_metricsGet usage statistics
Labelsacp_label_resourceAdd labels to session
acp_unlabel_resourceRemove labels by key
acp_list_sessions_by_labelFilter sessions by labels
acp_bulk_label_resourcesBulk add labels (max 3)
acp_bulk_unlabel_resourcesBulk remove labels (max 3)
Bulkacp_bulk_delete_sessionsDelete multiple sessions (max 3)
acp_bulk_stop_sessionsStop multiple sessions (max 3)
acp_bulk_restart_sessionsRestart multiple sessions (max 3)
acp_bulk_delete_sessions_by_labelDelete by label (max 3)
acp_bulk_stop_sessions_by_labelStop by label (max 3)
acp_bulk_restart_sessions_by_labelRestart by label (max 3)
Clusteracp_list_clustersList configured clusters
acp_whoamiCheck authentication status
acp_switch_clusterSwitch cluster context
acp_loginAuthenticate with Bearer token

Troubleshooting

"No authentication token available"

Your token is not configured. Either:

  1. Add token: your-token-here to your cluster in ~/.config/acp/clusters.yaml
  2. Set the ACP_TOKEN environment variable

"HTTP 401: Unauthorized"

Your token is expired or invalid. Get a new token from the ACP platform administrator.

"HTTP 403: Forbidden"

You don't have permission for this operation. Contact your ACP platform administrator.

"Direct Kubernetes API URLs (port 6443) are not supported"

You're using a direct K8s API URL. Use the public-api gateway URL instead:

  • Wrong: https://api.cluster.example.com:6443
  • Correct: https://public-api-ambient.apps.cluster.example.com

"mcp-acp: command not found"

Add Python user bin to PATH:

  • macOS: export PATH="$HOME/Library/Python/3.*/bin:$PATH"
  • Linux: export PATH="$HOME/.local/bin:$PATH"

Then restart your shell.

MCP Tools Not Showing in Claude

  1. Check Claude Desktop logs: Help → View Logs
  2. Verify config file syntax is valid JSON
  3. Make sure mcp-acp is in PATH
  4. Restart Claude Desktop completely (quit, not just close)

"Permission denied" on clusters.yaml

bash
chmod 600 ~/.config/acp/clusters.yaml
chmod 700 ~/.config/acp

Architecture

  • MCP SDK — Standard MCP protocol implementation (stdio transport)
  • httpx — Async HTTP REST client for the public-api gateway
  • Pydantic — Settings management and input validation
  • Three-layer design — Server (tool dispatch) → Client (HTTP + validation) → Formatters (output)

See CLAUDE.md for complete system design.


Security

  • Input Validation — DNS-1123 format validation for all resource names
  • Gateway URL Enforcement — Direct K8s API URLs (port 6443) rejected
  • Bearer Token Security — Tokens filtered from logs, sourced from config or environment
  • Resource Limits — Bulk operations limited to 3 items with confirmation

See SECURITY.md for complete security documentation including threat model and best practices.


Development

bash
# One-time setup
uv venv && uv pip install -e ".[dev]"

# Pre-commit workflow
uv run ruff format . && uv run ruff check . && uv run pytest tests/

# Run with coverage
uv run pytest tests/ --cov=src/mcp_acp --cov-report=html

# Build wheel
uvx --from build pyproject-build --installer uv

See CLAUDE.md for contributing guidelines.


Roadmap

Current implementation provides 26 tools. 3 tools remain planned:


Contributing

  1. Fork the repository
  2. Create a feature branch
  3. Add tests for new functionality
  4. Ensure all tests pass (uv run pytest tests/)
  5. Ensure code quality checks pass (uv run ruff format . && uv run ruff check .)
  6. Submit a pull request

Status

Code: Production-Ready | Tests: All Passing | Security: Input validation, gateway enforcement, token security | Tools: 26 implemented (3 more planned)


Documentation

  • API_REFERENCE.md — Full API specifications for all 26 tools
  • SECURITY.md — Security features, threat model, and best practices
  • CLAUDE.md — System architecture and development guide

License

MIT License — See LICENSE file for details.

Support

For issues and feature requests, use the GitHub issue tracker.

Установка

TypingMind
Требования:

Node.js 18+

{
  "mcpServers": {
    "acp": {
      "command": "uvx",
      "args": [
        "mcp-acp"
      ]
    }
  }
}

Используйте MCP Ambient Code Platform MCP Server с разными ИИ-моделями

TypingMind подключает инструменты MCP на уровне рабочего пространства, поэтому после подключения Ambient Code Platform MCP Server вы можете использовать их с разными моделями ИИ в TypingMind, не настраивая подключение отдельно для каждой модели. Эта интеграция MCP работает локально на вашем устройстве через коннектор MCP TypingMind.

Руководство по настройке локального коннектора

Выберите этот способ, если серверу MCP нужен доступ к локальным файлам, приложениям или закрытым ресурсам на вашем компьютере.

1

Откройте настройки MCP

В TypingMind откройте «Настройки», затем «Расширенные настройки», перейдите в раздел «Протокол контекста модели» и выберите «Настроить коннектор».

  1. Откройте TypingMind в браузере.
  2. Нажмите значок настроек.
  3. Перейдите в «Расширенные настройки».
  4. Откройте раздел «Протокол контекста модели».
  5. Нажмите «Настроить коннектор» и выберите «Это устройство».
Экран настройки коннектора MCP в TypingMind с выбранным вариантом «Это устройство»
2

Выполните команду коннектора

Выберите «Это устройство», скопируйте команду из TypingMind и выполните её в терминале. Не останавливайте процесс, пока используете MCP.

  1. Скопируйте команду настройки, показанную в TypingMind.
  2. Откройте «Терминал» в macOS или Windows Terminal в Windows.
  3. Вставьте и выполните команду.
  4. Подтвердите установку пакета, если терминал запросит разрешение продолжить.
  5. Не закрывайте окно терминала и не останавливайте процесс, пока используете инструменты MCP.
3

Добавьте Ambient Code Platform MCP Server как сервер

Когда статус коннектора сменится на «Готов», нажмите «Изменить серверы» и вставьте конфигурацию сервера MCP.

  1. Дождитесь, пока статус коннектора сменится на «Готов».
  2. Нажмите «Изменить серверы».
  3. Вставьте конфигурацию сервера MCP для Ambient Code Platform MCP Server.
  4. Сохраните список серверов.
  5. Обновите статус, если хотите убедиться, что коннектор по-прежнему готов к работе.
Настройки MCP в TypingMind с активным сервером и кнопкой «Изменить серверы»
{
  "mcpServers": {
    "ambient-code-platform-mcp-server": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-acp"
      ]
    }
  }
}
4

Используйте подключение с разными моделями

Сохраните список серверов, откройте раздел «Плагины», включите инструменты MCP для Ambient Code Platform MCP Server, затем выберите любую поддерживаемую модель ИИ в TypingMind и используйте инструменты в чате или назначьте их ИИ-агенту.

  1. Откройте страницу «Плагины» в TypingMind.
  2. Включите инструменты MCP для Ambient Code Platform MCP Server.
  3. Начните чат и выберите модель ИИ, которую хотите использовать.
  4. Используйте инструменты MCP в чате или назначьте их ИИ-агенту.
  5. При необходимости переключайтесь на другую модель ИИ без повторного подключения MCP.
Чат TypingMind с включёнными инструментами MCP и выбранной ИИ-моделью
Можете помочь мне с этой задачей с помощью Ambient Code Platform MCP Server?
Ambient Code Platform MCP Server
Конечно. Я всё прочитал.
Вот что я нашёл с помощью Ambient Code Platform MCP Server.

Часто задаваемые вопросы

Для чего используется сервер MCP Ambient Code Platform MCP Server?

Ambient Code Platform MCP Server — это сервер MCP, который позволяет совместимым ИИ-клиентам подключаться к внешним инструментам и получать контекст. В TypingMind достаточно один раз добавить этот сервер MCP, чтобы его инструменты стали доступны в вашем рабочем пространстве с ИИ.

Можно ли использовать сервер MCP Ambient Code Platform MCP Server с несколькими ИИ-моделями в TypingMind?

Да. TypingMind подключает инструменты MCP на уровне рабочего пространства, поэтому вы можете использовать Ambient Code Platform MCP Server с разными ИИ-моделями, например Claude, ChatGPT, Gemini или другими моделями, настроенными в TypingMind, без отдельной настройки сервера MCP для каждой модели.

Зачем использовать MCP Ambient Code Platform MCP Server с TypingMind?

TypingMind — один из лучших интерфейсов для чата с LLM: он объединяет разные ИИ-модели, промпты, плагины, ИИ-агентов, ключи API и инструменты MCP в одном рабочем пространстве. Подключив Ambient Code Platform MCP Server, вы сможете использовать его инструменты MCP с предпочитаемыми моделями, сохраняя удобную организацию работы с чатами в TypingMind.

Как подключить сервер MCP Ambient Code Platform MCP Server к TypingMind?

Ambient Code Platform MCP Server работает через локальный коннектор MCP TypingMind. Этот вариант лучше всего подходит, когда серверу MCP нужен доступ к локальным файлам, настольным приложениям, инструментам командной строки или закрытым ресурсам на вашем компьютере.

Какие инструменты предоставляет сервер MCP Ambient Code Platform MCP Server в TypingMind?

Ambient Code Platform MCP Server предоставляет возможности MCP, которые можно включить на странице «Плагины» в TypingMind и использовать в чате или назначить ИИ-агентам.

Нужно ли передавать TypingMind свои ключи API для использования сервера MCP Ambient Code Platform MCP Server?

Нет. TypingMind ориентирован прежде всего на локальную работу и позволяет вам контролировать выбор провайдеров моделей, ключи API, промпты и конфигурацию MCP. Если Ambient Code Platform MCP Server требует аутентификации, при создании подключения добавьте необходимые заголовки, настройки OAuth или локальную конфигурацию для этого сервера MCP.

Похожие серверы MCP

Все

Создайте свою рабочую ИИ-среду сейчас

Подпишитесь на нашу рассылку, чтобы узнавать о новых функциях и предстоящих розыгрышах 👇