MayaMCP
Allows execution of Python code inside Autodesk Maya's main thread, returning the value of the last expression if it is an expression.
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., "@MayaMCPRun Python to create a poly sphere at the origin"
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.
Maya MCP
Maya を AI エージェントとコマンドラインに開放します。外部から送った Python と MEL は、Script Editor で実行したときと同じ経路を通ります。
MCP クライアントは、Maya 自身が公開する Streamable HTTP エンドポイント
http://127.0.0.1:<port>/mcpに直接接続します。中継する別プロセスの MCP サーバーはありません。コマンドラインの
isuzu-maya-cliからも、エージェントと同じツールを呼び出せます。NativeAOT の単一バイナリなので、.NET ランタイムも Python も不要です。公開するツールは
execute_pythonとexecute_melの 2 つだけで、固有のシーン操作ツールは持ちません。
動作環境
Maya 2022 以降。動作確認は Maya 2023(Python 3.9.7 / PySide2)で行っています
ビルド済みバイナリを配布しているのは Windows x64 向けです。ほかの環境ではソースからビルドしてください
Maya 内で動くサーバーは標準ライブラリだけで実装しているため、Maya の Python 環境への pip install は不要です。
Related MCP server: maya_mcp
インストール
PowerShell で次の 1 行を実行すると、CLI と Maya 用パッケージの両方が入ります。
irm https://raw.githubusercontent.com/isuzu-shiranui/MayaMCP/main/install.ps1 | iex入るものは 2 つです。
CLI(
isuzu-maya-cli)は%LOCALAPPDATA%\Programs\isuzu-maya-cliに配置され、ユーザー PATH に追加されます。PATH の変更は新しい端末から効きますMaya 用パッケージは
%MAYA_APP_DIR%\scripts\MayaMCP(既定では%USERPROFILE%\Documents\maya\scripts\MayaMCP)に配置されます。そこが git のクローンだった場合は、上書きせずそのまま残します
GitHub Releases から実行ファイルを直接ダウンロードして、SHA256SUMS で検証することもできます。配置先を変えたい場合や CLI だけ入れたい場合は、インストールのカスタマイズをご覧ください。
使い方
1. Maya でサーバーを起動する
Script Editor の Python タブで実行します。
import MayaMCP
MayaMCP.run()Maya の起動と同時に立ち上げるなら、同じscripts フォルダーの userSetup.py に次の 2 行を書いてください。
import maya.utils
maya.utils.executeDeferred("import MayaMCP; MayaMCP.run()")2. コマンドラインから呼ぶ
サーバーが起動すると、接続先とトークンを書いた descriptor ファイルが公開されます。CLI はこれを読むので、ポートやトークンを指定する必要はありません。
isuzu-maya-cli instances # 起動中の Maya 一覧
isuzu-maya-cli health # サーバーの状態
isuzu-maya-cli tools # 利用可能なツール
isuzu-maya-cli call execute_python --file snippet.py # スクリプトの実行
isuzu-maya-cli doctor # 状態ファイル・ポート・疎通の診断コードは --file で渡してください。 シェルと JSON エンコーダーを二重に通すと、バックスラッシュ・改行・インデントが落ちます。--file は base64 にエンコードして送るので、この層が消えます。
Maya を複数起動しているときは、--scene <シーン名> か --pid <プロセス ID> で対象を選べます。
Maya の GUI を開かずに使うこともできます。
isuzu-maya-cli headless start --detach
isuzu-maya-cli headless stopすべてのコマンドは isuzu-maya-cli --help で確認できます。
MCP クライアントから接続する
HTTP で接続する
ポート番号は sha256(prefsDir + Maya のバージョン) から決まるので、Maya を再起動しても変わりません。<port> と <token> は isuzu-maya-cli instances --raw に出ます。
"maya": {
"type": "http",
"url": "http://127.0.0.1:<port>/mcp",
"headers": { "Authorization": "Bearer <token>" }
}stdio ブリッジで接続する
Maya を閉じている時間が長いなら、こちらの方が扱いやすいです。CLI が initialize と tools/list をキャッシュから返すため、Maya が起動していなくてもクライアントとの接続は成立します。
"maya": {
"type": "stdio",
"command": "%LOCALAPPDATA%\\Programs\\isuzu-maya-cli\\isuzu-maya-cli.exe",
"args": ["mcp-stdio"]
}ツール
ツール | 内容 |
| Maya のメインスレッドで Python を実行します。最後の文が式なら、その値が |
| 同じく MEL を実行します |
| 3 秒で返らず job に移った呼び出しの結果を取ります |
コード実行の 2 つは
codeとcode_base64を受け取り、両方あるときはcode_base64が優先します呼び出し 1 回が Undo 1 操作にまとまります。エージェントがノードを大量に作っても、Ctrl+Z 一回でまとめて戻せます
3 秒で返らなかった呼び出しは
202 Acceptedと job id を返し、実行は続きます。CLI はそのまま完了まで追いかけます(--no-waitを付けると job id だけを受け取ります)
セキュリティ
サーバーは
127.0.0.1にだけバインドしますOPTIONSを除くすべてのリクエストに bearer token が必要ですCORS ヘッダーは一切返しません。ループバックへのバインドだけではブラウザーからのアクセスを防げないため、
Access-Control-Allow-Origin: *を設定すると、開いている任意の Web ページからexecute_pythonを呼べるようになってしまうからです
descriptor ファイルとトークンファイルは資格情報として扱ってください。これらを読めるユーザーやプログラムは、Maya 内で任意のコードを実行できます。
設計上の保証
タイムアウトを返しません。3 秒で返らない呼び出しは job に移ります。タイムアウトは仕事をキューに残したままリトライを誘い、二重実行の原因になります
キャンセルした仕事は副作用を残しません。キューの各アイテムが
Pending → Running | Abandonedの状態を持ち、実行が始まる前にキャンセルできたものは一切実行されませんクライアントも POST を再送しません。接続すらできなかったとき、つまり 1 バイトも届いていないと確認できたときだけ送り直します
/healthと/jobsはメインスレッドに触りません。Maya が詰まっているときこそ状態を知る必要があるからです。queueDepthが伸びてreqCountが止まっていれば、メインスレッドが閉塞していますツールの定義は 1 箇所です。関数シグネチャから JSON Schema を生成するので、
/toolsとtools/listが食い違えませんポートの範囲を GUI とヘッドレスで分けています(
28200–28599と28600–28999)。同じ prefs から同じ鍵が出ても、両方を同時に起動して共存させられます
開発者向け
インストールのカスタマイズ(環境変数)
irm | iex はスクリプトファイルを残さないため、コマンドライン引数を渡せません。配置先などを変えたい場合は、実行前に次の環境変数を設定してください。
環境変数 | 用途 |
| インストールするリリースタグ。既定は最新版です |
| CLI の配置先 |
| Maya 用パッケージを入れる |
| 値を設定すると、CLI だけをインストールします |
実行時の環境変数
名前 | 用途 |
| descriptor ファイルの保存先。PATH と同じ区切りで複数指定できます |
| descriptor に書くホストを |
| 処理段階ごとの所要時間を stderr に出力します |
| 自動算出を無視してポート番号を固定します |
|
|
| Maya 用パッケージの読み込み元を指定します |
リポジトリの構成
ディレクトリ | 内容 | 実行環境 |
| Maya 内で動く HTTP + MCP サーバー | Maya 同梱 Python、標準ライブラリのみ |
| コマンドラインツール | .NET 10 / NativeAOT |
| Maya 抜きで実行できる Maya 側のテスト | 同上の Python |
| ビルドとテストのスクリプト | PowerShell |
.\build\run_tests.ps1ソースからビルドする
.NET 10 SDK と Visual Studio Build Tools(C++ によるデスクトップ開発ワークロード)が必要です。
git clone https://github.com/isuzu-shiranui/MayaMCP.git "$env:USERPROFILE\Documents\maya\scripts\MayaMCP"
cd "$env:USERPROFILE\Documents\maya\scripts\MayaMCP"
.\build\build_cli.ps1このスクリプトは NativeAOT で publish して %LOCALAPPDATA%\Programs\isuzu-maya-cli へ配置し、ユーザー PATH に追加します。
publish の前に%ProgramFiles(x86)%\Microsoft Visual Studio\Installer を PATH へ足すのは、ILCompiler が vswhere.exe を呼んでリンカーを探すためです。これが無いと、リンカーのエラーに見える失敗をします。
ライセンス
MIT
This server cannot be deployed
Maintenance
Related MCP Connectors
Build, validate, deploy — HTTP APIs, cron jobs, webhooks and MCP tools — from your AI client.
Cloud Blender for AI agents: scenes, assets, renders, MP4, STL, GLB — over hosted remote MCP.
Zero-setup MCP gateway securely connecting AI to your tools with authentication and workflows
Melaya is a remote MCP server. It gives an assistant hands on your own Android phone and browser: it reads the screen through the accessibility tree, then taps, types and navigates inside the apps and sites you allow-list, with no per-app API. It also builds, schedules and runs agent pipelines across 6k+ connected tools. OAuth 2.1, nothing to install.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables AI assistants to programmatically control Autodesk Maya via natural language using over 30 tools for 3D modeling, lighting, and animation. It connects through Maya's command port to facilitate procedural scene generation and complex production-ready workflows.1-
- AlicenseNot gradedqualityNot gradedmaintenanceA Model Context Protocol server that enables AI assistants to interact with active Autodesk Maya sessions using the maya.cmds API. It allows users to manage scene objects, control selections, and perform common 3D operations through natural language.Apache 2.0
- AlicenseNot gradedqualityCmaintenanceEnables AI assistants like Claude Desktop to control Autodesk Maya via natural language through the Model Context Protocol.MIT
- AlicenseNot gradedqualityCmaintenanceEnables execution of Python and MaxScript code inside Autodesk 3ds Max 2021 from Cursor or other MCP clients via HTTP+TCP bridge.MIT