AndroidBuilder MCP Server
The AndroidBuilder MCP Server connects to a Chrome/Chromium session running an App Inventor-family IDE (AndroidBuilder, MIT App Inventor, Kodular, Niotron, AppyBuilder) and lets MCP clients inspect and manipulate the Designer and Blocks workspaces.
Project & Navigation
Get project info: Retrieve the current project name, active screen, view mode (Designer vs. Blocks), IDE type, and page URL.
List screens: Get all available screens in the current project.
Switch screen: Navigate to a different screen in the IDE.
Designer (Read)
Get component tree: Retrieve the full component hierarchy (name, type, uid, children).
Get component properties: Read all visible property values for a specific component.
Designer (Write — requires ANDROIDBUILDER_ALLOW_WRITE=1)
Update component property: Modify a property (e.g., Text, BackgroundColor, Width) of a specific component.
Blocks Workspace (Read)
Get blocks XML: Export the entire Blockly workspace as a pretty-printed XML string for reading or backup.
Blocks Workspace (Write — requires ANDROIDBUILDER_ALLOW_WRITE=1)
Add blocks: Inject Blockly XML blocks into the workspace (with validation before injection).
Clear blocks: Destructively remove all blocks from the workspace (also requires
confirm: "CLEAR_BLOCKS").
Unsafe Fallback (requires ANDROIDBUILDER_ALLOW_UNSAFE_CLICK=1)
Click element: Click any arbitrary element on the IDE page via a CSS selector as a last resort (also requires
confirm: "CLICK_ELEMENT").
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@AndroidBuilder MCP Server List all screens in my project"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
AndroidBuilder MCP Server
Local Model Context Protocol server for MIT App Inventor, AndroidBuilder, Kodular, Niotron, and AppyBuilder. It connects to a Chrome/Chromium session through the Chrome DevTools Protocol and can safely inspect AIA/AIX archives offline.
The server is safe by default: read tools are available immediately, while write tools require explicit environment flags.
Tools
Tool | Mode | Notes |
| Read | Project, active screen, view, IDE type, URL |
| Read | Lists available screens |
| Read/navigation | Switches active screen |
| Read | Designer component tree |
| Read | Selects component by name when possible |
| Read | Exports Blockly XML |
| Write | Requires |
| Write | Requires |
| Destructive | Requires |
<<<<<<< Updated upstream | ||
| Unsafe fallback | Requires both write flags and |
======= | ||
| Unsafe fallback | Requires |
Stashed changes |
list_ide_tabs/select_ide_tab| Navigation | Explicit trusted-tab selection | |inspect_aia/validate_aia/diff_aia| Offline read | Safe project archive inspection | |inspect_aix/validate_aix| Offline read | Safe extension metadata inspection | |read_archive_entry| Offline read | Bounded single-entry read | |get_component_catalog/get_component_schema/search_components| Read | Provider-discovered component metadata | |get_block_diagnostics| Read | Counts, warnings, and orphaned value blocks | |take_screenshot| Read | Designer, blocks, or full-page PNG | |update_component_properties| Write | Verified sequential batch update |
All tool results include success. Errors include a stable code; mutation timeouts include outcome: "unknown" and must be verified before retrying.
Related MCP server: Chrome DevTools MCP
Requirements
Node.js
>=22.12Chrome or Chromium launched with remote debugging enabled
chrome.exe --remote-debugging-port=9222Open your App Inventor-family IDE and load the project in that Chrome session.
Install
npm install
npm run buildRun the server:
node dist/index.jsMCP Config
Use .mcp.json in this repository for local development:
{
"mcpServers": {
"androidbuilder-mcp": {
"command": "node",
"args": ["dist/index.js"],
"env": {
"BROWSER_DEBUG_PORT": "9222",
"ANDROIDBUILDER_ALLOW_WRITE": "0"
}
}
}
}For clients that do not resolve relative paths from the repository root, replace dist/index.js with an absolute path.
Environment
Variable | Default | Description |
|
| Chrome remote debugging port |
|
| Max time for page evaluation |
|
| Verbose stderr logging |
|
| Enables property/block mutations |
|
| Enables arbitrary CSS click fallback |
| empty | Dedicated root for relative AIA/AIX paths |
|
| Maximum Blockly XML mutation size |
Multi-IDE compatibility
<<<<<<< Updated upstream
The server recognizes IDEs by exact hostname and exposes provider capabilities and a validated flag through get_project_info. Providers currently share conservative GWT/Blockly fallbacks; AppyBuilder is read-only. A recognized provider is not automatically validated—run live contract tests against a disposable project before advertising production support.
The server recognizes IDEs by exact hostname and exposes provider capabilities and a validated flag through get_project_info. MIT App Inventor, AndroidBuilder, Kodular, and Niotron adapters use isolated strategies; AppyBuilder is experimental and read-only. A recognized provider is not automatically considered validated—run the live contract suite against a disposable project before advertising production support.
Stashed changes
Codex, Claude, and Antigravity
Codex plugin manifest:
.codex-plugin/plugin.jsonPortable MCP config:
.mcp.jsonOpen Agent Skill:
skills/androidbuilder-mcp/SKILL.md
See docs/compatibility.md for client-specific setup notes.
Comparison with appinventor-mcp
The useful transport-independent features from rhyumiranda/appinventor-mcp were adapted to the existing CDP bridge. See docs/appinventor-mcp-comparison.md for the architectural comparison, adopted features, and rejected high-risk RPC mutations.
Development
npm run build
npm test
npm pack --dry-runnpm test builds the server, runs a real MCP SDK smoke test, verifies write tools are gated, checks the no-Chrome error path, and validates package metadata.
Troubleshooting
Failed to connect to Chrome CDP: start Chrome with--remote-debugging-port=9222.No active AndroidBuilder/App Inventor tab found: open a project in the debug Chrome session.Component tree (.gwt-Tree) not found: switch to Designer view.Blockly is not available: switch to Blocks view.Write tool rejected: restart the MCP server with
ANDROIDBUILDER_ALLOW_WRITE=1.
Recognized IDEs
AndroidBuilder
MIT App Inventor 2
MIT App Inventor Code
Niotron
Kodular
AppyBuilder
License
MIT
Available Tools
10 toolsadd_blocksA
Injects Blockly XML blocks into the Blocks workspace. Validates the XML before injection to prevent silent failures. Requires the IDE to be in Blocks view.
Inputs: xmlString (required).
clear_blocksA
Clears ALL blocks from the current Blockly workspace. This action cannot be undone via MCP. Requires Blocks view.
Inputs: no named parameters.
click_elementA
Clicks an arbitrary element on the IDE page using a CSS selector. Useful as a last-resort fallback for IDE actions not covered by other tools.
Inputs: selector (required).
get_blocks_xmlA
Exports the entire current Blockly workspace as a pretty-printed XML string. Use this to read existing blocks or back them up. Requires Blocks view.
Inputs: no named parameters.
get_component_propertiesA
Reads all visible property values for a component from the Properties sidebar panel. You must click the component in the Designer first to populate the panel.
Inputs: componentName (required).
get_component_treeA
Returns the full component hierarchy from the Designer view as a tree of {name, type, uid, children}. Requires the IDE to be in Designer view.
Inputs: screenName.
get_project_infoA
Returns the current project name, active screen, view mode (Designer vs Blocks), IDE type (AndroidBuilder, App Inventor, Niotron, Kodular…), and page URL. Use this first to understand the context before calling other tools.
Inputs: no named parameters.
list_screensA
Returns all screens available in the current project as an array of strings.
Inputs: no named parameters.
switch_screenA
Switches the active screen in the IDE. Uses the GWT select element or tab bar to navigate. Call list_screens first to see available screen names.
Inputs: screenName (required).
update_component_propertyA
Updates a property of a component. Uses 3 strategies in order: (1) GWT BlocklyPanel_setComponentProperty API, (2) top-frame API (iframe-hosted IDEs), (3) DOM input field in the Properties sidebar. Requires Designer view.
Inputs: propName (required), propValue (required), screenName (required), componentName (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 10 tools
Each tool has a clear, distinct purpose: blocks manipulation, component inspection/editing, screen management, project context, and a fallback click. No overlapping or ambiguous tools.
All tool names follow a consistent verb_noun pattern in snake_case (e.g., add_blocks, get_component_tree), making it easy to predict functionality.
10 tools is well-scoped for an IDE automation server, covering blocks, components, screens, and project info without being overwhelming or incomplete.
Covers core read/update operations for blocks, components, and screens, but lacks create/delete for components and screens, and a dedicated view-switching tool, leaving notable gaps that may force reliance on the fallback click_element.
Maintenance
Related MCP Connectors
Live browser debugging for AI assistants — DOM, console, network via MCP.
Control a real browser from AI agents: navigate, click, type, screenshot, read the page.
Build, run, inspect, and continue AgentScript workflows on connected Super Chrome and Mac clients.
Give AI agents a real cloud Chrome: open sessions, navigate, read pages, click, type and screenshot.
Related MCP Servers
- AlicenseAqualityCmaintenanceEnables AI coding assistants to control and inspect a live Chrome browser for automation, debugging, performance analysis, and screenshot capture through Chrome DevTools.262,562,190 npm3Apache 2.0
- AlicenseNot gradedqualityDmaintenanceEnables AI coding assistants to control and inspect a live Chrome browser for automation, debugging, performance analysis, network monitoring, and DOM interaction through Chrome DevTools Protocol.Apache 2.0
- -licenseNot gradedqualityNot gradedmaintenanceEnables AI coding assistants to control and inspect a live Chrome browser for automated debugging, performance analysis, and web interaction. It leverages Puppeteer and Chrome DevTools to provide capabilities like network monitoring, console logging, and automated browser actions.-
- AlicenseNot gradedqualityDmaintenanceLets AI coding agents control and inspect a live Chrome browser via MCP, providing Chrome DevTools capabilities for automation, debugging, and performance analysis.6 npmApache 2.0