跳到正文
FunCoding

MCP Fabric (Minecraft)

官方 MCP Registry 已收录

See and play Minecraft: Java Edition through the mcpfabric mod (Fabric and NeoForge).

Star
25
版本
v1.0.3
许可证
MIT
最近提交
2026年12月1日

mcpfabric MCP server

Bridges an MCP client (Claude Desktop / Claude Code / any MCP host) to the in-game HTTP bridge exposed by the mcpfabric mod (Fabric / NeoForge), publishing ~50 tools to observe and control Minecraft, plus an agent runtime with persistent memory, goals, a world map and background jobs (see docs/AGENT.md). Requires Node.js ≥ 22.16.

Install from npm

npx -y mcpfabric-mcp-server          # or: npm install -g mcpfabric-mcp-server && mcpfabric

In an MCP client config:

{
  "mcpServers": {
    "mcpfabric": {
      "command": "npx",
      "args": ["-y", "mcpfabric-mcp-server"],
      "env": { "MCPFABRIC_TOKEN": "paste-the-token-from-the-mod-config" }
    }
  }
}

Build from source

npm install
npm run build       # -> dist/index.js
npm run typecheck   # tsc --noEmit (sources and tests)
npm test            # unit tests + agent jobs against a simulated world

Run

The MCP client normally launches this process. Manually:

MCPFABRIC_URL=http://127.0.0.1:25599 MCPFABRIC_TOKEN=<token> node dist/index.js

Environment

VariableDefaultMeaning
MCPFABRIC_URLhttp://127.0.0.1:25599In-game bridge base URL.
MCPFABRIC_TOKEN—Bearer token from config/mcpfabric.config.json.
MCPFABRIC_TIMEOUT_MS15000Per-call timeout.
MCPFABRIC_TRANSPORTstdiostdio (default) or http.
MCPFABRIC_HTTP_PORT25600Port for the streamable-HTTP transport (/mcp).
MCPFABRIC_AGENTon0/false/off disables the agent runtime tools.
MCPFABRIC_DATA_DIR~/.mcpfabricDirectory of the agent database (agent.db).
MCPFABRIC_WORLDreported by the gameForce the world id that keys agent memory.
MCPFABRIC_SCRIPTSon0/false/off removes the script tools (run_script, skills).

Architecture

src/tools.ts is the single source of truth for the tool catalogue: each entry maps an MCP tool to a bridge RPC method plus a zod input schema. src/index.ts registers every entry generically (forwarding args to POST /rpc) and renders results as JSON, except screenshot which returns an image content block. src/bridge.ts is the HTTP client; src/config.ts reads env config.

src/agent/ is the agent runtime: its tools (agent/tools.ts) run in this process, store state in SQLite (node:sqlite) and drive the game through the same bridge. test/fake-world.ts simulates the bridge contract so jobs are tested without a game.

src/script/ is code mode: run_script runs a model-written JavaScript program in QuickJS (WebAssembly, quickjs-emscripten), which reaches the game only through the catalogue methods of src/tools.ts; save_skill / run_skill keep programs per world in the agent database.

Keep tool names/methods in sync with the Java handler registry in the mod (dev.mcpfabric.handlers.* and dev.mcpfabric.client.handlers.*).

同类 MCP Server

官方

markitdown

Convert various file formats (PDF, Word, Excel, images, audio) to Markdown.

MImicrosoft/markitdown199k近 7 天新增 1,075 个 star

HyperFrames by HeyGen

Official HyperFrames by HeyGen: the best AI video editor in chat. Captions, motion graphics, MP4.

HEheygen-com/hyperframes93k近 7 天新增 4,463 个 star

精选

tldraw

在画布上与智能体协作,绘制图形并实时执行代码。

TLtldraw/tldraw52k近 7 天新增 130 个 star

Next AI Draw.io

draw.io diagrams your AI agent draws on a live browser canvas that you can also edit by hand

DADayuanJiang/next-ai-draw-io37k近 7 天新增 119 个 star

精选

mcp-for-blender

让智能体在 Blender 里建模,搭建和修改 3D 场景。

AHahujasid/mcp-for-blender37k近 7 天新增 952 个 star

screenpipe

Search your local screen recordings, audio transcripts, and computer activity from screenpipe.

SCscreenpipe/screenpipe23k近 7 天新增 97 个 star