Files
OrcaSlicer/tests/data/command_catalog.json
T
SoftFever 04b533f493 Let MCP clients see and close the Action Replay window
The Action Replay window was hidden from every GUI tool, so an agent or a test that opened it could not close it,
and it stayed on screen for the rest of the run. It is now listed with a ref, its page can be read, and Escape sent
to it closes it. Its file pickers and confirmation prompts stay the person's alone.
2026-11-19 23:29:31 +08:00

19494 lines
608 KiB
JSON

{
"commands": [
{
"completion": "immediate",
"description": "Find what does something, in one search, or look up one command. With query: the commands that match, best first, each with its group, the first sentence of its description and listed, whether the tool list shows it; one that is not listed (a menu item that takes no arguments, a Design tab command, or an operation a plugin offers, plugin.<plugin>.<name>) comes with its input schema, and its description when that says more, which nothing else shows. Beside them, the best few matches of each other catalog, with its total and how to use it: actions (the Speed Dial's plates, recent projects and plugin scripts and pages), settings, and python (the orca API a script calls). The reply says how to call each kind of match. With tool: that command's description and input schema, and its examples when it has some (the Design commands do). With neither: every command's name. group keeps the names and the command matches to one group; the other catalogs' matches stay as they are. The Design tab's CAD commands follow by heading (sketches, solid and surface features, bodies, measurements); look one up with tool before calling it. A command whose schema has silent does what its menu item does when called with no arguments, unless silent is true. Document: describe_design, import_step, import_mesh, set_variable, commit_to_plate, new_design, export_step, select_geometry, confirm_tool, cancel_tool. Sketch: sketch_create, sketch_project, sketch_text, sketch_insert_svg, sketch_offset, sketch_trim, sketch_fillet, sketch_chamfer, sketch_mirror, sketch_dimension, sketch_constrain, sketch_toggle_construction, sketch_extend, sketch_delete, sketch_describe, sketch_validate, sketch_list_constraints, sketch_blend_curve, sketch_finish, sketch_cancel, sketch_edit, sketch_draw, sketch_select, sketch_repair, sketch_set_value, sketch_transform, sketch_pattern, sketch_delete_constraint. Solid: extrude, revolve, sweep, loft, thicken, rib, boolean, hole, thread, shell, split, fillet, chamfer, draft, pattern, mirror, align, delete_face, list_align_types. Surface: surface_extrude, surface_revolve, surface_loft, surface_patch, surface_offset. Construct: construct_plane, construct_axis, construct_coordinate_system, helix. Inspect: measure, body_mass_properties, interference, body_describe, body_section, body_compare. Bodies: body_transform, body_delete, body_set, body_place. History: feature_edit, feature_delete, feature_describe, feature_set_expression, feature_move, feature_suppress, feature_rename. Menu items, which take no arguments and do what their item of the right-click menu does: rename_selected, zoom_to_selection, sketch_polygon_inscribed, sketch_polygon_circumscribed, sketch_constrain_selected.",
"destructive": false,
"group": "Tools and actions",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"group": {
"description": "Only the commands of this group, in any case: the heading of a place (Tools and actions; The app; The project; Objects; Parts; Plates; Presets and settings; Filaments; Printers and prints; Plugins, with the operations plugins offer; View and windows; Recordings, replays and scripts; Driving the GUI), the place a command's name starts with, but for window_screenshot and window_save_screenshot, which are under Recordings, replays and scripts; or Design (the Design tab's, with the CAD feature on). A group no command has is refused with the groups there are.",
"type": "string"
},
"limit": {
"description": "At most this many commands (default 5).",
"maximum": 200,
"minimum": 1,
"type": "integer"
},
"query": {
"description": "A few words saying what you want to do or find, e.g. \"brim\" or \"mesh normals\".",
"type": "string"
},
"tool": {
"description": "A command's name: its description and schema.",
"type": "string"
}
},
"type": "object"
},
"key": "tool_search",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Find tools, actions, settings and APIs"
},
{
"completion": "immediate",
"description": "Call any command by name with its arguments: a tool, or one the tool list does not show, a menu item that takes no arguments, a Design tab command or an operation a plugin offers (see tool_search). It runs and is recorded as that command's own call, with its guards and reply budget.",
"destructive": false,
"group": "Tools and actions",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"args": {
"description": "Its arguments.",
"type": "object"
},
"tool": {
"description": "The command to call.",
"type": "string"
}
},
"required": [
"tool"
],
"type": "object"
},
"key": "tool_call",
"listed": true,
"open_world": true,
"operations": [],
"read_only": false,
"title": "Call a tool or plugin operation"
},
{
"completion": "immediate",
"description": "Snapshot of OrcaSlicer. Call it first and whenever you are unsure what the app is doing. The app: version, platform and display backend, whether it is ready, the main window, the displays (each one's work area x, y, width and height, as window_set takes positions, its scale and whether it is primary), the MCP endpoint (mcp), python (available: Python runs in this build; scripts_unrestricted: a script's own file, network, process and thread access is not held to OrcaSlicer's folders, which only a person turns on, in Preferences > AI features > Python scripts or for one run with --unrestricted-scripts), design_tab (the Design tab is on, and tool_call runs its commands, tool_search's group Design) and, when they do not run, cad_note, how a person turns the CAD feature on; account (signed_in to the Orca cloud, bambu_signed_in to Bambu Lab's), network_plugin (installed, loaded, version, error: the Bambu network plug-in as the app found it) and config_folder (presets, app configuration and logs). The view outside the Design tab (view: sidebar_collapsed, sidebar_width, legend_collapsed, gcode_window, projection, section and the display switches labels, overhangs, outline, wireframe, gridlines, axes and navigator, under the names view_set takes them). The project: current tab and mode, printer technology, name, path and unsaved changes, selected printer/process/filament presets, plates (count, current), object count, the selection (objects, the instances [[object, instance]] they are selected in and, when parts rather than whole instances are selected, parts [[object, part]], in the indices object_select takes; wipe_tower when a prime tower is selected; canvas is the 3D view it belongs to), slicing state, the Preview's view type, time mode and layer range (1-based, with their Z), and the camera of the 3D view shown (camera: type, look_at, position, zoom, click_px_per_mm, elevation and azimuth, as view_set replies with it). What is going on: open modal dialogs, each with its title, buttons (enabled: false when disabled) and a message that reads it as shown: its text and its controls row by row, fields [value], choices [value ▾], checkboxes [x] / [ ] / [-], radio and selector options (*) / ( ), list rows \"- row | cells\", secrets [******], \" (disabled)\" after a disabled control; menus closed unseen (a menu a call opened that no reply listed), dialog_auto_answer rules in force, notifications, print host uploads (state, progress, error), the open gizmo, running jobs and a running recording.",
"destructive": false,
"group": "The app",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "app_state",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Get app state"
},
{
"completion": "immediate",
"description": "Search everything the Speed Dial can run: built-in commands (slice, export, views, object operations, plates, calibration wizards, help), recent projects, plugin scripts and pages. Each entry has an id for action_run, a description, the command's key for a built-in command, and, when it takes arguments, their input_schema. A query ranks them, best match first, as tool_search does; without one they are listed by group and title. include_settings also lists settings (each jumps to that setting in the sidebar; use settings_get / settings_set to read or change values).",
"destructive": false,
"group": "Tools and actions",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"group": {
"description": "Only this group, e.g. \"Object\", \"View\", \"Slice & Export\".",
"type": "string"
},
"include_settings": {
"description": "Also list settings (thousands). Default false.",
"type": "boolean"
},
"limit": {
"description": "Default 50.",
"maximum": 200,
"minimum": 1,
"type": "integer"
},
"offset": {
"minimum": 0,
"type": "integer"
},
"query": {
"description": "A few words, e.g. \"delete object\": each is matched at the start of the words of an action's id, title, group and description.",
"type": "string"
}
},
"type": "object"
},
"key": "action_search",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Search Speed Dial actions"
},
{
"completion": "immediate",
"description": "Run one action by the id action_search returned (orca_command:view_front:orca, or the name inside it, view_front), with args, the command's arguments, when it takes some (its input_schema). A command's action (action_search names the command) runs the command as a call with the action's arguments does: an action that asks in a dialog asks, and the call returns blocked_by_dialog; answer it with dialog_answer, or, for a native one it can't press (a file picker), register dialog_auto_answer before the call. Such an action takes no args, or exactly its own; to run a command without asking, call it with its arguments (an absolute path skips a file dialog). Go to layer and Go to tab take their value alone ({\"percent\": 50}, {\"tab\": \"preview\"}), and a Design command's own action takes the command's arguments. An action that starts a background job (obj_arrange, obj_orient) completes when the job ends. An action that does nothing (no object selected) is an error. Some commands add what they did to the reply (the order object_order leaves, the object object_assemble made). The other actions (plates, recent projects, plugin scripts and pages, settings) run only here.",
"destructive": false,
"group": "Tools and actions",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"args": {
"description": "The command's arguments, as its input_schema gives them.",
"type": "object"
},
"id": {
"description": "Action id from action_search, or the name inside it.",
"type": "string"
}
},
"required": [
"id"
],
"type": "object"
},
"key": "action_run",
"listed": true,
"open_world": true,
"operations": [],
"read_only": false,
"title": "Run a Speed Dial action"
},
{
"completion": "immediate",
"description": "Block until a condition holds or timeout_s passes (max 50). for: \"ready\" (startup finished), \"idle\" (no dialog, no running job, nothing slicing or arranging, no gizmo working in the background; a script_run run counts only through the calls it makes), \"dialog\" / \"no_dialog\", or \"job\" with a job id an earlier call returned, whose result is then the reply. On timeout the reply is {satisfied: false}, or for a job {status: \"running\", job, note}: call it again.",
"destructive": false,
"group": "The app",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"for": {
"description": "What to wait for; default job when job is given, else idle.",
"enum": [
"ready",
"idle",
"dialog",
"no_dialog",
"job"
],
"type": "string"
},
"job": {
"description": "Job id, for \"job\".",
"type": "string"
},
"timeout_s": {
"description": "Default 30.",
"maximum": 50,
"minimum": 0,
"type": "number"
}
},
"type": "object"
},
"key": "app_wait",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Wait for a condition"
},
{
"completion": "immediate",
"description": "The last lines of OrcaSlicer's current log file, optionally only those at or above a level. An entry's level is the one its first line starts with ([error]); the lines of its message after the first come with it, and the reply holds whole entries.",
"destructive": false,
"group": "The app",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"level": {
"description": "Minimum level.",
"enum": [
"trace",
"debug",
"info",
"warning",
"error",
"fatal"
],
"type": "string"
},
"lines": {
"description": "The most lines, of the newest whole entries; an entry longer than that gives its first lines. Default 200.",
"maximum": 2000,
"minimum": 1,
"type": "integer"
}
},
"type": "object"
},
"key": "app_log",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Read the log"
},
{
"action_group": "Commands",
"completion": "immediate",
"description": "Take back the last change of a history, as Edit > Undo does. history design is the Design tab's: the last feature added, edited, deleted, moved, shown or hidden, or renamed, or variable changed, or in a sketch session the last drawn shape; project is the project's. Without history, the Design tab's while it is shown, else the project's. Reply: history and, for the Design tab's, result: scope (design or sketch), undo_depth, redo_depth, features, bodies and generation; entities in a sketch.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"history": "design"
},
"tool": "undo"
}
],
"title": "Take back an extrude, its sketch with it"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 4,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"history": "design"
},
"tool": "undo"
}
],
"title": "Take back the last shape drawn in a sketch"
}
],
"group": "The app",
"guard": "mutate",
"has_own_action": true,
"icon": "menu_undo",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"history": {
"description": "The history: design, the Design tab's (with the CAD feature on), or project. Default: the Design tab's while it is shown, else the project's.",
"enum": [
"design",
"project"
],
"type": "string"
}
},
"type": "object"
},
"key": "undo",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Undo"
},
{
"action_group": "Commands",
"completion": "immediate",
"description": "Put back what undo took back, until the next change, as Edit > Redo does, in the history undo takes. Reply as undo's.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"history": "design"
},
"tool": "undo"
},
{
"args": {
"history": "design"
},
"tool": "redo"
}
],
"title": "Put back an extrude undo took back"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 4,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"history": "design"
},
"tool": "undo"
},
{
"args": {
"history": "design"
},
"tool": "redo"
}
],
"title": "Put back the shape undo took off a sketch"
}
],
"group": "The app",
"guard": "mutate",
"has_own_action": true,
"icon": "menu_redo",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"history": {
"description": "The history: design, the Design tab's (with the CAD feature on), or project. Default: the Design tab's while it is shown, else the project's.",
"enum": [
"design",
"project"
],
"type": "string"
}
},
"type": "object"
},
"key": "redo",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Redo"
},
{
"actions": [
{
"args": {
"page": "wiki"
},
"description": "Open the OrcaSlicer wiki in the browser.",
"group": "Help",
"icon": "link_wiki_img",
"key": "open_wiki",
"title": "Open Wiki"
},
{
"args": {
"page": "youtube"
},
"description": "Open the OrcaSlicer YouTube channel in the browser.",
"group": "Help",
"icon": "",
"key": "open_youtube",
"title": "Open YouTube Channel"
},
{
"args": {
"page": "plugin_hub"
},
"description": "Open the plugin hub's page in the default web browser, where a person picks a plugin to install; nothing opens in OrcaSlicer.",
"group": "Plugins",
"icon": "",
"key": "install_plugin",
"title": "Install Plugin"
}
],
"completion": "immediate",
"description": "Open one of OrcaSlicer's web pages in the default web browser, as its menu item does: wiki, the OrcaSlicer wiki; youtube, the OrcaSlicer YouTube channel; plugin_hub, the plugin hub's page, where a person picks a plugin to install. Nothing opens in OrcaSlicer.",
"destructive": false,
"group": "The app",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"page": {
"description": "The page.",
"enum": [
"wiki",
"youtube",
"plugin_hub"
],
"type": "string"
}
},
"required": [
"page"
],
"type": "object"
},
"key": "app_open_web_page",
"listed": true,
"open_world": true,
"operations": [],
"read_only": false,
"title": "Open a web page"
},
{
"actions": [
{
"args": {},
"description": "Check for a newer OrcaSlicer.",
"group": "Help",
"icon": "refresh",
"key": "help_check_updates",
"title": "Check for Updates"
}
],
"completion": "immediate",
"description": "Check for a newer OrcaSlicer.",
"destructive": false,
"group": "The app",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "app_check_for_updates",
"listed": true,
"open_world": true,
"operations": [],
"read_only": false,
"title": "Check for Updates"
},
{
"actions": [
{
"args": {},
"description": "Open the configuration folder in the file manager.",
"group": "Help",
"icon": "open_project",
"key": "help_open_config_folder",
"title": "Show Configuration Folder"
}
],
"completion": "immediate",
"description": "Open the configuration folder in the file manager.",
"destructive": false,
"group": "The app",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "app_show_config_folder",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Show Configuration Folder"
},
{
"actions": [
{
"args": {},
"description": "Time the 3D views on a test model. It asks first (Start or Cancel), then replaces the project with the OrcaSliced Combo as New Project does, which may ask about unsaved changes, slices it and shows the results.",
"group": "Help",
"icon": "",
"key": "help_benchmark_3d_scene",
"title": "Benchmark 3D Scene"
}
],
"completion": "immediate",
"description": "Time the 3D views on a test model. It asks first (Start or Cancel), then replaces the project with the OrcaSliced Combo as New Project does, which may ask about unsaved changes, slices it and shows the results.",
"destructive": false,
"group": "The app",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "app_benchmark_3d_scene",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Benchmark 3D Scene"
},
{
"completion": "immediate",
"description": "Read the app's preferences as the Preferences dialog shows them. With no argument, every preference it shows, tab by tab in its order, each with key (its control is named after it), tab, section and label (the row's title, in English), kind (checkbox, choice, number or text), value (what the dialog shows: true or false for a checkbox, a number for a number field), a choice's choices ({value, label}; preferences_set takes the value), a number's min and max, stored: false where nothing is stored and the value is the one the dialog shows then, restart_needed: true for a preference read at the next start, which a write changes nothing before, and refused, the reason, for a preference preferences_set does not write. The MCP server's switch and port read as the dialog shows them: on while the server runs, and the port it is on, also where this session's launch arguments set them without storing them; their stored says whether a value is stored. keys, query and tab narrow the list together; a named key the dialog does not show is read as the app configuration stores it ({key, value}), and one that is neither is listed under unknown_keys. The app configuration also holds account and device state, which is read only by name.",
"destructive": false,
"group": "The app",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"keys": {
"description": "Preference keys, e.g. [\"project_load_behaviour\"].",
"items": {
"type": "string"
},
"type": "array"
},
"query": {
"description": "Words to find in the keys, labels and section titles, in any case, e.g. \"auto slice\".",
"type": "string"
},
"tab": {
"description": "The dialog's tab, as window_open names it.",
"enum": [
"general",
"files",
"behaviour",
"control",
"graphics",
"online",
"developer"
],
"type": "string"
}
},
"type": "object"
},
"key": "preferences_get",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Read preferences"
},
{
"completion": "immediate",
"description": "Change preferences as their controls in the Preferences dialog do: values {key: value}, a checkbox as true or false, a choice as one of its values, a number within its range, as preferences_get lists them, and the downloads folder (download_path) as the absolute path of an existing folder. All are checked first and written together, so nothing changes if one is refused; then each does what its control does in the app, in the keys' order (the preview redrawn, the sidebar's lists, the settings' mode, the theme, preset sync started or stopped, stealth mode's sign-out of the cloud accounts), and those preferences_get marks restart_needed are stored and take effect at the next start. A key whose value is already the one given is left as it is. Refused, by name and with the reason: a key the dialog does not show, and those preferences_get marks refused, whose control opens a dialog, restarts OrcaSlicer, signs out, or reaches outside it (the language, the login region, the network plug-in, file associations, the mixed-temperature warning, the MCP server's switch and port); those change in the dialog: window_open {\"window\": \"preferences\", \"tab\", \"key\"}, then widget_set_value. Not in the undo history. Reply: changed, [{key, before, after}] typed as preferences_get gives them, with stored_before: false where nothing was stored and before is the value the dialog showed, and restart_needed: true where preferences_get gives it; and unchanged, the keys already so.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"query": "arrange"
},
"tool": "preferences_get"
},
{
"args": {
"values": {
"auto_arrange": false
}
},
"tool": "preferences_set"
}
],
"title": "Find a preference and turn it off"
},
{
"calls": [
{
"args": {
"values": {
"auto_calculate_flush": "color change",
"opengl_fps_cap": 60
}
},
"tool": "preferences_set"
}
],
"title": "Set a choice and a number"
}
],
"group": "The app",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"values": {
"description": "{key: value}, e.g. {\"auto_arrange\": false, \"auto_calculate_flush\": \"color change\"}.",
"type": "object"
}
},
"required": [
"values"
],
"type": "object"
},
"key": "preferences_set",
"listed": true,
"open_world": false,
"operations": [
"set_preferences"
],
"read_only": false,
"title": "Change preferences"
},
{
"completion": "immediate",
"description": "Stop the running operation: a slice or G-code export, as the slicing progress's cancel button does, or a background job an MCP call started (an arrange, orient or fill bed). Its job then reports cancelled; a background job keeps other changes out until it has really stopped. With job, only that job is stopped: the running operation, an object_fix, a script_run run or a recording_encode. Allowed while an operation holds the project. Reply: was_running, and job when one was stopped.",
"destructive": false,
"group": "The app",
"guard": "recover",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"job": {
"description": "The operation's job to cancel, e.g. \"j12\".",
"type": "string"
}
},
"type": "object"
},
"key": "job_cancel",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Cancel a job"
},
{
"actions": [
{
"args": {},
"description": "Open a project through the Open dialog (it asks first if the current project has unsaved changes); project_open with a path opens that file without a dialog.",
"group": "Commands",
"icon": "menu_open",
"key": "load_project",
"title": "Load Project"
}
],
"completion": "immediate",
"description": "Open a project (.3mf) by absolute path, without a file dialog, replacing the current project, with the settings it was saved with whatever the Preferences' Load behavior says; when the current project has unsaved changes that fails, changing nothing, unless discard_changes. A G-code file replaces the project too, to show its toolpaths: with unsaved changes the app asks first (blocked_by_dialog), whatever discard_changes says. project_import adds models, or a project's objects alone, to the current project. Called with no arguments it is Load Project: the Open dialog asks for the file (blocked_by_dialog), after asking about the unsaved changes. Reply: opened (project or gcode), and objects, names and plates for a project, path for a G-code.",
"destructive": false,
"group": "The project",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"discard_changes": {
"description": "Drop the project's unsaved changes rather than fail when a project replaces it.",
"type": "boolean"
},
"path": {
"description": "Absolute path of a .3mf project, or of a G-code file (.gcode, .bgcode).",
"type": "string"
},
"silent": {
"description": "true runs the command without asking; it then needs path, and what else the call leaves out takes its default. A call with no arguments does what a person's pick does.",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"path"
]
},
"type": "object"
},
"key": "project_open",
"listed": true,
"open_world": false,
"operations": [
"open_project"
],
"read_only": false,
"title": "Open a project"
},
{
"actions": [
{
"args": {},
"description": "Import models (3MF/STL/STEP/SVG/OBJ/AMF) through a file dialog, as one undo step; a project file's settings are not loaded (project_open opens a project). project_import with paths adds files' geometry without a dialog.",
"group": "Import",
"icon": "menu_open",
"key": "import_file",
"title": "Import 3MF/STL/STEP/SVG/OBJ/AMF"
},
{
"args": {
"archive": true
},
"description": "Import models from a ZIP archive (opens a file dialog).",
"group": "Import",
"icon": "menu_open",
"key": "import_zip_archive",
"title": "Import ZIP Archive"
}
],
"completion": "immediate",
"description": "Add the models of files (STL, 3MF, STEP, OBJ, AMF, SVG...) to the current project by absolute path, without a file dialog, as one undo step; a .3mf adds its objects only, not its settings (project_open opens it as a project). A .zip archive gives the model files it holds (STL, OBJ, AMF, 3MF, STEP; a .3mf its objects only, as above), as Import ZIP Archive does: those entries names, by their paths in the archive, else all of them, in place of its file list; an entry the archive lacks is refused with the names it has, before anything is imported. Importing can open a dialog (STEP mesh options, for instance); the reply is then blocked_by_dialog. Called with no arguments it is Import 3MF/STL/STEP/SVG/OBJ/AMF, and with archive: true alone Import ZIP Archive: a file dialog asks for the files, or for the archive and then which of its files to import (blocked_by_dialog). Reply: opened (models), added (how many objects), archives (each archive's path and the entries taken) and the project's objects, names and plates.",
"destructive": false,
"group": "The project",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"not": {
"enum": [
{},
{
"archive": true
}
]
}
},
"properties": {
"archive": {
"description": "true, alone: ask for a ZIP archive in a file dialog and import the models it holds, as Import ZIP Archive does.",
"type": "boolean"
},
"entries": {
"description": "The files to take from the one .zip archive among paths, by their paths in it (\"parts/cube.stl\"). Default: every model file it holds.",
"items": {
"type": "string"
},
"minItems": 1,
"type": "array"
},
"paths": {
"description": "Absolute paths of model files, or of a .zip archive of them.",
"items": {
"type": "string"
},
"type": "array"
},
"silent": {
"description": "true runs the command without asking; it then needs paths, and what else the call leaves out takes its default. A call with no arguments, or with exactly a Speed Dial action's arguments, does what a person's pick of that action does.",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"paths"
]
},
"type": "object"
},
"key": "project_import",
"listed": true,
"open_world": false,
"operations": [
"import_models"
],
"read_only": false,
"title": "Import models"
},
{
"actions": [
{
"args": {},
"description": "Runs project_new with no arguments, as New Project does: a new, empty project, after asking about the unsaved changes if there are any.",
"group": "Commands",
"icon": "menu_open",
"key": "new_project",
"title": "New Project"
}
],
"completion": "immediate",
"description": "Start a new, empty project. Called with no arguments, it asks as New Project does, about the unsaved changes if there are any: the reply is then blocked_by_dialog, and dialog_answer answers it. With arguments, or silent: true, it asks nothing: it fails, changing nothing, when the current project has unsaved changes, unless discard_changes. The presets' unsaved changes carry over to the new project unless preset_changes is \"discard\", as New Project's prompt offers. Reply, with arguments: objects, names, plates; when presets had or have unsaved changes, discarded and modified list per preset the keys dropped and the keys still unsaved. With no arguments the reply is ran and level, also once a prompt is answered, whatever the answer: Cancel keeps the project.",
"destructive": false,
"group": "The project",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"discard_changes": {
"description": "Drop the project's unsaved changes rather than fail; for the presets', see preset_changes.",
"type": "boolean"
},
"preset_changes": {
"description": "The presets' unsaved changes, not the project's: keep them for the new project (default) or drop them.",
"enum": [
"keep",
"discard"
],
"type": "string"
},
"silent": {
"description": "true runs the command without asking; what the call leaves out takes its default. A call with no arguments does what a person's pick does.",
"enum": [
true
],
"type": "boolean"
}
},
"type": "object"
},
"key": "project_new",
"listed": true,
"open_world": false,
"operations": [
"new_project"
],
"read_only": false,
"title": "New Project"
},
{
"actions": [
{
"args": {},
"description": "Runs project_save with no arguments, as Save Project does: to the project's file, or through a file dialog when it has none.",
"group": "Commands",
"icon": "menu_save",
"key": "save_project",
"title": "Save Project"
},
{
"args": {
"save_as": true
},
"description": "Save the project as a .3mf file through the save dialog. project_save with a path saves there without a dialog; a name ending in .gcode.3mf is refused (project_export {format: \"sliced_3mf\"} writes that).",
"group": "Commands",
"icon": "menu_save",
"key": "save_project_as",
"title": "Save Project As"
}
],
"completion": "immediate",
"description": "Save the project. Called with no arguments, it saves as Save Project does: to the project's file (reply: ran, level), or, when it has none, through a file dialog (blocked_by_dialog; a native picker needs dialog_auto_answer registered first); with save_as: true alone, as Save Project As does, always through the file dialog. With path, it saves a .3mf there without the file dialog, and the file becomes the project's (reply: path, bytes); a name ending in .gcode.3mf is refused (project_export writes that). Either way the save can still open a dialog (blocked_by_dialog): a warning when settings name a plugin OrcaSlicer cannot identify, or an error when the file cannot be written. A save that writes nothing, its file dialog or that warning cancelled or the write failed, fails with project_not_saved, and a file already there stays as it was.",
"destructive": false,
"group": "The project",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"not": {
"enum": [
{},
{
"save_as": true
}
]
}
},
"properties": {
"overwrite": {
"description": "Replace an existing file.",
"type": "boolean"
},
"path": {
"description": "Absolute .3mf path.",
"type": "string"
},
"save_as": {
"description": "true, alone: ask for the file in the save dialog, as Save Project As does. With path it adds nothing: path is the new file.",
"type": "boolean"
},
"silent": {
"description": "Goes with path, which every call but {} and {save_as: true} requires, and adds nothing to it: a call with path skips the file dialog already.",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"path"
]
},
"type": "object"
},
"key": "project_save",
"listed": true,
"open_world": false,
"operations": [
"save_project_as"
],
"read_only": false,
"title": "Save Project"
},
{
"actions": [
{
"args": {
"format": "gcode"
},
"description": "Export the current plate's G-code through the export dialog, in the background. project_export with a path exports the sliced plate there without a dialog, and the call returns when the file is written; a plate that is not sliced is refused (slice first).",
"group": "Slice & Export",
"icon": "custom-gcode_gcode",
"key": "export_gcode",
"title": "Export G-code"
},
{
"args": {
"format": "sliced_3mf"
},
"description": "Export the current plate's sliced file (.gcode.3mf) through a file dialog; project_export with a path writes there without one.",
"group": "Slice & Export",
"icon": "save",
"key": "export_sliced_file",
"title": "Export Sliced File"
},
{
"args": {
"format": "sliced_3mf",
"plates": "all"
},
"description": "Export every plate's sliced file into one .gcode.3mf through a file dialog; project_export with a path writes there without one.",
"group": "Slice & Export",
"icon": "save",
"key": "export_all_sliced_file",
"title": "Export All Sliced Files"
},
{
"args": {
"format": "3mf"
},
"description": "Export the model as a .3mf without slicing data, through a file dialog; project_export with a path writes there without one.",
"group": "Slice & Export",
"icon": "menu_save",
"key": "export_3mf",
"title": "Export 3MF"
},
{
"args": {
"format": "stl"
},
"description": "Export all objects as one STL through a file dialog; project_export with a path writes there without one.",
"group": "Slice & Export",
"icon": "save",
"key": "export_stl",
"title": "Export STL"
},
{
"args": {
"format": "stl",
"per_object": true
},
"description": "Export each object as its own STL into the folder a dialog asks for; project_export with a folder as path writes there without one.",
"group": "Export",
"icon": "save",
"key": "export_stl_multi",
"title": "Export All Objects as STLs"
},
{
"args": {
"format": "drc"
},
"description": "Export all objects as one Draco (.drc) file.",
"group": "Export",
"icon": "save",
"key": "export_drc_single",
"title": "Export All Objects as DRC (one file)"
},
{
"args": {
"format": "drc",
"per_object": true
},
"description": "Export each object as its own Draco (.drc) file.",
"group": "Export",
"icon": "save",
"key": "export_drc_multi",
"title": "Export All Objects as DRCs"
},
{
"args": {
"format": "toolpaths_obj"
},
"description": "Export the sliced toolpaths as an OBJ.",
"group": "Export",
"icon": "custom-gcode_gcode",
"key": "export_toolpaths_obj",
"title": "Export Toolpaths as OBJ"
}
],
"completion": "immediate",
"description": "Write the project to a file without a dialog. gcode: the plate's G-code (slice first; it is written in the background, and the call returns once it is). sliced_3mf: the sliced plate, or all plates, as .gcode.3mf (slice first: a plate that is not sliced is written without G-code). 3mf: the model without slicing data. stl and drc (Draco): the objects as one file, or with per_object each in a file of its own, named after it, into the folder path names; every object of every plate, or those objects names. toolpaths_obj: the toolpaths the Preview shows, as an OBJ, refused while it shows none (slice the plate and show the Preview first). Without format, the path's extension (.gcode, .gcode.3mf, .3mf, .stl, .drc, .obj) says which. Called with exactly the arguments of one of the File > Export menu items (format alone, sliced_3mf with plates \"all\", stl or drc with per_object), it asks for the file or folder in the dialog that item opens (blocked_by_dialog). A file per object of a project with no objects, and the toolpaths while the Preview shows none, are refused in either form. Reply: path and bytes; for gcode, path and export (ok, or superseded with a note when the project changed while it was written); for per_object, path and files (each file written); for stl and drc, objects (those written).",
"destructive": false,
"group": "The project",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"not": {
"enum": [
{
"format": "gcode"
},
{
"format": "sliced_3mf"
},
{
"format": "sliced_3mf",
"plates": "all"
},
{
"format": "3mf"
},
{
"format": "stl"
},
{
"format": "stl",
"per_object": true
},
{
"format": "drc"
},
{
"format": "drc",
"per_object": true
},
{
"format": "toolpaths_obj"
}
]
}
},
"properties": {
"format": {
"description": "What to write; default from the path's extension.",
"enum": [
"gcode",
"sliced_3mf",
"3mf",
"stl",
"drc",
"toolpaths_obj"
],
"type": "string"
},
"object_ids": {
"description": "The ids object_list reports for objects, one per entry: refused when an index names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"objects": {
"description": "Object indices.",
"items": {
"type": "integer"
},
"type": "array"
},
"overwrite": {
"description": "Replace an existing file.",
"type": "boolean"
},
"path": {
"description": "Absolute output path: the file, or with per_object an existing folder.",
"type": "string"
},
"per_object": {
"description": "stl and drc: a file per object, into a folder. Default false.",
"type": "boolean"
},
"plates": {
"description": "\"current\" (default), a plate index, which is selected first and is the plate gcode and sliced_3mf write, or \"all\" (sliced_3mf only).",
"type": [
"string",
"integer"
]
},
"silent": {
"description": "true runs the command without asking; it then needs path, and what else the call leaves out takes its default. A call with exactly a Speed Dial action's arguments does what a person's pick of that action does.",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"path"
]
},
"type": "object"
},
"key": "project_export",
"listed": true,
"open_world": false,
"operations": [
"start_gcode_export",
"export_sliced_3mf",
"export_model_3mf",
"export_stl",
"export_toolpaths_obj"
],
"read_only": false,
"title": "Export"
},
{
"completion": "immediate",
"description": "Read the settings the project stores outside any preset: the plate type (curr_bed_type), slot colours (filament_colour), flushing volumes (flush_volumes_matrix, flush_multiplier), purge mode (prime_volume_mode), prime tower position per plate (wipe_tower_x, wipe_tower_y), mixed slots (filament_is_mixed) and, with several extruders, the filament grouping (filament_map_mode, filament_map); all of them, or those named in keys. Each item has its value and meta; meta.offered lists the choices this printer has, and meta.read_only marks what is set elsewhere.",
"destructive": false,
"group": "The project",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"include_meta": {
"description": "Include labels, types and ranges. Default true.",
"type": "boolean"
},
"keys": {
"description": "Setting keys, e.g. [\"filament_colour\"].",
"items": {
"type": "string"
},
"type": "array"
}
},
"type": "object"
},
"key": "project_get_settings",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Read the project's settings"
},
{
"completion": "immediate",
"description": "Change the project's own settings as the sidebar's controls write them: curr_bed_type, filament_colour (#RRGGBB per slot), flush_multiplier, flush_volumes_matrix, prime_volume_mode, and wipe_tower_x/y (mm from the plate's origin, one per plate). flush_volumes_matrix is per nozzle, slots x slots from row to column, in config order over every slot, before the multiplier; a mixed slot's entries must be given as they are, and a colour change can recalculate it, so set it last. Values are checked before anything changes; a prime tower move is one undo step. Reply: applied, changed, and a note when the app moved a prime tower that did not fit.",
"destructive": false,
"group": "The project",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"values": {
"description": "{key: value}, or {key: {index, value}} for one entry",
"type": "object"
}
},
"required": [
"values"
],
"type": "object"
},
"key": "project_set_settings",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Change the project's settings"
},
{
"completion": "immediate",
"description": "The project as the Objects panel lists it. plates: each {index, name, objects}, with the objects that have an instance on it; outside: the objects with an instance on no plate. An object with instances on two plates is listed under both, each time with that plate's instances. An object has its filament, auto_drop, bounding box (instance 0), brim ear count and overrides, the keys of the settings it overrides (settings_get target object reads them); its mesh_errors, as the list's warning icon reads them: open_edges, manifold (no open edge), and the loader's or a repair's counts degenerate_facets, edges_fixed, facets_removed, facets_reversed and backwards_edges (object_fix repairs it); its instances (offset, rotation in degrees, scale, mirrored, bbox); its parts, one or more: parts, negative parts, modifiers, support blockers and enforcers and precise seams (type, with subtype for a precise seam; filament: a part's own or its object's, a modifier's only when it sets one; position, bbox and scaled_volume in mm3 on the bed, measured on instance 0; rotation_deg and scale in the object's frame; mirrored; triangle count; mesh_volume, the unscaled mesh's mm3; painted facets: supports and seam enforcers/blockers, fuzzy_skin, mmu per filament, texture per layer; a text part's text and font, an SVG part's file); its height range modifiers when it has any (layer_config_ranges: [{min_z, max_z, values}], values being a range's settings, which settings_set changes with target height_range; object_set_height_ranges takes min_z and max_z) and its variable layer height profile when it has one (layer_height_profile: {points, min_height, max_height}). A bbox is {min, max, size} in mm of model parts only, so unlike the panel's Size it leaves out modifiers. An object's index numbers it in the project and a part's in its object, whatever the plate: they are what object_select, object_transform, mouse_gesture targets and the settings tools' object and part targets take. Each object and part also has an id, which stays with it when a delete, split or assemble shifts the indices: pass it as object_id / part_id to object_transform, part_add, settings_set, object_set_height_ranges and object_set_variable_layer_height (object_ids, part_ids and instance_object_ids to object_select), and a call whose index names another one now is refused instead of acting on it. limit and offset page the objects and total counts them, each once.",
"destructive": false,
"group": "Objects",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"limit": {
"description": "Objects, default 200.",
"maximum": 500,
"minimum": 1,
"type": "integer"
},
"offset": {
"minimum": 0,
"type": "integer"
},
"plate": {
"description": "List this plate alone, without outside.",
"minimum": 0,
"type": "integer"
},
"screen": {
"description": "Add each instance's rectangle in the shown 3D view, logical pixels [x, y, w, h].",
"type": "boolean"
}
},
"type": "object"
},
"key": "object_list",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "List objects"
},
{
"actions": [
{
"args": {
"all": true
},
"description": "Select every object in the 3D view (the assemble view while it is shown, else Prepare, switching to it), and reply with the selection; refused while a gizmo that keeps its selection is open. A person's pick shows Prepare and selects there.",
"group": "Object",
"icon": "",
"key": "select_all",
"title": "Select All Objects"
},
{
"args": {
"none": true
},
"description": "Clear the selection in the 3D view (the assemble view while it is shown, else Prepare, switching to it), close the open gizmo, and reply with the selection. A person's pick clears it where it is, switching no tab.",
"group": "Object",
"icon": "",
"key": "deselect_all",
"title": "Deselect All"
}
],
"completion": "immediate",
"description": "Select objects, instances or parts in the 3D view (the assemble view while it is shown, else Prepare, switching to it), as clicking them would. Give objects, instances ([[object, instance], ...]) or parts ([[object, part], ...]); add keeps the current selection; all / none select everything or nothing, whatever else is given; none also closes the open gizmo, as Deselect All does, and all is refused while a gizmo that keeps its selection is open. The reply is the selection as app_state.selection gives it, for all and none alone (Select All and Deselect All) too.",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"add": {
"description": "Add to the selection instead of replacing it.",
"type": "boolean"
},
"all": {
"description": "Select all objects.",
"type": "boolean"
},
"instance_object_ids": {
"description": "The ids object_list reports for the objects of instances, one per entry: refused when a pair names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"instances": {
"description": "[[object, instance], ...]",
"items": {
"type": "array"
},
"type": "array"
},
"none": {
"description": "Clear the selection and close the open gizmo.",
"type": "boolean"
},
"object_ids": {
"description": "The ids object_list reports for objects, one per entry: refused when an index names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"objects": {
"description": "Object indices.",
"items": {
"type": "integer"
},
"type": "array"
},
"part_ids": {
"description": "The ids object_list reports for the entries of parts, one per entry: refused when a pair names another part now.",
"items": {
"type": "integer"
},
"type": "array"
},
"parts": {
"description": "[[object, part], ...]",
"items": {
"type": "array"
},
"type": "array"
}
},
"type": "object"
},
"key": "object_select",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Select objects"
},
{
"completion": "immediate",
"description": "Change one instance's placement, or one part's with part. translate is in mm, position where it goes (mm, as the Move panel shows it, whatever mode says), rotate in degrees about X/Y/Z, scale a factor (one number or [x, y, z]), size [x, y, z] mm along the object's or part's own axes, plate moves the instance onto that plate at the same place. mode \"relative\" (default) adds to the current placement (a scale multiplies it), \"absolute\" sets it. An instance is dropped back onto the bed, unless its object's auto_drop is off; drop_to_bed false lets it sink into the bed, but an object of one part left above the bed still drops. A part moves as the Object manipulation panel moves it: translate and rotate along the bed's axes, measured on instance 0, scale and size along its own axes; every instance shows the change, and Auto Drop may lower the object afterwards. The instance is the object's instance (default 0) and the part one of its parts; with no object, the instance or part selected in the Prepare view, or instance 0 of the object selected. One undo step. Reply: the instance's offset, scale and plate, or the part's size along its own axes and its object_list entry (part_info), and what it moved (instances or parts).",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"drop_to_bed": {
"description": "Default true; instances only.",
"type": "boolean"
},
"instance": {
"description": "An instance of the object (object_list).",
"minimum": 0,
"type": "integer"
},
"mode": {
"description": "Default relative.",
"enum": [
"relative",
"absolute"
],
"type": "string"
},
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"part": {
"description": "A part of the object (object_list).",
"minimum": 0,
"type": "integer"
},
"part_id": {
"description": "The id object_list reports for this part: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"plate": {
"description": "Move the instance to this plate.",
"minimum": 0,
"type": "integer"
},
"position": {
"description": "[x, y, z] mm: the position to move to. Not with translate.",
"items": {
"type": "number"
},
"type": "array"
},
"rotate": {
"description": "[x, y, z] degrees; relative only for a part",
"items": {
"type": "number"
},
"type": "array"
},
"scale": {
"description": "Factor or [x, y, z] factors.",
"type": [
"number",
"array"
]
},
"size": {
"description": "[x, y, z] mm, null keeps an axis; one number and two nulls keep the proportions. Not with scale.",
"items": {
"type": [
"number",
"null"
]
},
"type": "array"
},
"translate": {
"description": "[x, y, z] mm",
"items": {
"type": "number"
},
"type": "array"
}
},
"type": "object"
},
"key": "object_transform",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Move, rotate or scale an instance or a part"
},
{
"actions": [
{
"args": {
"shape": "cube"
},
"description": "Add a cube object to the current plate at the size its dialog asks for; fails while an object is selected. object_add_primitive with a size, or silent, skips the dialog.",
"group": "Add Primitive",
"icon": "menu_obj_cube",
"key": "add_primitive_cube",
"title": "Cube"
},
{
"args": {
"shape": "cylinder"
},
"description": "Add a cylinder object to the current plate at the size its dialog asks for; fails while an object is selected. object_add_primitive with a size, or silent, skips the dialog. The shape may then be turned toward the part-cooling fan, so the size is along its own axes before that turn.",
"group": "Add Primitive",
"icon": "menu_obj_cylinder",
"key": "add_primitive_cylinder",
"title": "Cylinder"
},
{
"args": {
"shape": "sphere"
},
"description": "Add a sphere object to the current plate at the size its dialog asks for; fails while an object is selected. object_add_primitive with a size, or silent, skips the dialog.",
"group": "Add Primitive",
"icon": "menu_obj_sphere",
"key": "add_primitive_sphere",
"title": "Sphere"
},
{
"args": {
"shape": "cone"
},
"description": "Add a cone object to the current plate at the size its dialog asks for; fails while an object is selected. object_add_primitive with a size, or silent, skips the dialog. The shape may then be turned toward the part-cooling fan, so the size is along its own axes before that turn.",
"group": "Add Primitive",
"icon": "menu_obj_cone",
"key": "add_primitive_cone",
"title": "Cone"
},
{
"args": {
"shape": "disc"
},
"description": "Add a disc object to the current plate at the size its dialog asks for; fails while an object is selected. object_add_primitive with a size, or silent, skips the dialog. The shape may then be turned toward the part-cooling fan, so the size is along its own axes before that turn.",
"group": "Add Primitive",
"icon": "menu_obj_disc",
"key": "add_primitive_disc",
"title": "Disc"
},
{
"args": {
"shape": "torus"
},
"description": "Add a torus object to the current plate at the size its dialog asks for; fails while an object is selected. object_add_primitive with a size, or silent, skips the dialog. The shape may then be turned toward the part-cooling fan, so the size is along its own axes before that turn.",
"group": "Add Primitive",
"icon": "menu_obj_torus",
"key": "add_primitive_torus",
"title": "Torus"
}
],
"completion": "immediate",
"description": "Add a primitive shape (cube, cylinder, sphere, cone, disc or torus) as a new object, as Add Primitive does: on the current plate, or on plate, which becomes the current one; at position, in the bed coordinates object_list and object_transform use, else where Add Primitive puts it; named name, else after its shape. With a size, at that size; with silent, at the shape's built-in size. With shape alone, as its Speed Dial actions, the Primitive size dialog asks for the size (blocked_by_dialog), unless a person turned that dialog off, and the call is refused while an object is selected (part_add adds a shape to an object); any other call adds the object whatever is selected. One undo step; the new object is selected. Reply: the object (objects, object), its plate and offset. The shape may then be turned toward the part-cooling fan, so the size is along its own axes before that turn.",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"not": {
"enum": [
{
"shape": "cube"
},
{
"shape": "cylinder"
},
{
"shape": "sphere"
},
{
"shape": "cone"
},
{
"shape": "disc"
},
{
"shape": "torus"
}
]
}
},
"properties": {
"name": {
"description": "The object's name. Default: its shape's.",
"type": "string"
},
"plate": {
"description": "The plate to add it on. Default: the current plate.",
"minimum": 0,
"type": "integer"
},
"position": {
"description": "[x, y, z] mm: where its first instance goes, as object_transform's position; it then rests on the bed.",
"items": {
"type": "number"
},
"type": "array"
},
"shape": {
"description": "The shape.",
"enum": [
"cube",
"cylinder",
"sphere",
"cone",
"disc",
"torus"
],
"type": "string"
},
"silent": {
"description": "true runs the command without asking; it then needs shape, and what else the call leaves out takes its default. A call with exactly a Speed Dial action's arguments does what a person's pick of that action does.",
"enum": [
true
],
"type": "boolean"
},
"size": {
"description": "mm, the Primitive size dialog's fields, in place of the dialog: cube [x, y, z]; cylinder, cone, disc [diameter, height]; sphere [diameter]; torus [inner diameter, tube diameter]; each above 0.",
"items": {
"type": "number"
},
"type": "array"
}
},
"then": {
"required": [
"shape"
]
},
"type": "object"
},
"key": "object_add_primitive",
"listed": true,
"open_world": false,
"operations": [
"add_primitive",
"rename_object"
],
"read_only": false,
"title": "Add a primitive"
},
{
"actions": [
{
"args": {
"model": "orca_cube"
},
"description": "Add the Orca Cube and its plug to the current plate, then arrange the objects as the toolbar's Arrange does, which moves the others too.",
"group": "Add Handy models",
"icon": "",
"key": "add_handy_orca_cube",
"title": "Orca Cube"
},
{
"args": {
"model": "orcasliced_combo"
},
"description": "Add the OrcaSliced Combo (the OrcaSliced model, the Orca Cube and its plug) to the current plate, then arrange the objects as the toolbar's Arrange does, which moves the others too.",
"group": "Add Handy models",
"icon": "",
"key": "add_handy_orcasliced_combo",
"title": "OrcaSliced Combo"
},
{
"args": {
"model": "orca_badge"
},
"description": "Add the Orca Badge model to the current plate.",
"group": "Add Handy models",
"icon": "",
"key": "add_handy_orca_badge",
"title": "Orca Badge"
},
{
"args": {
"model": "orca_tolerance_test"
},
"description": "Add the Orca Tolerance Test model to the current plate.",
"group": "Add Handy models",
"icon": "",
"key": "add_handy_orca_tolerance_test",
"title": "Orca Tolerance Test"
},
{
"args": {
"model": "3dbenchy"
},
"description": "Add the 3DBenchy model to the current plate.",
"group": "Add Handy models",
"icon": "",
"key": "add_handy_3dbenchy",
"title": "3DBenchy"
},
{
"args": {
"model": "cali_cat"
},
"description": "Add the Cali Cat model to the current plate.",
"group": "Add Handy models",
"icon": "",
"key": "add_handy_cali_cat",
"title": "Cali Cat"
},
{
"args": {
"model": "autodesk_fdm_test"
},
"description": "Add the Autodesk FDM Test model to the current plate.",
"group": "Add Handy models",
"icon": "",
"key": "add_handy_autodesk_fdm_test",
"title": "Autodesk FDM Test"
},
{
"args": {
"model": "voron_cube"
},
"description": "Add the Voron Cube model to the current plate.",
"group": "Add Handy models",
"icon": "",
"key": "add_handy_voron_cube",
"title": "Voron Cube"
},
{
"args": {
"model": "stanford_bunny"
},
"description": "Add the Stanford Bunny model to the current plate.",
"group": "Add Handy models",
"icon": "",
"key": "add_handy_stanford_bunny",
"title": "Stanford Bunny"
},
{
"args": {
"model": "orca_string_hell"
},
"description": "Add the Orca String Hell model to the current plate.",
"group": "Add Handy models",
"icon": "",
"key": "add_handy_orca_string_hell",
"title": "Orca String Hell"
}
],
"completion": "immediate",
"description": "Add one of the test models OrcaSlicer ships to the current plate, as Add Handy models does; orca_cube and orcasliced_combo, of several files, then arrange the objects as the toolbar's Arrange does, which moves the others too.",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"model": {
"description": "The model.",
"enum": [
"orca_cube",
"orcasliced_combo",
"orca_badge",
"orca_tolerance_test",
"3dbenchy",
"cali_cat",
"autodesk_fdm_test",
"voron_cube",
"stanford_bunny",
"orca_string_hell"
],
"type": "string"
}
},
"required": [
"model"
],
"type": "object"
},
"key": "object_add_handy_model",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Add a handy model"
},
{
"actions": [
{
"args": {},
"description": "Add a text: a part on the selected object, or a new object when nothing is selected. It is created in the background (app_wait {for: \"idle\"} waits for it), and the Text gizmo opens on it.",
"group": "Add Primitive",
"icon": "menu_obj_text",
"key": "add_primitive_text",
"title": "Text"
}
],
"completion": "immediate",
"description": "Add a text: a part on the selected object, or a new object when nothing is selected. It is created in the background (app_wait {for: \"idle\"} waits for it), and the Text gizmo opens on it. With object, the text becomes a part of that object, which is selected first; type makes it a negative part or a modifier, as the object's Add menu does.",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"type": {
"description": "The part's type, as the object's Add menu offers it. Default part. Without object, on the selected object.",
"enum": [
"part",
"negative",
"modifier"
],
"type": "string"
}
},
"type": "object"
},
"key": "object_add_text",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Text"
},
{
"actions": [
{
"args": {},
"description": "Add an SVG as a new object, or as a part of the selected object, from the file a dialog asks for; object_add_svg with a path uses that file without one. The part is created in the background (app_wait {for: \"idle\"} waits for it), and the SVG gizmo opens on it.",
"group": "Add Primitive",
"icon": "menu_obj_svg",
"key": "add_primitive_svg",
"title": "SVG"
}
],
"completion": "immediate",
"description": "Add an SVG as a new object, or as a part of the selected object. With a path, uses that file without a dialog; the part is created in the background (app_wait {for: \"idle\"} waits for it), and the SVG gizmo opens on it. With object, the SVG becomes a part of that object, which is selected first; type makes it a negative part or a modifier, as the object's Add menu does. Without path the file dialog opens, as the action's does, and the object and type apply to the file picked there.",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"path": {
"description": "Absolute path of an .svg file.",
"type": "string"
},
"type": {
"description": "The part's type, as the object's Add menu offers it. Default part. Without object, on the selected object.",
"enum": [
"part",
"negative",
"modifier"
],
"type": "string"
}
},
"type": "object"
},
"key": "object_add_svg",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "SVG"
},
{
"actions": [
{
"args": {},
"description": "Delete the selected objects or parts.",
"group": "Object",
"icon": "delete",
"key": "obj_delete",
"title": "Delete Selected"
},
{
"args": {
"all": true
},
"description": "Delete all objects.",
"group": "Object",
"icon": "delete",
"key": "obj_delete_all",
"title": "Delete All Objects"
}
],
"completion": "immediate",
"description": "Delete objects, instances or parts, as Delete does: those named (objects, instances, parts), what stands on a plate (plate: its objects, or the instances on it of an object on two plates), every object (all, as Delete All does), or with none of these what is selected in the Prepare view. An object whose every instance or every part is named goes whole. An object's last solid part alone, and a cut object or a solid or negative part of one, are refused with the message or the question Delete gives; a call with no arguments leaves them to the object list, which shows the message or asks the question (blocked_by_dialog), and all deletes cut objects without asking, as Delete All does. One undo step. Reply: what was deleted (objects, instances, parts, with the indices they had); kept, what was named and stayed, with its indices now (the object list deletes from the last named and stops at what it refuses or asks about); and object_count, the objects left; the objects after a deleted one move down.",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"all": {
"description": "Delete every object. Default false: the targets.",
"type": "boolean"
},
"instance_object_ids": {
"description": "The ids object_list reports for the objects of instances, one per entry: refused when a pair names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"instances": {
"description": "[[object, instance], ...]",
"items": {
"type": "array"
},
"type": "array"
},
"object_ids": {
"description": "The ids object_list reports for objects, one per entry: refused when an index names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"objects": {
"description": "Object indices.",
"items": {
"type": "integer"
},
"type": "array"
},
"part_ids": {
"description": "The ids object_list reports for the entries of parts, one per entry: refused when a pair names another part now.",
"items": {
"type": "integer"
},
"type": "array"
},
"parts": {
"description": "[[object, part], ...]",
"items": {
"type": "array"
},
"type": "array"
},
"plate": {
"description": "Delete what stands on this plate.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the command without asking; what the call leaves out takes its default. A call with no arguments, or with exactly a Speed Dial action's arguments, does what a person's pick of that action does.",
"enum": [
true
],
"type": "boolean"
}
},
"type": "object"
},
"key": "object_delete",
"listed": true,
"open_world": false,
"operations": [
"delete_objects"
],
"read_only": false,
"title": "Delete objects"
},
{
"actions": [
{
"args": {},
"description": "Rename the selected object or part (select one) in the Rename dialog; object_rename with a name skips it.",
"group": "Object",
"icon": "",
"key": "obj_rename",
"title": "Rename"
}
],
"completion": "immediate",
"description": "Rename an object, or a part of it (object and part), or with neither the object or part selected in the Prepare view. With a name, skips the Rename dialog; an empty name, or one with characters a file name cannot hold, is refused. Reply: what was renamed, with its name (objects or parts).",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"name": {
"description": "The new name, in place of the Rename dialog.",
"type": "string"
},
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"part": {
"description": "A part of the object (object_list).",
"minimum": 0,
"type": "integer"
},
"part_id": {
"description": "The id object_list reports for this part: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the command without asking; it then needs name, and what else the call leaves out takes its default. A call with no arguments does what a person's pick does.",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"name"
]
},
"type": "object"
},
"key": "object_rename",
"listed": true,
"open_world": false,
"operations": [
"rename_object"
],
"read_only": false,
"title": "Rename"
},
{
"actions": [
{
"args": {},
"description": "Give the selected object the number of instances the dialog asks for, in one undo step; object_set_instances with a count skips the dialog. New instances overlap; arrange afterwards.",
"group": "Object",
"icon": "instance_add",
"key": "obj_set_instances",
"title": "Set Number of Instances"
},
{
"args": {
"delta": 1
},
"description": "Add an instance of the selected object.",
"group": "Object",
"icon": "instance_add",
"key": "obj_instances_up",
"title": "Increase Instances"
},
{
"args": {
"delta": -1
},
"description": "Remove an instance of the selected object.",
"group": "Object",
"icon": "instance_remove",
"key": "obj_instances_down",
"title": "Decrease Instances"
}
],
"completion": "immediate",
"description": "Give an object this many instances (count), as Set Number of Instances does, or one more or one fewer (delta 1 or -1), as the toolbar's + and - do: the object named, else the one selected in the Prepare view, or the object of the selected instance or part. With no arguments the dialog asks for the count (blocked_by_dialog). New instances overlap; arrange afterwards. One undo step; the object is selected. Reply: the object (objects, object) and instances, how many it has.",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"count": {
"description": "The total number of instances, up to 1000, in place of the dialog.",
"minimum": 1,
"type": "integer"
},
"delta": {
"description": "1 adds an instance and -1 removes one, as the toolbar's + and - do.",
"enum": [
1,
-1
],
"type": "integer"
},
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the command without asking; it then needs count or delta. A call with no arguments, or with exactly an action's arguments, does what a person's pick of that action does.",
"enum": [
true
],
"type": "boolean"
}
},
"type": "object"
},
"key": "object_set_instances",
"listed": true,
"open_world": false,
"operations": [
"set_instance_count"
],
"read_only": false,
"title": "Set the number of instances"
},
{
"actions": [
{
"args": {},
"description": "Make each instance of the selected object a separate object (object_select {objects: [n]}); with some of its instances selected, only those. New objects are added last; the reply lists the objects that hold those instances (objects).",
"group": "Object",
"icon": "",
"key": "obj_instances_to_objects",
"title": "Set as Individual Objects"
}
],
"completion": "immediate",
"description": "Make each instance of an object a separate object (object), or some instances of one object one new object (instances), as Set as Individual Objects does; with neither, what is selected in the Prepare view: an object, or some of its instances. New objects are added last. Reply: the objects that hold those instances afterwards (objects): the object and its new objects, or the new object.",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"instance_object_ids": {
"description": "The ids object_list reports for the objects of instances, one per entry: refused when a pair names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"instances": {
"description": "[[object, instance], ...]",
"items": {
"type": "array"
},
"type": "array"
},
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "object_separate_instances",
"listed": true,
"open_world": false,
"operations": [
"separate_instances"
],
"read_only": false,
"title": "Set as Individual Objects"
},
{
"actions": [
{
"args": {
"into": "objects"
},
"description": "Split the selected object into separate objects.",
"group": "Object",
"icon": "menu_split_objects",
"key": "obj_split_objects",
"title": "Split to Objects"
},
{
"args": {
"into": "parts"
},
"description": "Split the selected object into parts.",
"group": "Object",
"icon": "menu_split_parts",
"key": "obj_split_parts",
"title": "Split to Parts"
}
],
"completion": "immediate",
"description": "Split an object into separate objects, or into parts of it, as Split > To Objects and To Parts do: the object named, else the one row selected in the object list, as Split reads it: an object's row, into objects also a row of the object's own other than a part's, and into parts a part's row, or another row of the object. A mesh of one shell is refused, and into parts so is an object of several parts, whose part is selected to split it. Into objects, the object is removed and its pieces are added last and selected. Where some of them would float above the bed of an object that drops, keep_z answers the question Split asks (true keeps their height, false lets them drop), and without it the call is refused (auto_drop_question); with only an action's arguments Split asks it (blocked_by_dialog). One undo step. Reply: the new objects (objects) or the parts the part became (parts), with their indices afterwards, and object_count.",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"not": {
"enum": [
{
"into": "objects"
},
{
"into": "parts"
}
]
}
},
"properties": {
"into": {
"description": "Separate objects, or parts of the object.",
"enum": [
"objects",
"parts"
],
"type": "string"
},
"keep_z": {
"description": "Into objects, the answer to the question whether pieces that would float above the bed keep their height: true keeps it, false lets them drop.",
"type": "boolean"
},
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the command without asking; it then needs into, and what else the call leaves out takes its default. A call with exactly a Speed Dial action's arguments does what a person's pick of that action does.",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"into"
]
},
"type": "object"
},
"key": "object_split",
"listed": true,
"open_world": false,
"operations": [
"split_object"
],
"read_only": false,
"title": "Split an object"
},
{
"actions": [
{
"args": {},
"description": "Assemble two or more selected objects into one object of parts named Assembly. They are removed and it is added last, so object indices change; the reply has its index (object) and name.",
"group": "Object",
"icon": "",
"key": "obj_assemble",
"title": "Assemble"
}
],
"completion": "immediate",
"description": "Assemble two or more objects into one object of parts named Assembly, as Assemble does: those named, else the object and instance rows selected in the object list, an instance becoming an object of its own first. Cut objects are refused. They are removed and the new object is added last and selected, so object indices change. One undo step. Reply: the new object's index (object) and name, and objects.",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"object_ids": {
"description": "The ids object_list reports for objects, one per entry: refused when an index names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"objects": {
"description": "Object indices.",
"items": {
"type": "integer"
},
"type": "array"
}
},
"type": "object"
},
"key": "object_assemble",
"listed": true,
"open_world": false,
"operations": [
"assemble_objects"
],
"read_only": false,
"title": "Assemble"
},
{
"actions": [
{
"args": {
"by": "name"
},
"description": "Order the current plate's objects by name, which sets the object list and print order, as the plate menu's Order By does. Choosing the order they already have reverses it. Object indices change; the reply lists the new order (order: [{object, name, plate}]) and descending.",
"group": "Object",
"icon": "",
"key": "obj_order_by_name",
"title": "Order by Name"
},
{
"args": {
"by": "filament"
},
"description": "Order the current plate's objects by filament, which sets the object list and print order, as the plate menu's Order By does. Choosing the order they already have reverses it. Object indices change; the reply lists the new order (order: [{object, name, plate}]) and descending.",
"group": "Object",
"icon": "",
"key": "obj_order_by_filament",
"title": "Order by Filament"
},
{
"args": {
"by": "height"
},
"description": "Order the current plate's objects by height, which sets the object list and print order, as the plate menu's Order By does. Choosing the order they already have reverses it. Object indices change; the reply lists the new order (order: [{object, name, plate}]) and descending.",
"group": "Object",
"icon": "",
"key": "obj_order_by_height",
"title": "Order by Height"
},
{
"args": {
"by": "size"
},
"description": "Order the current plate's objects by size (bounding box volume), which sets the object list and print order, as the plate menu's Order By does. Choosing the order they already have reverses it. Object indices change; the reply lists the new order (order: [{object, name, plate}]) and descending.",
"group": "Object",
"icon": "",
"key": "obj_order_by_size",
"title": "Order by Size"
}
],
"completion": "immediate",
"description": "Order the objects of a plate (the current one, or plate), or with all of every plate, by name, filament, height or size (bounding box volume), which sets the object list and print order, as the plate menu's Order By does: ascending, or with descending true descending. Called with by alone, as its Speed Dial actions, it shows the Prepare view and, as Order By does, reverses the order the objects already have. With order in place of by, the plate's objects go in the order given, as dragging them in the object list puts them: order names each of the plate's objects once, by index, and anything else is refused; the other plates' objects keep their order. One undo step, none when the order stays as it was; object indices change. Reply: the new order (order: [{object, name, plate}]), and descending with by.",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"all": {
"description": "With by: order the objects of every plate. Default false: one plate's.",
"type": "boolean"
},
"by": {
"description": "What to order by.",
"enum": [
"name",
"filament",
"height",
"size"
],
"type": "string"
},
"descending": {
"description": "With by: descending order. Default false.",
"type": "boolean"
},
"order": {
"description": "In place of by: the plate's objects, by index (object_list), each once, in the order wanted.",
"items": {
"minimum": 0,
"type": "integer"
},
"minItems": 1,
"type": "array"
},
"plate": {
"description": "Order this plate's objects. Default: the current plate.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "object_order",
"listed": true,
"open_world": false,
"operations": [
"order_objects",
"reorder_objects"
],
"read_only": false,
"title": "Order objects"
},
{
"actions": [
{
"args": {},
"description": "Drop the selection onto the bed.",
"group": "Object",
"icon": "toolbar_flatten",
"key": "obj_drop",
"title": "Drop to Bed"
}
],
"completion": "immediate",
"description": "Drop objects or parts onto the bed, as Drop does: those named, each instance and each part that does not rest on the bed dropped on its own, else what is selected in the Prepare view, dropped as one by its lowest point. What already rests on the bed is no error: moved false says that nothing moved. One undo step; the targets are left selected. Reply: what it acted on (objects, instances, parts) and moved.",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"object_ids": {
"description": "The ids object_list reports for objects, one per entry: refused when an index names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"objects": {
"description": "Object indices.",
"items": {
"type": "integer"
},
"type": "array"
},
"part_ids": {
"description": "The ids object_list reports for the entries of parts, one per entry: refused when a pair names another part now.",
"items": {
"type": "integer"
},
"type": "array"
},
"parts": {
"description": "[[object, part], ...]",
"items": {
"type": "array"
},
"type": "array"
}
},
"type": "object"
},
"key": "object_drop",
"listed": true,
"open_world": false,
"operations": [
"drop_objects"
],
"read_only": false,
"title": "Drop to Bed"
},
{
"actions": [
{
"args": {
"axis": "x"
},
"description": "Mirror the selection along X.",
"group": "Object",
"icon": "menu_mirror_x",
"key": "obj_mirror_x",
"title": "Mirror X"
},
{
"args": {
"axis": "y"
},
"description": "Mirror the selection along Y.",
"group": "Object",
"icon": "menu_mirror_y",
"key": "obj_mirror_y",
"title": "Mirror Y"
},
{
"args": {
"axis": "z"
},
"description": "Mirror the selection along Z.",
"group": "Object",
"icon": "menu_mirror_z",
"key": "obj_mirror_z",
"title": "Mirror Z"
}
],
"completion": "immediate",
"description": "Mirror objects or parts along an axis, as Mirror > Along X Axis, Y Axis and Z Axis do: those named, each instance of an object and the parts of each object in turn, else what is selected in the Prepare view, which Mirror takes of one instance or parts of one. Cut objects are refused. One undo step; the targets are left selected. Reply: what it mirrored (objects, instances, parts).",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"axis": {
"description": "The axis to mirror along.",
"enum": [
"x",
"y",
"z"
],
"type": "string"
},
"object_ids": {
"description": "The ids object_list reports for objects, one per entry: refused when an index names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"objects": {
"description": "Object indices.",
"items": {
"type": "integer"
},
"type": "array"
},
"part_ids": {
"description": "The ids object_list reports for the entries of parts, one per entry: refused when a pair names another part now.",
"items": {
"type": "integer"
},
"type": "array"
},
"parts": {
"description": "[[object, part], ...]",
"items": {
"type": "array"
},
"type": "array"
}
},
"required": [
"axis"
],
"type": "object"
},
"key": "object_mirror",
"listed": true,
"open_world": false,
"operations": [
"mirror_objects"
],
"read_only": false,
"title": "Mirror objects"
},
{
"actions": [
{
"args": {},
"description": "Center the selection on its plate.",
"group": "Object",
"icon": "",
"key": "obj_center",
"title": "Center Selected on Plate"
}
],
"completion": "immediate",
"description": "Centre objects on their plate, as Center does: those named, each plate's as one group on the plate it stands on (an object on no plate goes with the current plate's), or all on plate; with none named, what is selected in the Prepare view as one group, on plate, or with no arguments, as its Speed Dial action, on the current plate. A group moves as one, its box to the plate's centre, its objects keeping their places relative to each other, so a group spread over several plates and sent to plate may not fit on its bed. One undo step; the targets are left selected. Reply: what it centred (objects, instances, parts) and the groups (plates: [{plate, objects}]).",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"object_ids": {
"description": "The ids object_list reports for objects, one per entry: refused when an index names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"objects": {
"description": "Object indices.",
"items": {
"type": "integer"
},
"type": "array"
},
"plate": {
"description": "Centre them all on this plate.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "object_center",
"listed": true,
"open_world": false,
"operations": [
"center_objects"
],
"read_only": false,
"title": "Center Selected on Plate"
},
{
"actions": [
{
"args": {},
"description": "Scale the selection to fit the print volume.",
"group": "Object",
"icon": "",
"key": "obj_fit_volume",
"title": "Scale to Fit Print Volume"
}
],
"completion": "immediate",
"description": "Scale objects as one to fit the current plate's print volume and move them into it, as Scale to build volume does: those named, else the objects and instances selected in the Prepare view. Cut objects and a bed of another shape than a rectangle or a circle are refused. One undo step; the targets are left selected. Reply: what it scaled (objects, instances) and each instance's scale (scales: [{object, instance, scale}]).",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"object_ids": {
"description": "The ids object_list reports for objects, one per entry: refused when an index names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"objects": {
"description": "Object indices.",
"items": {
"type": "integer"
},
"type": "array"
}
},
"type": "object"
},
"key": "object_scale_to_fit",
"listed": true,
"open_world": false,
"operations": [
"scale_to_fit"
],
"read_only": false,
"title": "Scale to Fit Print Volume"
},
{
"actions": [
{
"args": {},
"description": "Auto-orient the selection, or every object when nothing is selected; the call returns when it is done.",
"group": "Object",
"icon": "toolbar_orient",
"key": "obj_orient",
"title": "Auto-Orient"
}
],
"completion": "immediate",
"description": "Turn objects to the orientation that prints best, as Auto-Orient does: those named and those that stand on plates, else what is selected in the Prepare view, an instance or a part standing for its object, or every object when nothing is selected. An object on a locked plate, or one that is not printable, keeps its orientation. A call that names objects or plates turns no other object: a plate named that holds no objects, a locked plate named, and objects named none of which can be turned (not printable, or on a locked plate) are refused. A selection of objects that are not printable, none on a locked plate, leaves the job to turn every other object, as the toolbar's does. Waits for the job to end. One undo step; objects named are left selected. Reply: the objects it turned (objects) and the rotation of each instance it turned (rotations: [{object, instance, rotation_deg}]).",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"object_ids": {
"description": "The ids object_list reports for objects, one per entry: refused when an index names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"objects": {
"description": "Object indices.",
"items": {
"type": "integer"
},
"type": "array"
},
"plates": {
"description": "Plate indices: orient the objects that stand on them.",
"items": {
"type": "integer"
},
"type": "array"
}
},
"type": "object"
},
"key": "object_auto_orient",
"listed": true,
"open_world": false,
"operations": [
"orient_objects"
],
"read_only": false,
"title": "Auto-Orient"
},
{
"completion": "immediate",
"description": "Mark objects, or some of their instances, printable or not, as the object list's Printable cell does: those named (objects: every instance of each; instances: those alone), else what is selected in the Prepare view. An instance that is not printable is greyed in the 3D view and left out of slicing. One undo step. Reply: every instance it set, with printable (instances), and the objects named (objects).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"count": 3,
"object": 0
},
"tool": "object_set_instances"
},
{
"args": {
"instances": [
[
0,
1
]
],
"printable": false
},
"tool": "object_set_printable"
}
],
"title": "Leave one instance out of the print"
},
{
"calls": [
{
"args": {
"printable": true
},
"tool": "object_set_printable"
}
],
"title": "Print the selected objects again"
}
],
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"instance_object_ids": {
"description": "The ids object_list reports for the objects of instances, one per entry: refused when a pair names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"instances": {
"description": "[[object, instance], ...]",
"items": {
"type": "array"
},
"type": "array"
},
"object_ids": {
"description": "The ids object_list reports for objects, one per entry: refused when an index names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"objects": {
"description": "Object indices.",
"items": {
"type": "integer"
},
"type": "array"
},
"printable": {
"description": "true marks them printable, false not printable.",
"type": "boolean"
}
},
"required": [
"printable"
],
"type": "object"
},
"key": "object_set_printable",
"listed": true,
"open_world": false,
"operations": [
"set_objects_printable"
],
"read_only": false,
"title": "Set printable"
},
{
"completion": "immediate",
"description": "Turn Auto Drop on or off for objects, as the 3D view's Auto Drop does: those named, else the objects of what is selected in the Prepare view, an instance or a part standing for its object. With it off an object stays where object_transform or the Move gizmo leaves it, above the bed; with it on it drops onto the bed when it is next moved. An object's instances share it. One undo step. Reply: the objects (objects) and auto_drop.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"auto_drop": false,
"objects": [
0
]
},
"tool": "object_set_auto_drop"
}
],
"title": "Let an object stay above the bed where it is moved to"
},
{
"calls": [
{
"args": {
"auto_drop": true
},
"tool": "object_set_auto_drop"
}
],
"title": "Let the selected objects drop onto the bed again"
}
],
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"auto_drop": {
"description": "true lets the objects drop onto the bed, false lets them stay above it.",
"type": "boolean"
},
"object_ids": {
"description": "The ids object_list reports for objects, one per entry: refused when an index names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"objects": {
"description": "Object indices.",
"items": {
"type": "integer"
},
"type": "array"
}
},
"required": [
"auto_drop"
],
"type": "object"
},
"key": "object_set_auto_drop",
"listed": true,
"open_world": false,
"operations": [
"set_objects_auto_drop"
],
"read_only": false,
"title": "Set Auto Drop"
},
{
"completion": "immediate",
"description": "Repair objects' meshes, as Fix Model does: those named (objects whole, or parts), the objects on a plate (plate, as Fix All on the current plate), every object (all), else what is selected in the Prepare view, an instance standing for its object. A painted modifier is left as it is, and painting is kept only with the keep_painting preference on. It opens no progress dialog and shows no notification; the call waits for the repair, during which the window does not redraw, and job_cancel {job} cancels it: the call fails with the reply in its details, and what was repaired before the cancel, a part of the object it stopped in among them, keeps its new mesh. Refused while a gizmo is open. One undo step. Reply: what it repaired (objects, parts) and repairs, for each in turn: changed, failed (why it could not be repaired), the object's mesh_errors_before and mesh_errors_after (as object_list gives them), painting_removed, and cancelled: true on the one a cancel stopped, listed when its mesh had changed by then.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {},
"tool": "object_list"
},
{
"args": {
"objects": [
0
]
},
"tool": "object_fix"
}
],
"title": "Repair an imported object whose mesh has holes"
},
{
"calls": [
{
"args": {
"plate": 0
},
"tool": "object_fix"
}
],
"title": "Repair the objects on the first plate"
}
],
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"all": {
"description": "Repair every object. Default false: the targets.",
"type": "boolean"
},
"object_ids": {
"description": "The ids object_list reports for objects, one per entry: refused when an index names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"objects": {
"description": "Object indices.",
"items": {
"type": "integer"
},
"type": "array"
},
"part_ids": {
"description": "The ids object_list reports for the entries of parts, one per entry: refused when a pair names another part now.",
"items": {
"type": "integer"
},
"type": "array"
},
"parts": {
"description": "[[object, part], ...]",
"items": {
"type": "array"
},
"type": "array"
},
"plate": {
"description": "Repair the objects on this plate.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "object_fix",
"listed": true,
"open_world": false,
"operations": [
"fix_objects"
],
"read_only": false,
"title": "Fix Model"
},
{
"completion": "immediate",
"description": "Make copies of objects as new objects, as the Clone dialog does: those named, else what is selected in the Prepare view (an object whole, or some of its instances, which a copy holds as one new object). count copies of each (default 1, as the dialog's field starts), added after the other objects, placed near them on the current plate; the last copies are left selected. With arrange true the current plate is then arranged, as the dialog's Auto arrange plate after cloning does; without arrange, the dialog's choice: the auto_arrange preference. The call waits for the arrangement. One undo step for the copies, and one for the arrangement. Reply: the new objects (objects), what was copied (copied: its objects, or its instances where instances were selected), object_count and arranged.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"arrange": true,
"count": 3,
"objects": [
0
]
},
"tool": "object_clone"
}
],
"title": "Make three copies of an object and arrange the plate"
},
{
"calls": [
{
"args": {
"arrange": false
},
"tool": "object_clone"
}
],
"title": "Copy the selected objects once, where they are"
}
],
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"arrange": {
"description": "Arrange the current plate afterwards. Default: the Clone dialog's choice, the auto_arrange preference.",
"type": "boolean"
},
"count": {
"description": "Copies of each, up to 1000 as the Clone dialog takes. Default 1.",
"maximum": 1000,
"minimum": 1,
"type": "integer"
},
"object_ids": {
"description": "The ids object_list reports for objects, one per entry: refused when an index names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"objects": {
"description": "Object indices.",
"items": {
"type": "integer"
},
"type": "array"
}
},
"type": "object"
},
"key": "object_clone",
"listed": true,
"open_world": false,
"operations": [
"clone_objects"
],
"read_only": false,
"title": "Clone"
},
{
"completion": "immediate",
"description": "Load parts again from the files they were loaded from, as Reload from disk does: every part of the objects named, the parts named, every object's (all, as Reload All does, cut objects left out), else what is selected in the Prepare view. A part's file is the one it was loaded from, else the file of that name beside its object's file. A part whose file is gone is not asked for: it is listed under missing. A part keeps its settings, type, filament and placement, and its painting when the keep_painting preference is on. Parts loaded from no file (primitives, the built-in models) are left out; cut objects are refused, since a reload would replace a cut part with its whole file, and so is a call while a gizmo is open. One undo step, none when every part's file is missing and nothing is reloaded. Reply: reloaded (parts), missing (with each part's path), unmatched (parts their file holds no part to take for) and unreadable (a file that could not be read, after which nothing more was loaded).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"objects": [
0
]
},
"tool": "object_reload_from_disk"
}
],
"title": "Reload an imported object after its file changed"
},
{
"calls": [
{
"args": {
"all": true
},
"tool": "object_reload_from_disk"
}
],
"title": "Reload every object"
}
],
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"all": {
"description": "Reload every object but the cut ones. Default false: the targets.",
"type": "boolean"
},
"object_ids": {
"description": "The ids object_list reports for objects, one per entry: refused when an index names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"objects": {
"description": "Object indices.",
"items": {
"type": "integer"
},
"type": "array"
},
"part_ids": {
"description": "The ids object_list reports for the entries of parts, one per entry: refused when a pair names another part now.",
"items": {
"type": "integer"
},
"type": "array"
},
"parts": {
"description": "[[object, part], ...]",
"items": {
"type": "array"
},
"type": "array"
}
},
"type": "object"
},
"key": "object_reload_from_disk",
"listed": true,
"open_world": false,
"operations": [
"reload_parts"
],
"read_only": false,
"title": "Reload from disk"
},
{
"actions": [
{
"args": {},
"description": "Arrange all objects on the unlocked plates with the saved Arrange options, as the toolbar does; the call waits for the arrangement and replies as object_arrange does: the settings in force, the instances left off every plate and the plates skipped. object_arrange with arguments also takes options, one plate or fill bed.",
"group": "Object",
"icon": "toolbar_arrange",
"key": "obj_arrange",
"title": "Auto-Arrange"
}
],
"completion": "immediate",
"description": "Arrange the objects of every unlocked plate as the toolbar's Arrange does, or of one plate (plates: an index or \"current\") as its Arrange icon does. With fill_object, fill that object's plate with more of it instead, as Fill bed with instances (or copies, by fill_with) does (reply: added, how many). spacing, rotate, align_y and multi_material are the Arrange options panel's settings: the values given stay in the panel, so later arranges use them too. Waits for the arrangement (a longer one replies with a job). Reply: the settings in force, instances left off every plate, plates the all-plates arrange skipped and the job's notifications. An arrange may reorder objects, so object_list again. One undo step. Called with no arguments it is Auto-Arrange, the toolbar's Arrange with the panel's settings, and waits and replies as any other call.",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"align_y": {
"description": "Align to Y axis (off while rotate is on).",
"type": "boolean"
},
"fill_object": {
"description": "An object index: instead of arranging, fill that object's plate with more of it.",
"minimum": 0,
"type": "integer"
},
"fill_with": {
"description": "Default instances.",
"enum": [
"instances",
"copies"
],
"type": "string"
},
"multi_material": {
"description": "Allow multiple materials on same plate.",
"type": "boolean"
},
"plates": {
"description": "\"all\" (default), \"current\" or a plate index.",
"type": [
"string",
"integer"
]
},
"rotate": {
"description": "Auto rotate for arrangement.",
"type": "boolean"
},
"spacing": {
"description": "mm between objects; 0 means auto.",
"minimum": 0,
"type": "number"
},
"timeout_s": {
"description": "Cancel it after this long (default 300).",
"maximum": 1800,
"minimum": 10,
"type": "integer"
}
},
"type": "object"
},
"key": "object_arrange",
"listed": true,
"open_world": false,
"operations": [
"start_arrange"
],
"read_only": false,
"title": "Arrange objects or fill the bed"
},
{
"completion": "immediate",
"description": "Open a painting gizmo on an object's instance, the first unless instance is given: type supports opens Support Painting, seam Seam Painting, color Color Painting (two filaments or more) and fuzzy_skin Paint-on fuzzy skin. Painting is left to the gizmo: pick a tool and a brush in its panel and paint with mouse_gesture strokes on the model. With no target, it opens on the selection as it is. Read the gizmo's panel with widget_list {include_imgui: true}, set its fields with widget_set_value, press its buttons with widget_click, and click or drag on the model with mouse_gesture; object_select {none: true} closes it. The gizmo already open on the same target stays open. Reply: gizmo (its name, as app_state.gizmo gives it), active, and what is selected (objects, instances, parts).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"object": 0,
"type": "supports"
},
"tool": "object_paint"
}
],
"title": "Paint support enforcers on object 0"
},
{
"calls": [
{
"args": {
"instance": 1,
"object": 1,
"type": "color"
},
"tool": "object_paint"
}
],
"title": "Paint colors on the second instance of object 1"
}
],
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"instance": {
"description": "An instance of the object (object_list).",
"minimum": 0,
"type": "integer"
},
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"type": {
"description": "The painting gizmo to open.",
"enum": [
"supports",
"seam",
"color",
"fuzzy_skin"
],
"type": "string"
}
},
"required": [
"type"
],
"type": "object"
},
"key": "object_paint",
"listed": true,
"open_world": false,
"operations": [
"open_gizmo"
],
"read_only": false,
"title": "Paint on an object"
},
{
"completion": "immediate",
"description": "Open the Measure gizmo on objects, else on the selection as it is (a part selected is measured as a part). Measuring is left to the gizmo: click two features of the model with mouse_gesture (Shift-click for a point) and read the results in its panel. Read the gizmo's panel with widget_list {include_imgui: true}, set its fields with widget_set_value, press its buttons with widget_click, and click or drag on the model with mouse_gesture; object_select {none: true} closes it. The gizmo already open on the same target stays open. Reply: gizmo (its name, as app_state.gizmo gives it), active, and what is selected (objects, instances, parts).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"objects": [
0,
1
]
},
"tool": "object_measure"
}
],
"title": "Measure between objects 0 and 1"
},
{
"calls": [
{
"args": {
"parts": [
[
0,
1
]
]
},
"tool": "object_select"
},
{
"args": {},
"tool": "object_measure"
}
],
"title": "Measure the selected part"
}
],
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"object_ids": {
"description": "The ids object_list reports for objects, one per entry: refused when an index names another object now.",
"items": {
"type": "integer"
},
"type": "array"
},
"objects": {
"description": "Object indices.",
"items": {
"type": "integer"
},
"type": "array"
}
},
"type": "object"
},
"key": "object_measure",
"listed": true,
"open_world": false,
"operations": [
"open_gizmo"
],
"read_only": false,
"title": "Measure"
},
{
"completion": "immediate",
"description": "Open the Simplify gizmo on a part: the part named, else the only part of the object named (an object of several parts needs part), else the selected part. The detail level or ratio and Apply are left to the gizmo. Read the gizmo's panel with widget_list {include_imgui: true}, set its fields with widget_set_value, press its buttons with widget_click, and click or drag on the model with mouse_gesture; object_select {none: true} closes it. The gizmo already open on the same target stays open. Reply: gizmo (its name, as app_state.gizmo gives it), active, and what is selected (objects, instances, parts).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"object": 0
},
"tool": "object_simplify"
}
],
"title": "Simplify object 0, an object of one part"
},
{
"calls": [
{
"args": {
"object": 2,
"part": 1
},
"tool": "object_simplify"
}
],
"title": "Simplify part 1 of object 2"
}
],
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"part": {
"description": "A part of the object (object_list).",
"minimum": 0,
"type": "integer"
},
"part_id": {
"description": "The id object_list reports for this part: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "object_simplify",
"listed": true,
"open_world": false,
"operations": [
"open_gizmo"
],
"read_only": false,
"title": "Simplify Model"
},
{
"completion": "immediate",
"description": "Cut an object's instance, the first unless instance is given, along a plane, as the Cut gizmo's Perform cut does. Acts from arguments: z, plane, keep, upper, lower, to_parts. With none of them it opens the Cut gizmo. z cuts level, that many mm above the bed; plane {point, normal} cuts along any plane, the upper piece being the one the normal points into. keep: both (default), upper or lower. upper and lower place a kept piece: as_cut, place_on_cut (laid on its cut face) or flip; by default the upper piece is laid on its cut face and the lower one stays as cut. to_parts keeps both pieces as two parts of one object, with no placement. A cut is one undo step and replaces the object: its pieces go to the end of the object list, upper first, and the reply gives them as pieces [{index, object_id, name, open_edges}], or with to_parts the object and its parts. A piece with open edges is repaired by object_fix. Connectors, the dovetail and a cut along a contour are left to the gizmo: open it with object_cut naming only the object. Read the gizmo's panel with widget_list {include_imgui: true}, set its fields with widget_set_value, press its buttons with widget_click, and click or drag on the model with mouse_gesture; object_select {none: true} closes it. The gizmo already open on the same target stays open. Reply: gizmo (its name, as app_state.gizmo gives it), active, and what is selected (objects, instances, parts).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"object": 0,
"z": 10
},
"tool": "object_cut"
}
],
"title": "Cut object 0 in two, 10 mm above the bed"
},
{
"calls": [
{
"args": {
"keep": "upper",
"object": 1,
"plane": {
"normal": [
1,
0,
1
],
"point": [
100,
100,
10
]
}
},
"tool": "object_cut"
}
],
"title": "Keep the part of object 1 above a tilted plane"
}
],
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"instance": {
"description": "An instance of the object (object_list).",
"minimum": 0,
"type": "integer"
},
"keep": {
"description": "The pieces kept. Default both.",
"enum": [
"both",
"upper",
"lower"
],
"type": "string"
},
"lower": {
"description": "Where the lower piece goes. Default as_cut.",
"enum": [
"as_cut",
"place_on_cut",
"flip"
],
"type": "string"
},
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"plane": {
"additionalProperties": false,
"description": "Cut along this plane. Not with z.",
"properties": {
"normal": {
"description": "[x, y, z]: the direction the upper piece lies in; any length but zero.",
"items": {
"type": "number"
},
"minItems": 3,
"type": "array"
},
"point": {
"description": "[x, y, z] mm: a point of the plane, in the 3D view's coordinates.",
"items": {
"type": "number"
},
"minItems": 3,
"type": "array"
}
},
"required": [
"point",
"normal"
],
"type": "object"
},
"to_parts": {
"description": "Keep both pieces as two parts of one object, as the gizmo's Cut to parts does. Default false.",
"type": "boolean"
},
"upper": {
"description": "Where the upper piece goes. Default place_on_cut.",
"enum": [
"as_cut",
"place_on_cut",
"flip"
],
"type": "string"
},
"z": {
"description": "mm above the bed: cut level at this height. Not with plane.",
"type": "number"
}
},
"type": "object"
},
"key": "object_cut",
"listed": true,
"open_world": false,
"operations": [
"open_gizmo",
"cut_object"
],
"read_only": false,
"title": "Cut"
},
{
"completion": "immediate",
"description": "Lay an object's instance, the first unless instance is given, on one of its faces, as a click on that face in the Lay on Face gizmo does. Acts from arguments: normal, frame. With none of them it opens the Lay on Face gizmo. normal is the direction the face points out to: in the object's own frame (frame object, the default, where [0, 0, -1] is the face that was its bottom) or in the 3D view's (frame world, where the face points now). The instance turns so that face lies on the bed and drops onto it, one undo step; the object's other instances turn with it. No flat face is looked for: the direction is laid down as given. A call that acts replies object, instance and rotation, the instance's rotation in degrees as object_list gives it. Read the gizmo's panel with widget_list {include_imgui: true}, set its fields with widget_set_value, press its buttons with widget_click, and click or drag on the model with mouse_gesture; object_select {none: true} closes it. The gizmo already open on the same target stays open. Reply: gizmo (its name, as app_state.gizmo gives it), active, and what is selected (objects, instances, parts).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"normal": [
0,
0,
-1
],
"object": 0
},
"tool": "object_lay_on_face"
}
],
"title": "Lay object 0 on the face that points down in its own frame"
},
{
"calls": [
{
"args": {
"frame": "world",
"normal": [
1,
0,
0
],
"object": 0
},
"tool": "object_lay_on_face"
}
],
"title": "Lay object 0 on the face that now points to +X"
}
],
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"frame": {
"description": "The frame normal is in: the object's own (default) or the 3D view's. Needs normal.",
"enum": [
"object",
"world"
],
"type": "string"
},
"instance": {
"description": "An instance of the object (object_list).",
"minimum": 0,
"type": "integer"
},
"normal": {
"description": "[x, y, z]: the direction the face to lay on the bed points out to; any length but zero.",
"items": {
"type": "number"
},
"type": "array"
},
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "object_lay_on_face",
"listed": true,
"open_world": false,
"operations": [
"open_gizmo",
"lay_on_face"
],
"read_only": false,
"title": "Lay on face"
},
{
"completion": "immediate",
"description": "Set an object's brim ears from positions on the bed, as the Brim Ears gizmo places them, through the instance named, the first unless instance is given. Acts from arguments: points, clear. With none of them it opens the Brim Ears gizmo. points replaces the object's ears with those given, each at a bed position, with a radius from 0.1 to 100 mm or the gizmo's default; clear removes them all. The ears are taken on the bed and stored in the object's coordinates, so they are the object's, shared by its instances. One undo step. They print only with the painted brim type: settings_set on the object sets brim_type. A call that acts replies object, ears as stored ({position: [x, y, z] in the object's coordinates, radius}), brim_type, the brim type the object prints with, and takes_effect, whether that is painted. Read the gizmo's panel with widget_list {include_imgui: true}, set its fields with widget_set_value, press its buttons with widget_click, and click or drag on the model with mouse_gesture; object_select {none: true} closes it. The gizmo already open on the same target stays open. Reply: gizmo (its name, as app_state.gizmo gives it), active, and what is selected (objects, instances, parts).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"object": 0,
"target": "object",
"values": {
"brim_type": "painted"
}
},
"tool": "settings_set"
},
{
"args": {
"object": 0,
"points": [
{
"position": [
90,
90
],
"radius": 3
},
{
"position": [
110,
90
]
}
]
},
"tool": "object_set_brim_ears"
}
],
"title": "Paint object 0's brim as two ears at its front corners"
},
{
"calls": [
{
"args": {
"clear": true,
"object": 1
},
"tool": "object_set_brim_ears"
}
],
"title": "Remove object 1's ears"
}
],
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"clear": {
"description": "Remove every ear. Not with points.",
"enum": [
true
],
"type": "boolean"
},
"instance": {
"description": "An instance of the object (object_list).",
"minimum": 0,
"type": "integer"
},
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"points": {
"description": "The ears, in place of the object's.",
"items": {
"additionalProperties": false,
"properties": {
"position": {
"description": "[x, y] mm: where on the bed.",
"items": {
"type": "number"
},
"type": "array"
},
"radius": {
"description": "mm. Default: the gizmo's, eight first-layer line widths.",
"type": "number"
}
},
"required": [
"position"
],
"type": "object"
},
"type": "array"
}
},
"type": "object"
},
"key": "object_set_brim_ears",
"listed": true,
"open_world": false,
"operations": [
"open_gizmo",
"set_brim_ears"
],
"read_only": false,
"title": "Brim ears"
},
{
"completion": "immediate",
"description": "Replace an object's height range modifiers (Height Range Modifier in the object list): Z ranges in mm, each printed with its own layer_height, filament and process settings, which settings_get and settings_set read and write with the target height_range. A range given with the min_z and max_z of one the object has keeps its settings; a new one starts from the object's layer height and filament. Ranges may touch but not overlap; [] removes them all. The object is the one named, else the one selected in the Prepare view. One undo step; the object is selected. Reply: the object (objects, object), its height and its ranges as object_list shows them, with their settings, and warnings, such as a variable layer height profile deciding the layer heights instead.",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"ranges": {
"description": "The object's ranges afterwards, in any order.",
"items": {
"additionalProperties": false,
"properties": {
"max_z": {
"description": "Top, mm above the bed.",
"minimum": 0,
"type": "number"
},
"min_z": {
"description": "Bottom, mm above the bed.",
"minimum": 0,
"type": "number"
}
},
"required": [
"min_z",
"max_z"
],
"type": "object"
},
"type": "array"
}
},
"required": [
"ranges"
],
"type": "object"
},
"key": "object_set_height_ranges",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Set height range modifiers"
},
{
"completion": "immediate",
"description": "Run the Variable layer height panel's Adaptive, Smooth or Reset on an object, without opening the panel: adaptive computes layer heights from the object's shape (inside a height range, the range's layer_height), smooth smooths its profile (or the one its height ranges give), reset goes back to its layer height and ranges. The object is the one named, else the one selected in the Prepare view. One undo step; the object is selected. Reply: the object (objects, object), its height, its layer_height_profile {points, min_height, max_height} as object_list shows it (absent after reset), and warnings.",
"destructive": false,
"group": "Objects",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"action": {
"description": "The panel's button.",
"enum": [
"adaptive",
"smooth",
"reset"
],
"type": "string"
},
"keep_min": {
"description": "smooth: keep the minimum layer heights (default false).",
"type": "boolean"
},
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"quality": {
"description": "adaptive: 0 = quality .. 1 = speed (default 0.5, as the panel).",
"maximum": 1,
"minimum": 0,
"type": "number"
},
"radius": {
"description": "smooth: default 5.",
"maximum": 10,
"minimum": 1,
"type": "integer"
}
},
"required": [
"action"
],
"type": "object"
},
"key": "object_set_variable_layer_height",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Set a variable layer height profile"
},
{
"completion": "immediate",
"description": "Add a part, negative part, modifier, support blocker or enforcer, or precise seam to an object, as its context menu's Add items do: a primitive shape at a size, or a model file as Load... adds it. The part lands where the menu puts it (a shape beside the object, a file at its coordinates relative to the object's first part) unless position is given. Like the menu, adding a shape folds the instance's rotation and scale into the object's parts (the instance's scale then reads 1). Refused for an object with several instances: add parts first. A STEP file may ask for mesh options (blocked_by_dialog). The object is the one named, else the one selected in the Prepare view, or the object of the selected instance or part. The new part is selected; one undo step. Reply: its index, which is not always the last (parts are ordered by type), the object's part count and the part's object_list entry (part_info), and the object (objects).",
"destructive": false,
"group": "Parts",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"path": {
"description": "Instead of shape: absolute path of a model file (STL, OBJ, 3MF, STEP, ...).",
"type": "string"
},
"position": {
"description": "[x, y, z] mm on the bed for the part's centre, on instance 0, as the Move panel shows it.",
"items": {
"type": "number"
},
"type": "array"
},
"shape": {
"description": "A primitive shape.",
"enum": [
"cube",
"cylinder",
"sphere",
"cone",
"disc",
"torus"
],
"type": "string"
},
"size": {
"description": "mm, the Primitive size dialog's fields: cube [x, y, z]; cylinder, cone, disc [diameter, height]; sphere [diameter]; torus [inner diameter, tube diameter]. Default: the built-in size.",
"items": {
"type": "number"
},
"type": "array"
},
"type": {
"description": "What the new part is.",
"enum": [
"part",
"negative",
"modifier",
"support_blocker",
"support_enforcer",
"precise_seam"
],
"type": "string"
}
},
"required": [
"type"
],
"type": "object"
},
"key": "part_add",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Add a part or modifier to an object"
},
{
"actions": [
{
"args": {
"type": "part"
},
"description": "Make the selected parts (object_select {parts} first) solid parts, as Change Type does. Parts are listed by type, so part indices change.",
"group": "Object",
"icon": "",
"key": "obj_type_part",
"title": "Change Type to Part"
},
{
"args": {
"type": "negative"
},
"description": "Make the selected parts negative parts, as Change Type does; not the object's last solid part. Parts are listed by type, so part indices change.",
"group": "Object",
"icon": "",
"key": "obj_type_negative",
"title": "Change Type to Negative Part"
},
{
"args": {
"type": "modifier"
},
"description": "Make the selected parts modifiers, as Change Type does; not the object's last solid part. Parts are listed by type, so part indices change.",
"group": "Object",
"icon": "",
"key": "obj_type_modifier",
"title": "Change Type to Modifier"
},
{
"args": {
"type": "support_blocker"
},
"description": "Make the selected parts support blockers, as Change Type does; not the object's last solid part, nor a text or SVG part. Parts are listed by type, so part indices change.",
"group": "Object",
"icon": "",
"key": "obj_type_support_blocker",
"title": "Change Type to Support Blocker"
},
{
"args": {
"type": "support_enforcer"
},
"description": "Make the selected parts support enforcers, as Change Type does; not the object's last solid part, nor a text or SVG part. Parts are listed by type, so part indices change.",
"group": "Object",
"icon": "",
"key": "obj_type_support_enforcer",
"title": "Change Type to Support Enforcer"
},
{
"args": {
"type": "precise_seam"
},
"description": "Make the selected parts Center precise seams (seams keep their subtype), as Change Type does; not the object's last solid part, nor a text or SVG part. Parts are listed by type, so part indices change.",
"group": "Object",
"icon": "",
"key": "obj_type_precise_seam",
"title": "Change Type to Precise Seam"
}
],
"completion": "immediate",
"description": "Change what parts are, as Change Type does: those named, else the part rows selected in the object list. type is part, negative, modifier, support_blocker, support_enforcer, or precise_seam, a Center precise seam where a seam keeps its subtype; subtype, with precise_seam alone, sets the seam's subtype as the Precise Seam Type menu does. Not an object's last solid part; a text or SVG part does not become a support blocker or enforcer or a precise seam; a painted modifier keeps its type. One undo step. Parts are listed by type, so part indices change. Reply: each part with its index afterwards and its type (parts).",
"destructive": false,
"group": "Parts",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"part_ids": {
"description": "The ids object_list reports for the entries of parts, one per entry: refused when a pair names another part now.",
"items": {
"type": "integer"
},
"type": "array"
},
"parts": {
"description": "[[object, part], ...]",
"items": {
"type": "array"
},
"type": "array"
},
"subtype": {
"description": "With type precise_seam: the seam's subtype, which every part named takes. Default: a seam keeps its own, another part becomes center.",
"enum": [
"center",
"left",
"right",
"enforced",
"blocked",
"neutral"
],
"type": "string"
},
"type": {
"description": "What the parts become.",
"enum": [
"part",
"negative",
"modifier",
"support_blocker",
"support_enforcer",
"precise_seam"
],
"type": "string"
}
},
"required": [
"type"
],
"type": "object"
},
"key": "part_change_type",
"listed": true,
"open_world": false,
"operations": [
"change_part_type"
],
"read_only": false,
"title": "Change a part's type"
},
{
"completion": "immediate",
"description": "Replace a part's mesh with the mesh of a model file, as Replace 3D file does: the part named (object and part, or an object of one part), else the one selected in the Prepare view. The part keeps its settings, type, filament and placement, and its painting when the keep_painting preference is on; with it off the painting is copied as it is, which fits the same mesh alone. A file that loads as more than one object or part is refused, as Replace 3D file refuses it. path names the file, so no file dialog opens; the loader may still ask, a STEP file for its mesh options (blocked_by_dialog). Cut objects are refused, and so is a call while a gizmo is open. One undo step. Reply: the part (parts), with its new part_id and its index, which moves when the object's parts are not in type order (the replacement sorts them), and its object_list entry (part_info).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"object": 0,
"path": "/models/bracket_v2.stl"
},
"tool": "part_replace"
}
],
"title": "Replace an object's only part with a new version of its file"
},
{
"calls": [
{
"args": {
"object": 0,
"part": 1,
"path": "/models/modifier.stl"
},
"tool": "part_replace"
}
],
"title": "Replace a modifier with a mesh of another shape"
}
],
"group": "Parts",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"part": {
"description": "A part of the object (object_list).",
"minimum": 0,
"type": "integer"
},
"part_id": {
"description": "The id object_list reports for this part: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"path": {
"description": "Absolute path of the model file (STL, OBJ, 3MF, STEP, ...).",
"type": "string"
}
},
"required": [
"path"
],
"type": "object"
},
"key": "part_replace",
"listed": true,
"open_world": false,
"operations": [
"replace_part"
],
"read_only": false,
"title": "Replace 3D file"
},
{
"completion": "immediate",
"description": "Open the Mesh Boolean gizmo on an object of two parts or more, its first instance. The operation (Union, Difference or Intersection), the two parts and Delete input are left to the gizmo: pick each part with a mouse_gesture click on a point of it the camera can see, then press the operation's button. Read the gizmo's panel with widget_list {include_imgui: true}, set its fields with widget_set_value, press its buttons with widget_click, and click or drag on the model with mouse_gesture; object_select {none: true} closes it. The gizmo already open on the same target stays open. Reply: gizmo (its name, as app_state.gizmo gives it), active, and what is selected (objects, instances, parts).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"object": 0
},
"tool": "part_boolean"
}
],
"title": "Open Mesh Boolean on object 0"
},
{
"calls": [
{
"args": {},
"tool": "part_boolean"
}
],
"title": "Open Mesh Boolean on the selected object"
}
],
"group": "Parts",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"object": {
"description": "Object index (object_list).",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "part_boolean",
"listed": true,
"open_world": false,
"operations": [
"open_gizmo"
],
"read_only": false,
"title": "Mesh Boolean"
},
{
"actions": [
{
"args": {
"test": "temperature"
},
"description": "Open the Temperature Calibration dialog; calibration_generate_test with the test's parameters, or silent, runs it with no dialog.",
"group": "Calibration",
"icon": "param_temperature",
"key": "calib_temperature",
"title": "Temperature Calibration"
},
{
"args": {
"test": "max_volumetric"
},
"description": "Open the Max Volumetric Speed Calibration dialog; calibration_generate_test with the test's parameters, or silent, runs it with no dialog.",
"group": "Calibration",
"icon": "param_volumetric_speed",
"key": "calib_max_volumetric",
"title": "Max Volumetric Speed Calibration"
},
{
"args": {
"test": "pressure_advance"
},
"description": "Open the Pressure Advance Calibration dialog; calibration_generate_test with the test's parameters, or silent, runs it with no dialog.",
"group": "Calibration",
"icon": "param_flow_ratio_and_pressure_advance",
"key": "calib_pressure_advance",
"title": "Pressure Advance Calibration"
},
{
"args": {
"test": "flow_ratio"
},
"description": "Open the Flow Ratio Calibration dialog; calibration_generate_test with the test's parameters, or silent, runs it with no dialog.",
"group": "Calibration",
"icon": "param_flow_ratio_and_pressure_advance",
"key": "calib_flow_ratio",
"title": "Flow Ratio Calibration"
},
{
"args": {
"test": "retraction"
},
"description": "Open the Retraction Calibration dialog; calibration_generate_test with the test's parameters, or silent, runs it with no dialog.",
"group": "Calibration",
"icon": "param_retraction",
"key": "calib_retraction",
"title": "Retraction Calibration"
},
{
"args": {
"test": "cornering"
},
"description": "Open the Cornering Calibration dialog; calibration_generate_test with the test's parameters, or silent, runs it with no dialog.",
"group": "Calibration",
"icon": "param_precision",
"key": "calib_cornering",
"title": "Cornering Calibration"
},
{
"args": {
"test": "input_shaping_freq"
},
"description": "Open the Input Shaping Frequency Calibration dialog; calibration_generate_test with the test's parameters, or silent, runs it with no dialog.",
"group": "Calibration",
"icon": "param_resonance_avoidance",
"key": "calib_input_shaping_freq",
"title": "Input Shaping Frequency Calibration"
},
{
"args": {
"test": "input_shaping_damp"
},
"description": "Open the Input Shaping Damping Calibration dialog; calibration_generate_test with the test's parameters, or silent, runs it with no dialog.",
"group": "Calibration",
"icon": "param_resonance_avoidance",
"key": "calib_input_shaping_damp",
"title": "Input Shaping Damping Calibration"
},
{
"args": {
"test": "vfa"
},
"description": "Open the VFA Calibration dialog; calibration_generate_test with the test's parameters, or silent, runs it with no dialog.",
"group": "Calibration",
"icon": "param_speed",
"key": "calib_vfa",
"title": "VFA Calibration"
}
],
"completion": "immediate",
"description": "Generate a Calibration menu test as its dialog's OK does: a new project named after the test with the test model, and the process, filament and printer presets changed as the test needs (presets_changed). The test prints with filament slot 1, so the filament tab is pointed at slot 1's preset. Omitted parameters take the dialog's defaults (pressure advance's by the printer's extruder type); temperatures are clamped to 155-500 °C and rounded down to 5 °C. Fails, changing nothing, when the project has unsaved changes (pass discard_changes) or presets do (pass preset_changes). Called with test alone it opens that test's dialog, as the Calibration menu does (blocked_by_dialog), and the dialog's OK runs the test; silent: true with test alone runs it with the dialog's defaults. Reply: test, project, params (the values used, which the journal records), objects, names, plates, presets_changed, result_keys (where the measured value belongs), warnings, adjusted (vfa), and discarded and modified as project_new. Then plate_slice and project_export. To save a measured value: project_new {discard_changes, preset_changes: \"discard\"}, settings_set the value, preset_save.",
"destructive": false,
"group": "Plates",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"not": {
"enum": [
{
"test": "temperature"
},
{
"test": "max_volumetric"
},
{
"test": "pressure_advance"
},
{
"test": "flow_ratio"
},
{
"test": "retraction"
},
{
"test": "cornering"
},
{
"test": "input_shaping_freq"
},
{
"test": "input_shaping_damp"
},
{
"test": "vfa"
}
]
}
},
"properties": {
"accelerations": {
"description": "pressure_advance pattern: one test per acceleration and speed; default the process's.",
"items": {
"minimum": 1,
"type": "integer"
},
"type": "array"
},
"auto_adjust": {
"description": "vfa: lower the layer height, else the end speed, to stay within the filament's maximum volumetric speed (default true); only with auto_scale.",
"type": "boolean"
},
"auto_scale": {
"description": "temperature, vfa: scale the model to the nozzle (default true).",
"type": "boolean"
},
"damping": {
"description": "input_shaping_freq: the damping ratio printed with.",
"type": "number"
},
"discard_changes": {
"description": "Drop the project's unsaved changes rather than fail; for the presets', see preset_changes.",
"type": "boolean"
},
"end": {
"description": "End of the swept value.",
"type": "number"
},
"end_y": {
"description": "input_shaping_freq: end of the Y range; default the X one.",
"type": "number"
},
"freq_x": {
"description": "input_shaping_damp: the X frequency, Hz.",
"type": "number"
},
"freq_y": {
"description": "input_shaping_damp: the Y frequency, Hz; default freq_x.",
"type": "number"
},
"method": {
"description": "pressure_advance: tower (default), line or pattern; flow_ratio: pass1, pass2, yolo (default) or yolo_perfectionist.",
"enum": [
"tower",
"line",
"pattern",
"pass1",
"pass2",
"yolo",
"yolo_perfectionist"
],
"type": "string"
},
"preset_changes": {
"description": "The presets' unsaved changes, not the project's: keep them for the test or drop them first. Required when presets are modified.",
"enum": [
"keep",
"discard"
],
"type": "string"
},
"print_numbers": {
"description": "pressure_advance line: print the values (default true).",
"type": "boolean"
},
"shaper_type": {
"description": "Input shaping: an input_shaping_type the printer's firmware offers; default the first.",
"type": "string"
},
"silent": {
"description": "true runs the command without asking; it then needs test, and what else the call leaves out takes its default. A call with exactly a Speed Dial action's arguments does what a person's pick of that action does.",
"enum": [
true
],
"type": "boolean"
},
"speeds": {
"description": "pressure_advance pattern: default an optimal speed.",
"items": {
"minimum": 1,
"type": "integer"
},
"type": "array"
},
"start": {
"description": "Start of the swept value: °C, mm³/s, PA, mm, mm/s (vfa), Hz (input_shaping_freq), damping (input_shaping_damp), junction deviation mm or jerk mm/s (cornering).",
"type": "number"
},
"start_y": {
"description": "input_shaping_freq: start of the Y range; default the X one.",
"type": "number"
},
"step": {
"description": "Step: max_volumetric, pressure_advance, retraction, vfa.",
"type": "number"
},
"test": {
"description": "The test, as the Calibration menu names it.",
"enum": [
"temperature",
"max_volumetric",
"pressure_advance",
"flow_ratio",
"retraction",
"vfa",
"cornering",
"input_shaping_freq",
"input_shaping_damp"
],
"type": "string"
},
"test_model": {
"description": "Input shaping: ringing_tower (default) or fast_tower; cornering: also scv_v2; temperature on belt printers: standard (default) or overhang.",
"enum": [
"ringing_tower",
"fast_tower",
"scv_v2",
"standard",
"overhang"
],
"type": "string"
},
"top_surface_pattern": {
"description": "flow_ratio (default archimedeanchords).",
"enum": [
"archimedeanchords",
"monotonic"
],
"type": "string"
}
},
"then": {
"required": [
"test"
]
},
"type": "object"
},
"key": "calibration_generate_test",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Generate a calibration test"
},
{
"completion": "immediate",
"description": "Read a plate's own settings, as the Plate Settings dialog sets them: curr_bed_type, print_sequence, spiral_mode, first_layer_print_sequence and other_layers_print_sequence; and as its filament grouping sets them on a printer with several extruders: filament_map_mode and filament_map (the extruder of each filament, 1-based). Each with value (the plate's own, null where it follows the global setting or Auto), effective (what the plate prints with) and meta (meta.offered lists the plate types or grouping modes this printer has). All of them, or those named in keys. Reply: plate, items; unknown_keys for the keys a plate does not have.",
"destructive": false,
"group": "Plates",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"include_meta": {
"description": "Include labels, types and ranges. Default true.",
"type": "boolean"
},
"keys": {
"description": "Setting keys, e.g. [\"curr_bed_type\"].",
"items": {
"type": "string"
},
"type": "array"
},
"plate": {
"description": "Plate index; default: the current plate.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "plate_get_settings",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Read a plate's settings"
},
{
"completion": "immediate",
"description": "Change a plate's own settings, which it selects and writes as the Plate Settings dialog's OK does: curr_bed_type, print_sequence (\"by layer\", \"by object\"), spiral_mode (true asks for confirmation), first_layer_print_sequence (every slot once, e.g. [2, 1]) and other_layers_print_sequence ([{from: layer >= 2, to, order}], to omitted for the last layer); and as the OK of its filament grouping does, with several extruders: filament_map_mode (an offered mode) and, with \"Manual\", filament_map (one extruder per filament, e.g. [1, 2, 2]; on a printer whose extruder holds several nozzles, refused as the dialog refuses it where an extruder it uses has no nozzle of the volume type its filaments print with). null returns a value to the global setting or Auto. Values are checked before anything changes, and the call is one undo step. Reply: plate, applied, changed, and effective for the settings the plate prints with.",
"destructive": false,
"group": "Plates",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"plate": {
"description": "Plate index; default: the current plate.",
"minimum": 0,
"type": "integer"
},
"values": {
"description": "{key: value}",
"type": "object"
}
},
"required": [
"values"
],
"type": "object"
},
"key": "plate_set_settings",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Change a plate's settings"
},
{
"completion": "immediate",
"description": "Plates with name, locked, current, objects (how many are on it; object_list lists them), and the settings they print with: curr_bed_type, print_sequence, spiral_mode, first_layer_print_sequence and other_layers_print_sequence (null: Auto), with several extruders filament_map_mode and filament_map; overrides lists those the plate sets itself (plate_set_settings). Also origin and size, the plate's place on the bed in mm: the [x, y] of its front left corner and its [width, depth], in the bed coordinates object positions are given in, so that origin plus half the size is its middle; sliced (an up-to-date slice), wipe_tower [x, y] and layer_gcode: the plate's pauses, custom G-code, templates and filament changes, each {z, layer, type, filament, color, gcode}; layer is the Preview slider's number, given while the plate's slice is up to date.",
"destructive": false,
"group": "Plates",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"limit": {
"description": "Default 100.",
"maximum": 500,
"minimum": 1,
"type": "integer"
},
"offset": {
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "plate_list",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "List plates"
},
{
"action_group": "Plate",
"completion": "immediate",
"description": "Add a plate.",
"destructive": false,
"group": "Plates",
"guard": "mutate",
"has_own_action": true,
"icon": "toolbar_add_plate",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "plate_add",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Add Plate"
},
{
"action_group": "Plate",
"completion": "immediate",
"description": "Delete a plate (plate, else the current one), as Delete Plate does. The objects on it stay in the project, outside the plates, and the plates after it move down one. The only plate is refused. One undo step. Reply: plate (the index it had), plates (each plate afterwards: index, name and objects, how many stand on it) and current (the current plate).",
"destructive": false,
"group": "Plates",
"guard": "mutate",
"has_own_action": true,
"icon": "delete",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"plate": {
"description": "Plate index; default: the current plate.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "plate_delete",
"listed": true,
"open_world": false,
"operations": [
"delete_plate"
],
"read_only": false,
"title": "Delete Plate"
},
{
"action_group": "Plate",
"completion": "immediate",
"description": "Add a plate with a copy of each object on the plate (plate, else the current one), placed on it as on that plate, as Duplicate Current Plate does. The new plate comes last, and the current plate stays current. Refused when the project holds as many plates as it can, and while slicing. One undo step. Reply: plate (the plate copied), new_plate (the new plate's index), plates (each plate afterwards: index, name and objects, how many stand on it) and current (the current plate).",
"destructive": false,
"group": "Plates",
"guard": "mutate",
"has_own_action": true,
"icon": "menu_copy",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"plate": {
"description": "Plate index; default: the current plate.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "plate_duplicate",
"listed": true,
"open_world": false,
"operations": [
"duplicate_plate"
],
"read_only": false,
"title": "Duplicate Plate"
},
{
"action_group": "Plate",
"completion": "immediate",
"description": "Name a plate (plate, else the current one), as its name icon does: a plate other than the current one is made current first. name \"\" leaves it unnamed. With no arguments, as its Speed Dial action, the name dialog asks for the current plate's name (blocked_by_dialog), and a cancelled dialog renames nothing, which the call is told. The name is one undo step; the name the plate has already changes nothing, the current plate included. Reply: plate and name.",
"destructive": false,
"group": "Plates",
"guard": "mutate",
"has_own_action": true,
"icon": "plate_name_edit",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"name": {
"description": "The plate's name, in place of the name dialog.",
"type": "string"
},
"plate": {
"description": "Plate index; default: the current plate.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the command without asking; it then needs name, and what else the call leaves out takes its default. A call with no arguments does what a person's pick does.",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"name"
]
},
"type": "object"
},
"key": "plate_rename",
"listed": true,
"open_world": false,
"operations": [
"rename_plate",
"select_plate"
],
"read_only": false,
"title": "Rename Plate"
},
{
"actions": [
{
"args": {},
"description": "Lock or unlock the current plate.",
"group": "Plate",
"icon": "lock_normal",
"key": "plate_toggle_lock",
"title": "Toggle Plate Lock"
}
],
"completion": "immediate",
"description": "Lock or unlock a plate (plate, else the current one), as its lock icon does: locked true locks it and false unlocks it; without locked it toggles, as its Speed Dial action does. An arrange of every plate leaves a locked one as it is. One undo step, none when the plate is in that state already. Reply: plate, locked, and changed (false when it was so already).",
"destructive": false,
"group": "Plates",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"locked": {
"description": "true locks the plate, false unlocks it. Default: the other state.",
"type": "boolean"
},
"plate": {
"description": "Plate index; default: the current plate.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "plate_lock",
"listed": true,
"open_world": false,
"operations": [
"set_plate_locked"
],
"read_only": false,
"title": "Toggle Plate Lock"
},
{
"actions": [
{
"args": {
"plate": 0
},
"description": "Make the first plate the current one.",
"group": "Plate",
"icon": "go_next_plate",
"key": "plate_goto",
"title": "Go to Plate"
}
],
"completion": "immediate",
"description": "Make a plate the current one, as a click on it does: plate; without it, the current plate stays current. An index the project lacks is an error. Reply: plate.",
"destructive": false,
"group": "Plates",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"plate": {
"description": "Plate index; default: the current plate.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "plate_select",
"listed": true,
"open_world": false,
"operations": [
"select_plate"
],
"read_only": false,
"title": "Go to Plate"
},
{
"actions": [
{
"args": {
"preview": true
},
"description": "Slice the current plate and show the Preview tab; the call waits for the result, and a pick starts the slice as a job.",
"group": "Slice & Export",
"icon": "media_play",
"key": "slice_and_preview",
"title": "Slice and Preview"
},
{
"args": {
"plates": "all",
"preview": true
},
"description": "Slice every plate and show the Preview tab; the call waits for the results, and a pick starts the slice as a job.",
"group": "Slice & Export",
"icon": "media_play",
"key": "slice_all",
"title": "Slice All Plates"
}
],
"completion": "immediate",
"description": "Slice the current plate, all plates, or one plate by index, the way the toolbar's Slice button does, and wait for the result (or reply with a job id when it takes longer than the reply budget). Each requested plate reports ok, error, cancelled, empty or skipped; the whole operation is superseded when someone else started a slice or edited the project while it ran. An ok plate has time_s (silent_time_s when the printer estimates it), filament_m and filament_g including flush, filament_cost, layers, max_z, filament_changes, and filaments[i] for slot i+1 with m, g and the grams of model_g, support_g, flush_g and tower_g. Other changes are refused until it finishes; job_cancel stops it. The Preview tab shows the result, as after the Slice button; preview: true, alone or with plates \"all\", is the call of Slice and Preview or Slice All Plates, whose pick starts the slice as a job and shows its result as a notification.",
"destructive": false,
"group": "Plates",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"plates": {
"description": "\"current\" (default), \"all\", or a plate index.",
"type": [
"string",
"integer"
]
},
"preview": {
"description": "Show the Preview tab, as every slice does: the argument of the Slice and Preview and Slice All Plates actions.",
"type": "boolean"
},
"timeout_s": {
"description": "Stop waiting after this long (default 1800): the call fails, and the slice goes on unless job_cancel stops it.",
"maximum": 7200,
"minimum": 10,
"type": "integer"
}
},
"type": "object"
},
"key": "plate_slice",
"listed": true,
"open_world": false,
"operations": [
"start_slice"
],
"read_only": false,
"title": "Slice"
},
{
"completion": "immediate",
"description": "Add or remove pauses, custom G-code, custom templates and filament changes at the start of a layer, as the Preview layer slider's menu does; they are saved per plate in the project. They go on the plate's sliced layers, so the plate needs an up-to-date slice, or must be the one the Preview still shows after an earlier edit; the call selects it and shows the Preview. Applies clear, then remove, then add, all checked first. One code per layer: adding where a code of the same type is replaces it, and where another type is, is refused (remove it first). Not undoable, as in the slider. A change invalidates the plate's slice: slice again before exporting. Reply: the plate's codes as plate_list's layer_gcode lists them, each with z and layer.",
"destructive": false,
"group": "Plates",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"add": {
"description": "Codes to add, each with layer or z.",
"items": {
"additionalProperties": false,
"properties": {
"filament": {
"description": "change_filament: printed from this layer up.",
"minimum": 1,
"type": "integer"
},
"gcode": {
"description": "custom: the G-code.",
"type": "string"
},
"layer": {
"description": "1-based, as the Preview's layer slider numbers layers.",
"minimum": 1,
"type": "integer"
},
"type": {
"description": "template runs the printer's template_custom_gcode.",
"enum": [
"pause",
"custom",
"template",
"change_filament"
],
"type": "string"
},
"z": {
"description": "mm: the layer whose top is at or above it.",
"minimum": 0,
"type": "number"
}
},
"required": [
"type"
],
"type": "object"
},
"type": "array"
},
"clear": {
"description": "Remove every code on the plate first.",
"type": "boolean"
},
"plate": {
"description": "Default: the current plate.",
"minimum": 0,
"type": "integer"
},
"remove": {
"description": "Codes to remove, by layer or z.",
"items": {
"additionalProperties": false,
"properties": {
"layer": {
"description": "1-based, as the Preview's layer slider numbers layers.",
"minimum": 1,
"type": "integer"
},
"z": {
"description": "mm: the layer whose top is at or above it.",
"minimum": 0,
"type": "number"
}
},
"type": "object"
},
"type": "array"
}
},
"type": "object"
},
"key": "plate_set_custom_gcode",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Set custom G-code at a layer"
},
{
"completion": "immediate",
"description": "What the Preview shows for a sliced plate. summary: plate_slice's, plus prepare and travel time and travel distance. features: seconds, share of the print time and grams per feature type (the Line Type legend), and travel. layers: per layer (1-based, as view_set's layer) Z, height, seconds and grams, paged; layer_features adds each feature type's seconds. objects: grams per object instance, with its object_list index when its name is unique. view, for the plate the Preview shows: view type, time mode, layer range, which legend rows are visible, and each view type's colour range for what the legend shows. Times are normal-mode estimates. A G-code file opened for viewing reads the same.",
"destructive": false,
"group": "Plates",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"include": {
"description": "Parts besides the summary; default [\"features\", \"view\"].",
"items": {
"enum": [
"features",
"layers",
"layer_features",
"objects",
"view"
],
"type": "string"
},
"type": "array"
},
"limit": {
"description": "Layers per page (default 100).",
"maximum": 1000,
"minimum": 1,
"type": "integer"
},
"offset": {
"minimum": 0,
"type": "integer"
},
"plate": {
"description": "Plate index; default the current plate.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "plate_slice_stats",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Get slice statistics"
},
{
"completion": "immediate",
"description": "Printer, process or filament presets, each with its name, alias (the name its selector shows, when another), system, user, project (kept inside the project), inherits, selected (and modified), compatible: false or installed: false when so, and vendor; a filament its filament_type and the slots using it (filament_slots), a printer its printer_model and nozzle. Only compatible, installed presets unless asked: a fresh install leaves most system filaments and printers out of the selectors, and preset_select takes such a preset too. printer lists the filaments or processes that fit another printer preset, in place of the selected one.",
"destructive": false,
"group": "Presets and settings",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"filament_type": {
"description": "Type filament: a filament type, in either case (\"PLA\").",
"type": "string"
},
"include_incompatible": {
"description": "Also list presets incompatible with the printer.",
"type": "boolean"
},
"include_uninstalled": {
"description": "Also list the system presets the selectors do not offer, which a person has not installed.",
"type": "boolean"
},
"limit": {
"description": "Default 100.",
"maximum": 500,
"minimum": 1,
"type": "integer"
},
"offset": {
"minimum": 0,
"type": "integer"
},
"printer": {
"description": "Types filament and process: list what fits this printer preset (a name from preset_list type printer) in place of the selected printer.",
"type": "string"
},
"query": {
"description": "Case-insensitive part of the name or alias.",
"type": "string"
},
"source": {
"description": "Where the presets come from: the system's, a person's own, or kept inside the project.",
"enum": [
"system",
"user",
"project"
],
"type": "string"
},
"type": {
"description": "Preset category.",
"enum": [
"printer",
"process",
"filament"
],
"type": "string"
},
"vendor": {
"description": "A vendor, in either case: a filament's maker (\"Bambu Lab\", \"Generic\"), a printer's or process's vendor bundle (\"BBL\").",
"type": "string"
}
},
"required": [
"type"
],
"type": "object"
},
"key": "preset_list",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "List presets"
},
{
"completion": "immediate",
"description": "Select a printer, process or filament preset by the name its selector shows (or its internal name), as a person would. One the selectors do not offer (preset_list include_uninstalled) is shown in them first, until the app restarts; one the selector leaves out as incompatible with the printer is refused. With unsaved changes the Transfer-or-discard prompt opens (blocked_by_dialog) unless preset_changes answers it. A filament is assigned to filament_slot (1-based, default 1); with several slots the filament tab keeps the preset and the changes it has, so nothing is asked. Reply: selected, shown (a preset it showed in the selectors); when presets had or have unsaved changes, discarded and modified list per preset the keys dropped and the keys still unsaved.",
"destructive": false,
"group": "Presets and settings",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"filament_slot": {
"description": "Filament slot, 1-based.",
"minimum": 1,
"type": "integer"
},
"name": {
"description": "Preset name as preset_list shows it.",
"type": "string"
},
"preset_changes": {
"description": "Unsaved changes of the presets the switch replaces: move them to the new preset or drop them, as the prompt's buttons do; transfer is refused where the prompt does not offer it (a printer's changes, a filament of another type). Omitted: the prompt opens.",
"enum": [
"transfer",
"discard"
],
"type": "string"
},
"type": {
"description": "Preset category.",
"enum": [
"printer",
"process",
"filament"
],
"type": "string"
}
},
"required": [
"type",
"name"
],
"type": "object"
},
"key": "preset_select",
"listed": true,
"open_world": false,
"operations": [
"resolve_preset",
"select_preset",
"assign_filament_preset"
],
"read_only": false,
"title": "Select a preset"
},
{
"completion": "immediate",
"description": "Save the printer, process or filament preset being edited, with its unsaved changes, as a preset called name, which is then selected: what the tab's Save button does through its dialog. A filament is filament_slot's (default 1), and every slot using the old preset takes the new one. Replacing another existing preset needs overwrite (pass it in replays and scripts meant to be rerun). Reply: saved, selected, user, project, inherits, filament_slots. A temperature warning or an unsaved-changes prompt makes it blocked_by_dialog. To keep only some edits, settings_set {reset_all: true, values} first.",
"destructive": false,
"group": "Presets and settings",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"detach": {
"description": "Copy inherited values and drop the parent (Developer mode).",
"type": "boolean"
},
"filament_slot": {
"description": "Filament slot, 1-based.",
"minimum": 1,
"type": "integer"
},
"inside_project": {
"description": "Keep it inside the project, not as a user preset. Default: where the edited preset is. A preset of that name stays where it is.",
"type": "boolean"
},
"name": {
"description": "Name to save under.",
"type": "string"
},
"overwrite": {
"description": "Replace another preset of that name.",
"type": "boolean"
},
"type": {
"description": "Preset category.",
"enum": [
"printer",
"process",
"filament"
],
"type": "string"
}
},
"required": [
"type",
"name"
],
"type": "object"
},
"key": "preset_save",
"listed": true,
"open_world": true,
"operations": [],
"read_only": false,
"title": "Save a preset"
},
{
"completion": "immediate",
"description": "Delete a user preset or one inside the project, its file and its cloud copy, as the tab's Delete does, without asking. A selected preset is replaced as the tab does (its parent or the next preset). Another filament is deleted without changing the selection, and slots using it take the selected one; another process is selected, deleted and the selection restored; a printer must be selected first, and the physical printers that use only it are deleted with it. Refused: system, default and bundle presets, presets others inherit from, another preset while the edited one of its type has unsaved changes. Deleting a selected printer or process can ask about other presets' unsaved changes (blocked_by_dialog). Reply: deleted, selected, filaments (per slot), attached, and discarded/modified as preset_select's.",
"destructive": true,
"group": "Presets and settings",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"delete_attached": {
"description": "A custom printer with process or filament presets made for it alone is refused without this: they are deleted with it, as the GUI deletes them.",
"type": "boolean"
},
"name": {
"description": "Preset name as preset_list shows it.",
"type": "string"
},
"type": {
"description": "Preset category.",
"enum": [
"printer",
"process",
"filament"
],
"type": "string"
}
},
"required": [
"type",
"name"
],
"type": "object"
},
"key": "preset_delete",
"listed": true,
"open_world": true,
"operations": [],
"read_only": false,
"title": "Delete a preset"
},
{
"completion": "immediate",
"description": "All the settings of a type in one reply, each item with its value as OrcaSlicer writes it, and without meta unless include_meta. process, printer and filament: the preset being edited, or with preset a saved one, or with filament_slot a slot's. object: the process settings an object or an assembly takes; region: those a part, a modifier or a height range takes, whose layer_height item has targets [\"height_range\"], a height range alone taking it; in both, each with the process preset's value, which an object or a region prints with unless it sets its own. With where, the settings of one settings page or \"Page > Group\" (an unknown one is refused with the list of them). Items with meta, which where gives them, come 100 a page. settings_get reads the settings named or searched for, and what an object, a part or a height range overrides.",
"destructive": false,
"group": "Presets and settings",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"filament_slot": {
"description": "Type filament: the slot whose preset is read, 1-based (default 1), with its unsaved changes when the filament tab is editing it.",
"minimum": 1,
"type": "integer"
},
"include_meta": {
"description": "Include labels, types and ranges. Default false, true with where.",
"type": "boolean"
},
"limit": {
"description": "Default: all of them, or 100 with meta.",
"maximum": 500,
"minimum": 1,
"type": "integer"
},
"offset": {
"minimum": 0,
"type": "integer"
},
"preset": {
"description": "Read this saved preset (a name from preset_list) instead of the one being edited: of the type, or for object and region a process preset.",
"type": "string"
},
"type": {
"description": "Which settings: a preset's, or those an object or a region takes.",
"enum": [
"process",
"printer",
"filament",
"object",
"region"
],
"type": "string"
},
"where": {
"description": "A settings page, or \"Page > Group\" as meta.where gives it, e.g. \"Strength > Walls\".",
"type": "string"
}
},
"required": [
"type"
],
"type": "object"
},
"key": "settings_list",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "List settings"
},
{
"completion": "immediate",
"description": "Read the settings named or searched for: each item has its value, as OrcaSlicer writes it, and meta: label, description (what the setting does, when to change it), where (its settings page and group), type, unit, range, allowed values and mode. Choose them by keys, or by query, a few words matched in keys, labels and descriptions, best matches first. Keys the settings lack are listed in unknown_keys, and type_of gives where each of those is a setting elsewhere (a type, or project for the project's own settings). It needs keys, query, compare or a target other than global; settings_list lists all of a type's settings.\n- No type: keys and query look through the process, filament and printer settings, and each item names its type, the one settings_set takes; otherwise the type is the process.\n- type printer, process or filament (target global): the preset being edited, or with preset a saved one; compare lists only the keys that differ from another preset (value and other). A per-variant value lists in meta its variants (what each entry is for) and active (the entry each extruder prints with).\n- target object (object), part (object and part) or height_range (object, min_z and max_z), the object or part selected in Prepare where none is named: without keys, what it overrides; keys and query read the process settings it takes (settings_list type object or region lists them) and extruder, its filament, and a key it does not take is refused with where it is set. Each has value (its own, null where it has none), effective (the value it prints with) and source, in the order the slicer applies them: height_range, part, object, global or default; an object's item lists in parts the parts and modifiers that override the key inside their own volume, and an object's or a part's item lists in height_ranges the ranges whose value applies to it between their heights. Inside a modifier, mesh or painted, that sets none of a key, the value of the part it overlaps applies, which the command does not work out: where a part (or a modifier of either kind before it) sets the key, the modifier's item has effective null, source overlapped_part, object_effective and object_source (the object's value), and in parts those that set it. These settings are process settings. The reply names the target (objects or parts, and height_range).\npreferences_get reads the app's preferences, plate_get_settings a plate's settings and project_get_settings the project's own.",
"destructive": false,
"group": "Presets and settings",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"compare": {
"description": "Target global: a preset name, \":saved\" (the unsaved changes) or \":parent\" (the preset it inherits from).",
"type": "string"
},
"filament_slot": {
"description": "Type filament: the slot whose preset is read, 1-based (default 1), with its unsaved changes when the filament tab is editing it.",
"minimum": 1,
"type": "integer"
},
"include_meta": {
"description": "Include labels, types and ranges. Default true, false with compare.",
"type": "boolean"
},
"keys": {
"description": "Option keys, e.g. [\"layer_height\", \"wall_loops\"].",
"items": {
"type": "string"
},
"type": "array"
},
"limit": {
"description": "Default 100, or 20 with query.",
"maximum": 500,
"minimum": 1,
"type": "integer"
},
"max_z": {
"description": "Target height_range: the range's top, mm.",
"minimum": 0,
"type": "number"
},
"min_z": {
"description": "Target height_range: the range's bottom, mm.",
"minimum": 0,
"type": "number"
},
"object": {
"description": "Object index from object_list (targets object, part and height_range); without it, the object selected in Prepare.",
"minimum": 0,
"type": "integer"
},
"offset": {
"minimum": 0,
"type": "integer"
},
"part": {
"description": "Part index in the object (target part, with object); without both, the part selected in Prepare.",
"minimum": 0,
"type": "integer"
},
"preset": {
"description": "Read this saved preset of the type (a name from preset_list) instead of the one being edited.",
"type": "string"
},
"query": {
"description": "A few distinctive words, e.g. \"stringing\" or \"ooze travel\"; the best 20 matches unless limit says otherwise.",
"type": "string"
},
"target": {
"description": "Where they apply: global (default), the type's preset; object, part or height_range, the overrides an object, one of its parts or modifiers, or one of its height ranges carries, which are process settings.",
"enum": [
"global",
"object",
"part",
"height_range"
],
"type": "string"
},
"type": {
"description": "Which settings: the printer, process or filament preset being edited.",
"enum": [
"printer",
"process",
"filament"
],
"type": "string"
}
},
"type": "object"
},
"key": "settings_get",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Read settings"
},
{
"completion": "immediate",
"description": "Change settings as typing them into their settings tab would: a type's preset (target global, the default), or the overrides an object, a part or a height range carries (targets object, part and height_range, whose settings are process settings). Values are strings in OrcaSlicer's format (\"15%\", \"0.2\", \"1,2\") or JSON numbers, booleans and arrays (a point as [x, y]). All are parsed strictly first and applied together, so nothing changes if one is invalid, and a key of another type is refused with that type named. Reply: applied, and changed, every setting the call changed, including those the app adjusted in turn. An object's or part's change is one undo step; a preset's is not in the undo history. Spiral vase and a few others confirm their adjustments in a dialog (blocked_by_dialog).\n- type printer, process (the default) or filament, target global: null takes a key back to its saved value, or with reset_to parent to the parent's; reset_all first discards every unsaved change, as the tab's undo button does (reply: reverted). A per-variant value (settings_get meta.variants) takes one value for the entries in use (meta.active), {index, value} for one entry, or an array of all.\n- type printer: extruders_count, alone, as the Extruders field of the Printer settings sets it; nozzle_volume_type, each extruder's nozzle flow type as its card in the sidebar picks it; a nozzle_diameter that a variant of the printer model has selects that variant's printer preset, as the sidebar's nozzle diameter does, with nozzle_volume_type alone (other keys go in a second call), each flow type checked against what the new preset's nozzle card offers, or gives where it offers none. The switch asks about the printer's unsaved changes (blocked_by_dialog) unless reset_all discards them first; the discard stays if the switch is not made.\n- target object (object), part (object and part) or height_range (object, min_z and max_z), the object or part selected in Prepare where none is named: overrides of the keys its row offers there (settings_list type object or region), and extruder; a key it does not take is refused with where it is set. null removes one; a height range keeps its layer_height, which is checked against the printer's layer heights for the range's filament. extruder, in neither list, is the target's filament (1-based; 0 or null for Default, the object's), set as the Change Filament menu does. The reply names the target (objects or parts, and height_range).\nplate_set_settings changes a plate's settings and project_set_settings the project's own. preferences_set changes the app's preferences; those it refuses (preferences_get marks them refused) change in the Preferences dialog, whose controls carry their effects: window_open {\"window\": \"preferences\", \"tab\": \"<tab>\", \"key\": \"<key>\"}, then widget_set_value {\"target\": {\"name\": \"<key>\", \"within\": \"Preferences\"}, \"value\": ...}.",
"destructive": false,
"group": "Presets and settings",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"filament_slot": {
"description": "Type filament: the slot whose preset is changed, 1-based (default 1). The filament tab switches to it, which can ask about the unsaved changes it holds (blocked_by_dialog).",
"minimum": 1,
"type": "integer"
},
"max_z": {
"description": "Target height_range: the range's top, mm.",
"minimum": 0,
"type": "number"
},
"min_z": {
"description": "Target height_range: the range's bottom, mm.",
"minimum": 0,
"type": "number"
},
"object": {
"description": "Object index from object_list (targets object, part and height_range); without it, the object selected in Prepare.",
"minimum": 0,
"type": "integer"
},
"object_id": {
"description": "The id object_list reports for this object: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"part": {
"description": "Part index in the object (target part, with object); without both, the part selected in Prepare.",
"minimum": 0,
"type": "integer"
},
"part_id": {
"description": "The id object_list reports for this part: the call is refused when the index names another one now.",
"minimum": 0,
"type": "integer"
},
"reset_all": {
"description": "Target global: discard the unsaved changes before applying values.",
"type": "boolean"
},
"reset_to": {
"description": "Target global: what a null value takes a key back to: the saved preset (default) or the preset it inherits from.",
"enum": [
"saved",
"parent"
],
"type": "string"
},
"target": {
"description": "Where they apply: global (default), the type's preset; object, part or height_range, the overrides an object, one of its parts or modifiers, or one of its height ranges carries, which are process settings.",
"enum": [
"global",
"object",
"part",
"height_range"
],
"type": "string"
},
"type": {
"description": "Which settings: the printer, process or filament preset being edited.",
"enum": [
"printer",
"process",
"filament"
],
"type": "string"
},
"values": {
"description": "{key: value}, or {key: {index, value}} for one entry",
"type": "object"
}
},
"type": "object"
},
"key": "settings_set",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Change settings"
},
{
"actions": [
{
"args": {},
"description": "Import presets from the file a dialog asks for. preset_import with a path imports a preset .json, a .zip of them, an .orca_printer, .orca_filament or .orca_bundle, or a .gcode without a dialog, and the message names the presets imported, replaced and kept; a .gcode loads the settings it was sliced with.",
"group": "Import",
"icon": "menu_open",
"key": "import_configs",
"title": "Import Configs"
}
],
"completion": "immediate",
"description": "Import presets from a preset .json, a .zip of them, an .orca_printer, .orca_filament or .orca_bundle, or a .gcode by absolute path, without a dialog, and the message names the presets imported, replaced and kept; a .gcode loads the settings it was sliced with. Called with no arguments it is Import Configs: the file dialog asks for the file (blocked_by_dialog).",
"destructive": false,
"group": "Presets and settings",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"on_conflict": {
"description": "What happens to a preset that exists already. Default skip.",
"enum": [
"skip",
"overwrite"
],
"type": "string"
},
"path": {
"description": "Absolute path of a preset .json, a .zip of them, an .orca_printer, .orca_filament or .orca_bundle, or a .gcode.",
"type": "string"
},
"silent": {
"description": "true runs the command without asking; it then needs path, and what else the call leaves out takes its default. A call with no arguments does what a person's pick does.",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"path"
]
},
"type": "object"
},
"key": "preset_import",
"listed": true,
"open_world": false,
"operations": [
"import_presets"
],
"read_only": false,
"title": "Import Configs"
},
{
"actions": [
{
"args": {},
"description": "Export presets as a bundle or ZIP archives through the Export Preset Bundle dialog: click the label of the kind to export, check its rows (each named after a printer preset or a filament), press OK, then answer the result message. preset_export with a folder as path has OK write there instead of asking for one.",
"group": "Export",
"icon": "save",
"key": "export_config",
"title": "Export Preset Bundle"
}
],
"completion": "immediate",
"description": "Export presets as a bundle or ZIP archives through the Export Preset Bundle dialog: click the label of the kind to export, check its rows (each named after a printer preset or a filament), press OK, then answer the result message. Every call opens the dialog (blocked_by_dialog). With path, OK writes into that folder instead of asking for one, and a cancelled dialog is an error: nothing was exported.",
"destructive": false,
"group": "Presets and settings",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"path": {
"description": "Absolute path of an existing folder, which the dialog's OK writes into.",
"type": "string"
}
},
"type": "object"
},
"key": "preset_export",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Export Preset Bundle"
},
{
"actions": [
{
"args": {},
"description": "Synchronize user presets with the cloud account.",
"group": "Presets",
"icon": "printer_sync_ok",
"key": "sync_presets",
"title": "Sync Presets"
}
],
"completion": "immediate",
"description": "Synchronize user presets with the cloud account. Refused while no account is signed in.",
"destructive": false,
"group": "Presets and settings",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "preset_sync",
"listed": true,
"open_world": true,
"operations": [
"sync_presets"
],
"read_only": false,
"title": "Sync Presets"
},
{
"actions": [
{
"args": {},
"description": "Migrate legacy user filament presets.",
"group": "Help",
"icon": "",
"key": "help_migrate_filament_presets",
"title": "Migrate Filament Presets"
}
],
"completion": "immediate",
"description": "Migrate legacy user filament presets.",
"destructive": false,
"group": "Presets and settings",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "preset_migrate_filaments",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Migrate Filament Presets"
},
{
"actions": [
{
"args": {
"mode": "simple"
},
"description": "Switch the settings view to Simple mode.",
"group": "Mode",
"icon": "advanced",
"key": "mode_simple",
"title": "Mode: Simple"
},
{
"args": {
"mode": "advanced"
},
"description": "Switch the settings view to Advanced mode.",
"group": "Mode",
"icon": "advanced",
"key": "mode_advanced",
"title": "Mode: Advanced"
},
{
"args": {
"mode": "expert"
},
"description": "Switch the settings view to Expert mode.",
"group": "Mode",
"icon": "advanced",
"key": "mode_expert",
"title": "Mode: Expert"
}
],
"completion": "immediate",
"description": "Switch the settings view to Simple, Advanced or Expert mode, which decides which settings the settings pages show.",
"destructive": false,
"group": "Presets and settings",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"mode": {
"description": "The mode.",
"enum": [
"simple",
"advanced",
"expert"
],
"type": "string"
}
},
"required": [
"mode"
],
"type": "object"
},
"key": "settings_set_mode",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Set the settings mode"
},
{
"actions": [
{
"args": {},
"description": "Turn Developer mode on or off.",
"group": "Mode",
"icon": "advanced",
"key": "toggle_developer_mode",
"title": "Toggle Developer Mode"
}
],
"completion": "immediate",
"description": "Turn Developer mode on or off.",
"destructive": false,
"group": "Presets and settings",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "settings_toggle_developer_mode",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Toggle Developer Mode"
},
{
"action_group": "Filament",
"completion": "immediate",
"description": "Add a filament slot, as the + button above the filament list does. It takes the next colour and the last slot's preset (change them with preset_select filament_slot and project_set_settings filament_colour). It goes after the physical slots: mixed filaments move up by one, and objects on them follow. Refused for a printer that has one filament per extruder, which shows no + and - buttons. Reply: filament_slot (the new slot) and filament_slots (how many the project has).",
"destructive": false,
"group": "Filaments",
"guard": "mutate",
"has_own_action": true,
"icon": "add_filament",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "filament_add",
"listed": true,
"open_world": false,
"operations": [
"add_filament_slot"
],
"read_only": false,
"title": "Add Filament Slot"
},
{
"action_group": "Filament",
"completion": "immediate",
"description": "Delete a filament slot, as its Delete menu item does, the objects on it taking the first filament; with merge_into, as its Merge with item does, the objects on it taking that slot. The slots after it move down by one. The only physical slot and a mixed filament (project_get_settings filament_is_mixed) are refused, and so is a merge into a mixed filament that mixes the slot. Refused for a printer that has one filament per extruder, which shows no + and - buttons. Not in the undo history. Reply: filament_slot (the slot deleted), merged_into (the slot its objects went to, as numbered afterwards) and filament_slots.",
"destructive": false,
"group": "Filaments",
"guard": "mutate",
"has_own_action": true,
"icon": "delete_filament",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"filament_slot": {
"description": "The 1-based filament slot. Default: the last physical slot, as the - button.",
"minimum": 1,
"type": "integer"
},
"merge_into": {
"description": "The 1-based slot the objects on it go to, as Merge with does. Default: they take the first filament.",
"minimum": 1,
"type": "integer"
}
},
"type": "object"
},
"key": "filament_delete",
"listed": true,
"open_world": false,
"operations": [
"delete_filament_slot"
],
"read_only": false,
"title": "Delete Filament Slot"
},
{
"completion": "immediate",
"description": "Add a mixed filament: a slot that prints its physical filaments in turn, layer by layer, in the ratios given, as the Add Mixed Filament dialog's OK does with no gradient. components are two or more of the physical slots (1-based), each named once, whose filaments are of one type; ratios a whole percentage for each, adding up to 100. It goes after every other slot. A mix the project has already is not added again: the reply names its slot. Not in the undo history. Reply: filament_slot (1-based) and added (false for a mix the project had).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"components": [
1,
2
],
"ratios": [
50,
50
]
},
"tool": "filament_add_mixed"
}
],
"title": "Mix the first two filaments half and half"
},
{
"calls": [
{
"args": {
"components": [
1,
2,
3
],
"ratios": [
25,
25,
50
]
},
"tool": "filament_add_mixed"
}
],
"title": "Mix three filaments, the third the most"
}
],
"group": "Filaments",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"components": {
"description": "The physical filament slots to mix, 1-based, two or more, each once, of filaments of one type.",
"items": {
"minimum": 1,
"type": "integer"
},
"type": "array"
},
"ratios": {
"description": "Each component's share in percent, in the order of components, adding up to 100.",
"items": {
"exclusiveMinimum": 0,
"type": "integer"
},
"type": "array"
}
},
"required": [
"components",
"ratios"
],
"type": "object"
},
"key": "filament_add_mixed",
"listed": true,
"open_world": false,
"operations": [
"add_mixed_filament"
],
"read_only": false,
"title": "Add Mixed Filament"
},
{
"actions": [
{
"args": {},
"description": "Synchronize the filament list from the connected printer's AMS.",
"group": "Printer",
"icon": "ams_fila_sync",
"key": "sync_ams",
"title": "Synchronize Filament List from AMS"
}
],
"completion": "immediate",
"description": "Synchronize the filament list from the connected printer's AMS. With mode, as the sync dialog's Synchronize now does with that choice, without the dialog: map maps each of the project's filaments to a slot, as the dialog's Mapping first does, which takes a project with objects; overwrite replaces the filament list with the slots' filaments. Called with no arguments, as its Speed Dial action, it opens the sync dialog where the project has objects (blocked_by_dialog), and a warning where it cannot sync. With no printer connected, no AMS or no filament it is refused, saying so. Not in the undo history. Reply: mode, filaments (each slot's preset and colour afterwards) and mapped_to_generic (slots whose filament is unknown, mapped to a generic preset).",
"destructive": false,
"group": "Filaments",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"mode": {
"description": "The sync dialog's choice: map or overwrite.",
"enum": [
"map",
"overwrite"
],
"type": "string"
}
},
"type": "object"
},
"key": "filament_sync_ams",
"listed": true,
"open_world": true,
"operations": [
"sync_filaments_from_ams"
],
"read_only": false,
"title": "Synchronize Filament List from AMS"
},
{
"completion": "immediate",
"description": "Install system filaments, for good, as ticking them in the System Filaments dialog and pressing Confirm does: the filament selectors offer them. Name them by names, or with vendor and filament_type every filament of that vendor and type that an installed printer fits. preset_list {type: \"filament\", include_uninstalled: true} lists the system filaments, those not installed with installed: false. A name no filament has is refused with the closest names. The app keeps an installed printer's default filaments installed while no other installed filament fits it: where the call leaves one so, they are installed again and listed under filaments_installed, as the next start would. The other filaments, and the presets' unsaved changes, are kept, and the selectors are refreshed. Not in the undo history. Reply: installed (the presets installed), installed_already, filaments_installed.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"include_uninstalled": true,
"query": "PETG HF",
"type": "filament"
},
"tool": "preset_list"
},
{
"args": {
"names": [
"Bambu PETG HF"
]
},
"tool": "filament_install"
}
],
"title": "Install a filament by the name the selector shows"
},
{
"calls": [
{
"args": {
"filament_type": "PETG",
"vendor": "Generic"
},
"tool": "filament_install"
}
],
"title": "Install every filament of a vendor and type"
}
],
"group": "Filaments",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"filament_type": {
"description": "With vendor: a filament type (\"PLA\"), in any case.",
"type": "string"
},
"names": {
"description": "System filaments: a preset's name, or the short name the filament selector shows (\"Bambu PLA Basic\"), which stands for its preset of every installed printer it fits.",
"items": {
"type": "string"
},
"minItems": 1,
"type": "array"
},
"vendor": {
"description": "With filament_type, in place of names: a filament maker (\"Bambu Lab\", \"Generic\"), in any case.",
"type": "string"
}
},
"type": "object"
},
"key": "filament_install",
"listed": true,
"open_world": false,
"operations": [
"install_filaments"
],
"read_only": false,
"title": "Install system filaments"
},
{
"completion": "immediate",
"description": "Uninstall system filaments, for good, as unticking them in the System Filaments dialog and pressing Confirm does: the filament selectors no longer offer them. names as filament_install takes them. A filament a slot of the project uses is refused, naming the slot. The app keeps an installed printer's default filaments installed while no other installed filament fits it: where the call leaves one so, they are installed again and listed under filaments_installed, as the next start would. The other filaments, and the presets' unsaved changes, are kept, and the selectors are refreshed. Not in the undo history. Reply: uninstalled (the presets uninstalled), not_installed, filaments_installed.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"names": [
"Bambu PETG HF"
]
},
"tool": "filament_uninstall"
}
],
"title": "Uninstall a filament"
}
],
"group": "Filaments",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"names": {
"description": "System filaments: a preset's name, or the short name the filament selector shows (\"Bambu PLA Basic\"), which stands for its preset of every installed printer it fits.",
"items": {
"type": "string"
},
"minItems": 1,
"type": "array"
}
},
"required": [
"names"
],
"type": "object"
},
"key": "filament_uninstall",
"listed": true,
"open_world": false,
"operations": [
"uninstall_filaments"
],
"read_only": false,
"title": "Uninstall system filaments"
},
{
"completion": "immediate",
"description": "Every printer model OrcaSlicer ships or has installed, of every vendor, as the Printer Selection dialog lists them: each with its vendor (the vendor's id, \"BBL\"), model, nozzles and installed_nozzles, the nozzles whose printer presets the printer selector offers. vendor keeps one vendor's models, and query those whose name holds it. The first call after the shipped profiles change reads every vendor, which takes a while and can reply with a job to wait for; later calls read the result kept in the configuration folder. printer_install and printer_uninstall change what is installed.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"query": "X1 Carbon"
},
"tool": "printer_list_models"
}
],
"title": "Find a printer model and its nozzles"
},
{
"calls": [
{
"args": {
"vendor": "Prusa"
},
"tool": "printer_list_models"
}
],
"title": "List one vendor's printer models"
}
],
"group": "Printers and prints",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"limit": {
"description": "Default 100.",
"maximum": 500,
"minimum": 1,
"type": "integer"
},
"offset": {
"minimum": 0,
"type": "integer"
},
"query": {
"description": "Models whose name holds this, in any case.",
"type": "string"
},
"vendor": {
"description": "A vendor's models only (\"BBL\", \"Prusa\"), in any case.",
"type": "string"
}
},
"type": "object"
},
"key": "printer_list_models",
"listed": true,
"open_world": false,
"operations": [
"printer_models"
],
"read_only": true,
"title": "List printer models"
},
{
"completion": "immediate",
"description": "Install printer models, for good, as ticking them in the Printer Selection dialog and pressing Confirm does: a vendor's profiles are installed from the ones OrcaSlicer ships, the presets reloaded, and a printer newly added selected. The other installed models are kept, and the installed filaments but for what the reload changes. A name no model has, a vendor or a nozzle a model lacks, is refused with the closest names. Reloading the presets drops their unsaved changes, so while there are some preset_changes says what becomes of them; without it the call is refused. A call that changes nothing reloads nothing. The reload installs a printer's default filaments where no installed filament fits it, as the dialog does, and where a vendor's profile lists default filaments of its own, which none of the shipped profiles does, swaps a @System filament for the vendor's: those are under filaments_installed and filaments_uninstalled. Two errors come after a change and say what it was: vendors_not_installed, where a vendor's profiles cannot be installed (the installed printers are as they were, the unsaved changes discarded if preset_changes said so, and the profiles copied before it stay in the configuration folder), and presets_not_reloaded (the installed printers were written, the presets not reloaded). Not in the undo history. Reply: models (what was named, resolved), added (the printer presets the printer selector offers that it did not before the call), selected, not_offered (named nozzles whose presets it still does not offer), and discarded/modified as preset_select's.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"query": "Velo"
},
"tool": "printer_list_models"
},
{
"args": {
"models": [
{
"model": "Goofoo Velo+",
"nozzles": [
"0.4"
],
"vendor": "Goofoo"
}
]
},
"tool": "printer_install"
}
],
"title": "Install a printer model with one of its nozzles"
},
{
"calls": [
{
"args": {
"models": [
{
"model": "Bambu Lab X1 Carbon"
}
],
"preset_changes": "discard"
},
"tool": "printer_install"
}
],
"title": "Install every nozzle of a model, dropping the presets' unsaved changes"
}
],
"group": "Printers and prints",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"models": {
"description": "The printer models, each with its nozzles.",
"items": {
"additionalProperties": false,
"properties": {
"model": {
"description": "The model, as printer_list_models lists it (\"Bambu Lab X1 Carbon\").",
"type": "string"
},
"nozzles": {
"description": "Its nozzles, as printer_list_models lists them (\"0.4\"). Default: all of them, as the dialog's tick of a model.",
"items": {
"type": "string"
},
"minItems": 1,
"type": "array"
},
"vendor": {
"description": "Its vendor (\"BBL\"), needed where several vendors have a model of that name.",
"type": "string"
}
},
"required": [
"model"
],
"type": "object"
},
"minItems": 1,
"type": "array"
},
"preset_changes": {
"description": "The presets' unsaved changes, which reloading the presets drops: move them to the presets selected after it, or drop them, as the Transfer and Discard of the question the dialog's Confirm asks. Needed while presets have unsaved changes; without it the call is refused.",
"enum": [
"transfer",
"discard"
],
"type": "string"
}
},
"required": [
"models"
],
"type": "object"
},
"key": "printer_install",
"listed": true,
"open_world": false,
"operations": [
"install_printers"
],
"read_only": false,
"title": "Install printer models"
},
{
"completion": "immediate",
"description": "Uninstall printer models, for good, as unticking them in the Printer Selection dialog and pressing Confirm does: the printer selector no longer offers their printer presets, and the vendor's profiles stay on disk. Without nozzles a model goes whole. A printer removed while selected is replaced by another installed one. Removing the last installed printer model is refused, and so are names as printer_install refuses them. Reloading the presets drops their unsaved changes, so while there are some preset_changes says what becomes of them; without it the call is refused. A call that changes nothing reloads nothing. The reload installs a printer's default filaments where no installed filament fits it, as the dialog does, and where a vendor's profile lists default filaments of its own, which none of the shipped profiles does, swaps a @System filament for the vendor's: those are under filaments_installed and filaments_uninstalled. Two errors come after a change and say what it was: vendors_not_installed, where a vendor's profiles cannot be installed (the installed printers are as they were, the unsaved changes discarded if preset_changes said so, and the profiles copied before it stay in the configuration folder), and presets_not_reloaded (the installed printers were written, the presets not reloaded). Not in the undo history. Reply: models, removed (the printer presets the printer selector no longer offers), selected, still_offered (named nozzles whose presets it still offers), and discarded/modified as preset_select's.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"models": [
{
"model": "Goofoo Velo+",
"vendor": "Goofoo"
}
]
},
"tool": "printer_uninstall"
}
],
"title": "Uninstall a printer model"
}
],
"group": "Printers and prints",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"models": {
"description": "The printer models, each with its nozzles.",
"items": {
"additionalProperties": false,
"properties": {
"model": {
"description": "The model, as printer_list_models lists it (\"Bambu Lab X1 Carbon\").",
"type": "string"
},
"nozzles": {
"description": "Its nozzles, as printer_list_models lists them (\"0.4\"). Default: all of them, as the dialog's tick of a model.",
"items": {
"type": "string"
},
"minItems": 1,
"type": "array"
},
"vendor": {
"description": "Its vendor (\"BBL\"), needed where several vendors have a model of that name.",
"type": "string"
}
},
"required": [
"model"
],
"type": "object"
},
"minItems": 1,
"type": "array"
},
"preset_changes": {
"description": "The presets' unsaved changes, which reloading the presets drops: move them to the presets selected after it, or drop them, as the Transfer and Discard of the question the dialog's Confirm asks. Needed while presets have unsaved changes; without it the call is refused.",
"enum": [
"transfer",
"discard"
],
"type": "string"
}
},
"required": [
"models"
],
"type": "object"
},
"key": "printer_uninstall",
"listed": true,
"open_world": false,
"operations": [
"uninstall_printers"
],
"read_only": false,
"title": "Uninstall printer models"
},
{
"completion": "immediate",
"description": "Open the dialog the Print button's Print plate opens for the selected printer, for the current plate or the plate plates names, or with plates \"all\" Print all's. For a printer on the Bambu network or with printer agents it is the Print dialog, which leaves the printer, bed levelling, flow calibration, timelapse, the AMS mapping and the button that prints to it; for a printer with a print host (OctoPrint, Moonraker, PrusaLink, Duet...) it is the host's Send G-code to printer host dialog, with Upload and Upload and Print. As the button does, it first applies the slicing result, and it is refused (not_sliced) where the button would be disabled, as for a plate not sliced: slice with plate_slice first. The call replies blocked_by_dialog while the dialog is open: read and set its fields with widget_list and widget_set_value, and press its buttons with dialog_answer. Nothing prints until its button is pressed. Refused: all_plates_not_offered for plates \"all\" where the button offers no Print all, no_print_host for a printer with no print host address.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {},
"tool": "print_start"
}
],
"title": "Open the Print dialog for the current plate"
},
{
"calls": [
{
"args": {
"plates": 1
},
"tool": "plate_slice"
},
{
"args": {
"plates": 1
},
"tool": "print_start"
}
],
"title": "Print the second plate after slicing it"
}
],
"group": "Printers and prints",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"plates": {
"description": "\"current\" (default), a plate index, which is selected first, or \"all\" for Print all, where the Print button offers it.",
"type": [
"string",
"integer"
]
}
},
"type": "object"
},
"key": "print_start",
"listed": true,
"open_world": true,
"operations": [
"open_print_dialog"
],
"read_only": false,
"title": "Print plate"
},
{
"actions": [
{
"args": {},
"description": "Open the dialog the Print button's Send opens for the selected printer, for the current plate or the plate plates names. For a printer on the Bambu network or with printer agents it is the dialog that sends the sliced plate to the printer's storage (with plates \"all\", Send all's), which leaves the printer, the file name, the storage and the button that sends to it, and is refused (not_sliced) for a plate not sliced. For a printer with a print host (OctoPrint, Moonraker, PrusaLink, Duet...) it is the Send G-code to printer host dialog: set the file name with widget_set_value and press Upload or Upload and Print with dialog_answer; the plate is sliced if needed, then uploaded in the background: app_state.uploads shows the row's state, and a failed upload also opens an error dialog. The call replies blocked_by_dialog while the dialog is open. A replay sends again. Refused: all_plates_not_offered for plates \"all\" where the button offers no Send all, no_print_host for a printer with no print host address.",
"group": "Slice & Export",
"icon": "printer",
"key": "send_gcode",
"title": "Send G-code to printer host"
}
],
"completion": "immediate",
"description": "Open the dialog the Print button's Send opens for the selected printer, for the current plate or the plate plates names. For a printer on the Bambu network or with printer agents it is the dialog that sends the sliced plate to the printer's storage (with plates \"all\", Send all's), which leaves the printer, the file name, the storage and the button that sends to it, and is refused (not_sliced) for a plate not sliced. For a printer with a print host (OctoPrint, Moonraker, PrusaLink, Duet...) it is the Send G-code to printer host dialog: set the file name with widget_set_value and press Upload or Upload and Print with dialog_answer; the plate is sliced if needed, then uploaded in the background: app_state.uploads shows the row's state, and a failed upload also opens an error dialog. The call replies blocked_by_dialog while the dialog is open. A replay sends again. Refused: all_plates_not_offered for plates \"all\" where the button offers no Send all, no_print_host for a printer with no print host address.",
"destructive": false,
"group": "Printers and prints",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"plates": {
"description": "\"current\" (default), a plate index, which is selected first, or \"all\" for Send all, where the Print button offers it.",
"type": [
"string",
"integer"
]
}
},
"type": "object"
},
"key": "printer_send",
"listed": true,
"open_world": true,
"operations": [
"open_print_dialog"
],
"read_only": false,
"title": "Send G-code to printer host"
},
{
"completion": "immediate",
"description": "Ask the selected printer's print host whether it answers, as the Test button of the printer's connection dialog does, with its connection settings as they stand. Reply: ok, whether the host answered, and message, the button's message in the app's language; branch on ok. A cloud host that wants a login is a failed test with the host's message: logging in stays in the printer's connection dialog. The window does not redraw while the host is asked. Refused: no_print_host for a printer with no print host address, host_cannot_be_tested for a kind of host that has no test.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"type": "printer",
"values": {
"host_type": "octoprint",
"print_host": "192.168.1.20"
}
},
"tool": "settings_set"
},
{
"args": {},
"tool": "printer_test_host"
}
],
"title": "Check the print host after setting its address"
}
],
"group": "Printers and prints",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "printer_test_host",
"listed": true,
"open_world": true,
"operations": [
"test_print_host"
],
"read_only": false,
"title": "Test the print host"
},
{
"completion": "immediate",
"description": "Read what the Device tab shows of the printer it is connected to, without sending it anything. Reply: connected; with a printer, name, model (null where the tab would say Unknown), printer_type (the model's id), online, state (IDLE, PREPARE, RUNNING, PAUSE, FINISH, FAILED...), stage (a number), percent, remaining_seconds, layer, total_layers, file (the job's name), error_code, and temperatures: nozzles (one {current, target} each), bed and chamber, null where the tab shows none. With no printer connected the reply is {\"connected\": false}, which is no error. The values are what the printer last reported.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {},
"tool": "printer_status"
}
],
"title": "Read the connected printer's state and temperatures"
}
],
"group": "Printers and prints",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "printer_status",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Printer status"
},
{
"completion": "immediate",
"description": "Pause the print running on the printer the Device tab is connected to, as the tab's Pause button does. Refused: no_printer_connected with no printer connected, printer_state, naming the state, unless it is RUNNING. The printer's new state arrives when it reports: read it with printer_status. Reply: printer (its name), state (the state it was in) and sent. A replay sends the command again.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {},
"tool": "printer_status"
},
{
"args": {},
"tool": "print_pause"
}
],
"title": "Pause the print once printer_status reads RUNNING"
}
],
"group": "Printers and prints",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "print_pause",
"listed": true,
"open_world": true,
"operations": [
"send_job_command"
],
"read_only": false,
"title": "Pause the print"
},
{
"completion": "immediate",
"description": "Resume the paused print on the printer the Device tab is connected to, as the tab's Resume button does. Refused: no_printer_connected with no printer connected, printer_state, naming the state, unless it is PAUSE, and resume_at_printer, in the app's own sentence, for a job (such as laser processing) that resumes only at the printer. The printer's new state arrives when it reports: read it with printer_status. Reply: printer (its name), state (the state it was in) and sent. A replay sends the command again.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {},
"tool": "printer_status"
},
{
"args": {},
"tool": "print_resume"
}
],
"title": "Resume the print once printer_status reads PAUSE"
}
],
"group": "Printers and prints",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "print_resume",
"listed": true,
"open_world": true,
"operations": [
"send_job_command"
],
"read_only": false,
"title": "Resume the print"
},
{
"completion": "immediate",
"description": "Stop the print on the printer the Device tab is connected to, as the tab's Stop button does, but without its question \"Are you sure you want to stop this print?\": it asks nothing, and a stopped print cannot be resumed. Refused: no_printer_connected with no printer connected, printer_state, naming the state, unless it is RUNNING, PAUSE, PREPARE or SLICING. The printer's new state arrives when it reports: read it with printer_status. Reply: printer (its name), state (the state it was in) and sent. A replay sends the command again.",
"destructive": true,
"examples": [
{
"calls": [
{
"args": {},
"tool": "print_stop"
}
],
"title": "Stop the print"
}
],
"group": "Printers and prints",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "print_stop",
"listed": true,
"open_world": true,
"operations": [
"send_job_command"
],
"read_only": false,
"title": "Stop the print"
},
{
"completion": "immediate",
"description": "The plugins, as the Plugins window lists them: each with its key (which the other plugin commands take), name, version (the one installed, else the latest offered), installed (a package is on disk), enabled (loaded: the row's switch), status (Activated, Error, RuntimeError, Inactive or Loading), source (local, subscribed, mine or orphaned), capabilities (a loaded plugin's: name, type, enabled) and error.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {},
"tool": "plugin_list"
}
],
"title": "List the plugins and how each stands"
}
],
"group": "Plugins",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "plugin_list",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "List plugins"
},
{
"actions": [
{
"args": {},
"description": "Install a plugin from the .py or .whl file a dialog asks for, as the Plugins dialog's Install local plugin does, asking before it replaces one installed; plugin_install_local with a path installs that file without a dialog. A plugin of that name installed already is replaced only with overwrite true; without it the call is refused with the question the dialog asks.",
"group": "Plugins",
"icon": "",
"key": "install_local_plugin",
"title": "Install Local Plugin"
}
],
"completion": "immediate",
"description": "Install a plugin from a .py or .whl file by absolute path, as the Plugins dialog's Install local plugin does, without its file dialog. A plugin of that name installed already is replaced only with overwrite true; without it the call is refused with the question the dialog asks. Called with no arguments, the file dialog asks for the file (blocked_by_dialog), and replacing an installed plugin asks first (dialog_answer).",
"destructive": false,
"group": "Plugins",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"overwrite": {
"description": "Replace a plugin of that name installed already. Default false.",
"type": "boolean"
},
"path": {
"description": "Absolute path of a .py or .whl plugin package.",
"type": "string"
},
"silent": {
"description": "true runs the command without asking; it then needs path, and what else the call leaves out takes its default. A call with no arguments does what a person's pick does.",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"path"
]
},
"type": "object"
},
"key": "plugin_install_local",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Install Local Plugin"
},
{
"completion": "immediate",
"description": "Turn a plugin, or with capability one of its capabilities, on or off, as the Plugins window's switches do. A plugin turned on is loaded, and the call waits for its load to end; a cloud plugin not installed is downloaded and installed first. A plugin that needs a permission while it loads asks in its permission dialog (blocked_by_dialog), which the caller answers. A plugin turned off is unloaded and loses its error. A capability is one of a loaded plugin's, by its name; an empty one is refused. Reply: plugin (its row, as plugin_list gives it) and changed; a call that fails once it has changed the plugin, a load that fails among them, is an error naming how the plugin is left.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {},
"tool": "plugin_list"
},
{
"args": {
"enabled": true,
"plugin": "my_plugin"
},
"tool": "plugin_enable"
}
],
"title": "Turn a plugin on"
},
{
"calls": [
{
"args": {
"capability": "Export report",
"enabled": false,
"plugin": "my_plugin"
},
"tool": "plugin_enable"
}
],
"title": "Turn one of a plugin's capabilities off"
}
],
"group": "Plugins",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"capability": {
"description": "One of the plugin's capabilities, by name, in place of the plugin itself. The plugin must be enabled.",
"minLength": 1,
"type": "string"
},
"enabled": {
"description": "On (true) or off (false).",
"type": "boolean"
},
"plugin": {
"description": "The plugin's key, as plugin_list gives it, or its name where one plugin has it.",
"type": "string"
}
},
"required": [
"plugin",
"enabled"
],
"type": "object"
},
"key": "plugin_enable",
"listed": true,
"open_world": true,
"operations": [
"set_plugin_enabled"
],
"read_only": false,
"title": "Enable or disable a plugin"
},
{
"completion": "immediate",
"description": "Load a plugin again after its files changed, as its row's Reload does: it is unloaded and loaded, and a plugin that was not loaded is unloaded again. clear_cache also removes its extracted wheel cache first, as Delete cache and reload does. A cloud plugin is installed again from the cloud, as its Reinstall does, and takes no clear_cache; one no longer available is refused. Reply: reloaded, reinstalled and plugin (its row); a reload that fails is an error naming how the plugin is left.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plugin": "my_plugin"
},
"tool": "plugin_reload"
}
],
"title": "Reload a plugin after editing its files"
},
{
"calls": [
{
"args": {
"clear_cache": true,
"plugin": "my_plugin"
},
"tool": "plugin_reload"
}
],
"title": "Reload a plugin with its wheel cache removed"
}
],
"group": "Plugins",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"clear_cache": {
"description": "Remove the plugin's extracted wheel cache before loading it. Default false.",
"type": "boolean"
},
"plugin": {
"description": "The plugin's key, as plugin_list gives it, or its name where one plugin has it.",
"type": "string"
}
},
"required": [
"plugin"
],
"type": "object"
},
"key": "plugin_reload",
"listed": true,
"open_world": true,
"operations": [
"reload_plugin"
],
"read_only": false,
"title": "Reload a plugin"
},
{
"completion": "immediate",
"description": "Remove a plugin for good, without asking, as its row's Delete does once confirmed: it is unloaded where it runs, and its files are removed. A cloud plugin subscribed to is unsubscribed, as its row's Unsubscribe does, which also ends the subscription in the cloud account; the person's own cloud plugin loses its package alone and stays listed, to be installed again. Reply: uninstalled (the key), name, unsubscribed, and plugin where it stays listed; a removal that fails is an error naming how the plugin is left.",
"destructive": true,
"examples": [
{
"calls": [
{
"args": {},
"tool": "plugin_list"
},
{
"args": {
"plugin": "my_plugin"
},
"tool": "plugin_uninstall"
}
],
"title": "Uninstall a plugin"
}
],
"group": "Plugins",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"plugin": {
"description": "The plugin's key, as plugin_list gives it, or its name where one plugin has it.",
"type": "string"
}
},
"required": [
"plugin"
],
"type": "object"
},
"key": "plugin_uninstall",
"listed": true,
"open_world": true,
"operations": [
"uninstall_plugin"
],
"read_only": false,
"title": "Uninstall a plugin"
},
{
"actions": [
{
"args": {},
"description": "Reload plugins.",
"group": "Plugins",
"icon": "",
"key": "refresh_plugins",
"title": "Refresh Plugins"
}
],
"completion": "immediate",
"description": "Reload the plugins, as Refresh Plugins does: the installed plugins are rescanned and the plugin hub's list fetched again, and a notification says how it went. The call waits for the refresh to end and replies with the plugins, as plugin_list gives them; a refresh already running, or waiting, runs before the call's own, so the reply comes from a rescan that began after the call. job_cancel stops the wait, not the refresh.",
"destructive": false,
"group": "Plugins",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "plugin_refresh",
"listed": true,
"open_world": true,
"operations": [
"start_plugin_refresh"
],
"read_only": false,
"title": "Refresh Plugins"
},
{
"actions": [
{
"args": {
"camera": "top"
},
"description": "Turn the camera of the view shown, the Design tab's too, to the top view.",
"group": "View",
"icon": "",
"key": "view_top",
"title": "View: Top"
},
{
"args": {
"camera": "bottom"
},
"description": "Turn the camera of the view shown, the Design tab's too, to the bottom view.",
"group": "View",
"icon": "",
"key": "view_bottom",
"title": "View: Bottom"
},
{
"args": {
"camera": "front"
},
"description": "Turn the camera of the view shown, the Design tab's too, to the front view.",
"group": "View",
"icon": "",
"key": "view_front",
"title": "View: Front"
},
{
"args": {
"camera": "rear"
},
"description": "Turn the camera of the view shown, the Design tab's too, to the rear view.",
"group": "View",
"icon": "",
"key": "view_rear",
"title": "View: Rear"
},
{
"args": {
"camera": "left"
},
"description": "Turn the camera of the view shown, the Design tab's too, to the left view.",
"group": "View",
"icon": "",
"key": "view_left",
"title": "View: Left"
},
{
"args": {
"camera": "right"
},
"description": "Turn the camera of the view shown, the Design tab's too, to the right view.",
"group": "View",
"icon": "",
"key": "view_right",
"title": "View: Right"
},
{
"args": {
"camera": "iso"
},
"description": "Turn the camera of the view shown, the Design tab's too, to the iso view.",
"group": "View",
"icon": "",
"key": "view_iso",
"title": "View: Isometric"
},
{
"args": {
"camera": "default"
},
"description": "Turn the camera of the view shown to the default view and fit the plate; on the Design tab, its Home view.",
"group": "View",
"icon": "",
"key": "view_default",
"title": "View: Default"
},
{
"args": {
"camera": "fit_bed"
},
"description": "Fit the build plate in the 3D view shown; refused on the Design tab, which has no bed to fit.",
"group": "View",
"icon": "",
"key": "view_fit_bed",
"title": "Fit Bed to View"
},
{
"args": {
"projection": "toggle"
},
"description": "Switch the 3D camera between perspective and orthographic.",
"group": "View",
"icon": "",
"key": "view_toggle_perspective",
"title": "Toggle Perspective"
},
{
"args": {
"layout": "default"
},
"description": "Restore the default window layout.",
"group": "View",
"icon": "toolbar_reset",
"key": "reset_window_layout",
"title": "Reset Window Layout"
},
{
"args": {},
"description": "Switch to a main window tab.",
"group": "Commands",
"icon": "",
"input": "tab",
"key": "go_to_tab",
"title": "Go to tab..."
},
{
"args": {},
"description": "Show the Preview tab at a layer chosen as a percentage of the layer range; an error while the Preview has no layers (slice first).",
"group": "Commands",
"icon": "height_range_layer",
"input": "percent",
"input_arg": "layer_percent",
"key": "go_to_layer",
"title": "Go to layer (percent)"
}
],
"completion": "immediate",
"description": "Set up what the window shows, for screenshots and GUI work: the main tab, the 3D view (canvas: Prepare's, the preview or the assemble view, which has its own gizmos), the camera of the 3D view shown (a named direction, the default view, or fit to bed / objects / selection, then look_at, the point it looks at, an orbit to look from between the named directions, and the zoom), the preview's color scheme (picked as in the legend's combo, which shows every feature type again), legend rows, time estimate and layers (1-based, or up to a height). Only the given fields change, but a preview field given without tab or canvas shows the Preview tab. On the Design tab the camera points its view (default is its Home view; no fit_bed; sketch_normal looks straight at the open sketch), and with tab design, section, origin_planes, world_axes, origin and bed set the Design view's switches. The reply echoes them; preview layers as [first, last, count] with z, the heights of first and last; with tab design, design: the section view and the four switches as they then are; with any camera field, camera_state, the camera it leaves as app_state.camera gives it, and adjusted: [\"zoom\"] when the zoom was held to its limits. tab takes the id of any other page of the window too, such as a plugin's. projection sets the 3D camera's, layout default restores the default window layout, and layer_percent shows the Preview at that share of the layer range, as Go to layer does. Outside the Design tab, from any tab: section {on} turns the section view of Prepare and the Preview on or off; labels, overhangs, outline, wireframe, gridlines, axes and navigator set the display switches of the View menu and of the 3D view's own menu; sidebar_collapsed and sidebar_width set the sidebar of Prepare and the Preview; in the Preview, legend_collapsed folds the legend and gcode_window shows the G-code window. Each is echoed as the app reads it back, and app_state's view gives them under these names. A pick of a view action runs the same code in place, so a camera action turns the Design tab's camera too.",
"destructive": false,
"group": "View and windows",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"axes": {
"description": "The axes on the bed of Prepare and the Preview, as the 3D view's own menu sets them; with tab design, world_axes is the Design view's.",
"type": "boolean"
},
"bed": {
"description": "Design tab: the Bed row's eye, the printer bed drawn.",
"type": "boolean"
},
"camera": {
"description": "Camera direction or fit; sketch_normal (Design tab) looks along the open sketch's normal, refused with no sketch open.",
"enum": [
"iso",
"top",
"bottom",
"front",
"rear",
"left",
"right",
"default",
"fit_bed",
"fit_objects",
"fit_selection",
"sketch_normal"
],
"type": "string"
},
"canvas": {
"description": "3D view: Prepare's, the preview, or the assemble view (needs an object; leave it with 3d, as its Return button does).",
"enum": [
"3d",
"preview",
"assemble"
],
"type": "string"
},
"gcode_window": {
"description": "Preview: show (true) or hide (false) the G-code window, as View > Show G-code Window does.",
"type": "boolean"
},
"gridlines": {
"description": "The plate's gridlines, as View > Show Gridlines sets them.",
"type": "boolean"
},
"labels": {
"description": "Prepare: the object labels, as View > Show Labels sets them.",
"type": "boolean"
},
"layer": {
"description": "Preview: show layers up to this one (1-based).",
"minimum": 1,
"type": "integer"
},
"layer_percent": {
"description": "Preview: show the layers up to this share of the layer range, as Go to layer does; the bottom of the shown range stays.",
"maximum": 100,
"minimum": 0,
"type": "number"
},
"layer_range": {
"description": "Preview: [first, last] layers, 1-based.",
"items": {
"type": "integer"
},
"type": "array"
},
"layer_z": {
"description": "Preview: show layers up to the first whose top is at or above this height (mm), as the slider places a custom G-code.",
"minimum": 0,
"type": "number"
},
"layout": {
"description": "default restores the default window layout, as View > Reset Window Layout does.",
"enum": [
"default"
],
"type": "string"
},
"legend": {
"additionalProperties": {
"type": "boolean"
},
"description": "Preview: show (true) or hide (false) legend rows: feature types by name as plate_slice_stats lists them (\"Sparse infill\"), and travel, wipe, retract, unretract, seams, filament_changes, color_changes, pauses, custom_gcode, in any case and with _ or a space between words. Hiding a row this print lacks does nothing. Applied after view_type.",
"type": "object"
},
"legend_collapsed": {
"description": "Preview: fold the legend to its title row (true) or unfold it (false), as its fold button does.",
"type": "boolean"
},
"look_at": {
"description": "[x, y, z] in mm: the point the camera looks at, in the 3D view's world coordinates, as object_list gives positions; on the Design tab, the Design view's, which the Design commands' world points use (describe_design's modeling_origin is the sketch planes' origin). The camera moves parallel, keeping its direction and distance. After camera.",
"items": {
"type": "number"
},
"type": "array"
},
"navigator": {
"description": "The 3D navigator of Prepare and the Preview, as View > Show 3D Navigator sets it.",
"type": "boolean"
},
"orbit": {
"description": "[yaw, pitch] in degrees: move the camera around what it looks at, yaw to its right and pitch up (negative looks from lower), after camera and look_at. The same on every install, unlike a mouse drag.",
"items": {
"type": "number"
},
"type": "array"
},
"origin": {
"description": "Design tab: the Origin row's eye, the XY, XZ and YZ planes kept up where a click picks one; off lets go of a picked plane.",
"type": "boolean"
},
"origin_planes": {
"description": "Design tab: show the origin helper planes (key P).",
"type": "boolean"
},
"outline": {
"description": "The outline around the selected objects, as View > Show Selected Outline sets it.",
"type": "boolean"
},
"overhangs": {
"description": "Prepare: the overhang highlight, as View > Show Overhang sets it.",
"type": "boolean"
},
"projection": {
"description": "The 3D camera's projection; toggle switches between the two.",
"enum": [
"perspective",
"orthographic",
"toggle"
],
"type": "string"
},
"section": {
"additionalProperties": false,
"description": "The section view, a cut that hides part of the model to show inside it. With tab design, the Design view's horizontal cut, as its toolbar's Section View and Flip set it, at z, keeping one half. Without it, the section view of Prepare and the Preview, on alone, as a right click on its toolbar button turns it on and off.",
"properties": {
"keep": {
"description": "The half that stays: lower (the default) or upper.",
"enum": [
"lower",
"upper"
],
"type": "string"
},
"on": {
"description": "Cut the model, or show it whole.",
"type": "boolean"
},
"z": {
"description": "Height of the cut in mm, in the Design view's world coordinates; left out, the model's middle.",
"type": "number"
}
},
"required": [
"on"
],
"type": "object"
},
"sidebar_collapsed": {
"description": "Collapse (true) or expand (false) the sidebar of Prepare and the Preview, as its collapse button does.",
"type": "boolean"
},
"sidebar_width": {
"description": "The sidebar's width in pixels, as a drag of its edge sets it, or \"default\", its width in the default window layout. A sidebar floating in a window of its own is sized with window_set.",
"minimum": 1,
"type": [
"integer",
"string"
]
},
"tab": {
"description": "Main window tab: home, design, prepare, preview, device, multi_device, project, calibration, or the id of another page of the window (monitor_web, the web Device page where the app shows one, or a plugin's page).",
"type": "string"
},
"time_mode": {
"description": "Preview: the time estimate the legend and layer times show; silent only when the print has its own.",
"enum": [
"normal",
"silent"
],
"type": "string"
},
"view_type": {
"description": "Preview color scheme.",
"enum": [
"summary",
"feature_type",
"color_print",
"speed",
"actual_speed",
"height",
"width",
"volumetric_flow_rate",
"actual_volumetric_flow_rate",
"layer_time_linear",
"layer_time_logarithmic",
"fan_speed",
"temperature",
"pressure_advance",
"acceleration",
"jerk"
],
"type": "string"
},
"wireframe": {
"description": "The objects' wireframe, as the 3D view's own menu sets it.",
"type": "boolean"
},
"world_axes": {
"description": "Design tab: show the world axis triad (key A).",
"type": "boolean"
},
"zoom": {
"description": "Screenshot pixels per mm at look_at's depth, so everywhere in an orthographic view; held to the camera's limits (at most 250, at least what the scene's size allows). Applied last.",
"exclusiveMinimum": 0,
"type": "number"
}
},
"type": "object"
},
"key": "view_set",
"listed": true,
"open_world": false,
"operations": [
"show_layer_range"
],
"read_only": false,
"title": "Set up the view"
},
{
"actions": [
{
"args": {
"window": "preferences"
},
"description": "Open the Preferences dialog. window_open with a tab, and a key on it, opens it on that tab with that preference's control scrolled into view and focused (shown on its own tab).",
"group": "Commands",
"icon": "cog",
"key": "open_preferences",
"title": "Preferences"
},
{
"args": {
"window": "plugins"
},
"description": "Open the plugins dialog.",
"group": "Plugins",
"icon": "",
"key": "open_plugins",
"title": "Open Plugins"
},
{
"args": {
"window": "action_replay"
},
"description": "Open the Action Replay window, where a person opens a replay file, reads its steps and replays them. Agents run replays with the replay_run tool instead.",
"group": "Commands",
"icon": "loop",
"key": "open_action_replay",
"title": "Action Replay"
},
{
"args": {
"window": "preset_bundle"
},
"description": "Open the preset bundle manager.",
"group": "Presets",
"icon": "menu_edit_preset",
"key": "preset_bundle",
"title": "Open Preset Bundle"
},
{
"args": {
"window": "keyboard_shortcuts"
},
"description": "Show the keyboard shortcuts dialog.",
"group": "Help",
"icon": "",
"key": "help_keyboard_shortcuts",
"title": "Keyboard Shortcuts"
},
{
"args": {
"window": "setup_wizard"
},
"description": "Open the setup wizard.",
"group": "Help",
"icon": "",
"key": "help_setup_wizard",
"title": "Setup Wizard"
},
{
"args": {
"window": "network_test"
},
"description": "Open the network test dialog.",
"group": "Help",
"icon": "",
"key": "help_network_test",
"title": "Open Network Test"
},
{
"args": {
"window": "troubleshoot"
},
"description": "Open the troubleshooting center.",
"group": "Help",
"icon": "",
"key": "help_troubleshoot",
"title": "Troubleshoot Center"
},
{
"args": {
"window": "tip_of_the_day"
},
"description": "Show a tip of the day.",
"group": "Help",
"icon": "info",
"key": "help_tip_of_the_day",
"title": "Show Tip of the Day"
},
{
"args": {
"window": "about"
},
"description": "Show the About dialog.",
"group": "Help",
"icon": "OrcaSlicer_gradient_circle",
"key": "help_about",
"title": "About OrcaSlicer"
}
],
"completion": "immediate",
"description": "Open one of OrcaSlicer's windows or dialogs for a person, as its menu item does: preferences, the Preferences dialog, with tab, and key on it, on that tab with that preference's control scrolled into view and focused (its controls are named after their preference keys: preferences_get reads them and preferences_set writes those it does not refuse, and widget_set_value {\"target\": {\"name\": key, \"within\": \"Preferences\"}} changes one through the dialog); plugins, the Plugins window; action_replay, the Action Replay window, where a person replays a replay file (agents run one with replay_run); preset_bundle, the preset bundle manager; keyboard_shortcuts; setup_wizard; network_test; troubleshoot, the troubleshooting center; tip_of_the_day; about. A modal one replies blocked_by_dialog.",
"destructive": false,
"group": "View and windows",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"key": {
"description": "preferences, with tab: a preference on that tab, e.g. auto_arrange on behaviour: its control is scrolled into view and focused.",
"type": "string"
},
"tab": {
"description": "preferences: the tab to show.",
"enum": [
"general",
"files",
"behaviour",
"control",
"graphics",
"online",
"developer"
],
"type": "string"
},
"window": {
"description": "The window.",
"enum": [
"preferences",
"plugins",
"action_replay",
"preset_bundle",
"keyboard_shortcuts",
"setup_wizard",
"network_test",
"troubleshoot",
"tip_of_the_day",
"about"
],
"type": "string"
}
},
"required": [
"window"
],
"type": "object"
},
"key": "window_open",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Open a window"
},
{
"completion": "immediate",
"description": "List OrcaSlicer's open windows: the main window, then the windows that don't block the app (Plugins, an object's settings, a dock panel floating on its own), then the modal dialogs in the order they opened, the topmost last. A window's ref goes to window_screenshot as target to capture that window, to widget_list as target to list it alone, and to keyboard_press as target; its title is the within of locators for its widgets.\nReply: each window's title, kind (main, window, dialog, or panel: a dock panel floating on its own), modal, ref, web (it shows a web page), x and y on screen (not on Wayland, which doesn't say), width and height, state (normal, maximized or minimized) and resizable (it has a resize border); window_set changes them.\nA native dialog (a message box, a file picker) has native: true and no ref: dialog_answer answers it. hidden: true marks the person's own windows (the Run Script panel floating, its prompts and Action Replay's, the Python scripts setting), which no tool reaches and screenshots leave out.",
"destructive": false,
"group": "View and windows",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"limit": {
"description": "Default 100.",
"maximum": 200,
"minimum": 1,
"type": "integer"
},
"offset": {
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "window_list",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "List the windows"
},
{
"completion": "immediate",
"description": "Size, move, maximize, minimize or raise a window: the main window (default), the topmost modal dialog, or one window_list lists, also while a modal dialog is open. Size the main window before view_set fits the camera and before recording_start, as a recording keeps its first frame's size. size and position are in the units window_list reports, whose x/y and width/height are read as position and size too. A size or position restores a maximized or minimized window first. A window takes only the states its title bar offers; a modal dialog never minimizes. A refused call changes nothing. Replies once the window holds still and the 3D view has drawn at its new size (3 s at most): title, kind, ref, size, position, state, resizable, scale (screenshot pixels per window unit), display (its work area), active with raise, and adjusted with a note: what the OS or a size limit changed.",
"destructive": false,
"group": "View and windows",
"guard": "recover",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"position": {
"description": "[x, y] of the window's top-left corner on screen; not on Wayland.",
"items": {
"type": "integer"
},
"type": "array"
},
"raise": {
"description": "Bring the window in front of the app's other windows; active in the reply says whether it became the active one.",
"type": "boolean"
},
"size": {
"description": "[width, height], held to the window's minimum and maximum size.",
"items": {
"type": "integer"
},
"type": "array"
},
"state": {
"description": "normal restores a maximized or minimized window; maximized and minimized take no size or position.",
"enum": [
"normal",
"maximized",
"minimized"
],
"type": "string"
},
"target": {
"description": "main (default), dialog (the topmost modal dialog), or a window's ref or locator from window_list; a widget's ref or locator picks the window it is in.",
"type": [
"string",
"object"
]
}
},
"type": "object"
},
"key": "window_set",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Size, move or raise a window"
},
{
"completion": "immediate",
"description": "Capture what OrcaSlicer shows and return it as an image, downscaled to max_dim on the long edge (default 1280), plus the full-size PNG written to save_path (or the session's output folder). target: \"main\" (the main window), \"canvas\" (the visible 3D view exactly as rendered: scene, toolpaths, toolbars, ImGui panels; on the Design tab its view), \"dialog\" (the topmost modal dialog), or a ref: a window's from window_list (one that is not modal, say), or a widget's from widget_list, cropped to that widget (a page element's ref captures its whole web view). The result says when parts may differ from the screen (approximate). Point the view first with view_set.",
"destructive": false,
"group": "Recordings, replays and scripts",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"include_image": {
"description": "Return the image itself (default true); false returns only the path.",
"type": "boolean"
},
"max_dim": {
"description": "Long edge of the returned image.",
"maximum": 2000,
"minimum": 256,
"type": "integer"
},
"overwrite": {
"description": "Replace an existing save_path.",
"type": "boolean"
},
"save_path": {
"description": "Absolute .png path for the full-size image.",
"type": "string"
},
"target": {
"description": "main (default), canvas, dialog, or a widget's ref or locator from widget_list.",
"type": [
"string",
"object"
]
}
},
"type": "object"
},
"key": "window_screenshot",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Take a screenshot"
},
{
"actions": [
{
"args": {},
"description": "Save a PNG of the main window in the folder Start Recording saves in (the person's Downloads unless they chose another) and show the person a notification naming it; the reply has its path. Agents use the window_screenshot tool, which returns the image.",
"group": "Commands",
"icon": "screenshot",
"key": "take_screenshot",
"title": "Take Screenshot"
}
],
"completion": "immediate",
"description": "Save a PNG of the main window in the folder Start Recording saves in (the person's Downloads unless they chose another) and show the person a notification naming it; the reply has its path. Agents use the window_screenshot tool, which returns the image.",
"destructive": false,
"group": "Recordings, replays and scripts",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "window_save_screenshot",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Take Screenshot"
},
{
"completion": "immediate",
"description": "Replay a list of tool calls in order and report each step: {orca_replay_version:\"0.2.0\", name, vars, steps:[{tool, args, expect, optional, await, save_as, timeout_s}]}, JSON with comments. Strings may use ${replay_dir}, ${out_dir}, ${env:NAME}, ${vars.NAME} and ${jobs.NAME}. A step that returns a job is awaited unless await:false, which stores the job under save_as so later steps can answer the dialog it opened. expect maps a JSON pointer into the step's result to matchers (eq ne gt ge lt le contains regex exists empty); the first failed step or expectation stops the run unless the step is optional. Writes result.json to out_dir (default: the replay file's name with .out, beside it; for an inline replay, replay-<timestamp> in the session's output folder). Reply: passed, steps, failed_step, out_dir and result_file. dialog_auto_answer rules a replay registers end with it. replay_export turns this session into one.",
"destructive": false,
"group": "Recordings, replays and scripts",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"out_dir": {
"description": "Absolute directory for result.json and screenshots; created if missing.",
"type": "string"
},
"path": {
"description": "Absolute path of a replay file.",
"type": "string"
},
"replay": {
"description": "The replay itself, as an object or as its JSON text, instead of path.",
"type": [
"object",
"string"
]
},
"vars": {
"description": "Values that override the replay's vars.",
"type": "object"
}
},
"type": "object"
},
"key": "replay_run",
"listed": true,
"open_world": true,
"operations": [],
"read_only": false,
"title": "Run a replay"
},
{
"completion": "immediate",
"description": "Turn the calls this session made into a replay that replay_run runs: mutating calls, app_wait, window_screenshot and the recording tools, in order, with refs replaced by locators, job replies replayed with await:false, and window_screenshot and recording paths moved under ${out_dir}. Calls that failed, at once or as a job later, are left out (a script_run that raised or timed out replied, so it stays); so is a call whose job is still running (unless it waits on a dialog), which left_out_running lists as {tool, job}. Reply: the replay, which with path is also written there. clear:true then forgets the calls made so far.",
"destructive": false,
"group": "Recordings, replays and scripts",
"guard": "inspect",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"clear": {
"description": "Forget the calls recorded so far once exported.",
"type": "boolean"
},
"name": {
"description": "Replay name.",
"type": "string"
},
"overwrite": {
"description": "Replace an existing file.",
"type": "boolean"
},
"path": {
"description": "Absolute .json path to write.",
"type": "string"
}
},
"type": "object"
},
"key": "replay_export",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Export this session as a replay"
},
{
"completion": "immediate",
"description": "Run Python code inside OrcaSlicer as its main program (__name__ == \"__main__\") against orca.host, the whole plugin API (script_search_api searches it): read objects, meshes and settings, compute, use orca.host.ui and the preset API, and call these same tools, with their guards and undo, through orca.host.tools.call(name, args). Mesh and matrix arrays need numpy, which script_search_api says is installed or not; a file run's PEP 723 block can install it. The code runs on a worker thread, where calls documented as UI thread only raise RuntimeError. The run ends once its code and the non-daemon threads and pool tasks it started are done; its windows close with it. `args` holds the args you pass; set `result` to a JSON value to return it; print() output comes back as output. Reply: {status: finished | raised | cancelled | timed_out, result, output, traceback?, message?}; a script that raised changed what it changed before. The code's own file access is held to OrcaSlicer's folders (its data folder, and read only its resources folder and, for a file run, the file's folder), and it starts no programs or threads and reaches no network: such an access raises PermissionError, unless a person has let Python scripts run unrestricted in Preferences (app_state.python.scripts_unrestricted), when the threads and pool tasks it starts call the tools too while the run lasts; the tools it calls work as they do for you. Recorded by replay_export as one step with its code, which a replay runs again against the project as it is then.",
"destructive": false,
"group": "Recordings, replays and scripts",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"args": {
"description": "Bound to the name `args` in the code.",
"type": "object"
},
"code": {
"description": "Python source, run as a module body.",
"type": "string"
},
"filename": {
"description": "The name tracebacks show for the code (default <script_run>). An existing file's path makes it a file run, as `python file.py` runs it: __file__, sys.argv, imports from its folder and its PEP 723 dependencies; any other name only names it. What runs is still `code`: pass the file's text there.",
"type": "string"
},
"timeout_s": {
"description": "The run is stopped as timed_out after this many seconds (default 300).",
"maximum": 3600,
"minimum": 1,
"type": "integer"
}
},
"required": [
"code"
],
"type": "object"
},
"key": "script_run",
"listed": true,
"open_world": true,
"operations": [],
"read_only": false,
"title": "Run a Python script"
},
{
"completion": "immediate",
"description": "Search orca, the Python API of script_run scripts and plugins, in the running build: orca.host (the project's model and meshes, presets and their editors, slicing data, orca.host.ui windows and dialogs, orca.host.tools calling these tools) and the classes, events and pages plugins build on. Each entry has its kind, signature (a class's constructors) and documentation. A query ranks them, best match first; without one, the whole package is listed with each entry's first sentence. Page with offset. numpy says whether numpy is installed, which mesh and matrix arrays need.",
"destructive": false,
"group": "Recordings, replays and scripts",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"limit": {
"description": "At most this many (default 20).",
"maximum": 200,
"minimum": 1,
"type": "integer"
},
"offset": {
"minimum": 0,
"type": "integer"
},
"query": {
"description": "A few words, such as \"mesh normals\" or \"preset value\".",
"type": "string"
}
},
"type": "object"
},
"key": "script_search_api",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Search the Python API"
},
{
"actions": [
{
"args": {},
"description": "Show or hide the Run Script panel, where a person writes and runs Python scripts cell by cell. Agents run Python with the script_run tool instead.",
"group": "Commands",
"icon": "media_play",
"key": "toggle_run_script_panel",
"title": "Run Script"
}
],
"completion": "immediate",
"description": "Show or hide the Run Script panel, where a person writes and runs Python scripts cell by cell. Agents run Python with the script_run tool instead.",
"destructive": false,
"group": "Recordings, replays and scripts",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "script_toggle_panel",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Run Script"
},
{
"actions": [
{
"args": {},
"description": "Runs recording_start with no arguments, as Start Recording does: the Start Recording dialog, whose Start recording starts the person's recording, which neither the end of a replay or script nor the server turning off ends.",
"group": "Commands",
"icon": "recording_start",
"key": "start_recording",
"title": "Start Recording"
}
],
"completion": "immediate",
"description": "Record a video of OrcaSlicer until recording_stop: the main window with any modal dialog on it (target main), or the 3D view shown (canvas). Frames are MJPEG in a Matroska (.mkv) file with their real timestamps. With captions, the tool call acting on the app shows as a caption at the bottom (secret setting values never show); with pointer, the pointer is highlighted, its clicks rippling. Capture takes at most about a third of the UI thread, so the frame rate drops where capturing is slow. One recording at a time: one a replay or script starts ends with it, a client's when the server is turned off. With encode, the recording_stop that reports it also encodes it to an MP4 beside it, as Start Recording does, and the .mkv is deleted once the MP4 is written unless keep_raw_video_file; recording_encode makes an MP4 of any recording later. Called with no arguments, it opens the Start Recording dialog instead, as Start Recording does (blocked_by_dialog): its controls are named after their settings for widget_set_value, dialog_answer \"Start recording\" starts the person's recording, which neither the end of a replay or script nor the server turning off ends, and the dialog remembers the settings; silent: true starts one here at once with the defaults.",
"destructive": false,
"group": "Recordings, replays and scripts",
"guard": "inspect",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"captions": {
"description": "Caption the tool call acting on the app (default false).",
"type": "boolean"
},
"codec": {
"description": "With encode: the codec (default the preset's).",
"enum": [
"h265",
"h264"
],
"type": "string"
},
"crf": {
"description": "With encode: constant rate factor, lower is better and larger (default the preset's).",
"maximum": 51,
"minimum": 0,
"type": "integer"
},
"encode": {
"description": "Encode it to an MP4 once stopped; needs an ffmpeg (default false).",
"type": "boolean"
},
"encode_preset": {
"description": "With encode: the settings the fields below change (default balanced: h265, crf 28, medium, main).",
"enum": [
"small",
"balanced",
"quality",
"compatible"
],
"type": "string"
},
"fps": {
"description": "Frames per second at most (default 10).",
"maximum": 30,
"minimum": 1,
"type": "integer"
},
"jpeg_quality": {
"description": "JPEG quality of the frames (default 80).",
"maximum": 95,
"minimum": 30,
"type": "integer"
},
"keep_raw_video_file": {
"description": "With encode: keep the .mkv beside the MP4 (default false: the encode deletes it once the MP4 is written).",
"type": "boolean"
},
"max_dim": {
"description": "Long edge of the video in pixels (default 1920).",
"maximum": 3840,
"minimum": 320,
"type": "integer"
},
"max_seconds": {
"description": "The recording ends on its own after this long (default 3600).",
"maximum": 3600,
"minimum": 1,
"type": "integer"
},
"overwrite": {
"description": "Replace an existing save_path, and with encode its MP4.",
"type": "boolean"
},
"pointer": {
"description": "Highlight the pointer and show its clicks (default false).",
"type": "boolean"
},
"profile": {
"description": "With encode: h264 high, main or baseline; h265 main or main10 (default the preset's, else the codec's first).",
"enum": [
"high",
"main",
"baseline",
"main10"
],
"type": "string"
},
"save_path": {
"description": "Absolute .mkv path; default the session's output folder.",
"type": "string"
},
"silent": {
"description": "true runs the command without asking; what the call leaves out takes its default. A call with no arguments does what a person's pick does.",
"enum": [
true
],
"type": "boolean"
},
"speed": {
"description": "With encode: slower makes a smaller file (default the preset's).",
"enum": [
"ultrafast",
"superfast",
"veryfast",
"faster",
"fast",
"medium",
"slow",
"slower",
"veryslow"
],
"type": "string"
},
"target": {
"description": "main (default): the main window and its dialogs; canvas: the 3D view shown.",
"enum": [
"main",
"canvas"
],
"type": "string"
}
},
"type": "object"
},
"key": "recording_start",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Start Recording"
},
{
"actions": [
{
"args": {},
"description": "Runs recording_stop with no arguments, as Stop Recording does: it stops the recording, whoever started it, and shows the person a notification naming its file.",
"group": "Commands",
"icon": "recording_stop",
"key": "stop_recording",
"title": "Stop Recording"
}
],
"completion": "immediate",
"description": "Stop the running recording. Call it with silent: true for the report: it waits for the file and returns it with its seconds, frames captured and written, frames dropped when encoding fell behind, failed when they could not be encoded, or skipped when the window could not be captured, the size, the mean UI-thread time a capture took (capture_ms), and why it ended. A recording that ended on its own (max_seconds, the replay or script that started it ended, a write error) is reported once by the next recording_stop. For a recording started with encode, it then starts the MP4 encode and returns it under encode: a job, whose app_wait {for: \"job\"} returns recording_encode's result, whose raw_video_file_deleted says whether the .mkv was deleted. Called with no arguments, it stops the recording as Stop Recording does, whoever started it: without waiting for its file, it shows the person a notification naming it and replies with its path; the next recording_stop with silent: true reports it as ended stopped_in_app.",
"destructive": false,
"group": "Recordings, replays and scripts",
"guard": "inspect",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"silent": {
"description": "true waits for the file and returns the report, and the encode job when the recording has one; a call with no arguments stops as Stop Recording does.",
"enum": [
true
],
"type": "boolean"
}
},
"type": "object"
},
"key": "recording_stop",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Stop Recording"
},
{
"completion": "immediate",
"description": "Encode a recording into an H.265 (or H.264) MP4 with the system ffmpeg (ORCA_FFMPEG, else ffmpeg on PATH; it needs libx265 or libx264), keeping its timing. Takes this session's last finished recording unless path names one, and writes beside it unless save_path says where. A long encode returns a job: app_wait waits for it, or job_cancel {job} stops it. Once the MP4 is written, it deletes the .mkv if this session recorded it, unless keep_raw_video_file; any other .mkv is kept. raw_video_file_deleted in the reply says which.",
"destructive": false,
"group": "Recordings, replays and scripts",
"guard": "inspect",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"codec": {
"description": "Default h265.",
"enum": [
"h265",
"h264"
],
"type": "string"
},
"crf": {
"description": "Constant rate factor, lower is better and larger (default 28 for h265, 23 for h264).",
"maximum": 51,
"minimum": 0,
"type": "integer"
},
"keep_raw_video_file": {
"description": "Keep the .mkv beside the MP4 (default false: a recording this session made is deleted once the MP4 is written).",
"type": "boolean"
},
"overwrite": {
"description": "Replace an existing save_path.",
"type": "boolean"
},
"path": {
"description": "Absolute .mkv of a finished recording; default this session's last.",
"type": "string"
},
"profile": {
"description": "h264: high, main or baseline; h265: main, or main10 for 10 bits per sample. Default the encoder's (high, main).",
"enum": [
"high",
"main",
"baseline",
"main10"
],
"type": "string"
},
"save_path": {
"description": "Absolute .mp4 path; default the recording's, with .mp4.",
"type": "string"
},
"speed": {
"description": "The encoder's preset: slower makes a smaller file of the same quality (default medium).",
"enum": [
"ultrafast",
"superfast",
"veryfast",
"faster",
"fast",
"medium",
"slow",
"slower",
"veryslow"
],
"type": "string"
}
},
"type": "object"
},
"key": "recording_encode",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Encode a recording"
},
{
"completion": "immediate",
"description": "Open a sketch session on a plane, as picking a plane or face for Sketch does. Sketch points are [x, y] in that plane's frame (mm), from its origin: modeling_origin for a base plane. Reply: frame.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
}
],
"title": "A sketch on the XY plane"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"generation": {
"from_call": 1,
"key": "generation"
},
"plane": {
"body": 0,
"face": 5
}
},
"tool": "sketch_create"
}
],
"title": "A sketch on a plate's top face"
},
{
"calls": [
{
"args": {
"base": "XY",
"offset": 20,
"type": "offset"
},
"tool": "construct_plane"
},
{
"args": {
"plane": {
"datum": 0
}
},
"tool": "sketch_create"
}
],
"title": "A sketch on a datum plane 20 mm above XY"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_sketch",
"idempotent": false,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"plane": {
"default": "XY",
"description": "\"XY\", \"XZ\" or \"YZ\" through modeling_origin; {\"datum\": i}, a Plane feature; or {\"body\": b, \"face\": f}, a planar face (origin at its centroid, normal out of the body, x from the world axes). The reply's frame gives the axes.",
"type": [
"string",
"object"
]
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"type": "object"
},
"key": "sketch_create",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Sketch"
},
{
"completion": "immediate",
"description": "Extrude a committed sketch, one of its loops, a face or a drawn profile into a body. A committed sketch, or one loop of it, extrudes as the Extrude card does; push/pull grows a planar face of a body; a profile drawn here is an explicit closed `profile` (list of [x,y]) or a centred width x height rectangle on `plane`. End conditions match Onshape. Reply: extrude_index, the index of its sketch (-1 for a face), the operation and body used, end, frame.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
}
],
"title": "A 20 x 20 x 5 mm plate on the XY plane"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 4,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"distance": 5,
"sketch": 0
},
"tool": "extrude"
}
],
"title": "A committed sketch extruded 5 mm: a rectangle around a circle makes a plate with a bore"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"distance": 3,
"face": 5,
"generation": {
"from_call": 1,
"key": "generation"
}
},
"tool": "extrude"
}
],
"title": "A plate's top face pushed up 3 mm"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_extrude",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"body": {
"default": -1,
"description": "the body to join, cut or intersect, or whose face is pushed; omit for the body a sketch touches, else the last body",
"type": "integer"
},
"distance": {
"default": 10,
"description": "In mm.",
"exclusiveMinimum": 0,
"type": "number"
},
"distance2": {
"default": 0,
"description": "second-side depth when end=two_sided (else falls back to distance) (mm)",
"type": "number"
},
"end": {
"default": "blind",
"enum": [
"blind",
"symmetric",
"two_sided",
"through_all",
"up_to_face"
],
"type": "string"
},
"face": {
"default": null,
"description": "push/pull: a planar face (body_describe id) of `body` grown along its outward normal (flip for inward); operation auto joins that body. sketch, loop, profile, width, height, plane and taper are then refused, and end is blind or symmetric",
"type": [
"integer",
"null"
]
},
"flip": {
"default": false,
"type": "boolean"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"height": {
"default": 20,
"description": "In mm.",
"type": "number"
},
"loop": {
"default": null,
"description": "with sketch: one closed loop (closed_loops[].index of sketch_describe {sketch}) with the loops inside it as holes; a hole is a loop of its own, so its index extrudes the disc. Omit for the whole sketch",
"type": [
"integer",
"null"
]
},
"operation": {
"default": null,
"description": "what the result does to the bodies: new_body makes a body of its own, join fuses it into `body`, cut removes it from `body`, intersect keeps their overlap; auto joins the body the profile touches, else makes a new body, as the card's default. Default auto with sketch or face, new_body without",
"enum": [
"auto",
"new_body",
"join",
"cut",
"intersect",
null
],
"type": [
"string",
"null"
]
},
"plane": {
"default": "XY",
"description": "\"XY\", \"XZ\" or \"YZ\" through modeling_origin; {\"datum\": i}, a Plane feature; or {\"body\": b, \"face\": f}, a planar face (origin at its centroid, normal out of the body, x from the world axes). The reply's frame gives the axes.",
"type": [
"string",
"object"
]
},
"profile": {
"default": [],
"description": "optional closed contour [[x,y],...] in plane mm; overrides width/height",
"type": "array"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"sketch": {
"default": null,
"description": "a committed Sketch feature to extrude (sketch_finish's sketch_index); profile, width, height and plane are then refused",
"type": [
"integer",
"null"
]
},
"taper": {
"default": 0,
"description": "draft/taper of the side wall (deg)",
"type": "number"
},
"up_to_face": {
"default": -1,
"description": "face id (body_describe) of the body the extrude works on, when end=up_to_face",
"type": "integer"
},
"width": {
"default": 20,
"description": "In mm.",
"type": "number"
}
},
"type": "object"
},
"key": "extrude",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Extrude"
},
{
"completion": "immediate",
"description": "Revolve a committed sketch as the Revolve card does, or a profile drawn here, about an axis. A sketch turns about a line of it or a plane axis; a profile drawn here is an explicit `profile` offset from the axis, or a width x height rectangle with one edge on the axis, centred along it, so a full turn is a cylinder width long of radius height. Reply: revolve_index, the index of its sketch, the operation, body and axis used, frame.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"axis": 1,
"plane": "XZ",
"profile": [
[
10,
0
],
[
15,
0
],
[
15,
10
],
[
10,
10
]
]
},
"tool": "revolve"
}
],
"title": "A ring: a profile 10 to 15 mm out from the XZ plane's vertical axis, turned a full circle"
},
{
"calls": [
{
"args": {
"plane": "XZ"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
10,
0
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
{
"construction": true,
"p0": [
0,
0
],
"p1": [
0,
10
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"sketch": 0
},
"tool": "revolve"
}
],
"title": "A committed sketch turned about its centerline, a construction line"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_revolve",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"angle": {
"default": 360,
"description": "In deg.",
"type": "number"
},
"axis": {
"default": 0,
"description": "the plane's X (0) or Y (1) axis through its origin",
"enum": [
0,
1
],
"type": "integer"
},
"axis_entity": {
"default": null,
"description": "with sketch: a line of the sketch (entity index) as the axis, or -1 for the plane axis; omit for the sketch's only centerline (construction line) when it has one and axis is not given",
"type": [
"integer",
"null"
]
},
"body": {
"default": -1,
"description": "the body to join, cut or intersect; omit for the last body",
"type": "integer"
},
"flip": {
"default": false,
"type": "boolean"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"height": {
"default": 10,
"description": "without sketch or profile: how far the rectangle reaches out from the axis, the solid's radius (mm)",
"type": "number"
},
"operation": {
"default": "new_body",
"description": "what the result does to the bodies: new_body makes a body of its own, join fuses it into `body`, cut removes it from `body`, intersect keeps their overlap",
"enum": [
"new_body",
"join",
"cut",
"intersect"
],
"type": "string"
},
"plane": {
"default": "XY",
"description": "\"XY\", \"XZ\" or \"YZ\" through modeling_origin; {\"datum\": i}, a Plane feature; or {\"body\": b, \"face\": f}, a planar face (origin at its centroid, normal out of the body, x from the world axes). The reply's frame gives the axes.",
"type": [
"string",
"object"
]
},
"profile": {
"default": [],
"description": "optional closed contour [[x,y],...] in plane mm; overrides width/height",
"type": "array"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"sketch": {
"default": null,
"description": "a committed Sketch feature to revolve (sketch_finish's sketch_index); profile, width, height and plane are then refused",
"type": [
"integer",
"null"
]
},
"width": {
"default": 20,
"description": "without sketch or profile: the rectangle's length along the axis (mm)",
"type": "number"
}
},
"type": "object"
},
"key": "revolve",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Revolve"
},
{
"completion": "immediate",
"description": "Sweep a committed sketch's closed profile along a path, a sketch or a helix, as the Sweep card does. Draw the profile across the path's start (a helix's start and tangent are in its reply); along a helix the profile keeps its angle to the helix axis. Long sweeps take seconds and the reply may be a job. Reply: sweep_index, bodies, operation, body.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"height": 20,
"pitch": 5,
"radius": 10
},
"tool": "helix"
},
{
"args": {
"plane": "XZ"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
10,
0
],
"radius": 1,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"path": 0,
"sketch": 1
},
"tool": "sweep"
}
],
"title": "A spring: a 2 mm circle across a helix's start, swept along it"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
0,
0
],
"p1": [
0,
40
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"plane": "XZ"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 3,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"path": 0,
"sketch": 1
},
"tool": "sweep"
}
],
"title": "A 6 mm rod swept along a 40 mm line"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_sweep",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"body": {
"default": -1,
"description": "the body a join, cut or intersect works on; omit for the last body",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"operation": {
"default": "new_body",
"description": "what the result does to the bodies: new_body makes a body of its own, join fuses it into `body`, cut removes it from `body`, intersect keeps their overlap",
"enum": [
"new_body",
"join",
"cut",
"intersect"
],
"type": "string"
},
"path": {
"description": "feature index of a sketch or a helix, other than the profile",
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"sketch": {
"description": "the profile: a committed sketch's feature index",
"type": "integer"
}
},
"then": {
"required": [
"sketch",
"path"
]
},
"type": "object"
},
"key": "sweep",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Sweep"
},
{
"completion": "immediate",
"description": "Loft a solid through two or more committed sketches, in order, as the Loft card does. Each sketch is on its own plane (sketch on datum planes). Lofts take seconds and the reply may be a job. Reply: loft_index, bodies, operation, body.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"base": "XY",
"offset": 20,
"type": "offset"
},
"tool": "construct_plane"
},
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-10,
-10
],
"p1": [
10,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"plane": {
"datum": 0
}
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 6,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"profiles": [
1,
2
]
},
"tool": "loft"
}
],
"title": "A square-to-round transition 20 mm tall, the circle sketched on a datum plane"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_loft",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"body": {
"default": -1,
"description": "the body a join, cut or intersect works on; omit for the last body",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"operation": {
"default": "new_body",
"description": "what the result does to the bodies: new_body makes a body of its own, join fuses it into `body`, cut removes it from `body`, intersect keeps their overlap",
"enum": [
"new_body",
"join",
"cut",
"intersect"
],
"type": "string"
},
"profiles": {
"description": "sketch feature indices, in loft order",
"type": "array"
},
"ruled": {
"default": false,
"description": "straight sections between the profiles instead of a smooth skin",
"type": "boolean"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"profiles"
]
},
"type": "object"
},
"key": "loft",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Loft"
},
{
"actions": [
{
"args": {
"type": "surface"
},
"description": "Thicken a sheet body into a solid. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"icon": "design_thicken",
"key": "thicken_surf",
"title": "Thicken Surface"
}
],
"completion": "immediate",
"description": "Thicken a face of a body, or a whole sheet body, into a new solid body by a wall thickness. type face offsets one face of a body into a thin plate. type surface thickens a sheet body: a sheet of several faces whose free rims close into planar loops (the walls of a box with no lids) is capped at them and grows inward, into the closed shape that makes, whatever flip says; one whose rim can't be capped is refused. A single face or a closed shell is offset face by face along each face's normal, the one body_describe gives, or against it with flip; a closed shell can fail to thicken this way. Reply: thicken_index, bodies. Called with exactly one of these argument sets and nothing else, it opens that item's tool of the Design tab for a person, as the menu item does: {\"type\":\"face\"} (Thicken), {\"type\":\"surface\"} (Thicken Surface).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"face": 5,
"generation": {
"from_call": 1,
"key": "generation"
},
"thickness": 2
},
"tool": "thicken"
}
],
"title": "A 2 mm skin grown from a plate's top face as a new body"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"sketch": 0
},
"tool": "surface_patch"
},
{
"args": {
"thickness": 2,
"type": "surface"
},
"tool": "thicken"
}
],
"title": "A 30 x 20 mm sheet thickened into a 2 mm plate, a new body"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 10,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"distance": 20,
"sketch": 0
},
"tool": "surface_extrude"
},
{
"args": {
"body": 0,
"flip": true,
"thickness": 1.5,
"type": "surface"
},
"tool": "thicken"
}
],
"title": "An open tube thickened 1.5 mm outward into a pipe: flip, as its normal points inward"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_thicken",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"body": {
"default": -1,
"description": "the body, a sheet body for type surface; omit for the last body",
"type": "integer"
},
"face": {
"default": null,
"description": "with type face: the face id to thicken (body_describe); refused with type surface",
"type": [
"integer",
"null"
]
},
"flip": {
"default": false,
"type": "boolean"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"thickness": {
"default": 2,
"description": "In mm.",
"type": "number"
},
"type": {
"default": null,
"description": "face thickens `face` of the body; surface thickens the whole sheet body. Left out: face when `face` is given, else surface",
"enum": [
"face",
"surface",
null
],
"type": [
"string",
"null"
]
}
},
"type": "object"
},
"key": "thicken",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Thicken"
},
{
"completion": "immediate",
"description": "Grow a thin rib wall (stiffener) from an open Line sketch entity, fused to a body. The wall is centred on the line in the sketch plane, thickness wide, and grows depth along the sketch plane's normal. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 3,
"height": 20,
"width": 40
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"generation": {
"from_call": 1,
"key": "generation"
},
"plane": {
"body": 0,
"face": 5
}
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
-15,
0
],
"p1": [
15,
0
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"depth": 8,
"entity": 0,
"sketch": 2,
"thickness": 2
},
"tool": "rib"
}
],
"title": "A 2 mm rib 8 mm tall across a plate's top face"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_rib",
"idempotent": false,
"input_schema": {
"if": {
"minProperties": 1
},
"properties": {
"body": {
"default": -1,
"description": "target body; omit for the last body",
"type": "integer"
},
"depth": {
"default": 10,
"description": "along the sketch plane's normal, or against it when negative (mm)",
"type": "number"
},
"entity": {
"description": "entity index of the open Line within the sketch",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"sketch": {
"description": "sketch feature index holding the open line",
"type": "integer"
},
"thickness": {
"default": 2,
"description": "In mm.",
"type": "number"
}
},
"then": {
"required": [
"sketch",
"entity"
]
},
"type": "object"
},
"key": "rib",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Rib"
},
{
"actions": [
{
"args": {
"operation": "cut"
},
"description": "Cut the tool body out of the target. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"icon": "design_boolean",
"key": "bool_subtract",
"title": "Subtract"
},
{
"args": {
"operation": "intersect"
},
"description": "Keep only where the two bodies overlap. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"icon": "design_boolean",
"key": "bool_intersect",
"title": "Intersect"
}
],
"completion": "immediate",
"description": "Combine two bodies: join them, cut the tool from the target, or keep where they intersect. A rejected rebuild is reported in the reply: ok is false or error is not empty. Called with exactly one of these argument sets and nothing else, it opens that item's tool of the Design tab for a person, as the menu item does: {\"operation\":\"join\"} (Join), {\"operation\":\"cut\"} (Subtract), {\"operation\":\"intersect\"} (Intersect).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 10,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"distance": 20,
"height": 6,
"operation": "new_body",
"width": 6
},
"tool": "extrude"
},
{
"args": {
"operation": "cut",
"target": 0,
"tool": 1
},
"tool": "boolean"
}
],
"title": "A post cut from a block"
},
{
"calls": [
{
"args": {
"distance": 10,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"distance": 10,
"operation": "new_body",
"profile": [
[
5,
-5
],
[
20,
-5
],
[
20,
5
],
[
5,
5
]
]
},
"tool": "extrude"
},
{
"args": {
"operation": "join",
"target": 0,
"tool": 1
},
"tool": "boolean"
}
],
"title": "Two overlapping blocks joined into one body"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_boolean",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"keep_tool": {
"default": false,
"type": "boolean"
},
"operation": {
"description": "join fuses the tool into the target; cut removes the tool from the target; intersect keeps only where the two overlap",
"enum": [
"join",
"cut",
"intersect"
],
"type": "string"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"target": {
"default": 0,
"type": "integer"
},
"tolerance": {
"default": 0,
"description": "In mm.",
"type": "number"
},
"tool": {
"default": 1,
"type": "integer"
}
},
"then": {
"required": [
"operation"
]
},
"type": "object"
},
"key": "boolean",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Join"
},
{
"completion": "immediate",
"description": "Extrude a sketch wire with no end caps -> an open sheet body. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
-15,
0
],
"p1": [
15,
0
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"distance": 10,
"sketch": 0
},
"tool": "surface_extrude"
}
],
"title": "A 30 mm line extruded 10 mm into a flat sheet"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 10,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"distance": 20,
"sketch": 0
},
"tool": "surface_extrude"
}
],
"title": "A circle extruded 20 mm into an open tube, with no end caps"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_extrude",
"idempotent": false,
"input_schema": {
"if": {
"minProperties": 1
},
"properties": {
"distance": {
"default": 10,
"description": "along the sketch plane's normal, or against it when negative (mm)",
"type": "number"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"sketch": {
"description": "sketch feature index",
"type": "integer"
}
},
"then": {
"required": [
"sketch"
]
},
"type": "object"
},
"key": "surface_extrude",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Surface Extrude"
},
{
"completion": "immediate",
"description": "Revolve a sketch wire with no caps -> an open sheet body. The axis is chosen as revolve chooses it: axis_entity, else the sketch's only centerline when axis is not given, else the plane axis. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XZ"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
10,
0
],
"p1": [
10,
20
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"axis": 1,
"sketch": 0
},
"tool": "surface_revolve"
}
],
"title": "A cylinder's wall: a line 10 mm out from the XZ plane's vertical axis, turned a full circle"
},
{
"calls": [
{
"args": {
"plane": "XZ"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
5,
0
],
"p1": [
15,
20
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"angle": 180,
"axis": 1,
"sketch": 0
},
"tool": "surface_revolve"
}
],
"title": "Half a truncated cone's wall: a sloping line turned 180 degrees about the XZ plane's vertical axis"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_revolve",
"idempotent": false,
"input_schema": {
"if": {
"minProperties": 1
},
"properties": {
"angle": {
"default": 360,
"description": "In deg.",
"type": "number"
},
"axis": {
"default": 0,
"description": "the sketch plane's X (0) or Y (1) axis through its origin",
"enum": [
0,
1
],
"type": "integer"
},
"axis_entity": {
"default": null,
"description": "a line of the sketch (entity index) as the axis, or -1 for the plane axis; omit for the sketch's only centerline (construction line) when it has one and axis is not given",
"type": [
"integer",
"null"
]
},
"flip": {
"default": false,
"description": "turn the other way about the axis",
"type": "boolean"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"sketch": {
"description": "sketch feature index",
"type": "integer"
}
},
"then": {
"required": [
"sketch"
]
},
"type": "object"
},
"key": "surface_revolve",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Surface Revolve"
},
{
"completion": "immediate",
"description": "Skin two or more profile sketches with no end caps -> an open sheet body. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"base": "XY",
"offset": 20,
"type": "offset"
},
"tool": "construct_plane"
},
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 5,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"plane": {
"datum": 0
}
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 15,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"profiles": [
1,
2
]
},
"tool": "surface_loft"
}
],
"title": "An open funnel skinned from a circle on XY to a wider one on a datum plane 20 mm up"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_loft",
"idempotent": false,
"input_schema": {
"if": {
"minProperties": 1
},
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"profiles": {
"description": "sketch feature indices, in order",
"type": "array"
},
"ruled": {
"default": false,
"type": "boolean"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"profiles"
]
},
"type": "object"
},
"key": "surface_loft",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Surface Loft"
},
{
"completion": "immediate",
"description": "Fill a sketch's closed boundary with one smooth face -> a sheet body. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 10,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"sketch": 0
},
"tool": "surface_patch"
}
],
"title": "A circle filled with a disc-shaped sheet"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"sketch": 0
},
"tool": "surface_patch"
}
],
"title": "A rectangle filled with a flat sheet"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_surface",
"idempotent": false,
"input_schema": {
"if": {
"minProperties": 1
},
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"sketch": {
"description": "sketch feature index",
"type": "integer"
}
},
"then": {
"required": [
"sketch"
]
},
"type": "object"
},
"key": "surface_patch",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Surface Fill"
},
{
"completion": "immediate",
"description": "Drill a hole, simple, counterbored or countersunk, at (x,y) or `at` on a plane. type counterbore or countersink seats a screw head: a counterbore sized by cbore_*, a countersink by csink_*, each refused with another type. designation drills a standard clearance hole (ISO 273 / ANSI) and sizes its seat to the standard, in place of diameter. Reply: hole_index, body, x and y in the frame, off_plane with at, frame.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"diameter": 5,
"through": true
},
"tool": "hole"
}
],
"title": "A 5 mm hole through the middle of a plate"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"csink_angle": 90,
"csink_diameter": 9,
"diameter": 4.5,
"generation": {
"from_call": 1,
"key": "generation"
},
"plane": {
"body": 0,
"face": 5
},
"through": true,
"type": "countersink"
},
"tool": "hole"
}
],
"title": "A countersunk hole through a plate's top face"
},
{
"calls": [
{
"args": {
"distance": 10,
"height": 30,
"width": 30
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"designation": "M6",
"generation": {
"from_call": 1,
"key": "generation"
},
"plane": {
"body": 0,
"face": 5
},
"through": true,
"type": "counterbore"
},
"tool": "hole"
}
],
"title": "An M6 counterbored clearance hole through a 10 mm block's top face"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_hole",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"at": {
"default": null,
"description": "instead of x and y: a world point [x, y, z], projected onto the plane along its normal (off_plane says how far), or {\"body\": b, \"face\": f} a cylindrical face or {\"body\": b, \"edge\": e} a circular edge whose axis the hole shares. A world point moves with modeling_origin; x and y replay on any printer",
"type": [
"array",
"object",
"null"
]
},
"body": {
"default": -1,
"description": "the body to drill; omit for a face plane's body, else the last body",
"type": "integer"
},
"cbore_depth": {
"default": 0,
"description": "with type counterbore, refused with the others: its depth from the face (mm)",
"type": "number"
},
"cbore_diameter": {
"default": 0,
"description": "with type counterbore, refused with the others: the counterbore's diameter (mm)",
"type": "number"
},
"csink_angle": {
"default": 90,
"description": "with type countersink, refused with the others: its included angle (deg)",
"type": "number"
},
"csink_diameter": {
"default": 0,
"description": "with type countersink, refused with the others: the countersink's diameter at the face (mm)",
"type": "number"
},
"depth": {
"default": 10,
"description": "In mm.",
"type": "number"
},
"designation": {
"default": null,
"description": "a standard clearance size, e.g. M6 or 1/4-20: the hole and its seat are the standard's; refused with diameter, cbore_*, csink_* and standard",
"type": [
"string",
"null"
]
},
"diameter": {
"default": 5,
"description": "refused with designation, which gives it (mm)",
"exclusiveMinimum": 0,
"type": "number"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"plane": {
"default": "XY",
"description": "\"XY\", \"XZ\" or \"YZ\" through modeling_origin; {\"datum\": i}, a Plane feature; or {\"body\": b, \"face\": f}, a planar face to drill into that body (origin at its centroid, normal into the body, x along its longest edge). The reply's frame gives the axes.",
"type": [
"string",
"object"
]
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"standard": {
"default": "",
"description": "the designation the hole was sized for, e.g. M6, kept with the feature; it sizes nothing",
"type": "string"
},
"through": {
"default": false,
"type": "boolean"
},
"type": {
"default": "simple",
"description": "the hole's seat for a screw head: none, a counterbore or a countersink",
"enum": [
"simple",
"counterbore",
"countersink"
],
"type": "string"
},
"x": {
"default": 0,
"description": "offset in the plane's frame from its origin, NOT world (mm)",
"type": "number"
},
"y": {
"default": 0,
"description": "offset in the plane's frame from its origin, NOT world (mm)",
"type": "number"
}
},
"type": "object"
},
"key": "hole",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Hole"
},
{
"completion": "immediate",
"description": "Cut a thread as the Thread card does, along a cylindrical face or a circular edge, or on a plane. On a face a bore is tapped, a boss threaded; on a plane the thread goes at (x,y) or `at`. Without designation, a face or edge takes the nearest standard size, ISO metric and UTS alike. Long threads take seconds and the reply may be a job. Reply: thread_index, designation (null when custom), internal, diameter, pitch, depth, length, body, x, y, frame.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 10,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"diameter": 6.8,
"through": true
},
"tool": "hole"
},
{
"args": {
"body": 0,
"kinds": [
"cylindrical"
]
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"designation": "M8",
"face": 6,
"generation": {
"from_call": 2,
"key": "generation"
}
},
"tool": "thread"
}
],
"title": "An M8 thread tapped into a 6.8 mm hole through a block"
},
{
"calls": [
{
"args": {
"designation": "M6",
"internal": false,
"length": 10,
"plane": "XY"
},
"tool": "thread"
}
],
"title": "An M6 threaded rod 10 mm long, standing on the XY plane"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 5,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"distance": 12,
"sketch": 0
},
"tool": "extrude"
},
{
"args": {
"body": 0,
"kinds": [
"cylindrical"
]
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"face": 0,
"generation": {
"from_call": 4,
"key": "generation"
}
},
"tool": "thread"
}
],
"title": "A 10 mm boss threaded at the nearest standard size, which the reply's designation names"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_thread",
"idempotent": false,
"input_schema": {
"properties": {
"at": {
"default": null,
"description": "on a plane, instead of x and y: a world point [x, y, z], or {\"body\": b, \"face\": f} a cylindrical face or {\"body\": b, \"edge\": e} a circular edge whose axis the thread shares, as hole takes it",
"type": [
"array",
"object",
"null"
]
},
"body": {
"default": -1,
"description": "the body of face or edge, or the body threaded on a plane; omit for the last body (on a plane, a face plane's body)",
"type": "integer"
},
"depth": {
"default": null,
"description": "radial depth; default the 60 degree V's for the pitch and role (mm)",
"type": [
"number",
"null"
]
},
"designation": {
"default": null,
"description": "e.g. M5, M8x1, 1/4-20 UNC: sets diameter, pitch and depth",
"type": [
"string",
"null"
]
},
"diameter": {
"default": null,
"description": "nominal (major) diameter, replacing the standard's; with pitch, a custom thread (mm)",
"type": [
"number",
"null"
]
},
"edge": {
"default": null,
"description": "instead of face: a circular edge id of `body`, the thread rising along its normal; needs length",
"type": [
"integer",
"null"
]
},
"face": {
"default": null,
"description": "a cylindrical face id of `body` (body_describe); the thread runs its length from its lower end",
"type": [
"integer",
"null"
]
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"internal": {
"default": null,
"description": "true taps a hole, false threads a rod; required on a plane, else from the face (a bore is internal), external for an edge",
"type": [
"boolean",
"null"
]
},
"length": {
"default": null,
"description": "default the face's length; required for an edge or a plane (mm)",
"type": [
"number",
"null"
]
},
"pitch": {
"default": null,
"description": "replaces the standard's (mm)",
"type": [
"number",
"null"
]
},
"plane": {
"default": null,
"description": "\"XY\", \"XZ\" or \"YZ\" through modeling_origin; {\"datum\": i}, a Plane feature; or {\"body\": b, \"face\": f}, a planar face to drill into that body (origin at its centroid, normal into the body, x along its longest edge). The reply's frame gives the axes.",
"type": [
"string",
"object"
]
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"x": {
"default": 0,
"description": "on a plane: offset in the plane's frame from its origin, NOT world (mm)",
"type": "number"
},
"y": {
"default": 0,
"description": "on a plane: offset in the plane's frame from its origin, NOT world (mm)",
"type": "number"
}
},
"type": "object"
},
"key": "thread",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Thread"
},
{
"completion": "immediate",
"description": "Hollow a body to a wall thickness (inward); optionally leave one face open. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 10,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"face": 5,
"generation": {
"from_call": 1,
"key": "generation"
},
"thickness": 1.5
},
"tool": "shell"
}
],
"title": "A 20 x 20 x 10 mm box hollowed to 1.5 mm walls, open at the top"
},
{
"calls": [
{
"args": {
"distance": 10,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"thickness": 2
},
"tool": "shell"
}
],
"title": "A block hollowed to closed 2 mm walls"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_shell",
"idempotent": false,
"input_schema": {
"properties": {
"body": {
"default": -1,
"description": "target body; omit for the last body",
"type": "integer"
},
"face": {
"default": -1,
"description": "face id to leave open (body_describe); omit for a closed hollow",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"thickness": {
"default": 1,
"description": "In mm.",
"exclusiveMinimum": 0,
"type": "number"
}
},
"type": "object"
},
"key": "shell",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Shell"
},
{
"completion": "immediate",
"description": "Split a body with a plane, as the Cut card does, moved by offset and turned over by flip; or along the plane of a face. The upper piece is on the plane's normal side; keeping both makes two bodies, the lower one right after the upper. Reply: split_index, bodies, body, upper_body and lower_body (the pieces kept), frame (a plane's, after offset and flip).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 10,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"offset": 5,
"plane": "XY"
},
"tool": "split"
}
],
"title": "A block cut in two at half its height"
},
{
"calls": [
{
"args": {
"distance": 10,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"keep_upper": false,
"offset": 5,
"plane": "XY"
},
"tool": "split"
}
],
"title": "A block cut at half its height, keeping only the lower half"
},
{
"calls": [
{
"args": {
"distance": 10,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"distance": 4,
"height": 30,
"operation": "new_body",
"width": 30
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 1
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"face": 5,
"face_body": 1,
"generation": {
"from_call": 2,
"key": "generation"
}
},
"tool": "split"
}
],
"title": "A block split along the top face of a wider plate"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_cut",
"idempotent": false,
"input_schema": {
"properties": {
"body": {
"default": -1,
"description": "target body; omit for the last body",
"type": "integer"
},
"face": {
"default": null,
"description": "instead of plane: a face id (body_describe) to split along",
"type": [
"integer",
"null"
]
},
"face_body": {
"default": -1,
"description": "with face: the body that owns it; -1 = target",
"type": "integer"
},
"flip": {
"default": false,
"description": "with plane: turn it over, swapping upper and lower",
"type": "boolean"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"keep_lower": {
"default": true,
"type": "boolean"
},
"keep_upper": {
"default": true,
"type": "boolean"
},
"offset": {
"default": 0,
"description": "with plane: along its normal (mm)",
"type": "number"
},
"plane": {
"default": null,
"description": "\"XY\", \"XZ\" or \"YZ\" through modeling_origin; {\"datum\": i}, a Plane feature; or {\"body\": b, \"face\": f}, a planar face (origin at its centroid, normal out of the body, x from the world axes). The reply's frame gives the axes.",
"type": [
"string",
"object",
"null"
]
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"type": "object"
},
"key": "split",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Cut"
},
{
"completion": "immediate",
"description": "Round measured edges of a body (edge ids from body_describe on that body). Reply: fillet_index, body, bodies.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"body": 0,
"convex": true,
"direction": [
0,
0,
1
],
"edge_kinds": [
"line"
]
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"edges": [
0,
1,
4,
7
],
"generation": {
"from_call": 1,
"key": "generation"
},
"radius": 2
},
"tool": "fillet"
}
],
"title": "A plate's four vertical corners rounded to 2 mm"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"adjacency": true,
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"edges": 3,
"generation": {
"from_call": 1,
"key": "generation"
},
"radius": 1
},
"tool": "fillet"
}
],
"title": "One top edge of a plate rounded to 1 mm"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_filletedge",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"body": {
"default": -1,
"description": "target body; omit for the last body. The edge ids are resolved against this body.",
"type": "integer"
},
"edges": {
"description": "one edge id, or an array of ids rounded together in one feature; or an edge group, the card's Edges choice: \"top\", \"bottom\", \"lateral\" or \"all\"",
"type": [
"integer",
"array",
"string"
]
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"radius": {
"default": 1,
"description": "In mm.",
"exclusiveMinimum": 0,
"type": "number"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"edges"
]
},
"type": "object"
},
"key": "fillet",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Fillet"
},
{
"completion": "immediate",
"description": "Chamfer measured edges of a body (edge ids from body_describe on that body). Reply: chamfer_index, body, bodies.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"adjacency": true,
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"distance": 1,
"edges": [
3,
6,
9,
11
],
"generation": {
"from_call": 1,
"key": "generation"
}
},
"tool": "chamfer"
}
],
"title": "A plate's top edges chamfered 1 mm"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_chamfer",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"body": {
"default": -1,
"description": "target body; omit for the last body. The edge ids are resolved against this body.",
"type": "integer"
},
"distance": {
"default": 1,
"description": "In mm.",
"exclusiveMinimum": 0,
"type": "number"
},
"edges": {
"description": "one edge id, or an array of ids chamfered together in one feature; or an edge group, the card's Edges choice: \"top\", \"bottom\", \"lateral\" or \"all\"",
"type": [
"integer",
"array",
"string"
]
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"edges"
]
},
"type": "object"
},
"key": "chamfer",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Chamfer"
},
{
"completion": "immediate",
"description": "Taper a body face by an angle about its base (pull direction +Z). A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 10,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"body": 0,
"direction": [
1,
0,
0
]
},
"tool": "body_describe"
},
{
"args": {
"angle": 5,
"body": 0,
"face": 1,
"generation": {
"from_call": 1,
"key": "generation"
}
},
"tool": "draft"
}
],
"title": "A block's +X side tapered 5 degrees"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_draft",
"idempotent": false,
"input_schema": {
"if": {
"minProperties": 1
},
"properties": {
"angle": {
"default": 5,
"description": "In deg.",
"type": "number"
},
"body": {
"default": -1,
"description": "target body; omit for the last body",
"type": "integer"
},
"face": {
"description": "face id to draft (body_describe)",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"face"
]
},
"type": "object"
},
"key": "draft",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Draft"
},
{
"completion": "immediate",
"description": "Offset a sheet body by a signed distance -> another sheet body. A positive offset moves each face along its normal, the one body_describe gives, and a negative one against it, so the side depends on how the sheet was made: an extruded circle's normal points inward. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"sketch": 0
},
"tool": "surface_patch"
},
{
"args": {
"offset": 5
},
"tool": "surface_offset"
}
],
"title": "A rectangular sheet copied 5 mm above itself"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 10,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"distance": 20,
"sketch": 0
},
"tool": "surface_extrude"
},
{
"args": {
"body": 0,
"offset": -2
},
"tool": "surface_offset"
}
],
"title": "An open tube of radius 10 mm offset -2 mm, against its inward normal, to one of radius 12 mm"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_offset",
"idempotent": false,
"input_schema": {
"properties": {
"body": {
"default": -1,
"description": "sheet body; omit for the last body",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"offset": {
"default": 1,
"description": "In mm.",
"type": "number"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"type": "object"
},
"key": "surface_offset",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Surface Offset"
},
{
"actions": [
{
"args": {
"type": "circular"
},
"description": "Repeat the body around an axis — set the count and sweep. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"icon": "design_polararray",
"key": "pattern_circular",
"title": "Circular pattern"
}
],
"completion": "immediate",
"description": "Replicate a body in a row, around the plane's normal, or along a sketch curve. linear places count copies along a plane axis at spacing; circular spreads them over angle about the plane's normal through its origin; curve places them at equal-parameter points on a sketch entity, each translated by (P_i - P_0). An argument of one type is refused with another. Reply: pattern_index, bodies, and for linear and circular the frame. Called with exactly one of these argument sets and nothing else, it opens that item's tool of the Design tab for a person, as the menu item does: {\"type\":\"linear\"} (Linear pattern), {\"type\":\"circular\"} (Circular pattern).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"count": 3,
"spacing": 30
},
"tool": "pattern"
}
],
"title": "Three plates 30 mm apart along X"
},
{
"calls": [
{
"args": {
"distance": 5,
"profile": [
[
20,
-3
],
[
30,
-3
],
[
30,
3
],
[
20,
3
]
]
},
"tool": "extrude"
},
{
"args": {
"count": 6,
"type": "circular"
},
"tool": "pattern"
}
],
"title": "Six blocks in a circle about the XY plane's normal"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"end_angle_deg": 180,
"radius": 30,
"start_angle_deg": 0,
"type": "arc_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"distance": 10,
"profile": [
[
28,
-2
],
[
32,
-2
],
[
32,
2
],
[
28,
2
]
]
},
"tool": "extrude"
},
{
"args": {
"count": 4,
"entity": 0,
"sketch": 0,
"type": "curve"
},
"tool": "pattern"
}
],
"title": "Four pegs spaced along a half circle"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_array",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"angle": {
"default": 360,
"description": "with type circular, refused with the others: the total sweep (deg)",
"type": "number"
},
"body": {
"default": -1,
"description": "target body; omit for the last body",
"type": "integer"
},
"count": {
"default": 3,
"minimum": 1,
"type": "integer"
},
"dir": {
"default": 0,
"description": "with type linear, refused with the others: the axis, 0=plane X, 1=plane Y",
"enum": [
0,
1
],
"type": "integer"
},
"entity": {
"default": null,
"description": "with type curve, which requires it: the guide curve's entity index within that sketch; refused with the other types",
"type": [
"integer",
"null"
]
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"plane": {
"default": "XY",
"description": "with type linear or circular, refused with curve: \"XY\", \"XZ\" or \"YZ\" through modeling_origin; {\"datum\": i}, a Plane feature; or {\"body\": b, \"face\": f}, a planar face (origin at its centroid, normal out of the body, x from the world axes). The reply's frame gives the axes.",
"type": [
"string",
"object"
]
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"sketch": {
"default": null,
"description": "with type curve, which requires it: the feature index of the sketch holding the guide curve; refused with the other types",
"type": [
"integer",
"null"
]
},
"spacing": {
"default": 10,
"description": "with type linear, refused with the others: the step between copies (mm)",
"type": "number"
},
"type": {
"default": "linear",
"description": "the copies' layout: in a row, around the plane's normal, or along a sketch curve",
"enum": [
"linear",
"circular",
"curve"
],
"type": "string"
}
},
"type": "object"
},
"key": "pattern",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Linear pattern"
},
{
"completion": "immediate",
"description": "Mirror a body about a base plane. operation new_body makes a mirrored copy; join fuses the mirror back into the source. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"profile": [
[
-5,
5
],
[
5,
5
],
[
5,
15
],
[
-5,
15
]
]
},
"tool": "extrude"
},
{
"args": {
"plane": "XZ"
},
"tool": "mirror"
}
],
"title": "A mirrored copy of a block across the XZ plane"
},
{
"calls": [
{
"args": {
"distance": 5,
"profile": [
[
-5,
0
],
[
5,
0
],
[
5,
10
],
[
-5,
10
]
]
},
"tool": "extrude"
},
{
"args": {
"operation": "join",
"plane": "XZ"
},
"tool": "mirror"
}
],
"title": "A block against the XZ plane and its mirror image fused into one body"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_mirror",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"body": {
"default": -1,
"description": "target body; omit for the last body",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"keep_original": {
"default": true,
"description": "with operation new_body, keep the source body",
"type": "boolean"
},
"operation": {
"default": "new_body",
"description": "what the mirror does to the source body: new_body makes a body of its own, join fuses it into the source",
"enum": [
"new_body",
"join"
],
"type": "string"
},
"plane": {
"default": "XZ",
"description": "\"XY\", \"XZ\" or \"YZ\" through modeling_origin; {\"datum\": i}, a Plane feature; or {\"body\": b, \"face\": f}, a planar face (origin at its centroid, normal out of the body, x from the world axes). The reply's frame gives the axes.",
"type": [
"string",
"object"
]
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"type": "object"
},
"key": "mirror",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Mirror"
},
{
"completion": "immediate",
"description": "Move and/or rotate a body (B-rep transform). copy=true keeps the source and appends the transformed copy as a new body. The rotation is angle about the axis (axis_x, axis_y, axis_z) through the pivot, a world point that defaults to the world origin. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"dx": 30
},
"tool": "body_transform"
}
],
"title": "A plate moved 30 mm along X"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"copy": true,
"dz": 10
},
"tool": "body_transform"
}
],
"title": "A copy of a plate 10 mm above it"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_move",
"idempotent": false,
"input_schema": {
"properties": {
"angle": {
"default": 0,
"description": "In deg.",
"type": "number"
},
"axis_x": {
"default": 0,
"type": "number"
},
"axis_y": {
"default": 0,
"type": "number"
},
"axis_z": {
"default": 1,
"type": "number"
},
"body": {
"default": -1,
"description": "target body; omit for the last body",
"type": "integer"
},
"copy": {
"default": false,
"type": "boolean"
},
"dx": {
"default": 0,
"description": "In mm.",
"type": "number"
},
"dy": {
"default": 0,
"description": "In mm.",
"type": "number"
},
"dz": {
"default": 0,
"description": "In mm.",
"type": "number"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"pivot_x": {
"default": 0,
"description": "In mm.",
"type": "number"
},
"pivot_y": {
"default": 0,
"description": "In mm.",
"type": "number"
},
"pivot_z": {
"default": 0,
"description": "In mm.",
"type": "number"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"type": "object"
},
"key": "body_transform",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Move"
},
{
"completion": "immediate",
"description": "Align two bodies: transform the moving body (cs_b) so its connector lands on the fixed one (cs_a). An align that cannot hold with those before it is listed in describe_design's align_conflicts, with the reason. Reply: align_index, bodies.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"distance": 10,
"operation": "new_body",
"profile": [
[
30,
-5
],
[
40,
-5
],
[
40,
5
],
[
30,
5
]
]
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"face": 5,
"generation": {
"from_call": 2,
"key": "generation"
},
"type": "face_and_direction"
},
"tool": "construct_coordinate_system"
},
{
"args": {
"at_extreme": "-z",
"body": 1
},
"tool": "body_describe"
},
{
"args": {
"body": 1,
"face": 4,
"generation": {
"from_call": 4,
"key": "generation"
},
"type": "face_and_direction"
},
"tool": "construct_coordinate_system"
},
{
"args": {
"cs_a": 4,
"cs_b": 5,
"flip": true,
"type": "fastened"
},
"tool": "align"
}
],
"title": "A block stood on a plate: its bottom-face connector fastened, turned over, to the plate's top-face one"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_c_coincident",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"angle": {
"default": 0,
"description": "In deg.",
"type": "number"
},
"cs_a": {
"description": "feature index of the fixed CoordSys (mate connector A)",
"type": "integer"
},
"cs_b": {
"description": "feature index of the CoordSys on the body that moves",
"type": "integer"
},
"flip": {
"default": false,
"type": "boolean"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"offset": {
"default": 0,
"description": "In mm.",
"type": "number"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"type": {
"default": "fastened",
"description": "fastened is rigid; planar matches the normal only; revolute leaves rotation about the axis free; slider translation along it; cylindrical both",
"enum": [
"fastened",
"planar",
"revolute",
"slider",
"cylindrical"
],
"type": "string"
}
},
"then": {
"required": [
"cs_a",
"cs_b"
]
},
"type": "object"
},
"key": "align",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Mate"
},
{
"completion": "immediate",
"description": "Add a datum plane as the Plane card does, to sketch or build on as {\"datum\": plane_index}. Offset from a base plane or a face, at an angle about an edge, midway between two faces, tangent to a cylindrical face, through two edges, or coincident with a base plane or a face. Not the `plane` param of other Design commands. Reply: plane_index, name, frame.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"base": "XY",
"offset": 20,
"type": "offset"
},
"tool": "construct_plane"
}
],
"title": "A datum plane 20 mm above XY"
},
{
"calls": [
{
"args": {
"distance": 10,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"body": 0,
"kinds": [
"planar"
]
},
"tool": "body_describe"
},
{
"args": {
"face_a": {
"body": 0,
"face": 4
},
"face_b": {
"body": 0,
"face": 5
},
"generation": {
"from_call": 1,
"key": "generation"
},
"type": "midplane"
},
"tool": "construct_plane"
}
],
"title": "A datum plane midway between a block's top and bottom faces"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"adjacency": true,
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"angle": 30,
"edge_a": {
"body": 0,
"edge": 3
},
"face_a": {
"body": 0,
"face": 5
},
"generation": {
"from_call": 1,
"key": "generation"
},
"type": "angle"
},
"tool": "construct_plane"
}
],
"title": "A datum plane turned 30 degrees from a plate's top face about its front edge"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_plane",
"idempotent": false,
"input_schema": {
"properties": {
"angle": {
"default": 0,
"description": "offset without face_a: tilt about the base axis `axis`; angle: turn about edge_a from the reference plane; tangent: position around the cylinder (deg)",
"type": "number"
},
"axis": {
"default": 0,
"description": "offset without face_a: tilt about the base plane's X (0) or Y (1) axis",
"enum": [
0,
1
],
"type": "integer"
},
"base": {
"default": "XY",
"description": "\"XY\", \"XZ\" or \"YZ\" through modeling_origin, or {\"datum\": i}: what offset, coincident and angle build on without face_a",
"type": [
"string",
"object"
]
},
"edge_a": {
"default": null,
"description": "Edge A, {\"body\": b, \"edge\": e}: angle's hinge; two_edges' first edge",
"type": [
"object",
"null"
]
},
"edge_b": {
"default": null,
"description": "Edge B, {\"body\": b, \"edge\": e}: two_edges' second edge",
"type": [
"object",
"null"
]
},
"face_a": {
"default": null,
"description": "Face A, {\"body\": b, \"face\": f}: offset or coincident on a face; angle's reference plane; midplane's first face; tangent's cylindrical face",
"type": [
"object",
"null"
]
},
"face_b": {
"default": null,
"description": "Face B, {\"body\": b, \"face\": f}: midplane's second face",
"type": [
"object",
"null"
]
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"offset": {
"default": 20,
"description": "offset: distance along the normal of base or face_a (mm)",
"type": "number"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"size": {
"default": [
60,
60
],
"description": "[u, v]: the size the plane is drawn at (mm)",
"type": "array"
},
"type": {
"default": "offset",
"enum": [
"offset",
"angle",
"midplane",
"tangent",
"two_edges",
"coincident"
],
"type": "string"
}
},
"type": "object"
},
"key": "construct_plane",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Plane"
},
{
"completion": "immediate",
"description": "Create a datum axis (reference line): two points, face normal, cylinder centreline, plane intersection, or along edge. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"diameter": 5,
"through": true
},
"tool": "hole"
},
{
"args": {
"body": 0,
"kinds": [
"cylindrical"
]
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"face": 6,
"generation": {
"from_call": 2,
"key": "generation"
},
"type": "cylinder"
},
"tool": "construct_axis"
}
],
"title": "The axis of a hole through a plate"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"face": 5,
"generation": {
"from_call": 1,
"key": "generation"
},
"type": "face_normal"
},
"tool": "construct_axis"
}
],
"title": "The normal through the centre of a plate's top face"
},
{
"calls": [
{
"args": {
"base": "XZ",
"offset": 10,
"type": "offset"
},
"tool": "construct_plane"
},
{
"args": {
"base": "YZ",
"offset": 10,
"type": "offset"
},
"tool": "construct_plane"
},
{
"args": {
"plane_a": 0,
"plane_b": 1,
"type": "plane_intersection"
},
"tool": "construct_axis"
}
],
"title": "The vertical line where two datum planes meet"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_line",
"idempotent": false,
"input_schema": {
"properties": {
"body": {
"default": -1,
"description": "body for face/edge refs",
"type": "integer"
},
"edge": {
"default": -1,
"description": "edge id (body_describe) for along_edge",
"type": "integer"
},
"face": {
"default": -1,
"description": "face id (body_describe) for face_normal/cylinder",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"p1": {
"default": [
0,
0,
0
],
"description": "first point [x,y,z] for two_points",
"type": "array"
},
"p2": {
"default": [
0,
0,
10
],
"description": "second point [x,y,z] for two_points",
"type": "array"
},
"plane_a": {
"default": -1,
"description": "first datum plane feature index for plane_intersection",
"type": "integer"
},
"plane_b": {
"default": -1,
"description": "second datum plane feature index for plane_intersection",
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"type": {
"default": "two_points",
"enum": [
"two_points",
"face_normal",
"cylinder",
"plane_intersection",
"along_edge"
],
"type": "string"
}
},
"type": "object"
},
"key": "construct_axis",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Axis"
},
{
"completion": "immediate",
"description": "Create a datum coordinate system (origin + orthonormal axes). PointWorld aligns to world; FaceAndDirection uses a face for Z and an edge/hint for X. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"adjacency": true,
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"edge": 3,
"face": 5,
"generation": {
"from_call": 1,
"key": "generation"
},
"type": "face_and_direction"
},
"tool": "construct_coordinate_system"
}
],
"title": "A connector on a plate's top face, its x axis along the front edge"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_point",
"idempotent": false,
"input_schema": {
"properties": {
"body": {
"default": -1,
"description": "body for face/edge refs",
"type": "integer"
},
"edge": {
"default": -1,
"description": "edge id (body_describe) for X axis hint",
"type": "integer"
},
"face": {
"default": -1,
"description": "face id (body_describe) for Z axis",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"point": {
"default": [
0,
0,
0
],
"description": "origin [x,y,z] for point_world",
"type": "array"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"type": {
"default": "point_world",
"enum": [
"point_world",
"face_and_direction"
],
"type": "string"
},
"x_hint": {
"default": [
1,
0,
0
],
"description": "fallback X direction hint if no edge given",
"type": "array"
}
},
"type": "object"
},
"key": "construct_coordinate_system",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Coordinate system"
},
{
"completion": "immediate",
"description": "Create a helical curve, a sweep path for springs, coils and augers. It starts on the plane's x axis at `radius` from its origin. pitch = axial rise per turn. left_handed flips the winding. taper_deg != 0 gives a conical helix. Reply: helix_index, frame, start and tangent (world), to draw a sweep's profile across the curve there.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"height": 20,
"pitch": 5,
"radius": 10
},
"tool": "helix"
}
],
"title": "A four-turn helix on XY: radius 10 mm, pitch 5 mm, 20 mm tall"
},
{
"calls": [
{
"args": {
"height": 20,
"left_handed": true,
"pitch": 4,
"radius": 10,
"taper_deg": 10
},
"tool": "helix"
}
],
"title": "A left-handed conical helix tapering 10 degrees"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_thread",
"idempotent": false,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"height": {
"default": 20,
"description": "In mm.",
"exclusiveMinimum": 0,
"type": "number"
},
"left_handed": {
"default": false,
"type": "boolean"
},
"pitch": {
"default": 5,
"description": "In mm.",
"exclusiveMinimum": 0,
"type": "number"
},
"plane": {
"default": "XY",
"description": "\"XY\", \"XZ\" or \"YZ\" through modeling_origin; {\"datum\": i}, a Plane feature; or {\"body\": b, \"face\": f}, a planar face (origin at its centroid, normal out of the body, x from the world axes). The reply's frame gives the axes.",
"type": [
"string",
"object"
]
},
"radius": {
"default": 10,
"description": "In mm.",
"exclusiveMinimum": 0,
"type": "number"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"taper_deg": {
"default": 0,
"description": "In deg.",
"type": "number"
}
},
"type": "object"
},
"key": "helix",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Helix"
},
{
"completion": "immediate",
"description": "Project a body's edges onto a plane as a new sketch, or into the open sketch as construction entities. With no sketch open it adds a Project feature on plane, a sketch whose entities follow the body as it rebuilds; reply: scope \"feature\", project_index, bodies, error, frame. With a sketch open, a new one or one re-opened with sketch_edit, the edges are copied into it on its plane as construction entities, which new geometry can be constrained to and which do not follow the body; plane is refused there; reply: scope \"sketch\", first_index, added, entities (how many the sketch has). A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"face": 5,
"generation": {
"from_call": 1,
"key": "generation"
},
"plane": "XY",
"source_body": 0
},
"tool": "sketch_project"
}
],
"title": "A plate's top-face outline projected onto the XY plane as a new sketch"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"adjacency": true,
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"edges": [
3,
6
],
"generation": {
"from_call": 1,
"key": "generation"
},
"plane": "XY",
"source_body": 0
},
"tool": "sketch_project"
}
],
"title": "Two top edges of a plate, meeting at a corner, projected onto the XY plane"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"face": 5,
"generation": {
"from_call": 1,
"key": "generation"
},
"source_body": 0
},
"tool": "sketch_project"
}
],
"title": "A plate's top-face outline drawn into an open sketch as construction entities"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_sketch",
"idempotent": false,
"input_schema": {
"properties": {
"edges": {
"default": [],
"description": "global edge ids to project; empty => project the face",
"type": "array"
},
"face": {
"default": -1,
"description": "global face id on the source body; when set, all its edges are projected",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"plane": {
"default": null,
"description": "with no sketch open, the plane of the new sketch: \"XY\" (left out or null), \"XZ\" or \"YZ\" through modeling_origin; {\"datum\": i}, a Plane feature; or {\"body\": b, \"face\": f}, a planar face (origin at its centroid, normal out of the body, x from the world axes). The reply's frame gives the axes. With a sketch open, refused: the edges go on its plane.",
"type": [
"string",
"object",
"null"
]
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"source_body": {
"default": -1,
"description": "body owning the edges; -1 = last body",
"type": "integer"
}
},
"type": "object"
},
"key": "sketch_project",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Project"
},
{
"completion": "immediate",
"description": "Measure two refs, on one body or two: distance, closest points, angle and the gap between parallel faces. distance is between their representative points (a face's centroid, an edge's middle, an axis's middle); min_distance comes with closest_a and closest_b; angle_deg when both have a direction; parallel_gap across two parallel planar faces.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"body": 0,
"kinds": [
"planar"
]
},
"tool": "body_describe"
},
{
"args": {
"a": {
"face": 5
},
"b": {
"face": 4
},
"body": 0,
"generation": {
"from_call": 1,
"key": "generation"
}
},
"tool": "measure"
}
],
"title": "A plate's thickness, between its top and bottom faces"
},
{
"calls": [
{
"args": {
"distance": 10,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"distance": 10,
"operation": "new_body",
"profile": [
[
20,
-5
],
[
30,
-5
],
[
30,
5
],
[
20,
5
]
]
},
"tool": "extrude"
},
{
"args": {
"body": 0,
"direction": [
1,
0,
0
]
},
"tool": "body_describe"
},
{
"args": {
"body": 1,
"direction": [
-1,
0,
0
]
},
"tool": "body_describe"
},
{
"args": {
"a": {
"body": 0,
"face": 1
},
"b": {
"body": 1,
"face": 3
},
"generation": {
"from_call": 3,
"key": "generation"
}
},
"tool": "measure"
}
],
"title": "The 10 mm gap between two blocks' facing sides"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"properties": {
"a": {
"description": "{\"face\": f}, {\"edge\": e} or {\"point\": [x, y, z]}, with an optional \"body\"; {\"face\": f, \"axis\": true} is a cylindrical face's axis over its length",
"type": "object"
},
"b": {
"description": "as a",
"type": "object"
},
"body": {
"default": 0,
"description": "the body of a ref that names none",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
}
},
"required": [
"a",
"b"
],
"type": "object"
},
"key": "measure",
"listed": false,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Measure"
},
{
"completion": "immediate",
"description": "Volume / surface area / centre of mass / inertia tensor of a body.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"body": 0
},
"tool": "body_mass_properties"
}
],
"title": "The volume and centre of mass of a 20 x 20 x 5 mm plate"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "info",
"idempotent": true,
"input_schema": {
"properties": {
"body": {
"default": 0,
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"type": "object"
},
"key": "body_mass_properties",
"listed": false,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Volume and area"
},
{
"completion": "immediate",
"description": "Solid bodies that overlap, as {body_a, body_b, volume}. Read-only; bodies that merely touch enclose no volume and are not reported.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 10,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"distance": 20,
"height": 10,
"operation": "new_body",
"width": 10
},
"tool": "extrude"
},
{
"args": {
"silent": true
},
"tool": "interference"
}
],
"title": "A post standing in a block: the two overlap"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_boolean",
"idempotent": true,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"min_volume": {
"default": 1e-06,
"description": "overlap volume above which a pair counts as interfering (mm^3)",
"type": "number"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"type": "object"
},
"key": "interference",
"listed": false,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Interference"
},
{
"completion": "immediate",
"description": "Change a feature's fields and what it refers to, as its card's Confirm does when editing: one undo step, a rebuild. fields, then refs, are written; a call with neither is refused, and a field an expression drives is refused. Body indices and face and edge ids in refs are those of the model just before the feature, which body_describe {before: feature} reads and feature_describe's bodies_before lists; a Plane's, an Axis's and a CoordSys's are the finished model's (feature_describe's ids_of says which). An extrude's profile and target are fixed. Reply: changed {name: [old, new]}.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"feature": 1,
"fields": {
"distance": 15
}
},
"tool": "feature_edit"
}
],
"title": "A plate made 15 mm thick"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"diameter": 5,
"through": true
},
"tool": "hole"
},
{
"args": {
"feature": 2,
"fields": {
"hole_diameter": 8
}
},
"tool": "feature_edit"
}
],
"title": "A plate's hole widened from 5 to 8 mm"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_edit",
"idempotent": false,
"input_schema": {
"if": {
"minProperties": 1
},
"properties": {
"feature": {
"description": "feature index (describe_design)",
"type": "integer"
},
"fields": {
"default": {},
"description": "{field: value} from feature_describe's editable, e.g. {\"distance\": 15}: numbers within its ranges; operation new_body|join|cut|intersect; extrude_end blind|symmetric|two_sided|through_all; shape rectangle|circle; xf_* vectors [x, y, z]; imported art's import_offset [x, y]; a Text feature's text_string, text_height (0.5 to 500 mm) and text_font, a face name (with text_bold, text_italic) or the stored value, which outline it again",
"type": "object"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"refs": {
"default": {},
"description": "{name: value} under the names of feature_describe's refs that the feature's card can pick again: revolve_axis_entity; sweep_path_ref; loft_profile_refs; target_body, bool_tool_body; plane (as sketch_create's plane) for a mirror, split, helix, hole or thread; rib_sketch_ref, rib_entity; mate_cs_a, mate_cs_b; a fillet's or chamfer's edges, or face_group top|bottom|lateral|all; shell_face, draft_face, thicken_face; delete_faces; a datum's plane_, axis_ and coordsys_ refs. Feature indices must come before the feature",
"type": "object"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"feature"
]
},
"type": "object"
},
"key": "feature_edit",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Edit"
},
{
"completion": "immediate",
"description": "Give this feature a name you will recognise in the tree (a body takes its name from the feature that makes it). It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"destructive": false,
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "rename_edit",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "rename_selected",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Rename…"
},
{
"completion": "immediate",
"description": "Remove faces from a solid, healing the gap via OCCT defeaturing. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"diameter": 5,
"through": true
},
"tool": "hole"
},
{
"args": {
"body": 0,
"kinds": [
"cylindrical"
]
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"faces": [
6
],
"generation": {
"from_call": 2,
"key": "generation"
}
},
"tool": "delete_face"
}
],
"title": "A plate's bore filled in by deleting its cylindrical face"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_delete",
"idempotent": false,
"input_schema": {
"if": {
"minProperties": 1
},
"properties": {
"body": {
"default": -1,
"description": "target body; omit for the last body",
"type": "integer"
},
"faces": {
"description": "global face ids to delete",
"type": "array"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"faces"
]
},
"type": "object"
},
"key": "delete_face",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Delete Face"
},
{
"completion": "immediate",
"description": "Frame the selection in the view, keeping the view direction. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"destructive": false,
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_zoom",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "zoom_to_selection",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Zoom to selection"
},
{
"completion": "immediate",
"description": "Delete a feature as its tree row's Delete does; deleting a sketch also deletes the features built on it. One undo step. Later indices shift. Reply: removed (how many features went), features, bodies.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"diameter": 5,
"through": true
},
"tool": "hole"
},
{
"args": {
"feature": 2
},
"tool": "feature_delete"
}
],
"title": "A plate's hole deleted"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"distance": 5,
"sketch": 0
},
"tool": "extrude"
},
{
"args": {
"feature": 0
},
"tool": "feature_delete"
}
],
"title": "A committed sketch deleted, and the extrude built on it with it"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_delete",
"idempotent": false,
"input_schema": {
"if": {
"minProperties": 1
},
"properties": {
"feature": {
"description": "feature index (describe_design)",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"feature"
]
},
"type": "object"
},
"key": "feature_delete",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Delete"
},
{
"completion": "immediate",
"description": "Delete a body as its row's Delete does: the feature that made it goes, which can take other features and bodies with it. One undo step. Reply: deleted_feature {index, type, name}, removed, features, bodies.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"distance": 10,
"operation": "new_body",
"profile": [
[
20,
-5
],
[
30,
-5
],
[
30,
5
],
[
20,
5
]
]
},
"tool": "extrude"
},
{
"args": {
"body": 1
},
"tool": "body_delete"
}
],
"title": "The second of two bodies deleted, with the extrude that made it"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_delete",
"idempotent": false,
"input_schema": {
"if": {
"minProperties": 1
},
"properties": {
"body": {
"description": "body index (describe_design)",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"body"
]
},
"type": "object"
},
"key": "body_delete",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Delete Body"
},
{
"completion": "immediate",
"description": "Measure the polygon to its corners (inscribed). It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"destructive": false,
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_polygon",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "sketch_polygon_inscribed",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Inscribed"
},
{
"completion": "immediate",
"description": "Measure the polygon to its flats (circumscribed). It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"destructive": false,
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_polygon",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "sketch_polygon_circumscribed",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Circumscribed"
},
{
"completion": "immediate",
"description": "Add text as a Text feature on a plane or a planar face, outlined in a font, as the Text dialog adds it. It runs on the model, in one undo step, with no dialog and no placement step, and is refused while a sketch is open. Refused for a font that is not installed or cannot be loaded, and for text with no outline (spaces only). The feature keeps its words, font and height, as the dialog's does. Reply: text_index, bodies, frame (the plane's).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"height": 12,
"text": "Orca"
},
"tool": "sketch_text"
}
],
"title": "The word Orca, 12 mm high, on the XY plane"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"generation": {
"from_call": 1,
"key": "generation"
},
"height": 6,
"plane": {
"body": 0,
"face": 5
},
"text": "A1"
},
"tool": "sketch_text"
}
],
"title": "A label centred on a plate's top face"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_text",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"bold": {
"default": false,
"description": "the face's bold",
"type": "boolean"
},
"font": {
"default": "",
"description": "a font face, as the Text dialog's Font list names it; left out or empty, the face last used",
"type": "string"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"height": {
"default": null,
"description": "the text's height; left out, the height last used (10 mm at first) (mm)",
"maximum": 500,
"minimum": 0.5,
"type": [
"number",
"null"
]
},
"italic": {
"default": false,
"description": "the face's italic",
"type": "boolean"
},
"plane": {
"default": "XY",
"description": "\"XY\", \"XZ\" or \"YZ\" through modeling_origin; {\"datum\": i}, a Plane feature; or {\"body\": b, \"face\": f}, a planar face, whose centre the text is centred on. The reply's frame gives the axes.",
"type": [
"string",
"object"
]
},
"position": {
"default": [
0,
0
],
"description": "[x, y] in the plane, mm: where the text's centre goes",
"type": "array"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only in an open sketch (sketch_create opens one).",
"enum": [
true
],
"type": "boolean"
},
"text": {
"description": "the words",
"type": "string"
}
},
"then": {
"required": [
"text"
]
},
"type": "object"
},
"key": "sketch_text",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Text"
},
{
"completion": "immediate",
"description": "Add an SVG file's filled outlines to the open sketch as lines, or to the model as art on a plane. The outlines are centred on the plane's origin, scaled by scale and moved by position, with no file dialog and no placement step. With a sketch open, a new one or one re-opened with sketch_edit, they are added to it as lines, as Insert SVG adds them there, and plane is refused; reply: scope \"sketch\", added, entities (how many the sketch has). With none open, an art feature on plane, as Insert SVG adds one on the model, in one undo step; reply: art_index, bodies, frame (the plane's). Refused when the file is not there or gives no outline (no filled shape).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"path": "/path/to/logo.svg",
"position": [
10,
0
]
},
"tool": "sketch_insert_svg"
}
],
"needs": "an SVG file with a filled shape",
"title": "A logo placed on the XY plane as art, its centre 10 mm right of the origin"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"path": "/path/to/logo.svg",
"scale": 0.5
},
"tool": "sketch_insert_svg"
}
],
"needs": "an SVG file with a filled shape",
"title": "A logo's outlines drawn into an open sketch at half size"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_svg",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"path": {
"description": "absolute path of the .svg file",
"type": "string"
},
"plane": {
"default": null,
"description": "with no sketch open, the art's plane: \"XY\" (left out or null), \"XZ\" or \"YZ\" through modeling_origin; {\"datum\": i}, a Plane feature; or {\"body\": b, \"face\": f}, a planar face, whose centre is the origin. The reply's frame gives the axes. With a sketch open, refused: the outlines go on its plane.",
"type": [
"string",
"object",
"null"
]
},
"position": {
"default": [
0,
0
],
"description": "[x, y] in the plane, mm: where the outlines' centre goes",
"type": "array"
},
"scale": {
"default": 1,
"description": "times the size the file gives",
"exclusiveMinimum": 0,
"type": "number"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only in an open sketch (sketch_create opens one).",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"path"
]
},
"type": "object"
},
"key": "sketch_insert_svg",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "SVG"
},
{
"completion": "immediate",
"description": "Add an offset copy of sketch lines, arcs and circles. The copy of one entity alone is bound to it, Parallel for a line and Concentric for an arc or a circle, as the Offset tool binds it. Reply: first_index, added, constraints_added (that binding, as sketch_list_constraints writes it), dof.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"distance": 2
},
"tool": "sketch_offset"
}
],
"title": "A rectangle's 2 mm inner wall"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 5,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"distance": -2,
"entities": [
0
]
},
"tool": "sketch_offset"
}
],
"title": "A circle grown 2 mm by a negative offset"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_offset",
"idempotent": false,
"input_schema": {
"if": {
"minProperties": 1
},
"properties": {
"distance": {
"description": "signed offset (mm)",
"type": "number"
},
"entities": {
"default": [],
"description": "entity indices; omit for the selection, else every entity",
"type": "array"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only in an open sketch (sketch_create opens one).",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"distance"
]
},
"type": "object"
},
"key": "sketch_offset",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Offset"
},
{
"completion": "immediate",
"description": "Trim the open sketch's entity nearest `at`, as a Trim click there does. A line or an arc is cut back from its end nearer `at` to the first crossing with another entity beyond `at`; a circle loses the part between the crossings either side of `at` and becomes an arc. The entity's constraints are released. Reply: entity, geometry (its new fields), released_constraints, entities, dof.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
-10,
0
],
"p1": [
10,
0
],
"type": "line"
},
{
"p0": [
0,
-5
],
"p1": [
0,
5
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"at": [
5,
0
]
},
"tool": "sketch_trim"
}
],
"title": "A line cut back to the line crossing it"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_trim",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"at": {
"description": "[x, y] in the sketch plane, mm: a point on the part to cut",
"type": "array"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only in an open sketch (sketch_create opens one).",
"enum": [
true
],
"type": "boolean"
},
"tolerance": {
"default": 0.05,
"description": "how far from `at` the entity may be (mm)",
"type": "number"
}
},
"then": {
"required": [
"at"
]
},
"type": "object"
},
"key": "sketch_trim",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Trim"
},
{
"completion": "immediate",
"description": "Round the corner of two lines of the open sketch, as the Fillet tool does. Both lines are cut back and joined by an arc of `radius`, bound coincident and tangent to them; constraints the sharp corner held are released. Reply: entity (the arc), lines, released_constraints, entities, constraints, dof, solve_ok.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
0,
1
],
"radius": 3
},
"tool": "sketch_fillet"
}
],
"title": "A rectangle's corner rounded to 3 mm"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_filletedge",
"idempotent": false,
"input_schema": {
"if": {
"minProperties": 1
},
"properties": {
"entities": {
"default": [],
"description": "the two line indices; omit for the selection",
"type": "array"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"radius": {
"description": "In mm.",
"type": "number"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only in an open sketch (sketch_create opens one).",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"radius"
]
},
"type": "object"
},
"key": "sketch_fillet",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Fillet"
},
{
"completion": "immediate",
"description": "Bevel the corner of two lines of the open sketch, as the Chamfer tool does. Both lines are cut back by `distance` from the corner and joined by a line bound coincident to them. Reply: entity (the new line), lines, released_constraints, entities, constraints, dof, solve_ok.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"distance": 2,
"entities": [
1,
2
]
},
"tool": "sketch_chamfer"
}
],
"title": "A rectangle's corner bevelled 2 mm back"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_chamfer",
"idempotent": false,
"input_schema": {
"if": {
"minProperties": 1
},
"properties": {
"distance": {
"description": "setback along each line (mm)",
"type": "number"
},
"entities": {
"default": [],
"description": "the two line indices; omit for the selection",
"type": "array"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only in an open sketch (sketch_create opens one).",
"enum": [
true
],
"type": "boolean"
}
},
"then": {
"required": [
"distance"
]
},
"type": "object"
},
"key": "sketch_chamfer",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Chamfer"
},
{
"completion": "immediate",
"description": "Add a mirrored copy of sketch entities about a line of the sketch, one of its axes, or the line through two points. About axis, as the Mirror tool's Confirm: each copy is bound Symmetric to its source about the axis, unless that would move anything off its reflection, and constraints_added lists the constraints kept. axis_a and axis_b, two free points, bind nothing, and axis is refused beside either. Reply: first_index, added, constraints_added (as sketch_list_constraints writes them), dof.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
10,
0
],
"radius": 3,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"axis": "y_axis"
},
"tool": "sketch_mirror"
}
],
"title": "A circle mirrored about the sketch's y axis, its copy bound to it"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
5,
0
],
"p1": [
10,
5
],
"type": "line"
},
{
"construction": true,
"p0": [
20,
-10
],
"p1": [
20,
10
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"axis": 1,
"entities": [
0
]
},
"tool": "sketch_mirror"
}
],
"title": "A line mirrored about a construction line of the sketch"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
10,
0
],
"radius": 3,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"axis_a": [
0,
0
],
"axis_b": [
1,
1
]
},
"tool": "sketch_mirror"
}
],
"title": "A circle mirrored across the line through two free points"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_mirror",
"idempotent": false,
"input_schema": {
"properties": {
"axis": {
"default": null,
"description": "a line of the sketch by its entity index, \"x_axis\" or \"y_axis\"; omit for axis_a and axis_b",
"type": [
"integer",
"string",
"null"
]
},
"axis_a": {
"default": [
0,
0
],
"description": "[x, y] in the sketch plane, mm",
"type": "array"
},
"axis_b": {
"default": [
0,
1
],
"description": "[x, y] in the sketch plane, mm",
"type": "array"
},
"entities": {
"default": [],
"description": "entity indices; omit for the selection, else every entity but the axis",
"type": "array"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only in an open sketch (sketch_create opens one).",
"enum": [
true
],
"type": "boolean"
}
},
"type": "object"
},
"key": "sketch_mirror",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Mirror"
},
{
"completion": "immediate",
"description": "Add a dimension to the open sketch: a distance, an angle, a radius or a diameter. With `entities`, else the selection, the CONSTRAIN bar's rules choose the points, and the value is `value` or the current one. With `refs` the references are taken as written, as sketch_constrain takes them, and `value` is required. distance has no button and takes refs. A dimension the sketch cannot solve with is rolled back and the call fails. Reply: added (indices), items, constraints, dof, solve_ok.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
0,
0
],
"p1": [
10,
2
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"refs": [
{
"entity": 0,
"role": "p0"
},
{
"entity": 0,
"role": "p1"
}
],
"type": "distance",
"value": 25
},
"tool": "sketch_dimension"
}
],
"title": "A line's ends held 25 mm apart, named by refs"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 3,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
0
],
"type": "radius",
"value": 5
},
"tool": "sketch_dimension"
}
],
"title": "A circle's radius set to 5 mm"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_dimension",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"entities": {
"default": [],
"description": "1 or 2 entity indices; omit for the selection",
"type": "array"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"refs": {
"default": [],
"description": "[{entity, role?}], instead of entities",
"type": "array"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only in an open sketch (sketch_create opens one).",
"enum": [
true
],
"type": "boolean"
},
"type": {
"enum": [
"distance",
"distance_x",
"distance_y",
"angle",
"radius",
"diameter"
],
"type": "string"
},
"value": {
"default": null,
"description": "mm, or degrees for an angle",
"type": [
"number",
"null"
]
}
},
"then": {
"required": [
"type"
]
},
"type": "object"
},
"key": "sketch_dimension",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Dimension"
},
{
"completion": "immediate",
"description": "Add a constraint to the open sketch, as a CONSTRAIN bar button does (sketch_set_value is the value field, V). With `entities`, else the selection, the button's own rules choose the points. With `refs` the references are taken as written, in sketch_list_constraints' form: {entity, role} for a point (role p0, p1 or center; entity also \"origin\") and {entity} for a whole entity (also \"x_axis\", \"y_axis\"). lock_x, lock_y, point_on_line and point_on_object have no button and take refs. A distance, an angle, a radius or a diameter is sketch_dimension's. A constraint the sketch cannot solve with is rolled back and the call fails. Reply: added (indices), items, constraints, dof, solve_ok.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
0,
0
],
"p1": [
10,
2
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
0
],
"type": "horizontal"
},
"tool": "sketch_constrain"
}
],
"title": "A sloping line made horizontal"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 4,
"type": "circle_center"
},
{
"center": [
15,
0
],
"radius": 6,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
0,
1
],
"type": "equal"
},
"tool": "sketch_constrain"
}
],
"title": "Two circles given equal radii"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
0,
0
],
"p1": [
10,
2
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"refs": [
{
"entity": 0,
"role": "p0"
}
],
"type": "lock_x",
"value": 5
},
"tool": "sketch_constrain"
}
],
"title": "A line's start held at x = 5, named by refs"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_constrain",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"entities": {
"default": [],
"description": "1 to 3 entity indices; omit for the selection",
"type": "array"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"refs": {
"default": [],
"description": "[{entity, role?}], instead of entities",
"type": "array"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only in an open sketch (sketch_create opens one).",
"enum": [
true
],
"type": "boolean"
},
"type": {
"description": "\"equal\" is the Equal button: equal length, or equal radius for two curves",
"enum": [
"fix",
"coincident",
"horizontal",
"vertical",
"lock_x",
"lock_y",
"equal_length",
"parallel",
"perpendicular",
"concentric",
"tangent",
"midpoint",
"symmetric",
"point_on_line",
"point_on_object",
"equal_radius",
"collinear",
"symmetric_about_y",
"symmetric_about_x",
"equal"
],
"type": "string"
},
"value": {
"default": null,
"description": "mm: the coordinate lock_x and lock_y hold, or point_on_line's distance from the line; the other types take none",
"type": [
"number",
"null"
]
}
},
"then": {
"required": [
"type"
]
},
"type": "object"
},
"key": "sketch_constrain",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Constrain"
},
{
"completion": "immediate",
"description": "Add dimensions and relations (coincident, tangent, parallel...) to the selected sketch. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"destructive": false,
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_constrain",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {},
"type": "object"
},
"key": "sketch_constrain_selected",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Constrain sketch"
},
{
"completion": "immediate",
"description": "Toggle construction on sketch entities. Reply: changed, how many, and ok, false when none did.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
{
"p0": [
0,
-10
],
"p1": [
0,
10
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
4
]
},
"tool": "sketch_toggle_construction"
}
],
"title": "A centre line across a rectangle, made construction so it splits no loop"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_construction",
"idempotent": false,
"input_schema": {
"properties": {
"entities": {
"default": [],
"description": "entity indices; omit for the selection",
"type": "array"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only in an open sketch (sketch_create opens one).",
"enum": [
true
],
"type": "boolean"
}
},
"type": "object"
},
"key": "sketch_toggle_construction",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Construction"
},
{
"completion": "immediate",
"description": "Extend the open sketch's line or arc nearest `at` to the next entity, as an Extend click there does. The line's or arc's end nearer `at` runs out to the first entity it meets. The entity's constraints are released. Reply: entity, geometry (its new fields), released_constraints, entities, dof.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
-10,
0
],
"p1": [
10,
0
],
"type": "line"
},
{
"p0": [
0,
3
],
"p1": [
0,
8
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"at": [
0,
3
]
},
"tool": "sketch_extend"
}
],
"title": "A line extended down to the line below it"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_extend",
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"if": {
"minProperties": 1
},
"properties": {
"at": {
"description": "[x, y] in the sketch plane, mm: near the end to extend",
"type": "array"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only in an open sketch (sketch_create opens one).",
"enum": [
true
],
"type": "boolean"
},
"tolerance": {
"default": 0.05,
"description": "how far from `at` the entity may be (mm)",
"type": "number"
}
},
"then": {
"required": [
"at"
]
},
"type": "object"
},
"key": "sketch_extend",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Extend"
},
{
"completion": "immediate",
"description": "Delete sketch entities. Reply: removed, entities.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
2
]
},
"tool": "sketch_delete"
}
],
"title": "Delete a rectangle's top side"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
1,
3
]
},
"tool": "sketch_select"
},
{
"args": {
"silent": true
},
"tool": "sketch_delete"
}
],
"title": "Delete the selected sides"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": true,
"icon": "design_delete",
"idempotent": false,
"input_schema": {
"properties": {
"entities": {
"default": [],
"description": "entity indices; omit for the selection",
"type": "array"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only in an open sketch (sketch_create opens one).",
"enum": [
true
],
"type": "boolean"
}
},
"type": "object"
},
"key": "sketch_delete",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Delete"
},
{
"completion": "immediate",
"description": "The Design document: features, variables with their values, bodies, undo_depth / redo_depth and generation. A feature's bound lists the fields an expression drives; a body gives bbox, where the model has it, source_feature, visible, color, moved, and placement: where the body stands for Commit to Plate and Export STEP (body_place, the Move gizmo, Place on Face), null where the model has it, else three rows of four numbers, the rotation and the translation in mm, in the world frame. commit_mode is the Commit button's mode, assembly or bodies, which commit_to_plate uses when given none. selection is what the right-click menu would be built for: its kind, the selection_kind a tool's opening reply gives, and its id (none, face_planar, body_solid, sk_line and the like). picked_plane is the reference plane picked in the view (XY, XZ, YZ), which the next Sketch opens on, and feature_row the selected row of the Feature list, a feature index; each is null when there is none.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {},
"tool": "describe_design"
}
],
"title": "An empty design"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {},
"tool": "describe_design"
}
],
"title": "A plate's two features and its body"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "describe_design",
"listed": false,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Describe design"
},
{
"completion": "immediate",
"description": "One feature as its card shows it: params, the editable ones with their ranges, expr, refs, used_by and bodies_made. expr holds its bindings, and refs the feature and body indices and face and edge ids it uses, those feature_edit's refs takes; ids_of says which model those body indices and ids are read in: \"before\", the model just before the feature, whose bodies bodies_before lists ({index, name}) and body_describe {before: feature} reads, or \"finished\" for a Plane, an Axis and a CoordSys, read with body_describe without before. A sketch adds its plane, entities and constraints (angles in degrees). Imported Text or SVG art shows its regions (a count), region_loops (how many closed loops each region has, its outer loop plus its holes; counts, not the loops' geometry) and region_areas (each region's filled area in mm² as placed, its outer loop less its holes).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"feature": 1
},
"tool": "feature_describe"
}
],
"title": "A plate's extrude, with the fields its card edits"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"feature": 0
},
"tool": "feature_describe"
}
],
"title": "A committed sketch's plane, entities and constraints"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"properties": {
"feature": {
"description": "feature index (describe_design)",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
}
},
"required": [
"feature"
],
"type": "object"
},
"key": "feature_describe",
"listed": false,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Feature describe"
},
{
"completion": "immediate",
"description": "A body's faces and edges, with their kinds and geometry, narrowed by face and edge filters. Faces give kind, area, centroid, normal, and a cylinder's, cone's, sphere's or torus's numbers; edges give kind, length, ends, a circle's centre and radius. Face filters (kinds, direction, at_extreme) and edge filters (edge_kinds, direction, convex) narrow their own list; when filters are given, a list none of its filters names is empty, or with adjacency holds the neighbours of the other list. Reply: face_count and edge_count of the body, faces_total and edges_total after filtering, next_offset while a page has more, generation.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"body": 0
},
"tool": "body_describe"
}
],
"title": "Every face and edge of a 20 x 20 x 5 mm plate"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
}
],
"title": "A plate's top face"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"body": 0,
"convex": true,
"direction": [
0,
0,
1
],
"edge_kinds": [
"line"
]
},
"tool": "body_describe"
}
],
"title": "A plate's vertical outside corners, the edges a fillet rounds"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"properties": {
"adjacency": {
"default": false,
"description": "faces list their edges; edges list their faces (one for a seam) and say convex true or false, or tangent where the faces meet smoothly",
"type": "boolean"
},
"at_extreme": {
"default": null,
"description": "faces whose centroid lies on that side of the body's bounding box, e.g. +z for the top face",
"enum": [
"+x",
"-x",
"+y",
"-y",
"+z",
"-z",
null
],
"type": [
"string",
"null"
]
},
"before": {
"default": null,
"description": "a feature index: the body as it stood just before that feature, whose ids are the ones feature_edit's refs takes for it; the reply says before, and its generation is the design's",
"type": [
"integer",
"null"
]
},
"body": {
"default": 0,
"type": "integer"
},
"convex": {
"default": null,
"description": "edges where two faces meet in an outside (true) or inside (false) corner; implies adjacency",
"type": [
"boolean",
"null"
]
},
"direction": {
"default": null,
"description": "[x, y, z]: planar faces whose outward normal points this way, and line edges along it either way, within 1 degree",
"type": [
"array",
"null"
]
},
"edge_kinds": {
"default": null,
"description": "edge kinds to list: line, circle, ellipse, bspline, bezier, other",
"type": [
"array",
"null"
]
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"kinds": {
"default": null,
"description": "face kinds to list: planar, cylindrical, conical, spherical, toroidal, bezier, bspline, revolution, extrusion, offset, other",
"type": [
"array",
"null"
]
},
"limit": {
"default": null,
"description": "page size of both lists; omit for all",
"minimum": 1,
"type": [
"integer",
"null"
]
},
"offset": {
"default": 0,
"type": "integer"
},
"vertices": {
"default": false,
"description": "also list every vertex of the body as vertices [{id, p}], unfiltered and unpaged",
"type": "boolean"
}
},
"type": "object"
},
"key": "body_describe",
"listed": false,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Body describe"
},
{
"completion": "immediate",
"description": "Cross-section of a body by a base plane at an offset (sections-as-evidence). Returns ordered world contours, each flagged closed/open.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"body": 0,
"offset": 2.5,
"plane": "XY"
},
"tool": "body_section"
}
],
"title": "A plate's cross-section halfway up"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 4,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"distance": 5,
"sketch": 0
},
"tool": "extrude"
},
{
"args": {
"body": 0,
"offset": 2.5,
"plane": "XY"
},
"tool": "body_section"
}
],
"title": "The two contours through a plate with a bore"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"properties": {
"body": {
"default": 0,
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"offset": {
"default": 0,
"description": "along the plane's normal, from the world origin (mm)",
"type": "number"
},
"plane": {
"default": "XY",
"description": "the base plane through the world origin, not through modeling_origin as the other commands' planes are",
"enum": [
"XY",
"XZ",
"YZ"
],
"type": "string"
}
},
"type": "object"
},
"key": "body_section",
"listed": false,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Body section"
},
{
"completion": "immediate",
"description": "Compare a body with a reference: volume, bbox, centroid and surface deviation (the RE acceptance metric). The reference is {step:path|body:id}; the surface deviation is max/mean/rms in mm.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"distance": 6,
"height": 20,
"operation": "new_body",
"width": 20
},
"tool": "extrude"
},
{
"args": {
"body": 0,
"reference": {
"body": 1
}
},
"tool": "body_compare"
}
],
"title": "A 5 mm plate against a 6 mm one"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"body": 0,
"reference": {
"step": "/path/to/reference.step"
}
},
"tool": "body_compare"
}
],
"needs": "a STEP file of the reference part",
"title": "A plate against a reference part's STEP file"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"properties": {
"body": {
"default": 0,
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"reference": {
"type": "object"
}
},
"required": [
"reference"
],
"type": "object"
},
"key": "body_compare",
"listed": false,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Body compare"
},
{
"completion": "immediate",
"description": "The open sketch, or a committed one: entities, constraint count and its loops. The loops are closed_loops {index, entities, holes, area}, open_ends, defects, buildable. The open sketch adds dof, the armed tool, the selection (entity indices) and selected_constraint, the index of the constraint picked by its badge or the Constraints list, null for none; a committed one adds its name and plane.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 4,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_describe"
}
],
"title": "The open sketch: a rectangle with a circle inside it as a hole"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"sketch": 0
},
"tool": "sketch_describe"
}
],
"title": "A committed sketch's plane, entities and loop"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"sketch": {
"default": null,
"description": "a committed Sketch feature's index; omit for the open sketch",
"type": [
"integer",
"null"
]
}
},
"type": "object"
},
"key": "sketch_describe",
"listed": false,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Sketch describe"
},
{
"completion": "immediate",
"description": "The open sketch's loops (closed_loops, open_ends, defects, buildable) and dof.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
0,
0
],
"p1": [
20,
0
],
"type": "line"
},
{
"p0": [
20,
0.05
],
"p1": [
20,
10
],
"type": "line"
},
{
"p0": [
20,
10
],
"p1": [
0,
0
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_validate"
}
],
"title": "A triangle with a 0.05 mm gap: two open ends, not buildable"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"tolerance": {
"default": 0.001,
"description": "reported back (mm)",
"type": "number"
}
},
"type": "object"
},
"key": "sketch_validate",
"listed": false,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Sketch validate"
},
{
"completion": "immediate",
"description": "The constraints of the open sketch, or of a committed one: index, type, refs and value. A ref is {entity, role} for a point and {entity} for a whole entity; value is mm, or degrees for an angle. Reply: scope (live or committed), items, and dof and solve_ok for the open sketch.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_list_constraints"
}
],
"title": "The coincident, horizontal and vertical constraints a drawn rectangle gets"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"sketch": 0
},
"tool": "sketch_list_constraints"
}
],
"title": "A committed sketch's constraints"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"sketch": {
"default": null,
"description": "a committed Sketch feature's index; omit for the open sketch",
"type": [
"integer",
"null"
]
}
},
"type": "object"
},
"key": "sketch_list_constraints",
"listed": false,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Sketch list constraints"
},
{
"completion": "immediate",
"description": "Import a STEP file as native B-rep bodies (the reference part to measure). A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"path": "/path/to/part.step"
},
"tool": "import_step"
}
],
"needs": "a STEP file of the part",
"title": "A part read from a STEP file as a body"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"path": {
"description": "absolute path",
"type": "string"
}
},
"required": [
"path"
],
"type": "object"
},
"key": "import_step",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Import step"
},
{
"completion": "immediate",
"description": "Convert a triangle mesh (STL/OBJ) into an editable B-rep body. Reports whether the result is a real solid or an open shell, and why. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"path": "/path/to/part.stl"
},
"tool": "import_mesh"
}
],
"needs": "an STL or OBJ mesh file",
"title": "An STL mesh turned into an editable body"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"merge_angle_deg": {
"default": 5.0,
"type": "number"
},
"path": {
"description": "absolute path",
"type": "string"
},
"tolerance": {
"default": 0.01,
"type": "number"
}
},
"required": [
"path"
],
"type": "object"
},
"key": "import_mesh",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Import mesh"
},
{
"completion": "immediate",
"description": "Build a cubic-Bezier G1 bridge (BSpline) between two sketch-entity endpoints within a sketch feature. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
-20,
0
],
"p1": [
-5,
0
],
"type": "line"
},
{
"p0": [
5,
10
],
"p1": [
20,
10
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"end_a": 1,
"end_b": 0,
"ent_a": 0,
"ent_b": 1,
"sketch": 0
},
"tool": "sketch_blend_curve"
}
],
"title": "A smooth curve joining the facing ends of two lines in a committed sketch"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"end_a": {
"default": 1,
"description": "0 = start/p0 side, 1 = end/p1 side",
"enum": [
0,
1
],
"type": "integer"
},
"end_b": {
"default": 0,
"description": "0 = start/p0 side, 1 = end/p1 side",
"enum": [
0,
1
],
"type": "integer"
},
"ent_a": {
"description": "first entity index within the sketch",
"type": "integer"
},
"ent_b": {
"description": "second entity index within the sketch",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"sketch": {
"description": "sketch feature index",
"type": "integer"
}
},
"required": [
"sketch",
"ent_a",
"ent_b"
],
"type": "object"
},
"key": "sketch_blend_curve",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Sketch blend curve"
},
{
"completion": "immediate",
"description": "Set a design variable to an expression, or remove it with an empty expr. Feature fields bound with feature_set_expression follow it. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"expr": "20",
"name": "w"
},
"tool": "set_variable"
}
],
"title": "A variable w of 20"
},
{
"calls": [
{
"args": {
"expr": "20",
"name": "w"
},
"tool": "set_variable"
},
{
"args": {
"expr": "w / 2 + 3",
"name": "h"
},
"tool": "set_variable"
}
],
"title": "A variable worked out from another: h = w / 2 + 3, which is 13"
},
{
"calls": [
{
"args": {
"expr": "20",
"name": "w"
},
"tool": "set_variable"
},
{
"args": {
"expr": "",
"name": "w"
},
"tool": "set_variable"
}
],
"title": "A variable removed with an empty expression"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"expr": {
"description": "e.g. \"20\" or \"width / 2 + 3\"; \"\" removes the variable",
"type": "string"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"name": {
"type": "string"
}
},
"required": [
"name",
"expr"
],
"type": "object"
},
"key": "set_variable",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Set variable"
},
{
"completion": "immediate",
"description": "Bind a feature's numeric field to an expression over the design variables, or unbind it with an empty expr. Unbound, the field keeps its value. A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"expr": "8",
"name": "t"
},
"tool": "set_variable"
},
{
"args": {
"expr": "t",
"feature": 1,
"field": "distance"
},
"tool": "feature_set_expression"
}
],
"title": "A plate's thickness bound to the variable t"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"expr": "8",
"name": "t"
},
"tool": "set_variable"
},
{
"args": {
"expr": "t",
"feature": 1,
"field": "distance"
},
"tool": "feature_set_expression"
},
{
"args": {
"expr": "",
"feature": 1,
"field": "distance"
},
"tool": "feature_set_expression"
}
],
"title": "A plate's thickness unbound, keeping the 8 mm the binding gave it"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"expr": {
"description": "\"\" removes the binding",
"type": "string"
},
"feature": {
"description": "feature index (describe_design)",
"type": "integer"
},
"field": {
"description": "a numeric field of feature_describe's params, e.g. width, distance, hole_diameter, thread_diameter",
"type": "string"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
}
},
"required": [
"feature",
"field",
"expr"
],
"type": "object"
},
"key": "feature_set_expression",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Feature set expression"
},
{
"completion": "immediate",
"description": "Move a feature one place up or down the history, as Move up / Move down do. A feature cannot come before one it uses. One undo step. Reply: feature (its new index), from.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"base": "XY",
"offset": 20,
"type": "offset"
},
"tool": "construct_plane"
},
{
"args": {
"delta": -1,
"feature": 2
},
"tool": "feature_move"
}
],
"title": "A datum plane moved up the history, above the extrude before it"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"delta": {
"description": "-1 up, 1 down",
"enum": [
-1,
1
],
"type": "integer"
},
"feature": {
"description": "feature index (describe_design)",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
}
},
"required": [
"feature",
"delta"
],
"type": "object"
},
"key": "feature_move",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Feature move"
},
{
"completion": "immediate",
"description": "Suppress a feature, or bring it back, as its row's eye hides or shows it. A suppressed feature is left out of the rebuild and bodies may renumber. One undo step, none when it already was. Reply: feature, suppressed, changed, bodies.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"diameter": 5,
"through": true
},
"tool": "hole"
},
{
"args": {
"feature": 2,
"suppressed": true
},
"tool": "feature_suppress"
}
],
"title": "A plate's hole hidden: the plate rebuilds without it"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"diameter": 5,
"through": true
},
"tool": "hole"
},
{
"args": {
"feature": 2,
"suppressed": true
},
"tool": "feature_suppress"
},
{
"args": {
"feature": 2,
"suppressed": false
},
"tool": "feature_suppress"
}
],
"title": "A hidden hole shown again"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"feature": {
"description": "feature index (describe_design)",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"suppressed": {
"description": "true leaves the feature out of the rebuild; false brings it back",
"type": "boolean"
}
},
"required": [
"feature",
"suppressed"
],
"type": "object"
},
"key": "feature_suppress",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Feature suppress"
},
{
"completion": "immediate",
"description": "Rename a feature as F2 on its row does. Its own undo step. Reply: name, changed.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"feature": 1,
"name": "Base plate"
},
"tool": "feature_rename"
}
],
"title": "A plate's extrude renamed Base plate"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"feature": {
"description": "feature index (describe_design)",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"name": {
"description": "trimmed; not empty",
"type": "string"
}
},
"required": [
"feature",
"name"
],
"type": "object"
},
"key": "feature_rename",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Feature rename"
},
{
"actions": [
{
"args": {},
"description": "Set the selected body's display color. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"icon": "color_palette",
"key": "colour",
"title": "Color"
}
],
"completion": "immediate",
"description": "Rename, colour or show/hide a body, as its Bodies row and the Color button do; give one or more. Not in the undo history. The name and colour are saved with the project and the name names its committed object; visibility is view state, and commit_to_plate leaves hidden bodies out. Reply: name, color, visible. Called with exactly one of these argument sets and nothing else, it opens that item's tool of the Design tab for a person, as the menu item does: {} (Color).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"body": 0,
"color": "#3366CC",
"name": "Base"
},
"tool": "body_set"
}
],
"title": "A plate's body named Base and coloured blue"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"distance": 10,
"operation": "new_body",
"profile": [
[
20,
-5
],
[
30,
-5
],
[
30,
5
],
[
20,
5
]
]
},
"tool": "extrude"
},
{
"args": {
"body": 1,
"visible": false
},
"tool": "body_set"
}
],
"title": "The second of two bodies hidden"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"if": {
"minProperties": 1
},
"properties": {
"body": {
"description": "body index (describe_design)",
"type": "integer"
},
"color": {
"default": null,
"description": "\"#RRGGBB\"",
"type": [
"string",
"null"
]
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"name": {
"default": null,
"description": "trimmed; not empty",
"type": [
"string",
"null"
]
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only outside a sketch (sketch_finish or sketch_cancel ends one; while the tab constrains a sketch, its Confirm or Cancel button ends that).",
"enum": [
true
],
"type": "boolean"
},
"visible": {
"default": null,
"type": [
"boolean",
"null"
]
}
},
"then": {
"required": [
"body"
]
},
"type": "object"
},
"key": "body_set",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Body set"
},
{
"completion": "immediate",
"description": "Commit to Plate: send the visible bodies to Prepare at their Move-gizmo positions and show Prepare. It is one Prepare undo step. A lone body is sent even when hidden. A body named in the Bodies list or with body_set names its object or part. Reply: objects (object_list index after replace, name, parts: how many), bodies_sent, bodies_hidden, replaced.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {},
"tool": "commit_to_plate"
}
],
"title": "A plate sent to Prepare as one object"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"distance": 10,
"operation": "new_body",
"profile": [
[
20,
-5
],
[
30,
-5
],
[
30,
5
],
[
20,
5
]
]
},
"tool": "extrude"
},
{
"args": {
"mode": "bodies"
},
"tool": "commit_to_plate"
}
],
"title": "Two bodies sent to Prepare as an object each"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"mode": {
"default": "",
"description": "assembly: one object with a part per body; bodies: an object per body. Default: the Commit button's mode, which this leaves as it is.",
"enum": [
"assembly",
"bodies"
],
"type": "string"
},
"replace": {
"default": [],
"description": "object_list indices to delete in the same undo step, such as an earlier commit. Their settings, modifiers and paint go with them.",
"type": "array"
}
},
"type": "object"
},
"key": "commit_to_plate",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Commit to plate"
},
{
"completion": "immediate",
"description": "New Design: erase every feature, body and variable and the Design undo history. Committed objects stay on the plate. Reply: cleared {features, bodies, variables}.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"discard_changes": true
},
"tool": "new_design"
}
],
"title": "A plate's design erased"
},
{
"calls": [
{
"args": {},
"tool": "new_design"
}
],
"title": "An empty design started over, which needs no discard_changes"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"discard_changes": {
"default": false,
"description": "needed when the design is not empty",
"type": "boolean"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "new_design",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "New design"
},
{
"completion": "immediate",
"description": "Export STEP: write every body to a file as native B-rep, at its Move-gizmo position. Reply: path, bytes, bodies, moved_bodies.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"path": "/path/to/part.step"
},
"tool": "export_step"
}
],
"needs": "a folder to write the STEP file in",
"title": "A plate written to a STEP file"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"overwrite": {
"default": false,
"description": "replace an existing file",
"type": "boolean"
},
"path": {
"description": "absolute path; its directory must exist",
"type": "string"
}
},
"required": [
"path"
],
"type": "object"
},
"key": "export_step",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Export step"
},
{
"completion": "immediate",
"description": "Commit the open sketch as a Sketch feature, as the sketch's Confirm does, and leave sketch mode. A new sketch left empty is refused and stays open. A sketch re-opened with sketch_edit is replaced in place, in one undo step, with what is built on it rebuilt, and the reply adds replaced: true. A replace the rebuild refuses, or a re-opened sketch left empty, ends the edit with the design as it was and replies ok false, replaced false, its sketch_index and error, which says why it was not replaced. Reply: sketch_index, name, features (the new count) and its loops (closed_loops with the index extrude's loop takes, open_ends, defects, buildable). A rejected rebuild is reported in the reply: ok is false or error is not empty.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 4,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
}
],
"title": "A rectangle around a circle, committed as a sketch of two loops"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "sketch_finish",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Sketch finish"
},
{
"completion": "immediate",
"description": "Discard the open sketch and leave sketch mode. A sketch re-opened with sketch_edit keeps what it had before the edit.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_cancel"
}
],
"title": "Discard a sketch with a rectangle drawn"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "sketch_cancel",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Sketch cancel"
},
{
"completion": "immediate",
"description": "Re-open a committed sketch to change its entities and constraints, as Edit on its Feature tree row does. The sketch_ commands then act on it; sketch_finish replaces it in place, in one undo step, and rebuilds what is built on it, and sketch_cancel drops the changes. An extrude of one loop keeps its own copy of that loop and does not follow the edit. Refused while a sketch is open, and for text, imported art, a Project sketch and a sketch not drawn from entities. Reply: sketch, entities and constraints (how many the edit starts with) and plane.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"sketch": 0
},
"tool": "sketch_edit"
}
],
"title": "Re-open a committed rectangle"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-10,
-5
],
"p1": [
10,
5
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"distance": 5,
"sketch": 0
},
"tool": "extrude"
},
{
"args": {
"sketch": 0
},
"tool": "sketch_edit"
}
],
"title": "Re-open the sketch a block is extruded from, which the block follows"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"sketch": {
"description": "a committed Sketch feature's index (describe_design's features[].index)",
"type": "integer"
}
},
"required": [
"sketch"
],
"type": "object"
},
"key": "sketch_edit",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Sketch edit"
},
{
"actions": [
{
"args": {
"type": "line"
},
"description": "Line — click start, then end. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_line",
"key": "sk_line_t",
"title": "Line"
},
{
"args": {
"type": "polyline"
},
"description": "Click points; click the first point to close the loop, right-click to end it open. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_polyline",
"key": "sk_polyline",
"title": "Polyline"
},
{
"args": {
"type": "rectangle_2_point"
},
"description": "Rectangle — click two opposite corners. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_rect",
"key": "sk_rect",
"title": "Corner rectangle"
},
{
"args": {
"type": "rectangle_center"
},
"description": "Click center, then a corner. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_crect",
"key": "sk_rect_center",
"title": "Center rectangle"
},
{
"args": {
"type": "rectangle_3_point"
},
"description": "Click two corners of one edge, then a point for the width. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_rect_oblique",
"key": "sk_rect_oblique",
"title": "Oblique rectangle"
},
{
"args": {
"type": "rectangle_rounded"
},
"description": "Click two opposite corners, then a point for the corner radius. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_rect_rounded",
"key": "sk_rect_rounded",
"title": "Rounded rectangle"
},
{
"args": {
"type": "circle_center"
},
"description": "Circle — click center, then radius. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_circle",
"key": "sk_circle",
"title": "Center circle"
},
{
"args": {
"type": "circle_2_point"
},
"description": "Click two ends of the diameter. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_circle2pt",
"key": "sk_circle_2pt",
"title": "2-point circle"
},
{
"args": {
"type": "circle_3_point"
},
"description": "Click three points on the circle. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_circle3pt",
"key": "sk_circle_3pt",
"title": "3-point circle"
},
{
"args": {
"type": "arc_3_point"
},
"description": "Arc — click start, end, then a point. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_arc3pt",
"key": "sk_arc_t",
"title": "3-point arc"
},
{
"args": {
"type": "arc_tangent"
},
"description": "Click start (on the last entity) then end. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_tangentarc",
"key": "sk_arc_tangent",
"title": "Tangent arc"
},
{
"args": {
"type": "arc_center"
},
"description": "Click center, then start, then a point for the end angle. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_arc_center",
"key": "sk_arc_center",
"title": "Center-point arc"
},
{
"args": {
"type": "slot"
},
"description": "Slot — two centerline ends, then the width. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_slot",
"key": "sk_slot",
"title": "Slot"
},
{
"args": {
"type": "slot_arc"
},
"description": "Click center, start, end, then a point for the width. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_slot_arc",
"key": "sk_slot_arc",
"title": "Arc slot"
},
{
"args": {
"type": "ellipse"
},
"description": "Ellipse — center, major end, minor point. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_ellipse",
"key": "sk_ellipse",
"title": "Ellipse"
},
{
"args": {
"type": "ellipse_arc"
},
"description": "Click center, major-axis end, minor point, then arc start and end. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_ellipse_arc",
"key": "sk_ellipse_arc",
"title": "Elliptical arc"
},
{
"args": {
"type": "spline"
},
"description": "Spline — click control points. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_bspline",
"key": "sk_spline",
"title": "Spline"
},
{
"args": {
"sides": 3,
"type": "polygon"
},
"description": "Triangle — click center, then a vertex. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_polygon",
"key": "sk_poly_3",
"title": "Triangle"
},
{
"args": {
"sides": 4,
"type": "polygon"
},
"description": "Square — click center, then a vertex. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_polygon",
"key": "sk_poly_4",
"title": "Square"
},
{
"args": {
"sides": 5,
"type": "polygon"
},
"description": "Pentagon — click center, then a vertex. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_polygon",
"key": "sk_poly_5",
"title": "Pentagon"
},
{
"args": {
"sides": 6,
"type": "polygon"
},
"description": "Hexagon — click center, then a vertex. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_polygon",
"key": "sk_polygon",
"title": "Hexagon"
},
{
"args": {
"sides": 8,
"type": "polygon"
},
"description": "Octagon — click center, then a vertex. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_polygon",
"key": "sk_poly_8",
"title": "Octagon"
},
{
"args": {
"sides": 12,
"type": "polygon"
},
"description": "Dodecagon — click center, then a vertex. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_polygon",
"key": "sk_poly_12",
"title": "Dodecagon"
},
{
"args": {
"type": "point"
},
"description": "Point — click to place. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_point",
"key": "sk_point_t",
"title": "Point"
}
],
"completion": "immediate",
"description": "Draw a shape in the open sketch from its fields beside `type`, or a list of shapes as `entities`. Each type, and the fields it takes: line {p0, p1}; polyline {points: 2 or more, a loop when the last is the first}; rectangle_2_point {p0, p1: opposite corners}; rectangle_center {center, corner}; rectangle_3_point {p0, p1: one side; width: signed, to the left of p0 to p1}; rectangle_rounded {p0, p1: opposite corners; radius: of the corners}; circle_center {center, radius}; circle_2_point {p0, p1: the ends of a diameter}; circle_3_point {p0, p1, p2: on the circle}; arc_3_point {p0: start; p1: end; on_arc}; arc_center {center, radius, start_angle, end_angle}; arc_tangent {end; entity: the line or arc it leaves, the sketch's or one an item before it adds, at that one's end, along its direction there, left out the one added last}; slot {c0, c1, width}; slot_arc {center, start, end: its direction from the centre, width}; ellipse {center, radius (semi-major), rminor, rotation}; ellipse_arc {the ellipse's fields, start_angle, end_angle: parametric, counter-clockwise}; spline {ctrl: 2 or more poles}; polygon {center, sides, radius (to a vertex) or across_flats, angle (of that vertex, or of the first edge's midpoint)}; point {p}. A type refuses a field it does not take. Each is built as its drawing tool builds it: a rectangle, a slot or a polygon is one shape, which one undo of the sketch takes off whole, and a polyline is its lines, as its tool leaves them; the constraints are inferred exactly, so that none moves what is given. Each shape carries the constraints its tool gives it, at any slant; a constraint between a shape and the sketch's axes or what is already in the sketch, or between plain lines, is inferred only where it holds exactly, so a square on the axes is level only on a side lying exactly on one, with right angles holding the others. Each item of entities may carry its own construction; the top-level construction is the single-type form's, and beside entities each item's that gives none. Beside entities a shape's field, type among them, is refused: it belongs in its item. Points are [x, y] in the sketch plane (mm); angles are radians, or degrees as start_angle_deg and the like. A polygon is lines; its side count is not kept once committed. Reply: first_index, added, shapes [{first, count}] per item, entities, dof. Called with exactly one of these argument sets and nothing else, it opens that item's tool of the Design tab for a person, as the menu item does: {\"type\":\"line\"} (Line), {\"type\":\"polyline\"} (Polyline), {\"type\":\"rectangle_2_point\"} (Corner rectangle), {\"type\":\"rectangle_center\"} (Center rectangle), {\"type\":\"rectangle_3_point\"} (Oblique rectangle), {\"type\":\"rectangle_rounded\"} (Rounded rectangle), {\"type\":\"circle_center\"} (Center circle), {\"type\":\"circle_2_point\"} (2-point circle), {\"type\":\"circle_3_point\"} (3-point circle), {\"type\":\"arc_3_point\"} (3-point arc), {\"type\":\"arc_tangent\"} (Tangent arc), {\"type\":\"arc_center\"} (Center-point arc), {\"type\":\"slot\"} (Slot), {\"type\":\"slot_arc\"} (Arc slot), {\"type\":\"ellipse\"} (Ellipse), {\"type\":\"ellipse_arc\"} (Elliptical arc), {\"type\":\"spline\"} (Spline), {\"sides\":3,\"type\":\"polygon\"} (Triangle), {\"sides\":4,\"type\":\"polygon\"} (Square), {\"sides\":5,\"type\":\"polygon\"} (Pentagon), {\"sides\":6,\"type\":\"polygon\"} (Hexagon), {\"sides\":8,\"type\":\"polygon\"} (Octagon), {\"sides\":12,\"type\":\"polygon\"} (Dodecagon), {\"type\":\"point\"} (Point).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
}
],
"title": "A 30 x 20 mm rectangle"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 12,
"type": "circle_center"
},
{
"across_flats": 10,
"center": [
0,
0
],
"sides": 6,
"type": "polygon"
}
]
},
"tool": "sketch_draw"
}
],
"title": "A hexagon 10 mm across flats inside a circle"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"end_angle_deg": 90,
"radius": 20,
"start_angle_deg": 0,
"type": "arc_center"
},
{
"c0": [
-10,
-20
],
"c1": [
10,
-20
],
"type": "slot",
"width": 6
}
]
},
"tool": "sketch_draw"
}
],
"title": "A quarter arc given in degrees, and a slot"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"across_flats": {
"default": null,
"description": "polygon: the distance between opposite flats, in place of radius (mm)",
"type": [
"number",
"null"
]
},
"angle": {
"default": null,
"description": "polygon: the angle of the vertex radius reaches, or with across_flats of the first edge's midpoint, 0 when left out; or angle_deg (rad)",
"type": [
"number",
"null"
]
},
"angle_deg": {
"default": null,
"description": "polygon: angle in degrees (deg)",
"type": [
"number",
"null"
]
},
"c0": {
"default": null,
"description": "slot: one end of its centreline, [x, y], mm",
"type": [
"array",
"null"
]
},
"c1": {
"default": null,
"description": "slot: the other end of its centreline, [x, y], mm",
"type": [
"array",
"null"
]
},
"center": {
"default": null,
"description": "rectangle_center, circle_center, arc_center, slot_arc, ellipse, ellipse_arc, polygon: the centre, [x, y], mm",
"type": [
"array",
"null"
]
},
"construction": {
"default": false,
"description": "true draws construction geometry: the single-type form's shape, or each item of entities that gives no construction of its own",
"type": "boolean"
},
"corner": {
"default": null,
"description": "rectangle_center: a corner, [x, y], mm",
"type": [
"array",
"null"
]
},
"ctrl": {
"default": null,
"description": "spline: its poles, 2 or more [x, y], mm",
"type": [
"array",
"null"
]
},
"end": {
"default": null,
"description": "arc_tangent: where it ends; slot_arc: a point in the direction its centreline ends, from the centre. [x, y], mm",
"type": [
"array",
"null"
]
},
"end_angle": {
"default": null,
"description": "arc_center: the end, 0 when left out; ellipse_arc: the parametric end, which it requires; or end_angle_deg (rad)",
"type": [
"number",
"null"
]
},
"end_angle_deg": {
"default": null,
"description": "arc_center, ellipse_arc: end_angle in degrees (deg)",
"type": [
"number",
"null"
]
},
"entities": {
"default": [],
"description": "shapes, each an object with its type and fields, drawn in order",
"type": "array"
},
"entity": {
"default": null,
"description": "arc_tangent: the index of the line or arc it leaves, one the sketch has or one an item before it adds, at that one's end along its direction there; left out, the entity added last",
"minimum": 0,
"type": [
"integer",
"null"
]
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"on_arc": {
"default": null,
"description": "arc_3_point: a point on it between its ends, [x, y], mm",
"type": [
"array",
"null"
]
},
"p": {
"default": null,
"description": "point: where it is, [x, y], mm",
"type": [
"array",
"null"
]
},
"p0": {
"default": null,
"description": "line: its start; rectangle_2_point, rectangle_rounded: a corner; rectangle_3_point: one end of a side; circle_2_point: one end of a diameter; circle_3_point: a point on it; arc_3_point: its start. [x, y] in the sketch plane, mm",
"type": [
"array",
"null"
]
},
"p1": {
"default": null,
"description": "line: its end; rectangle_2_point, rectangle_rounded: the opposite corner; rectangle_3_point: the side's other end; circle_2_point: the diameter's other end; circle_3_point: a second point on it; arc_3_point: its end. [x, y], mm",
"type": [
"array",
"null"
]
},
"p2": {
"default": null,
"description": "circle_3_point: a third point on it, [x, y], mm",
"type": [
"array",
"null"
]
},
"points": {
"default": null,
"description": "polyline: its points, 2 or more [x, y], mm; the last on the first closes a loop",
"type": [
"array",
"null"
]
},
"radius": {
"default": null,
"description": "rectangle_rounded: of its corners, less than half its shorter side; circle_center, arc_center: the radius; ellipse, ellipse_arc: the semi-major axis; polygon: centre to a vertex, in place of across_flats (mm)",
"type": [
"number",
"null"
]
},
"rminor": {
"default": null,
"description": "ellipse, ellipse_arc: the semi-minor axis, at most radius (mm)",
"type": [
"number",
"null"
]
},
"rotation": {
"default": null,
"description": "ellipse, ellipse_arc: the major axis's angle from the plane's x axis, 0 when left out; or rotation_deg (rad)",
"type": [
"number",
"null"
]
},
"rotation_deg": {
"default": null,
"description": "ellipse, ellipse_arc: rotation in degrees (deg)",
"type": [
"number",
"null"
]
},
"sides": {
"default": null,
"description": "polygon: its number of sides",
"maximum": 1000,
"minimum": 3,
"type": [
"integer",
"null"
]
},
"start": {
"default": null,
"description": "slot_arc: where its centreline starts, [x, y], mm",
"type": [
"array",
"null"
]
},
"start_angle": {
"default": null,
"description": "arc_center: the start, counter-clockwise from the plane's x axis, 0 when left out; ellipse_arc: the parametric start, which it requires; or start_angle_deg (rad)",
"type": [
"number",
"null"
]
},
"start_angle_deg": {
"default": null,
"description": "arc_center, ellipse_arc: start_angle in degrees (deg)",
"type": [
"number",
"null"
]
},
"type": {
"default": "",
"description": "one shape, its fields beside it",
"enum": [
"line",
"polyline",
"rectangle_2_point",
"rectangle_center",
"rectangle_3_point",
"rectangle_rounded",
"circle_center",
"circle_2_point",
"circle_3_point",
"arc_3_point",
"arc_center",
"arc_tangent",
"slot",
"slot_arc",
"ellipse",
"ellipse_arc",
"spline",
"polygon",
"point"
],
"type": "string"
},
"width": {
"default": null,
"description": "rectangle_3_point: the distance to the far side, signed, to the left of p0 to p1; slot, slot_arc: its whole width (mm)",
"type": [
"number",
"null"
]
}
},
"type": "object"
},
"key": "sketch_draw",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Sketch draw"
},
{
"completion": "immediate",
"description": "Select sketch entities by index; an empty list clears the selection. Reply: selected.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
0,
2
]
},
"tool": "sketch_select"
}
],
"title": "Select a rectangle's two long sides"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
0
]
},
"tool": "sketch_select"
},
{
"args": {
"entities": []
},
"tool": "sketch_select"
}
],
"title": "Clear the selection"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"entities": {
"default": [],
"description": "entity indices",
"type": "array"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "sketch_select",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Sketch select"
},
{
"completion": "immediate",
"description": "Weld sketch endpoints that nearly meet and constrain them coincident, so loops are closed by construction. Reply: welded and the loops.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
0,
0
],
"p1": [
20,
0
],
"type": "line"
},
{
"p0": [
20,
0.05
],
"p1": [
20,
10
],
"type": "line"
},
{
"p0": [
20,
10
],
"p1": [
0,
0
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"tolerance": 0.1
},
"tool": "sketch_repair"
}
],
"title": "Close a triangle's 0.05 mm gap"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"ignore_construction": {
"default": true,
"type": "boolean"
},
"tolerance": {
"default": 0.001,
"description": "In mm.",
"type": "number"
}
},
"type": "object"
},
"key": "sketch_repair",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Sketch repair"
},
{
"actions": [
{
"args": {},
"description": "Type the length of this line. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_dimension",
"key": "sk_length",
"title": "Length…"
},
{
"args": {},
"description": "Type the radius of this arc, or the diameter of this circle. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_dimension",
"key": "sk_radius",
"title": "Radius / diameter…"
},
{
"args": {},
"description": "Type the angle between two lines, or the distance between the two picks. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_dimension",
"key": "sk_angdist",
"title": "Angle / distance…"
}
],
"completion": "immediate",
"description": "Set the dimension of the selected sketch entities, as the value field does. A line's length, a circle's diameter, an arc's radius, or the angle or distance between two. Select them with sketch_select first. Reply: kind, before, value, dof and the loops. Called with exactly one of these argument sets and nothing else, it opens that item's tool of the Design tab for a person, as the menu item does: {} (Length…, Radius / diameter…, Angle / distance…).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
0
]
},
"tool": "sketch_select"
},
{
"args": {
"value": 40
},
"tool": "sketch_set_value"
}
],
"title": "A rectangle's bottom side made 40 mm long"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 4,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"entities": [
0
]
},
"tool": "sketch_select"
},
{
"args": {
"value": 12
},
"tool": "sketch_set_value"
}
],
"title": "A circle's diameter set to 12 mm"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"if": {
"minProperties": 1
},
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"silent": {
"description": "true runs the tool with the other arguments and opens nothing. A call with no arguments does what the Design tab's menu item does, as a person's pick does. Called with no arguments, it runs only in an open sketch (sketch_create opens one).",
"enum": [
true
],
"type": "boolean"
},
"value": {
"description": "mm, or degrees for an angle",
"type": "number"
}
},
"then": {
"required": [
"value"
]
},
"type": "object"
},
"key": "sketch_set_value",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Sketch set value"
},
{
"actions": [
{
"args": {
"type": "move"
},
"description": "Pick entities, then drag the handle or click the distance; click empty to apply. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_move",
"key": "sk_move",
"title": "Move"
},
{
"args": {
"type": "rotate"
},
"description": "Pick entities, then drag around the pivot or click the angle; click empty to apply. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_rotate",
"key": "sk_rotate",
"title": "Rotate"
},
{
"args": {
"type": "scale"
},
"description": "Pick entities, then drag the handle or click the factor; click empty to apply. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_scale",
"key": "sk_scale",
"title": "Scale"
}
],
"completion": "immediate",
"description": "Move, rotate or scale entities of the open sketch, as the transform tools' Confirm does. move {dx, dy}, rotate {angle, pivot} and scale {scale, pivot} change the entities and release the constraints that no longer hold. pivot defaults to the entities' centroid. Angles are radians, or degrees as angle_deg. Reply: type, moved, released_constraints, pivot, entities, dof. Called with exactly one of these argument sets and nothing else, it opens that item's tool of the Design tab for a person, as the menu item does: {\"type\":\"move\"} (Move), {\"type\":\"rotate\"} (Rotate), {\"type\":\"scale\"} (Scale).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 3,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"dx": 10,
"entities": [
0
],
"type": "move"
},
"tool": "sketch_transform"
}
],
"title": "A circle moved 10 mm along x"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
0,
0
],
"p1": [
20,
0
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"angle_deg": 30,
"entities": [
0
],
"pivot": [
0,
0
],
"type": "rotate"
},
"tool": "sketch_transform"
}
],
"title": "A line turned 30 degrees about its start"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"angle": {
"default": null,
"description": "rotate's angle, or angle_deg (rad)",
"type": "number"
},
"angle_deg": {
"default": null,
"description": "rotate's angle in degrees, in place of angle (deg)",
"type": "number"
},
"dx": {
"default": 0,
"description": "In mm.",
"type": "number"
},
"dy": {
"default": 0,
"description": "In mm.",
"type": "number"
},
"entities": {
"default": [],
"description": "entity indices; omit for the selection",
"type": "array"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"pivot": {
"default": null,
"description": "[x, y] in the sketch plane, mm",
"type": "array"
},
"scale": {
"default": null,
"type": "number"
},
"type": {
"enum": [
"move",
"rotate",
"scale"
],
"type": "string"
}
},
"required": [
"type"
],
"type": "object"
},
"key": "sketch_transform",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Sketch transform"
},
{
"actions": [
{
"args": {
"type": "linear"
},
"description": "Pick entities, drag the spacing handle, click the count; click empty to apply. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_array",
"key": "sk_array",
"title": "Linear array"
},
{
"args": {
"type": "circular"
},
"description": "Pick entities, drag the sweep handle, click the count; click empty to apply. It takes no arguments and does what the Design tab's right-click menu item does, as a person's pick does: open a tool, start a sketch tool, act at once, or tell the person why it cannot. The reply's status is what the tab's status line shows then. It runs only in an open sketch (sketch_create opens one).",
"icon": "design_polararray",
"key": "sk_array_polar",
"title": "Polar array"
}
],
"completion": "immediate",
"description": "Repeat entities of the open sketch in a row or around a point, as the Linear and Polar array tools do. linear adds copies stepped by dx, dy; circular adds copies every angle/count about pivot (angle is the whole sweep, default 360 degrees). count includes the original, and each copy is bound to its source (equal length and parallel, or its radius). Angles are radians, or degrees as angle_deg. Reply: type, first_index, added, bound, pivot (circular), entities, dof. Called with exactly one of these argument sets and nothing else, it opens that item's tool of the Design tab for a person, as the menu item does: {\"type\":\"linear\"} (Linear array), {\"type\":\"circular\"} (Polar array).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
20,
0
],
"radius": 3,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"angle_deg": 360,
"count": 6,
"entities": [
0
],
"pivot": [
0,
0
],
"type": "circular"
},
"tool": "sketch_pattern"
}
],
"title": "Six holes on a 40 mm bolt circle"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"center": [
0,
0
],
"radius": 2,
"type": "circle_center"
}
]
},
"tool": "sketch_draw"
},
{
"args": {
"count": 3,
"dx": 10,
"entities": [
0
],
"type": "linear"
},
"tool": "sketch_pattern"
}
],
"title": "Three holes 10 mm apart along x"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"angle": {
"default": null,
"description": "circular: the whole sweep, or angle_deg (rad)",
"type": "number"
},
"angle_deg": {
"default": null,
"description": "circular: the whole sweep in degrees, in place of angle (deg)",
"type": "number"
},
"count": {
"default": null,
"description": "instances, the original among them; required",
"maximum": 1000,
"minimum": 2,
"type": "integer"
},
"dx": {
"default": 0,
"description": "linear: the step (mm)",
"type": "number"
},
"dy": {
"default": 0,
"description": "linear: the step (mm)",
"type": "number"
},
"entities": {
"default": [],
"description": "entity indices; omit for the selection",
"type": "array"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"pivot": {
"default": null,
"description": "circular, which requires it: the centre [x, y] in the sketch plane, mm",
"type": "array"
},
"type": {
"enum": [
"linear",
"circular"
],
"type": "string"
}
},
"required": [
"type"
],
"type": "object"
},
"key": "sketch_pattern",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Sketch pattern"
},
{
"completion": "immediate",
"description": "Delete a constraint of the open sketch, as its row's delete button does; the constraints after it move down one index. Reply: removed, constraints, dof, solve_ok.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_list_constraints"
},
{
"args": {
"index": 4
},
"tool": "sketch_delete_constraint"
}
],
"title": "A rectangle's bottom side freed from horizontal"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"index": {
"description": "sketch_list_constraints' items[].index",
"type": "integer"
}
},
"required": [
"index"
],
"type": "object"
},
"key": "sketch_delete_constraint",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Sketch delete constraint"
},
{
"completion": "immediate",
"description": "Which align types fit a pair of coordinate systems, and why each other one does not. As the Mate card dims the types it does not offer. Reply: cs_a, cs_b and types, the five align types in order (fastened, planar, revolute, slider, cylindrical), each {type, fits, reason}, reason null where it fits.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"distance": 10,
"operation": "new_body",
"profile": [
[
30,
-5
],
[
40,
-5
],
[
40,
5
],
[
30,
5
]
]
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"face": 5,
"generation": {
"from_call": 2,
"key": "generation"
},
"type": "face_and_direction"
},
"tool": "construct_coordinate_system"
},
{
"args": {
"at_extreme": "-z",
"body": 1
},
"tool": "body_describe"
},
{
"args": {
"body": 1,
"face": 4,
"generation": {
"from_call": 4,
"key": "generation"
},
"type": "face_and_direction"
},
"tool": "construct_coordinate_system"
},
{
"args": {
"cs_a": 4,
"cs_b": 5
},
"tool": "list_align_types"
}
],
"title": "The types that fit a plate's top-face connector and a block's bottom-face one"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"properties": {
"cs_a": {
"description": "feature index of the fixed CoordSys, align's cs_a",
"type": "integer"
},
"cs_b": {
"description": "feature index of the CoordSys on the body that moves, align's cs_b",
"type": "integer"
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
}
},
"required": [
"cs_a",
"cs_b"
],
"type": "object"
},
"key": "list_align_types",
"listed": false,
"open_world": false,
"operations": [],
"read_only": true,
"title": "Align types"
},
{
"completion": "immediate",
"description": "Select a body, a face, edges, a vertex, a reference plane, a sketch's loop or a feature by id, as a click selects it. One form: body; body with face, edges (the last the current edge, as in a Shift+click set) or vertex; plane; sketch with loop; feature; or nothing, which clears the selection. A body is selected as a click on its row of the Bodies list selects it, a face, edges or a vertex as a click in the view picks them, a loop as a click on it, which also selects its Sketch's row, and a feature as a click on its row of the Feature list. A plane is picked only where a click can pick one: while the Origin row shows the planes, or while Sketch waits for its plane (sketch_create {}), where picking it opens the sketch. A loop is numbered as sketch_describe {sketch} numbers closed_loops and extrude {sketch, loop} takes it, and is selected only while the view shows it: an extrude that takes the whole sketch hides the sketch, and one that takes a loop hides that loop. Whatever was selected goes first, of every kind. The menu-item forms then act on the selection: feature_edit, rename_selected, feature_delete and sketch_constrain_selected called with no arguments act on the selected row of the Feature list while nothing is picked in the view, and zoom_to_selection acts on what is picked in the view, so a sketch is zoomed to through sketch with loop, not through feature. Refused, changing nothing, for an id the model does not have, and while a card, a sketch, Constrain mode, a body Move or the Text dialog is open, where a click means something else. Reply: selection {kind, id}, plane and feature, as describe_design reports selection, picked_plane and feature_row; for a vertex also point, as body_describe gives it, and placed_point, where the view draws it (the same unless the body was moved).",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"body": 0
},
"tool": "select_geometry"
}
],
"title": "A plate selected whole, as a click on its row of the Bodies list selects it"
},
{
"calls": [
{
"args": {
"distance": 5,
"height": 20,
"width": 20
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "+z",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"face": 5,
"generation": {
"from_call": 1,
"key": "generation"
}
},
"tool": "select_geometry"
}
],
"title": "A plate's top face selected, as a click on it selects it"
},
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-10,
-10
],
"p1": [
10,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "sketch_finish"
},
{
"args": {
"loop": 0,
"sketch": 0
},
"tool": "select_geometry"
}
],
"title": "A sketched square's loop selected, which selects its Sketch's row too"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"body": {
"default": null,
"description": "body index (describe_design); alone, the whole body",
"minimum": 0,
"type": [
"integer",
"null"
]
},
"edges": {
"default": null,
"description": "edge ids of body (body_describe), one or more",
"type": [
"array",
"null"
]
},
"face": {
"default": null,
"description": "a face id of body (body_describe)",
"minimum": 0,
"type": [
"integer",
"null"
]
},
"feature": {
"default": null,
"description": "feature index (describe_design): its row of the Feature list",
"minimum": 0,
"type": [
"integer",
"null"
]
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"loop": {
"default": null,
"description": "a closed loop of sketch: its index in sketch_describe's closed_loops",
"minimum": 0,
"type": [
"integer",
"null"
]
},
"plane": {
"default": null,
"description": "a reference plane",
"enum": [
"XY",
"XZ",
"YZ",
null
],
"type": [
"string",
"null"
]
},
"sketch": {
"default": null,
"description": "feature index of a committed sketch",
"minimum": 0,
"type": [
"integer",
"null"
]
},
"vertex": {
"default": null,
"description": "a vertex id of body (body_describe {vertices: true})",
"minimum": 0,
"type": [
"integer",
"null"
]
}
},
"type": "object"
},
"key": "select_geometry",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Select geometry"
},
{
"completion": "immediate",
"description": "Confirm what is open in the Design tab, as its Confirm button and Enter do. What is open, in the order Confirm takes it: the Text dialog (text), a value field (value), a body Move (move), a text or art placement (insert), a feature card (card), a sketch (sketch), Constrain mode (constrain). The Text dialog takes it as its OK does: a new text goes into the design, its placement then open (insert), and an edited one keeps its new words. A card adds or edits its feature in one undo step and closes; an add the card refuses, or whose rebuild fails, leaves no feature and no undo step and keeps the card open with the reason on the status line. A Confirm that does not take, such as that add or a value that is no number, replies ok false. It runs under what is open, which refuses the commands that change the document. Refused, changing nothing, when nothing is open, while Sketch waits for its plane (pick one with select_geometry {plane}, or call cancel_tool), while the Text dialog's OK is off, with no text to insert, with the dialog's reason, and while Confirm is off, such as for a card whose preview fails, with the status line as the reason. Reply: was, what was open; ok, whether it took the Confirm; feature, the index of the feature added or edited, or null; open, what is still open, or null; status, the status line.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"p0": [
-15,
-10
],
"p1": [
15,
10
],
"type": "rectangle_2_point"
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "confirm_tool"
}
],
"title": "A sketched rectangle committed, as the sketch's Confirm commits it"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "confirm_tool",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Confirm tool"
},
{
"completion": "immediate",
"description": "Cancel what is open in the Design tab, as its Cancel button does. What is open, in the order Cancel takes it: the Text dialog (text), closed as its Cancel closes it, with a new text not added and an edited one as it was, a value field (value), a body Move (move), put back where it started, a text or art placement (insert), a feature card (card), with nothing added or edited, Sketch waiting for its plane (plane_pick), a sketch (sketch), discarded without the dialog a person gets, a re-opened one kept as it was, and Constrain mode (constrain). It runs under what is open, which refuses the commands that change the document. Refused when nothing is open. Reply: was, what was open, and status, the status line.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"plane": "XY"
},
"tool": "sketch_create"
},
{
"args": {
"entities": [
{
"p0": [
0,
0
],
"p1": [
10,
0
],
"type": "line"
}
]
},
"tool": "sketch_draw"
},
{
"args": {},
"tool": "cancel_tool"
}
],
"title": "A sketch holding a line discarded, with no dialog"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
}
},
"type": "object"
},
"key": "cancel_tool",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Cancel tool"
},
{
"completion": "immediate",
"description": "Place a body where Commit to Plate and Export STEP send it: move it, turn it, lay a face on the bed, or put it back. The Bodies row's Move and Place on Face, outside the history: no undo step, and the project file does not keep it. One form: move and rotate, either or both, added to where the body stands as the Move / Rotate card adds them, the turn about the body's centre; face, which lays that face on the bed as Place on Face does; or reset: true, which puts the body back where the model has it. The view draws and picks the body where it stands, and its placement follows it when the bodies are renumbered. Refused, changing nothing, for a body or face the model does not have, for none or more than one of the forms, and while a card, a sketch, Constrain mode, a body Move or the Text dialog is open. Reply: ok, body, moved and placement, as describe_design reports them.",
"destructive": false,
"examples": [
{
"calls": [
{
"args": {
"distance": 10,
"height": 20,
"width": 30
},
"tool": "extrude"
},
{
"args": {
"body": 0,
"move": [
10,
0,
0
],
"rotate": {
"angle": 90,
"axis": "z"
}
},
"tool": "body_place"
}
],
"title": "A box moved 10 mm along x and turned a quarter turn about z"
},
{
"calls": [
{
"args": {
"distance": 10,
"height": 20,
"width": 30
},
"tool": "extrude"
},
{
"args": {
"at_extreme": "-y",
"body": 0
},
"tool": "body_describe"
},
{
"args": {
"body": 0,
"face": 0,
"generation": {
"from_call": 1,
"key": "generation"
}
},
"tool": "body_place"
}
],
"title": "A box laid on its side face whose normal is -y"
}
],
"group": "Design",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"body": {
"description": "body index (describe_design)",
"minimum": 0,
"type": "integer"
},
"face": {
"default": null,
"description": "a face id of body (body_describe), laid on the bed",
"minimum": 0,
"type": [
"integer",
"null"
]
},
"generation": {
"description": "The generation (describe_design, body_describe) the face and edge ids this call passes were read at. Ids expire when a feature rebuilds the model, and a stale id still names a real face or edge: with the generation, a call whose ids were read before the model changed is refused.",
"minimum": 0,
"type": "integer"
},
"move": {
"default": null,
"description": "[dx, dy, dz] in the world frame (mm)",
"type": [
"array",
"null"
]
},
"reset": {
"default": false,
"description": "true: back where the model has it",
"type": "boolean"
},
"rotate": {
"default": null,
"description": "{\"axis\": \"x\", \"y\" or \"z\", \"angle\": degrees}: a turn about that world axis through the body's centre",
"type": [
"object",
"null"
]
}
},
"required": [
"body"
],
"type": "object"
},
"key": "body_place",
"listed": false,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Place body"
},
{
"completion": "immediate",
"description": "Describe what is on screen as an indented tree, one element per line with a ref to pass to widget_click, widget_set_value, keyboard_press and webview_run_javascript (a page element's to mouse_gesture too): the widgets of every shown window, the rows of lists, trees and tables, each shown popup after the window it opened from, the main menus, the 3D canvas's toolbar items and gizmos, each ImGui panel drawn in the last frame with its items and text, and the elements of each shown web page (dialogs, the setup wizard, sign-in, plugin windows) under its web view. With a modal dialog open, only the topmost dialog's pages are read. Refs go stale when their element goes away: call widget_list again then. Prefer action_run and the typed tools when one fits.\nA locator names an element without a ref, in any session (replay_export records them); index (0-based) picks one of several matches:\n- a widget: {label, class, name, within, index}, within being its window's title; a notebook page: {tab: \"General\", within}\n- a setting's field: {option: \"layer_height\"}\n- {menu: \"File>Export>Export G-code\"}, {gltoolbar: \"arrange\"}, {gizmo: \"Move\"}\n- an ImGui item: {imgui: \"label\", imgui_name?: \"name\", window?, canvas?, index?}, by its label, its name or both\n- a row of a list, tree, table or drop-down list: {row: \"Plate 1>Cube>Cylinder\", column?, within?, index?}, by its last labels; column names the cell to act on\n- a plate or one of its icons in the Prepare view: {plate_icon: \"lock\", plate: 0}, the icon being plate, delete, orient, arrange, lock, settings, name, move_to_front, filament_map or imex_mode\n- a web page's element: {web: \"Next\", kind?: \"button\", css?: \"#AcceptBtn\", within?, index?}, by the label widget_list lists (exactly, else ignoring case, else a part of it), its kind, a CSS selector (the id a line shows as name: name=#save is {css: \"#save\"}), or together. Without within it looks in the topmost dialog's pages while one is open, else in every shown page, and an action on it waits for its element up to 2 s short of the action's timeout_s (8 s by default), but at least 3 s or the whole of a shorter timeout_s.",
"destructive": false,
"group": "Driving the GUI",
"guard": "inspect",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"include_imgui": {
"description": "List ImGui items (default true).",
"type": "boolean"
},
"include_menus": {
"description": "List menu items (default true).",
"type": "boolean"
},
"include_web": {
"description": "List the elements of web pages (default true).",
"type": "boolean"
},
"max_nodes": {
"description": "Default 400.",
"maximum": 5000,
"minimum": 1,
"type": "integer"
},
"max_web_nodes": {
"description": "Page elements, apart from max_nodes; default 300.",
"maximum": 5000,
"minimum": 1,
"type": "integer"
},
"query": {
"description": "Case-insensitive text to look for in labels, values, names and classes.",
"type": "string"
},
"target": {
"description": "all (default), main, dialog (the topmost modal), popup, or a window's ref (window_list).",
"type": "string"
}
},
"type": "object"
},
"key": "widget_list",
"listed": true,
"open_world": false,
"operations": [],
"read_only": true,
"title": "List the widgets"
},
{
"completion": "immediate",
"description": "Click a GUI element as a person would. Menu items, buttons, checkboxes, toggles, radio buttons, toolbar items and gizmos are activated the way their owners expect: a gizmo opens and a second click closes it (Text on an object without text creates a text part: created). Other widgets and ImGui items get a mouse click once scrolled into view; with x/y, at that point of a 3D canvas or custom-drawn widget, in logical pixels from its top left. A row is selected as a click on its cell selects it (ctrl adds, shift extends; in the object list the named column acts, as Printable toggles), double activates it and a right click opens its menu; a drop-down list's row is picked. A plate icon does what it does in the Prepare view: lock replies locked, arrange and orient reply done once their job ends, settings and filament_map list the dialog they open (dialogs). A button, checkbox, toggle or radio button is activated so by a plain left click only: with modifiers, double or another button it gets a mouse click, which a native control ignores. A menu item runs whatever those options are, a toolbar item takes a left or a right click, and a gizmo a single left one. Modifiers reach the 3D canvas, the object list and handlers that read them. To click a point of the model, drag, scroll or hold a press, use mouse_gesture. A menu the click opens is never shown: the reply lists it as popup_menu, or popup_item runs one of its items (ran). A click that opens a dialog replies blocked_by_dialog.\nA web page's element gets the pointer and mouse events of a click at its centre (or x/y) once scrolled into view, refused when something else covers that point. The reply reads back checked, and has closed when the click closed its dialog (with dialogs, those still open under it, which still need an answer), navigated (with url) when it changed the page, or dialogs when it opened another. Otherwise page says what changed on the page within 300 ms: changed (false when its lines are as before), the widget_list lines added and removed, partial when a plugin configuration frame could not be compared, and posted, how many messages the page sent OrcaSlicer.",
"destructive": false,
"group": "Driving the GUI",
"guard": "recover",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"button": {
"description": "Default left.",
"enum": [
"left",
"right",
"middle"
],
"type": "string"
},
"double": {
"description": "Double click.",
"type": "boolean"
},
"modifiers": {
"description": "Modifier keys held during the input, as in keyboard_press: ctrl and cmd are both Command on macOS and Ctrl elsewhere; rawctrl is the macOS Control key.",
"items": {
"enum": [
"ctrl",
"cmd",
"rawctrl",
"shift",
"alt"
],
"type": "string"
},
"type": "array"
},
"popup_item": {
"description": "Run this item of the menu the input opens (a right click's context menu, a button's menu), by its label path, \"Add Modifier>Cylinder\"; \"#2\" picks a repeated label's second item. Without it, such a menu is listed in the reply (popup_menu), not shown.",
"type": "string"
},
"target": {
"description": "A ref widget_list gave (\"w12\"), which later listings leave good (one refused as stale or unknown needs a new listing), or a locator, such as {label: \"OK\", within: \"Preferences\"} or {menu: \"File>Export>Export G-code\"}; widget_list's description lists every kind.",
"type": [
"string",
"object"
]
},
"timeout_s": {
"description": "For a web page's element: seconds the page gets to answer (default 10).",
"maximum": 120,
"minimum": 1,
"type": "integer"
},
"x": {
"description": "x of the point to click, in a 3D canvas, a custom-drawn widget or a page element.",
"type": "integer"
},
"y": {
"description": "y of the point to click.",
"type": "integer"
}
},
"required": [
"target"
],
"type": "object"
},
"key": "widget_click",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Click an element"
},
{
"completion": "immediate",
"description": "Set a widget's value and send the events a person's edit would. Widgets: text fields (submit, the default, also presses Enter and leaves the field, which is when Orca's setting fields commit), spin controls, sliders, choice, combo and list boxes (by option text or index), checkboxes, toggles and a row's checkbox (true or false), and a radio button (an Orca radio box too) or a selector's option, as the dialog message shows them (*) / ( ) (true selects it; false on the selected one is refused, as only selecting another unselects it). ImGui items, by their kind, with the value read back: a field is typed into (a slider through the number field beside it, multiline text with \\n), and one that then shows another value, the edit in its own terms or bounded, replies typed and a note beside it; a combo's option is picked by its text or 0-based index, and a checkbox, radio or toggle is clicked when it differs. A web page's fields, as typing would leave them: text, number, range, colour and date fields and editable text get the value with input and change events (submit then leaves the field; keyboard_press Return presses Enter), a select its option by text, value or index, and a checkbox or radio is clicked when it differs; the value is read back and page says what changed, as for widget_click. File fields can't be set. For settings, settings_set is more reliable.",
"destructive": false,
"group": "Driving the GUI",
"guard": "recover",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"submit": {
"description": "Press Enter / commit after setting (default true).",
"type": "boolean"
},
"target": {
"description": "A ref widget_list gave (\"w12\"), which later listings leave good (one refused as stale or unknown needs a new listing), or a locator, such as {label: \"OK\", within: \"Preferences\"} or {menu: \"File>Export>Export G-code\"}; widget_list's description lists every kind.",
"type": [
"string",
"object"
]
},
"timeout_s": {
"description": "For a web page's element: seconds the page gets to answer (default 10).",
"maximum": 120,
"minimum": 1,
"type": "integer"
},
"value": {
"description": "The new value.",
"type": [
"string",
"number",
"boolean"
]
}
},
"required": [
"target",
"value"
],
"type": "object"
},
"key": "widget_set_value",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Set a widget's value"
},
{
"completion": "immediate",
"description": "Send a key chord (\"Ctrl+S\", \"Escape\", \"Return\", \"Delete\", \"Shift+Tab\", \"Left\", \"F5\") and/or type text to a target or, without one, to the focused window (the topmost dialog while one is open, the shown 3D view when nothing has focus). As with a real key press, the shortcut handling of the target's panels and window sees the keys first. Typing reaches ImGui fields and key handlers; fill a widget's text field with widget_set_value. A menu the keys open is listed as popup_menu, or popup_item runs one of its items. Keys for a web page (its element, or without a target the focused web view or the topmost dialog's only page) go to the page's focused element with the browser's default actions: typing, Backspace/Delete, Enter (submits a form, activates a button), Space, Tab moving the focus, arrows stepping a select, range or radio group; page says what they changed, as for widget_click.",
"destructive": false,
"group": "Driving the GUI",
"guard": "recover",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"keys": {
"description": "One chord: a key, after any modifiers joined by +. Keys: one character, Enter, Esc, Tab, Space, Backspace, Delete, Insert, Home, End, PageUp, PageDown, Left, Right, Up, Down, F1 to F24. Modifiers: Ctrl, Cmd, RawCtrl, Shift, Alt. With text, the chord goes first.",
"type": "string"
},
"popup_item": {
"description": "Run this item of the menu the input opens (a right click's context menu, a button's menu), by its label path, \"Add Modifier>Cylinder\"; \"#2\" picks a repeated label's second item. Without it, such a menu is listed in the reply (popup_menu), not shown.",
"type": "string"
},
"target": {
"description": "A ref widget_list gave (\"w12\"), which later listings leave good (one refused as stale or unknown needs a new listing), or a locator, such as {label: \"OK\", within: \"Preferences\"} or {menu: \"File>Export>Export G-code\"}; widget_list's description lists every kind.",
"type": [
"string",
"object"
]
},
"text": {
"description": "Characters to type.",
"type": "string"
},
"timeout_s": {
"description": "For a web page's element: seconds the page gets to answer (default 10).",
"maximum": 120,
"minimum": 1,
"type": "integer"
}
},
"type": "object"
},
"key": "keyboard_press",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Press keys"
},
{
"completion": "immediate",
"description": "Make a mouse gesture on a 3D canvas as a person would: move, down, up, click, drag or wheel. It starts at `at`, a point of the model, which is projected through the camera and by default checked to land on that part (check \"point\" only projects it), or at x/y, logical pixels from the canvas's top left. A drag goes through `waypoints` to `to`, `steps` moves per leg: on an object it moves the object, in a painting gizmo it paints from a press on the object being painted (waypoints zigzagging over an area paint all of it), and elsewhere it turns or pans the camera as this install's mouse settings say, so turn the camera with view_set camera or orbit instead. A wheel turns delta notches; positive zooms in (out with the Reverse mouse zoom preference on) or scrolls a panel up. Modifiers are held as keys for the gesture (shift picks points in Measure and erases in a painting gizmo). A down keeps its button and modifiers held, so moves drag, until an up or another gesture. Grabbers are set through the gizmo's panel fields or object_transform, not dragged. A menu a right click opens is listed as popup_menu, or popup_item (with click or up) runs one of its items. The reply's camera_moved says the gesture moved the camera, so earlier screenshots and pixels no longer match the view.\nWith target, the gesture is on a web page's element instead (a canvas such as the colour picker's spectrum, a slider, a sortable or scrolled list): x/y, to and waypoints are logical pixels from its top left, a drag keeps the pointer captured where the page asks for it, and a wheel scrolls what is under the pointer unless the page takes it; page says what the gesture changed there, as for widget_click.",
"destructive": false,
"group": "Driving the GUI",
"guard": "recover",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"action": {
"description": "Default click.",
"enum": [
"move",
"down",
"up",
"click",
"drag",
"wheel"
],
"type": "string"
},
"at": {
"additionalProperties": false,
"description": "A point of the model: {object, instance (default 0), part (default 0), and point [x, y, z] in the part's own mesh coordinates (frame \"part\", the default) or the scene's (frame \"world\"), or spot: top | bottom | front | back | left | right, where a ray along that axis first meets the part}.",
"properties": {
"frame": {
"description": "Default part.",
"enum": [
"part",
"world"
],
"type": "string"
},
"instance": {
"minimum": 0,
"type": "integer"
},
"object": {
"minimum": 0,
"type": "integer"
},
"part": {
"minimum": 0,
"type": "integer"
},
"point": {
"description": "[x, y, z] mm",
"items": {
"type": "number"
},
"type": "array"
},
"spot": {
"description": "A side of the part.",
"enum": [
"top",
"bottom",
"front",
"back",
"left",
"right"
],
"type": "string"
}
},
"required": [
"object"
],
"type": "object"
},
"button": {
"description": "Default left.",
"enum": [
"left",
"right",
"middle"
],
"type": "string"
},
"canvas": {
"description": "Default current, the view shown. design takes x/y only.",
"enum": [
"3d",
"preview",
"assemble",
"design",
"current"
],
"type": "string"
},
"check": {
"description": "For model points: surface (default) or projection only.",
"enum": [
"surface",
"point"
],
"type": "string"
},
"delta": {
"description": "Wheel notches (default 1 on a canvas; a page element needs it given).",
"type": "integer"
},
"double": {
"description": "Double click.",
"type": "boolean"
},
"modifiers": {
"description": "Modifier keys held during the input, as in keyboard_press: ctrl and cmd are both Command on macOS and Ctrl elsewhere; rawctrl is the macOS Control key.",
"items": {
"enum": [
"ctrl",
"cmd",
"rawctrl",
"shift",
"alt"
],
"type": "string"
},
"type": "array"
},
"popup_item": {
"description": "Run this item of the menu the input opens (a right click's context menu, a button's menu), by its label path, \"Add Modifier>Cylinder\"; \"#2\" picks a repeated label's second item. Without it, such a menu is listed in the reply (popup_menu), not shown.",
"type": "string"
},
"steps": {
"description": "Moves per drag leg (default 10).",
"maximum": 200,
"minimum": 1,
"type": "integer"
},
"target": {
"description": "A web page's element (its ref or a {web}/{css} locator) to gesture on instead of a 3D canvas.",
"type": [
"string",
"object"
]
},
"timeout_s": {
"description": "For a web page's element: seconds the page gets to answer (default 10).",
"maximum": 120,
"minimum": 1,
"type": "integer"
},
"to": {
"description": "A canvas pixel [x, y] or a point of the model, as for at.",
"type": [
"array",
"object"
]
},
"tolerance": {
"description": "Surface check distance in mm (default 1% of the part's size, at least 0.1).",
"minimum": 0,
"type": "number"
},
"waypoints": {
"description": "Where a drag goes after the start, before to.",
"items": {
"description": "A canvas pixel [x, y] or a point of the model, as for at.",
"type": [
"array",
"object"
]
},
"type": "array"
},
"x": {
"description": "Start x, instead of at.",
"type": "integer"
},
"y": {
"description": "Start y, instead of at.",
"type": "integer"
}
},
"type": "object"
},
"key": "mouse_gesture",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Mouse gesture on a 3D view or page element"
},
{
"completion": "immediate",
"description": "Do what a file picker inside the open gizmo does, with a path instead of its dialog: svg_change loads another SVG file into the SVG part being edited, svg_save_as writes that part's SVG to a new file (an existing one only with overwrite), texture_import imports a height-map image into the texture library and puts it on Texture Displacement's active layer. To add an SVG part, use object_add_svg with a path. Gizmos open with widget_click {target: {gizmo: name}}, and their panels take widget_set_value / widget_click on the ImGui items widget_list lists.",
"destructive": false,
"group": "Driving the GUI",
"guard": "mutate",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"action": {
"description": "What to do.",
"enum": [
"svg_change",
"svg_save_as",
"texture_import"
],
"type": "string"
},
"overwrite": {
"description": "svg_save_as: replace an existing file.",
"type": "boolean"
},
"path": {
"description": "Absolute path of the file to read or write.",
"type": "string"
}
},
"required": [
"action",
"path"
],
"type": "object"
},
"key": "gizmo_pick_file",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Load or save the open gizmo's SVG or texture file"
},
{
"completion": "immediate",
"description": "Press a button of the topmost modal dialog: yes, no, ok, cancel, close, apply, a button's label, or a numeric id. A disabled button (enabled: false) is refused, the dialog's message showing what it still needs, and so is one on a page the dialog does not show, except a hidden cancel or close, which ends the dialog. On a dialog that is neither native nor a web dialog, a standard name or id it has no button for ends it with that answer too, without a handler running (pressed: false). The label of an option of a selector made of buttons (Orca's radio groups, tab bars and multi-switches, shown as (*) / ( ) in the message) selects that option and leaves the dialog open; set other radio buttons and switches with widget_click or widget_set_value true, and notebook tabs with widget_click. dialog.title, text the dialog's title contains, makes sure which dialog that is; it must be the topmost. Reply: dialog, button, pressed, and id, the wx id pressed or ended with, or web: true for a button on a web dialog's page, with what the page did as widget_click reports it; closed: true when it closed, and dialogs, those still open. A native message box (native: true) is pressed through the OS, by one of the buttons app_state.dialogs lists for it; a file or folder picker can't be answered here, nor any native dialog on macOS (its buttons list is empty): register dialog_auto_answer before opening them. A web dialog's buttons are on its page: a label is pressed there, waiting up to 3 s for it to show, so the page's own handler runs. With no such page button, or a page busy for those 3 s, cancel and close end the dialog, and ok, yes, no and apply are refused rather than skip the page's commit; page_buttons then lists the page's buttons.",
"destructive": false,
"group": "Driving the GUI",
"guard": "recover",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"button": {
"description": "Button to press.",
"type": "string"
},
"dialog": {
"additionalProperties": false,
"description": "Which dialog; default the topmost.",
"properties": {
"title": {
"description": "Text the dialog's title contains (case-insensitive).",
"type": "string"
}
},
"type": "object"
}
},
"required": [
"button"
],
"type": "object"
},
"key": "dialog_answer",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Answer a dialog"
},
{
"completion": "immediate",
"description": "Answer modal dialogs automatically when their title or message matches a rule's regex (case-insensitive). app_state.auto_answer_rules lists the rules in force. Called from a replay or script, the rules join those it set before and last until it ends, and a plugin's likewise until it unloads; an MCP client's replace the ones MCP clients set before and last until the MCP server stops, and an empty list clears them. Reply: scope (run, plugin or session), rules (uses counts a rule's answers) and answered_open_dialog. A native dialog returns the rule's button at once and never shows. A file or folder picker takes button ok with an absolute path and returns it without showing (on Linux such a rule cancels it); without a path a picker can only be cancelled, and a multi-select picker takes no path. A wx dialog is answered as dialog_answer does. A matching dialog already open is answered too (answered_open_dialog), so a prompt that shows around the same time, such as the restore prompt after startup, is caught either way. A web dialog is matched by its title: a button that names one of its shown wx buttons (by label, standard name or id) is pressed as for a wx dialog, any other on its page once it shows there, for up to 10 s after the page loads; past that, cancel and close end the dialog and any other button gives up.",
"destructive": false,
"group": "Driving the GUI",
"guard": "recover",
"has_own_action": false,
"idempotent": true,
"input_schema": {
"additionalProperties": false,
"properties": {
"rules": {
"description": "Rules, first match wins.",
"items": {
"additionalProperties": false,
"properties": {
"button": {
"description": "yes | no | ok | cancel | close | apply | label | id",
"type": "string"
},
"match": {
"description": "Regex searched in \"title\\nmessage\", in \"title\\ntext\" (the dialog's own static text, one line each, without its controls), and in the title alone for a dialog with no text (a web dialog), so ^Title$ matches it.",
"type": "string"
},
"overwrite": {
"description": "A save picker may return an existing file at path (default false).",
"type": "boolean"
},
"path": {
"description": "Absolute path a matching file or folder picker returns, with button ok. A picker has no title until it shows, so the rule matches its prompt and must not anchor on a title with ^. The rule answers pickers only: an open picker needs an existing file, a folder picker an existing folder, and a save picker a new file. A picker the path can't serve is cancelled and the reason logged.",
"type": "string"
}
},
"required": [
"match",
"button"
],
"type": "object"
},
"type": "array"
}
},
"required": [
"rules"
],
"type": "object"
},
"key": "dialog_auto_answer",
"listed": true,
"open_world": false,
"operations": [],
"read_only": false,
"title": "Answer dialogs automatically"
},
{
"completion": "immediate",
"description": "Evaluate JavaScript in one of OrcaSlicer's web views (Home, the device page, dialogs, plugin windows). Prefer widget_list and the input tools (widget_click, widget_set_value, keyboard_press, mouse_gesture), which see and drive pages as they do widgets. The code runs in the target's page: a web view's (kind webview in widget_list), or a page element's, with the element as `el`; without a target, in the topmost dialog's web view, else in the only shown one. While a modal dialog is open, only its pages run code. Reply: result, the value of the last expression (JSON values come back parsed), and url; closed: true when the code closed its dialog, navigated: true when it changed the page, dialogs when it opened another. Messages the page posts to OrcaSlicer reach it once the code has returned. It runs through eval, which a page whose Content-Security-Policy forbids it may refuse (widget_list and the input tools still work there).",
"destructive": false,
"group": "Driving the GUI",
"guard": "recover",
"has_own_action": false,
"idempotent": false,
"input_schema": {
"additionalProperties": false,
"properties": {
"code": {
"description": "JavaScript statements, run through eval: the last expression's value is the result. No top-level return or await; a Promise or a DOM node comes back as {}.",
"type": "string"
},
"target": {
"description": "A web view (its ref; widget_list lists it as kind webview) or an element of its page (its ref or a {web} / {css} locator), which the code gets as `el`. Default: the topmost dialog's web view, else the only one shown.",
"type": [
"string",
"object"
]
},
"timeout_s": {
"description": "Seconds the code gets (default 10).",
"maximum": 120,
"minimum": 1,
"type": "integer"
}
},
"required": [
"code"
],
"type": "object"
},
"key": "webview_run_javascript",
"listed": true,
"open_world": true,
"operations": [],
"read_only": false,
"title": "Run JavaScript in a web view"
}
]
}