rhino_run_python
Execute Python code inside Rhino's runtime to automate geometry operations, analyze models, control Grasshopper, and run custom scripts on demand.
Instructions
Execute arbitrary Python code inside Rhino's runtime environment.
Args:
code: Python source code string to execute.
rhino_id: Optional Rhino instance ID (for multi-instance setups).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"code": "<code>"
},
"name": "rhino_run_python"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| code | Yes | ||
| rhino_id | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |