unity-mcp/MCPForUnity/Editor/Windows
Marcus Sanatan 7f44e4b53e
Add CLI (#606)
* feat: Add CLI for Unity MCP server

- Add click-based CLI with 15+ command groups
- Commands: gameobject, component, scene, asset, script, editor, prefab, material, lighting, ui, audio, animation, code
- HTTP transport to communicate with Unity via MCP server
- Output formats: text, json, table
- Configuration via environment variables or CLI options
- Comprehensive usage guide and unit tests

* Update based on AI feedback

* Fixes main.py error

* Update for further error fix

* Update based on AI

* Update script.py

* Update with better coverage and Tool Readme

* Log a message with implicit URI changes

Small update for #542

* Minor fixes (#602)

* Log a message with implicit URI changes

Small update for #542

* Log a message with implicit URI changes

Small update for #542

* Add helper scripts to update forks

* fix: improve HTTP Local URL validation UX and styling specificity

- Rename CSS class from generic "error" to "http-local-url-error" for better specificity
- Rename "invalid-url" class to "http-local-invalid-url" for clarity
- Disable httpServerCommandField when URL is invalid or transport not HTTP Local
- Clear field value and tooltip when showing validation errors
- Ensure field is re-enabled when URL becomes valid

* Docker mcp gateway (#603)

* Log a message with implicit URI changes

Small update for #542

* Update docker container to default to stdio

Replaces #541

* fix: Rider config path and add MCP registry manifest (#604)

- Fix RiderConfigurator to use correct GitHub Copilot config path:
  - Windows: %LOCALAPPDATA%\github-copilot\intellij\mcp.json
  - macOS: ~/Library/Application Support/github-copilot/intellij/mcp.json
  - Linux: ~/.config/github-copilot/intellij/mcp.json
- Add mcp.json for GitHub MCP Registry support:
  - Enables users to install via coplaydev/unity-mcp
  - Uses uvx with mcpforunityserver from PyPI

* Use click.echo instead of print statements

* Standardize whitespace

* Minor tweak in docs

* Use `wait` params

* Unrelated but project scoped tools should be off by default

* Update lock file

* Whitespace cleanup

* Update custom_tool_service.py to skip global registration for any tool name that already exists as a built‑in.

* Avoid silently falling back to the first Unity session when a specific unity_instance was requested but not found.

If a client passes a unity_instance that doesn’t match any session, this code will still route the command to the first available session, which can send commands to the wrong project in multi‑instance environments. Instead, when a unity_instance is provided but no matching session_id is found, return an error (e.g. 400/404 with "Unity instance '' not found") and only default to the first session when no unity_instance was specified.

Co-authored-by: sourcery-ai[bot] <58596630+sourcery-ai[bot]@users.noreply.github.com>

* Update docs/CLI_USAGE.md

Co-authored-by: sourcery-ai[bot] <58596630+sourcery-ai[bot]@users.noreply.github.com>

* Updated the CLI command registration to only swallow missing optional modules and to surface real import-time failures, so broken command modules don’t get silently ignored.

* Sorted __all__ alphabetically to satisfy RUF022 in __init__.py.

* Validate --params is a JSON object before merging.

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

---------

Co-authored-by: Shutong Wu <51266340+Scriptwonder@users.noreply.github.com>
Co-authored-by: dsarno <david@lighthaus.us>
Co-authored-by: sourcery-ai[bot] <58596630+sourcery-ai[bot]@users.noreply.github.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2026-01-21 20:53:13 -04:00
..
Components Add CLI (#606) 2026-01-21 20:53:13 -04:00
EditorPrefs Project scoped tools (#596) 2026-01-21 13:07:52 -04:00
Components.meta HTTP Server, uvx, C# only custom tools (#375) 2025-11-24 23:21:06 -04:00
EditorPrefs.meta Add EditorPrefs management window for MCP configuration debugging (#491) 2025-12-29 13:30:45 -04:00
MCPForUnityEditorWindow.cs fix: comprehensive performance optimizations, claude code config, and stability improvements (issue #577) (#595) 2026-01-20 18:11:25 -08:00
MCPForUnityEditorWindow.cs.meta Add .meta files (#472) 2025-12-19 18:59:19 -04:00
MCPForUnityEditorWindow.uss Test/478 matrix4x4 serialization crash (#481) 2025-12-23 15:53:14 -08:00
MCPForUnityEditorWindow.uss.meta Add .meta files (#472) 2025-12-19 18:59:19 -04:00
MCPForUnityEditorWindow.uxml [FEATURE] Custom Tool Fix and Add inspection window for all the tools (#414) 2025-12-07 19:38:32 -05:00
MCPForUnityEditorWindow.uxml.meta Add .meta files (#472) 2025-12-19 18:59:19 -04:00
MCPSetupWindow.cs feat: Mark setup as completed when user clicks Done button (#529) 2026-01-07 18:58:36 -04:00
MCPSetupWindow.cs.meta HTTP Server, uvx, C# only custom tools (#375) 2025-11-24 23:21:06 -04:00
MCPSetupWindow.uss HTTP Server, uvx, C# only custom tools (#375) 2025-11-24 23:21:06 -04:00
MCPSetupWindow.uss.meta HTTP Server, uvx, C# only custom tools (#375) 2025-11-24 23:21:06 -04:00
MCPSetupWindow.uxml HTTP Server, uvx, C# only custom tools (#375) 2025-11-24 23:21:06 -04:00
MCPSetupWindow.uxml.meta HTTP Server, uvx, C# only custom tools (#375) 2025-11-24 23:21:06 -04:00