Skip to main content
When the Runchat panel is open in a desktop app, that app is connected to your account through a bridge. Agents, scripts and workflows can then read the open document, run code in it and capture its viewport. There are three ways to use a bridge:
  • Canvas API and MCP. The tools on this page go through the Canvas API endpoint and the Runchat MCP server, like any other canvas tool.
  • Code nodes. A Code node with a CAD language runs its script in the connected app each time the workflow runs.
  • Rhino app tools. HTML apps installed in Rhino reach it through runchat.rhino.
Over REST, the runchat_id comes from the URL path. Over MCP, pass it as an argument to every tool except install_cad_tool and uninstall_cad_tool.

Requirements

  • The app is open with the Runchat panel signed in to the same account as the API key or MCP connection. See the setup guides for Rhino, Grasshopper, Blender, Revit, ArchiCAD and SketchUp.
  • Tools that change the document need the panel’s run permission. Read-only tools do not.
  • Tools that change the document can only be used on runchats you own or share a team with.

Sessions

If you have several windows of the same app open, each is a separate session. Tools use the most recently connected one unless you pass session. When more than one is open, the tool result lists the session ids.

Supported apps

Rhino

get_rhino_context

A read-only snapshot of the open Rhino document. Use it before writing a script that needs to know what is in the model. Returns units and tolerance, object counts by type and busiest layer, layers and the current layer, the selection (id, name, layer, type, bounding box), the active view’s camera and display mode, view and layout names, the block count, and toolbar_tools: the user’s installed CAD tools.

run_rhino_command

Runs a Rhino command, or a one-off Python or C# script, in the connected Rhino. Returns success, message and any new console output.
  • Commands use the non-interactive _- form with _Enter. Avoid commands that open dialogs or ask the user to pick.
  • Python runs in Rhino 8’s CPython 3 with rhinoscriptsyntax and RhinoCommon. print() output is returned.
  • C# runs with System, System.Linq, System.Collections.Generic, Rhino and Rhino.Geometry imported. Console output and a runchat_result variable are returned. Needs plugin 0.3.77 or later on Rhino 8.

Grasshopper

The Grasshopper tools read and edit the definition open in Grasshopper. Grasshopper opens automatically if it isn’t already. Components are identified by their instanceGuid, which grasshopper_read_canvas and the create tools return. All of them also take an optional session.

Creating and wiring components

Give each new component an id: a temporary reference that identifies it in the result, where you get the instanceGuid to wire it with grasshopper_connect_components.

Script components

For grasshopper_create_python_script_components, each input takes a name, an access of "item", "list" or "tree", an optional typeHint ("int", "float", "str", "bool") and optional. Outputs take a name and access. To update a script component, pass its instanceGuid as id: the fields you give replace the existing ones, and inputs and outputs replace the whole list. Run runchat use_skill --name grasshopper-canvas for the full reference agents use.

Blender

run_blender_command

Runs Python in the connected Blender, with bpy available. Returns success, message and the console output. Avoid code that blocks Blender’s main thread for a long time, such as renders or heavy loops.

Revit and ArchiCAD

Revit and ArchiCAD are scripted through Code nodes rather than a dedicated tool. Create a Code node with language set to revit-csharp or archicad-python (see create_code_node) and run it with run_nodes. The script runs in the connected app.

Screenshots

take_screenshot

Captures the viewport of a connected app. Over MCP the image is attached to the agent’s next turn so it can see the result. In Rhino the settings apply to this capture only and the user’s view is restored afterwards. Set host after scripting a specific app, so the capture comes from that app rather than whichever connected last.

CAD tools

CAD tools are Rhino toolbar buttons published as artifacts. See Rhino tools. Tools you create are installed for you already; use install_cad_tool for a teammate’s or a public one.