跳到正文
FunCoding

搜索

搜索文档、Skill 和 MCP

mcp_flutter

MCP Toolkit for Flutter AI Agent Driven Development (MCP/CLI + custom client side tools) - via closed feedback loop (visual & semantic snapshot) and high client side customization adaptable for any Flutter app. Nowadays it is often called as agentic harness.

README

flutter-mcp-toolkit

MCP Toplist

Inspect and drive a running Flutter app from your AI assistant.

skills.sh pub: mcp_toolkit Contract Gates intentcall eval gates skill-assets-drift Docs Ask DeepWiki License: MIT Flutter smithery badge Official MCP Registry All Contributors maintained with Skill Steward

flutter-mcp-toolkit is a Dart MCP server + Flutter package for AI agents (Codex, Zed, Cursor, Intent, Claude Code, Cline, and more). Agents can inspect a running Flutter app, take semantic snapshots, tap widgets, type into forms, hot-reload, and read logs. Apps can also register their own MCP tools and resources at runtime via MCP Toolkit — all without leaving the conversation. The result is a closed feedback loop between agent and app.

And one step further: the toolkit is becoming a chain of declarative automation APIs — the same observe/act/verify vocabulary runs through interactive MCP (fmt_*), the CLI, programmatic Dart scenarios (flutter_mcp_harness), and declarative build+lifecycle runners like oka, all over the universal AutomationDriver contract. See The Automation Chain. (OpenAI describes this pattern as harness engineering.)

Watercolor comic infographic explaining flutter-mcp-toolkit: install fmtk, add it to a Flutter app, connect an AI agent, then inspect, tap, reload, and prove changes in a close feedback loop.

The picture's story: the toolkit gives an AI assistant a shared window and control loop into a running Flutter app, so it can inspect state, act like a user, hot reload, read proof, and use custom tools from your app instead of guessing.

View Screenshots

Get started in 4 steps

# 1. Install the binary
curl -fsSL https://raw.githubusercontent.com/Arenukvern/mcp_flutter/main/install.sh | bash
# Installs flutter-mcp-toolkit plus the short fmtk alias for repeated CLI loops.

# 2. Add the toolkit to your Flutter app
cd my-flutter-app
flutter-mcp-toolkit codegen-init   # adds mcp_toolkit + emits main.dart snippet

# 3. Install skills for your AI agent
flutter-mcp-toolkit init claude-code   # or: cursor | codex | cline | agents-skills | all
# Alternative (skills only): npx skills add Arenukvern/mcp_flutter -a cursor -y

# 4. Run
flutter run --debug

That's it. Your AI agent can now inspect and drive the running app — and your app can expose custom MCP tools at runtime (see Dynamic Tools Registration below).

📰 News

  • 2026-10-02 — 6.0.0 released: the invoke tier (ADR-0017) — the app's intent registry is the single action source; the harness driver lists (driver.actions()) and invokes it (InvokeAction) with schema-validated args, IntentAutomationAction.custom routes hints, and any web surface (Jaspr, plain JS) composes via window.__mcpActions. flutter_mcp_harness 0.2.x on pub.dev; server 6.0.0 on the MCP registry.

  • 2026-10-01 — The toolkit is becoming a chain of declarative automation APIs: universal AutomationDriver contracts (universal_automation_*), the programmatic flutter_mcp_harness package, and oka as the build+lifecycle runner. New: The Automation Chain guide + flutter-mcp-automation-chain skill.

  • 2026-07-11 - v4 new Live Demos records: v4 semantic snapshot etc.. with Grok Build CLI, v4 with IntentCall power - WebMCP projection

  • 2026-05-26 — v3.1.0: Platform-view capture routing, macOS/iOS Simulator host screenshots, web CDP tab capture (SCK → CDP → flutter_layer), and cross-platform showcase platform views.

Install from marketplaces

PlatformCommand / link
Any agent (recommended)flutter-mcp-toolkit init <agent> — see AI agent setup
Claude Code (git catalog)/plugin marketplace add Arenukvern/mcp_flutter then install flutter-mcp-toolkit
Codex (git catalog)codex plugin marketplace add Arenukvern/mcp_flutter
Cursor (local plugin)flutter-mcp-toolkit init cursor
Skills onlynpx skills add Arenukvern/mcp_flutter -a <agent> -y (add MCP via init or manual JSON)
MCP registriesOfficial MCP Registry — server io.github.Arenukvern/flutter-mcp-toolkit (OCI image: ghcr.io/arenukvern/flutter-mcp-toolkit), Smithery, MseeP

Docker / MCP Registry install

The official registry serves an OCI image from GHCR. Point any MCP client at it:

{
  "mcpServers": {
    "flutter-mcp-toolkit": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "--network=host",
        "ghcr.io/arenukvern/flutter-mcp-toolkit:6.0.0"
      ]
    }
  }
}

See Docker guide for flags, version pinning, and networking notes.

Maintainers submitting to official stores: marketplace submission runbook. Full matrix: marketplace distribution.

Documentation

Published packages

PackagePub.devRole
mcp_toolkitpub package pub pointsFlutter app package for runtime MCP tools/resources and toolkit bootstrap.
flutter_mcp_toolkit_corepub package pub pointsPure-Dart shared command/result/capability types.
flutter_mcp_toolkit_capability_kernelpub package pub pointsCapability kernel contracts for composable MCP units.
flutter_mcp_toolkit_capability_corepub package pub pointsServer-side fmt_* capability implementation.

The server binary lives in mcp_server_dart and is shipped through GitHub Release artifacts as flutter-mcp-toolkit, fmtk, and flutter-mcp-toolkit-server; it is not a pub.dev package.

The automation chain

Different surfaces own different parts of the lifecycle, and all of them drive the same ext.mcp.toolkit.* extensions through the universal AutomationDriver contract (universal_automation_* family):

TierSurfaceBest for
Interactive MCPfmt_* toolschat-driven debugging and verification
CLIflutter-mcp-toolkit / fmtkone-shot commands in scripts and CI
Programmatic Dartpackages/harness — flutter_mcp_harness on pub.devrepeatable scenarios as checked-in code
Build + lifecycleokadeclarative device builds, owned dev sessions

Guide: The Automation Chain · skill: flutter-mcp-automation-chain.

The showcase/ folder holds examples that test the whole stack end-to-end — a minimal instrumented Flutter app (showcase/flutter_demo) and a static web page (showcase/web_demo) — each driven live by a checked-in composition root:

make drive-flutter   # instrumented tier: ToolkitDriver over the VM service
make drive-web       # browser tier: CdpDriver over CDP (headless Chrome)

packages/harness implements the shared contract for the Flutter tier (ToolkitDriver), so one observe/act/verify vocabulary covers Flutter apps, browsers, and OS-native targets — the same pipeline composition style oka uses.

Development support

NeedStart here
Contribute code or docsCONTRIBUTING.md · Contribution guide
Add or credit contributorsContributors guide · .all-contributorsrc
Report vulnerabilitiesSECURITY.md
Validate local changessteward probe --json --profile quick · make check-contracts
Maintain releasesRelease train notes · flutter-mcp-toolkit-repo-maintainer
Install or update agent skillsAI agent setup · Marketplace distribution

What it does

The default toolkit surface exposes 31 MCP tools under the fmt_* capability prefix across four categories (35 with the --dumps debug tools enabled):

  • Inspection — semantic snapshot, view details, errors, screenshots, VM info
  • Interaction — tap, scroll, type, fill forms, hot-reload, navigate, wait_for
  • Debug — recent logs, evaluate Dart expressions
  • Lifecycle — discover apps, hot-reload, hot-restart

See the flutter-mcp-toolkit-{guide,inspect,control,debug} skills for the full reference (installed by flutter-mcp-toolkit init or npx skills add Arenukvern/mcp_flutter). Install options: AI agent setup.

Dynamic Tools Registration

Flutter apps can register custom tools and resources at runtime. See how it works in this short YouTube video. The same arguments.connection targeting is supported by the CLI's exec, batch, daemon command/execute, daemon watch/start, and snapshot step args.

Note

There is official MCP Server for Flutter from Flutter team which exposes Dart tooling. The main goal of this project is to bring power of MCP server tools by creating them in Flutter app, using dynamic MCP tools registration and close feedback loop for AI Agent. See how it works in short YouTube video. See Quick Start for more details. See original motivation behind the idea.

⚠️ Note on Dump RPCs

Dump RPC methods (like dump_render_tree) can produce huge token output and are disabled by default. Enable with --dumps. See mcp_server_dart README for the full flag surface.

🔒 Security

Generally, since you use MCP server to connect to Flutter app in Debug Mode, it should be safe to use. However, I still recommend to review how it works in ARCHITECTURE.md, how it can be modified to improve security if needed.

This MCP server is verified by MseeP.ai.

MseeP.ai Security Assessment Badge

🔧 Troubleshooting

  1. Connection Issues

    • Ensure your Flutter app is running in debug mode
    • Verify the port matches in both Flutter app and MCP server
    • Check if the port is not being used by another process
    • Safest explicit targeting: use arguments.connection.uri and paste exact Flutter machine app.debugPort.wsUri
    • If response includes connection_selection_required, retry with arguments.connection.targetId using one URI from availableTargets (or set arguments.connection.uri directly)
  2. AI Tool Not Detecting Inspector

    • Restart the AI tool after configuration changes
    • Verify the configuration JSON syntax
    • Check the tool's logs for connection errors
  3. Dynamic Tools Not Appearing

    • Ensure mcp_toolkit package is properly initialized in your Flutter app
    • Check that tools are registered using MCPToolkitBinding.instance.addEntries()
    • Use fmt_list_client_tools_and_resources to verify registration
    • Hot reload your Flutter app after adding new tools

The Flutter MCP Server is registered with Smithery's registry, making it discoverable and usable by other AI tools through a standardized interface.

Integration Architecture

┌─────────────────┐     ┌───────────────────────┐     ┌─────────────────┐
│                 │     │  Flutter App with     │     │                 │
│  Flutter App    │<--->│  mcp_toolkit          │<--->│ flutter-mcp-    │
│  (Debug Mode)   │     │  (VM Svc. Extensions  │     │ toolkit-server  │
│                 │     │  + Dynamic Tools)     │     │                 │
└─────────────────┘     └───────────────────────┘     └─────────────────┘

🤝 Contributing

Contributions are welcome! See CONTRIBUTING.md (maintainer releases, binary checksums) and the contribution guide. Pull requests and issues: GitHub.

✨ Contributors

Huge thanks to all contributors for making this project better!

This roster is maintained with all-contributors. To add someone, update .all-contributorsrc and regenerate the README table, or use the all-contributors bot/CLI from a PR. More detail: docs/contributing/contributors.mdx.

Henry Mao
Henry Mao

🚇
Marwen
Marwen

📖
Lawrence Sinclair
Lawrence Sinclair

📖 🛡️
Frank Fiegel
Frank Fiegel

🚇
Harish Anbalagan
Harish Anbalagan

📓 🐛
Torben Keller
Torben Keller

📓 🐛
Isfun
Isfun

📓 🐛 🔬 💻
Cosy Studio
Cosy Studio

📓 🐛 🔬
Luke Memet
Luke Memet

📓 🔬 🚧 ✅
Commentatk Media
Commentatk Media

💻 🚧 📖
Umit Arslan
Umit Arslan

💻 🚧
Joel Kitching
Joel Kitching

💻 🚧
Jean-Luc Thumm
Jean-Luc Thumm

🚧
Miguel Casagrande
Miguel Casagrande

💻 🚧
drown0315
drown0315

💻 🚧 🐛
druyang
druyang

💻 🚧 🐛
dipsy
dipsy

💻 🚧 🐛
wenyue
wenyue

💻 🚧
Christophe
Christophe

📖 📦

📖 Learn More

Star History

Star History Chart

📄 License

MIT - Feel free to use in your projects!


Flutter and Dart are trademarks of Google LLC.

同类 MCP Server

koala73/worldmonitor88k

World Monitor

Live markets, conflicts, country risk, chokepoints, energy, and China decision signals. 90 tools.

AI 与智能体

ahujasid/mcp-for-blender30k

mcp-for-blender

Community plugin to control Blender 3D with any LLM of your choice. Not affiliated with the official Blender Foundation.

AI 与智能体

oraios/serena30k

serena

A powerful MCP toolkit for coding, providing semantic retrieval and editing capabilities - the IDE for your agent

AI 与智能体

agentskills/agentskills26k

Agent Skills Search Server

Search and discover Agent Skills from the skills.sh registry. Powered by HAPI MCP server.

AI 与智能体

activepieces/activepieces25k

activepieces

AI Agents & MCPs & AI Workflow Automation • (~400 MCP servers for AI agents) • AI Automation / AI Agent with MCPs • AI Workflows & AI Agents • MCPs for AI Agents

AI 与智能体

czlonkowski/n8n-mcp23k

n8n-mcp

A MCP for Claude Desktop / Claude Code / Windsurf / Cursor to build n8n workflows for you

AI 与智能体