Skip to main content
Glama
emicyx

bongocat-mcp

by emicyx

bongocat-mcp

A standalone controller that unifies various "BongoCat cats" into MCP tools—fully decoupled from the BongoCat repository, so MCP clients / LLMs such as astrbot can actively control the cat's key-press animations / typing / expressions / chat bubbles, without requiring the cat to be recompiled. Comes with a local web dashboard for viewing status and editing configuration.

Full design docs: Requirements docs/requirements.md · Architecture docs/architecture.md.

Supports three cats (auto-detected, or force-specified via config)

driver

Target cat

Principle

Prerequisites

embedded

Self-compiled BongoCat (built-in control channel)

Local HTTP control channel (127.0.0.1 random port + Bearer token)

Just launch the self-compiled build; auto-discovers mcp-server.json

cdp

Tauri-based releases: official release, skin-repackaged builds (frontend unchanged, only model assets swapped)

WebView2 CDP injection: launch the release with a debug port → Runtime.evaluate calls `TAURI_INTERNALS.invoke('plugin:event

emit')` to synthesize native events

No config needed; if the cat is running but the debug port is not open, auto-restarts and takes over (one brief disconnect); exe path can be specified in config

mver

BongoCatMver-based releases: C++/SFML skin builds (hand-modified img/ + config.json)

Empirically reverse-engineered UDP protocol: transparent mirror layer (60fps forwarding of real keyboard/mouse + AI overlay)

Mver must have network sync enabled and set to receive mode; configuring mver_dir resolves skin bindings

Cost of mver receive mode and the mirror layer: Once Mver enables network receive, it ignores the local keyboard/mouse and only renders network packets. The mver driver's send thread reads real keyboard/mouse at 60fps (GetAsyncKeyState/GetCursorPos) and forwards them, so the cat behaves identically to local mode (about one frame of latency); AI commands are layered on top as an overlay. If the MCP/mirror process stops, the cat loses keyboard/mouse response (restarting restores it); only one Mver instance can run at a time.

Related MCP server: Vox MCP

Auto-onboarding new cats (mver)

  • Auto-detection: The dashboard status poll probes for a running Mver process every 5 seconds; if the configured cat is not running (or none is configured) and another one is running, it automatically switches mver_dir to the running cat and rebuilds the driver (switch records are visible in the event log)

  • One-click onboarding: The dashboard's "🚀 One-click onboard new Mver cat" button does it all automatically—locate the running cat → rewrite its config.json at the text level to enable network sync (receive mode, preserving author comments; this is the same file its own settings UI writes, without modifying the program itself) → restart the cat process with elevation → rebuild the driver

  • Newly installed skin builds of Mver default to network:false (no UDP listening); one-click onboarding fixes it; you can also manually enable network sync in the cat's settings and set it to receive mode

  • Note: only one Mver instance can occupy the receive port at a time

Quick start

python -m venv .venv
.venv\Scripts\activate            # Windows;macOS/Linux: source .venv/bin/activate
pip install -r requirements.txt

# 方式一:仪表盘(推荐日常使用,自动打开浏览器)
python dashboard.py               # 默认隐藏窗口后台运行
python dashboard.py --stop        # 停止后台仪表盘
python dashboard.py --visible     # 前台调试模式(终端可见)

# 方式二:MCP stdio server(供 astrbot 拉起)
python server.py

# 方式三:只让接收模式的 Mver 恢复键鼠跟随(不开 AI)
python mver-mirror.py               # 默认隐藏窗口后台运行
python mver-mirror.py --stop        # 停止隐藏运行的镜像
python mver-mirror.py --visible     # 前台调试模式(Ctrl+C 退出)

# 本地回归测试(自动探测 driver;或传 embedded / cdp / mver)
python test_client.py

ZCode plugin (bongocat-notify)

The zcode-plugin/ directory is a local plugin marketplace + plugin that connects Zcode to this MCP server:

  • MCP integration: .mcp.json registers server.py as a stdio MCP server (tool names mcp__bongo-cat__*), so agents can directly control the cat; the /bongo-test command does a full end-to-end self-check

  • Task notifications: hooks drive the cat's bubble + expression switching on key Zcode events— Stop (task complete → starry eyes), PermissionRequest (awaiting approval → question), PostToolUseFailure (error → crying), SessionStart / UserPromptSubmit (starting work)

  • Expressions are not hardcoded by index: each time it reads the expression list from get_cat_status in real time and matches by name keyword, so it auto-adapts when skins change; hooks go through the dashboard HTTP API (python dashboard.py must stay running), and silently skip when the dashboard is absent—never blocking the session

Install: Zcode → Settings → Plugin management → Discover → + add local marketplace directory zcode-plugin/, then install bongocat-notify (see zcode-plugin/bongocat-notify/README.md for details).

Want to develop your own cat notification plugin for ZCode / AstrBot or other clients? See Integration development guide docs/zcode-plugin-dev.md for channel selection, plugin skeleton templates, expression extensibility conventions, and validation methodology.

Claude Code plugin (bongocat-notify)

claude-plugin/ is the Claude Code version of the same "local marketplace + plugin" setup (feature-equivalent to the ZCode version):

  • MCP integration: .mcp.json registers server.py as a stdio MCP server (tool names also mcp__bongo-cat__*); the /bongo-test command does a full end-to-end self-check

  • Task notifications: the event model differs—Claude Code has no PermissionRequest / PostToolUseFailure events; pending approval is expressed via Notification (filtered by message keywords for idle prompts), and tool errors are conservatively determined from PostToolUse's tool_response

Install: claude plugin marketplace add claude-plugin/目录claude plugin install bongocat-notify@bongocat-local, then verify with /mcp after restarting the session (see claude-plugin/bongocat-notify/README.md for details).

Codex plugin (bongocat-notify)

codex-plugin/ is the OpenAI Codex CLI version of the same plugin (feature-equivalent to the ZCode version):

  • MCP integration: .mcp.json (Codex's native direct-connect server format) registers server.py as a stdio MCP server; the bongo-test skill (skills/*/SKILL.md—Codex custom prompts are deprecated, skills are the official replacement) does a full end-to-end self-check

  • Task notifications: Codex hooks map almost one-to-one to ZCode events—PermissionRequest is a native event; tool errors have no PostToolUseFailure, so they are conservatively determined from PostToolUse's tool_response; hooks are bundled by the plugin manifest (.codex-plugin/plugin.json), all running async in the background without blocking turns

Install: codex plugin marketplace add codex-plugin/目录codex plugin install bongocat-notify@bongocat-localTrust each of the 5 hooks one by one in /hooks (Codex trust review mechanism—untrusted hooks don't run) → verify in a new session with codex mcp list (see codex-plugin/bongocat-notify/README.md for details).

Configuration (config.json, editable from the dashboard)

Read priority: environment variable BONGOCAT_* > config.json > defaults. On first use, copy config.example.json to config.json.

Key

Description

driver

Empty=auto-detect; embedded / cdp / mver to force

app_path

cdp: BongoCat.exe / bongo-cat.exe path

app_paths

cdp: additional candidate path list

cdp_port

cdp: debug port, default 9223

mver_dir

mver: skin directory (contains config.json), used for key bindings and receive port

mver_port

mver: receive port; empty=read from network.receive_port in the skin's config.json

host

Target host, default 127.0.0.1

embedded_config / embedded_port / embedded_token

embedded: override auto-discovery

dashboard_host / dashboard_port

Dashboard listen address, default 127.0.0.1:8766

Corresponding environment variables: BONGOCAT_MCP_DRIVER, BONGOCAT_APP_PATH, BONGOCAT_CDP_PORT, BONGOCAT_MVER_DIR, BONGOCAT_MVER_PORT, BONGOCAT_MCP_HOST, BONGOCAT_MCP_CONFIG, BONGOCAT_MCP_PORT, BONGOCAT_MCP_TOKEN (backward compatible with older versions).

Dashboard

Start with python dashboard.py (auto-opens the browser), includes:

  • Status overview: current driver, capability matrix (green=supported / gray=not supported by that cat), cat status (model/mode/window), mver mirror thread, 2-second polling refresh

  • Driver selection: auto / embedded / cdp / mver, switching saves and rebuilds the driver

  • Config editing: visual editing of all config.json keys

  • Tool playground: call all commands directly from the web page (expression dropdown, key presses, typing, bubbles, window show/hide, set-hand), with the latest 200 event log entries

The dashboard and astrbot's stdio server each hold independent driver instances and can be used in parallel; embedded / cdp have no conflicts, dual mver mirrors are a benign overlay (two paths with identical state frames), and the chat bubble may be rendered once by each of the two processes.

MCP Tools (14 tools, mapped to 12 unified commands, consistent across all drivers)

Tool

Description

embedded

cdp

mver

ping

Health check

get_cat_status

driver/capabilities/model info/window visibility

list_expressions / list_motions

List expressions/motions

⚠️ requires model assets

set_expression(index, duration)

Switch expression (auto-returns to default after duration seconds, 0=keep)

⚠️ requires model assets

play_motion(motion)

Play motion

⚠️ requires model assets

press_key / release_key

Key press/release animation

type_text(text)

Character-by-character typing animation

set_hand(left, right)

Cat paw press-down

set_parameter(id, value)

Live2D parameter

show_bubble / hide_bubble

Chat bubble (auto-dismisses 8 seconds after typing animation, duration=0 stays)

set_window_visible(visible)

Show/hide cat window

Capabilities are asset-aware: an mver skin only advertises expression/motion capabilities when the model directory actually contains the corresponding asset files; otherwise it honestly reports unsupported (to avoid treating stale leftover config as a real capability).

Security notes

  • All channels bind only to the local loopback address; the embedded channel uses a random Bearer token on every startup

  • cdp's WebView2 debug port (default 127.0.0.1:9223) is a local control surface; don't leave a cat running with the debug port open for long periods when not in use

  • cdp takeover restarts a running cat once; only one cat is supported at a time

Project structure

bongocat-mcp\
  bongocat_mcp\           # 核心包
    config.py             # 统一配置(env > config.json > 默认)
    detect.py             # driver 探测/切换
    dispatch.py           # 命令调度(能力门控 + 事件日志)
    drivers\              # embedded_http / cdp_webview2 / mver_udp / win32_utils
    bubble\overlay.py     # bridge 自绘聊天气泡窗
  server.py               # MCP stdio 入口
  dashboard.py            # FastAPI 仪表盘
  web\index.html          # 仪表盘前端(原生单页,无构建)
  mver-mirror.py          # Mver 独立镜像进程
  zcode-plugin\           # ZCode 插件(本地市场 + bongocat-notify)
  claude-plugin\          # Claude Code 插件(本地市场 + bongocat-notify)
  codex-plugin\           # Codex CLI 插件(本地市场 + bongocat-notify)
  docs\                   # 需求/架构/接入文档;验证截图为本地存档不入库

Mver UDP protocol (empirically reverse-engineered notes)

  • 312-byte full state frame, sent continuously at 60fps, no handshake

  • bytes[0..255]: VK-indexed key states; 0x81=pressed (sent continuously for the entire hold duration), 0x80=release edge frame, 0x00=idle; VK 0x01/0x02 = mouse left/right buttons

  • bytes[256..311]: 14 floats, fl[8]=0.8×cursor x/screen width, fl[9]=0.8×cursor y/screen height

  • Constant slots 0x90/0xF0/0xF3/0xF6/0xFB = 0x01

  • Combo key bindings require timed pressing (hold the modifier first for ≥0.3s, then press the trigger key)

  • mode: 1=standard, 2=keyboard, 3=gamepad (from BongoCatMverUI source code)

F
license - not found
Not graded
quality - not tested
C
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    A
    quality
    B
    maintenance
    Enables MCP clients like Claude Code and Cursor to use multiple AI models (Gemini, GPT, Grok, DeepSeek, Kimi, Ollama) via a unified chat tool with conversation memory.
    3
    Apache 2.0
  • A
    license
    Not graded
    quality
    D
    maintenance
    An MCP server that enables LLMs to see and control a computer — screen capture, window management, mouse and keyboard automation — with a structured plan-execute workflow for complex desktop automation.
    GPL 3.0
  • F
    license
    A
    quality
    A
    maintenance
    Cross-platform desktop automation MCP server that lets AI agents capture screenshots, run OCR with UI-element classification, control mouse/keyboard, and launch programs on Linux, macOS, and Windows.
    20

View all related MCP servers

Related MCP Connectors

  • A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…

  • Real-time chat hub for AI agents — Claude Code, Cursor, Cline, Codex over MCP or REST.

  • MCP server for AI dialogue using various LLM models via AceDataCloud

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/emicyx/bongocat-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server