The MCP server is the interface layer that exposes RbxGenie tools to AI assistants like Claude Desktop and Cursor through the Model Context Protocol (MCP).Documentation Index
Fetch the complete documentation index at: https://mintlify.com/nnaridz/RbxGenie/llms.txt
Use this file to discover all available pages before exploring further.
Overview
Location:src/mcp.ts
The MCP server is a stdio-based MCP implementation that:
- Defines 50+ tools with Zod schema validation
- Forwards tool calls to the Node.js daemon via HTTP
- Translates responses back to MCP format for AI consumption
MCP is an open protocol developed by Anthropic that allows AI assistants to interact with external systems through a standardized tool interface. Learn more at modelcontextprotocol.io
Configuration
Location:src/mcp.ts:5-6
- Default URL
- Override
http://127.0.0.1:7766 — Standard daemon address
Tool Definitions
Location:src/mcp.ts:8-80
Tools are defined with name, description, and Zod schema for argument validation:
Tool Categories
The 50+ tools are organized into logical groups:Instance / Info (11 tools)
Instance / Info (11 tools)
get_file_tree— Recursive instance treesearch_files— Name pattern searchget_place_info— PlaceId, version, creator infoget_services— List all servicessearch_objects— Multi-criteria searchget_instance_properties— All properties of an instanceget_instance_children— Direct childrensearch_by_property— Find instances by property valueget_class_info— Roblox class informationget_project_structure— High-level structuresummarize_game— Game summary
Properties (5 tools)
Properties (5 tools)
set_property— Set single propertymass_set_property— Set property on multiple instancesmass_get_property— Get property from multiple instancesset_calculated_property— Use expression for valueset_relative_property— Relative adjustment
Objects (7 tools)
Objects (7 tools)
create_object— Create single instancecreate_object_with_properties— Create with initial propertiesmass_create_objects— Create multiple instancesmass_create_objects_with_properties— Batch create with propertiesdelete_object— Delete instancesmart_duplicate— Intelligent duplicationmass_duplicate— Duplicate multiple instances
Scripts (5 tools)
Scripts (5 tools)
get_script_source— Read script sourceset_script_source— Replace entire sourceedit_script_lines— Edit line rangeinsert_script_lines— Insert at line numberdelete_script_lines— Delete line range
Attributes (4 tools)
Attributes (4 tools)
get_attribute— Get single attributeset_attribute— Set attribute valueget_attributes— Get all attributesdelete_attribute— Remove attribute
Tags (4 tools)
Tags (4 tools)
Selection (1 tool)
Selection (1 tool)
get_selection— Get currently selected instances
Execute (3 tools)
Execute (3 tools)
execute_luau— Run Luau code in edit modeget_console_output— Retrieve console logsclear_console_output— Clear log buffer
Playtest (5 tools)
Playtest (5 tools)
start_play— Enter play modestop_play— Exit play moderun_server— Enter server modeget_studio_mode— Current moderun_script_in_play_mode— Automated test runner
Marketplace (1 tool)
Marketplace (1 tool)
insert_model— Search and insert free models
HTTP Proxy
Location:src/mcp.ts:82-107
The MCP server forwards tool calls to the daemon via HTTP POST:
Server Registration
Location:src/mcp.ts:109-143
The MCP server uses stdio transport, which means it communicates with the AI assistant via standard input/output. This is the standard transport for MCP servers.
Integration with AI Assistants
Claude Desktop
Add to~/Library/Application Support/Claude/claude_desktop_config.json (macOS):
Cursor
Add to.cursorrules or Cursor settings:
OpenCode
Add to~/.config/opencode/mcp.json:
Once configured, the AI assistant will automatically discover all 50+ RbxGenie tools and can use them in conversations.
Tool Response Format
All tools return text responses formatted for AI consumption:Success Response
Simple text or JSON string:Error Response
JSON witherror field:
Timeout Response
The MCP server always returns
content: [{ type: "text", text: "..." }] format. Complex data structures are JSON-stringified for the AI to parse.Error Propagation
Errors flow through multiple layers:Debugging
The MCP server logs to stderr (visible in AI assistant logs):Schema Validation
Zod schemas validate arguments before forwarding to daemon:If the AI provides invalid arguments (wrong type, missing required field), the MCP SDK automatically returns a validation error before the daemon is called.
Performance Characteristics
Startup Time
~100-200ms — Node.js startup + MCP SDK initialization
Tool Call Latency
50-200ms typical (network + daemon + plugin)
Up to 120s for timeouts
Up to 120s for timeouts
Concurrent Tools
Multiple tool calls execute sequentially in the plugin
MCP server handles concurrent requests from AI
MCP server handles concurrent requests from AI
Memory Usage
~20-40 MB for Node.js + MCP SDK
Security Considerations
The MCP server trusts the AI assistant and forwards all tool calls to the daemon without additional authentication. Only use RbxGenie with trusted AI assistants in local development environments.
- No network exposure — Daemon binds to localhost only
- No authentication — Assumes single-user local machine
- Full Studio access —
execute_luaucan run arbitrary code - AI trust boundary — AI assistant must be trusted
Next Steps
Architecture Overview
Understand the complete system architecture
MCP Integration
Learn how to configure MCP for your AI assistant