Skip to main content

MCP server for controlling Autodesk Maya via commandPort

Project description

Maya MCP

Python 3.10.1+ PyPI version Docs License: MIT

Maya MCP is a local Model Context Protocol server for controlling Autodesk Maya through Maya's commandPort.

It gives MCP clients a typed tool surface for scene work, nodes, selection, modeling, shading, skinning, animation, curves, scripts, and viewport capture without importing Maya modules in the server process.

This project is unofficial and is not affiliated with or endorsed by Autodesk. Autodesk Maya is a trademark of Autodesk, Inc.

Why Use It

  • runs outside Maya, so the server stays isolated from Maya imports
  • talks to Maya over localhost only
  • exposes 71 typed tools instead of raw API calls
  • supports safer scene replacement flows for unsaved changes
  • leaves raw code execution disabled unless you opt in

Quick Start

1. Install

pip install maya-mcp

On Windows:

py -m pip install maya-mcp

From source:

pip install -e ".[dev]"

2. Open Maya commandPort

Run this in Maya's Script Editor on the Python tab:

import maya.cmds as cmds

try:
    cmds.commandPort(name=":7001", close=True)
except RuntimeError:
    pass

cmds.commandPort(
    name=":7001",
    sourceType="python",
    echoOutput=True,
    noreturn=False,
    bufferSize=16384,
)

3. Start the server

maya-mcp

Other supported launch styles:

python -m maya_mcp.server
python src/maya_mcp/server.py
fastmcp run

fastmcp run works from this repo because it includes fastmcp.json.

4. Add it to your client

Codex CLI / IDE extension

Codex uses ~/.codex/config.toml for MCP servers. The CLI and IDE extension share that config.

Installed package:

[mcp_servers.maya]
command = "maya-mcp"

Source checkout or Windows-friendly setup:

[mcp_servers.maya]
command = "py"
args = ["-m", "maya_mcp.server"]
env = { PYTHONPATH = "src" }

Use the PYTHONPATH line only when running from a source checkout. Use python instead of py on platforms that do not provide the Windows launcher.

Claude Code

Claude Code project-scoped MCP servers live in .mcp.json. The server key is user-defined; these examples use maya consistently.

Installed package:

{
  "mcpServers": {
    "maya": {
      "command": "maya-mcp",
      "args": []
    }
  }
}

Source checkout or Windows-friendly setup:

{
  "mcpServers": {
    "maya": {
      "command": "py",
      "args": ["-m", "maya_mcp.server"],
      "env": {
        "PYTHONPATH": "src"
      }
    }
  }
}

For Codex CLI and Claude Code on Windows, py -m maya_mcp.server is usually more reliable than relying on the maya-mcp console script being on the correct PATH.

VS Code

VS Code uses .vscode/mcp.json with a servers object.

{
  "servers": {
    "maya": {
      "type": "stdio",
      "command": "maya-mcp"
    }
  }
}

Other MCP clients

Some clients use a generic mcpServers object:

{
  "mcpServers": {
    "maya": {
      "command": "maya-mcp",
      "args": []
    }
  }
}

5. Verify

Call these tools in order:

  1. health.check
  2. scene.info
  3. nodes.list

Tool Coverage

Family Count
health 1
maya 2
scene 9
nodes 7
attributes 2
selection 6
connections 5
mesh 3
viewport 1
modeling 15
shading 3
skin 6
animation 6
curve 2
script 3

script.run is disabled by default and requires MAYA_MCP_ENABLE_RAW_EXECUTION=true.

scene.new and scene.open still refuse by default when the current scene has unsaved changes. Clients that advertise MCP form elicitation can receive an in-band discard-changes confirmation instead of having to retry with force=True.

Main Docs

Published docs: https://gimbalgoats.github.io/GG_MayaMCP/

Development

This repo uses py for Python commands on Windows:

py -m ruff check .
py -m ruff format .
py -m mypy src/
py -m pytest

If tests import maya_mcp from site-packages instead of this repo:

$env:PYTHONPATH='src'
py -m pytest

Security Notes

  • localhost only
  • no remote-host support
  • no Maya imports in the MCP server process
  • no arbitrary code execution by default
  • no secrets or raw tracebacks in client-facing errors

License

MIT. See LICENSE.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

maya_mcp-0.4.1.tar.gz (158.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

maya_mcp-0.4.1-py3-none-any.whl (118.9 kB view details)

Uploaded Python 3

File details

Details for the file maya_mcp-0.4.1.tar.gz.

File metadata

  • Download URL: maya_mcp-0.4.1.tar.gz
  • Upload date:
  • Size: 158.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for maya_mcp-0.4.1.tar.gz
Algorithm Hash digest
SHA256 89fecb4065e9c60516f0ee778d400fb4ee09018eac4f9588629e66c6134a8cd6
MD5 a275a77c6d66f19c036eafc37df3ad49
BLAKE2b-256 baf27af508205b8face4135f6746c4cd2adb32d59dd588bc9b127123e44f5449

See more details on using hashes here.

Provenance

The following attestation bundles were made for maya_mcp-0.4.1.tar.gz:

Publisher: publish-pypi.yml on GimbalGoats/GG_MayaMCP

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file maya_mcp-0.4.1-py3-none-any.whl.

File metadata

  • Download URL: maya_mcp-0.4.1-py3-none-any.whl
  • Upload date:
  • Size: 118.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for maya_mcp-0.4.1-py3-none-any.whl
Algorithm Hash digest
SHA256 fcaede9597f6081b5f668858ac196439f35ed8597828b2c47c195f53c8820170
MD5 384985873f8d122d1ed7d9c2116c747e
BLAKE2b-256 998178cefbd34832dbd64590b14af99f9aedd53306e78e1fbe784b62f4e06bb9

See more details on using hashes here.

Provenance

The following attestation bundles were made for maya_mcp-0.4.1-py3-none-any.whl:

Publisher: publish-pypi.yml on GimbalGoats/GG_MayaMCP

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page