Execute Approved Script
script.executeRun a Python script in Maya from an authorized directory, with optional arguments passed as variables in the script's namespace.
Instructions
Execute a Python script file in Maya from an allowed MAYA_MCP_SCRIPT_DIRS directory. The script is read server-side and sent to Maya. Optional args dict is injected as args in the script namespace.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| args | No | Optional arguments dict injected as __args__ in the script namespace | |
| timeout | No | Optional timeout override in seconds (default from MAYA_MCP_SCRIPT_TIMEOUT) | |
| file_path | Yes | Absolute path to the .py script file |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| errors | Yes | ||
| output | Yes | ||
| script | Yes | ||
| success | Yes |