AndroidBuilder MCP Server
Enables LLMs to interact with MIT App Inventor, AndroidBuilder, Kodular, or Niotron IDEs in real-time, controlling the Designer and Blocks workspace via Chrome DevTools Protocol.
README
AndroidBuilder MCP Server
An official Model Context Protocol (MCP) server that connects to running instances of MIT App Inventor, AndroidBuilder, Kodular, or Niotron, allowing LLMs to interact with the Designer and Blocks workspace in real-time via the Chrome DevTools Protocol.
Features
| Tool | Description |
|---|---|
get_project_info |
Project name, active screen, view mode, IDE type, URL |
get_component_tree |
Full component hierarchy (name, type, uid, children) from Designer |
get_component_properties |
All property values for a specific component |
update_component_property |
Set a property using 3-strategy fallback (GWT API → top-frame → DOM) |
add_blocks |
Inject validated Blockly XML into the Blocks workspace |
get_blocks_xml |
Export the current workspace as Blockly XML |
clear_blocks |
Clear all blocks from the workspace |
switch_screen |
Navigate to a different screen |
list_screens |
List all screens in the project |
click_element |
Click an arbitrary CSS selector on the IDE page |
Prerequisites
- Node.js ≥ 18
- Google Chrome / Chromium launched with remote debugging enabled
Setup
1. Launch Chrome with Debugging Port
Windows (PowerShell / CMD):
chrome.exe --remote-debugging-port=9222
macOS:
/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --remote-debugging-port=9222
Open your IDE (androidbuilder.in, App Inventor, etc.) and load your project.
2. Configure MCP Client
Add this server to your MCP client configuration (e.g. claude_desktop_config.json):
{
"mcpServers": {
"androidbuilder-mcp": {
"command": "node",
"args": [
"C:/Users/User/.gemini/antigravity-ide/scratch/androidbuilder-mcp/dist/index.js"
],
"env": {
"BROWSER_DEBUG_PORT": "9222",
"ANDROIDBUILDER_DEBUG": "0"
}
}
}
}
Environment Variables
| Variable | Default | Description |
|---|---|---|
BROWSER_DEBUG_PORT |
9222 |
Chrome remote debugging port |
EVAL_TIMEOUT_MS |
15000 |
Max ms to wait for page evaluation |
ANDROIDBUILDER_DEBUG |
0 |
Set to 1 to enable verbose stderr logging |
Tool Reference
get_project_info
No parameters required.
Returns:
{
"projectName": "MyApp",
"activeScreen": "Screen1",
"isBlocksView": false,
"isDesignerView": true,
"ideType": "AndroidBuilder",
"url": "https://androidbuilder.in/ode/..."
}
get_component_tree
| Parameter | Type | Required | Description |
|---|---|---|---|
screenName |
string | No | Screen to inspect (default: active screen) |
Returns:
{
"screen": "Screen1",
"tree": [
{
"name": "Screen1",
"type": "Form",
"children": [
{ "name": "Button1", "type": "Button" },
{ "name": "Label1", "type": "Label" }
]
}
]
}
get_component_properties
| Parameter | Type | Required | Description |
|---|---|---|---|
componentName |
string | Yes | Component name (e.g. Button1) |
Note: Click the component in Designer view first to populate the Properties panel.
update_component_property
| Parameter | Type | Required | Description |
|---|---|---|---|
screenName |
string | Yes | Screen owning the component (e.g. Screen1) |
componentName |
string | Yes | Component name (e.g. Button1) |
propName |
string | Yes | Property name (e.g. Text, BackgroundColor) |
propValue |
string | Yes | New value (e.g. Hello, #FF0000) |
add_blocks
| Parameter | Type | Required | Description |
|---|---|---|---|
xmlString |
string | Yes | Valid Blockly XML (must start with <) |
Requires: Blocks view
get_blocks_xml
No parameters. Exports current workspace as XML.
clear_blocks
No parameters. Clears all blocks (irreversible via MCP).
switch_screen
| Parameter | Type | Required | Description |
|---|---|---|---|
screenName |
string | Yes | Target screen (e.g. Screen2) |
list_screens
No parameters. Returns all screen names in the project.
click_element
| Parameter | Type | Required | Description |
|---|---|---|---|
selector |
string | Yes | CSS selector of element to click |
Troubleshooting
Failed to connect to Chrome CDP
- Chrome was not started with
--remote-debugging-port=9222 - Another process is using port 9222
- Check
BROWSER_DEBUG_PORTenv var
No active AndroidBuilder/App Inventor tab found
- Open a project in the IDE before calling any tool
- The IDE page must be fully loaded, not just navigated to
Component tree (.gwt-Tree) not found
- You are in Blocks view — switch to Designer view
Blockly is not available
- You are in Designer view — switch to Blocks view
Tools hang / timeout
- Increase
EVAL_TIMEOUT_MS(default 15000ms) - Reload the IDE page and try again
Development
# Build
npm run build
# Run with debug logging
ANDROIDBUILDER_DEBUG=1 node dist/index.js
# Run with custom port
BROWSER_DEBUG_PORT=9223 node dist/index.js
Supported IDEs
License
MIT
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.