SlateInspectorToolset.SlateInspectorToolset¶
Playwright-style Slate UI automation toolset.
Exposes snapshot, screenshot, and interaction tools for driving the Unreal Editor UI programmatically. Registered via UToolsetRegistry so the ModelContextProtocol plugin picks them up automatically.
A shallow root observer (depth 0) continuously tracks top-level windows. Before working with a specific window or panel, call Observe() on it to get deep widget coverage, then Unobserve() when done. Observers walk their subtree every ~100ms, assigning refs to newly appeared widgets and keeping the ref cache current.
Input simulation uses direct Slate event APIs (ProcessKeyCharEvent, ProcessMouseButtonDownEvent, etc.) rather than the AutomationDriver, because AutomationDriver's synchronous API deadlocks when called from the game thread (which is where MCP tool calls execute).
14 tool(s).
SlateInspectorToolset.SlateInspectorToolset.Click¶
Click a Slate widget identified by its ref.
Input schema
{
"properties": {
"button": {
"default": "left",
"description": "\"left\", \"right\", or \"middle\".",
"type": "string"
},
"doubleClick": {
"default": false,
"description": "True for double-click.",
"type": "boolean"
},
"modifiers": {
"default": {
"bAlt": false,
"bCmd": false,
"bCtrl": false,
"bShift": false
},
"description": "Modifier keys held during the click.",
"properties": {
"bAlt": {
"type": "boolean"
},
"bCmd": {
"type": "boolean"
},
"bCtrl": {
"type": "boolean"
},
"bShift": {
"type": "boolean"
}
},
"required": [
"bShift",
"bCtrl",
"bAlt",
"bCmd"
],
"title": "SlateInspectorToolsetModifierKeys",
"type": "object"
},
"ref": {
"description": "Slate widget ref.",
"type": "string"
}
},
"required": [
"ref"
],
"type": "object"
}
Output schema
{
"properties": {
"returnValue": {
"type": "boolean"
}
},
"required": [
"returnValue"
],
"type": "object"
}
SlateInspectorToolset.SlateInspectorToolset.Drag¶
Drag from one Slate widget to another (mouse down, move, release).
Input schema
{
"properties": {
"endRef": {
"description": "Slate widget ref for the drop target.",
"type": "string"
},
"modifiers": {
"default": {
"bAlt": false,
"bCmd": false,
"bCtrl": false,
"bShift": false
},
"description": "Modifier keys held during the drag.",
"properties": {
"bAlt": {
"type": "boolean"
},
"bCmd": {
"type": "boolean"
},
"bCtrl": {
"type": "boolean"
},
"bShift": {
"type": "boolean"
}
},
"required": [
"bShift",
"bCtrl",
"bAlt",
"bCmd"
],
"title": "SlateInspectorToolsetModifierKeys",
"type": "object"
},
"startRef": {
"description": "Slate widget ref for the drag source.",
"type": "string"
}
},
"required": [
"startRef",
"endRef"
],
"type": "object"
}
Output schema
{
"properties": {
"returnValue": {
"type": "boolean"
}
},
"required": [
"returnValue"
],
"type": "object"
}
SlateInspectorToolset.SlateInspectorToolset.FillForm¶
Fill multiple Slate form fields at once.
Input schema
{
"properties": {
"fields": {
"description": "Array of {Ref, Value, FieldType} where FieldType is \"textbox\", \"checkbox\", or \"combobox\".",
"items": {
"properties": {
"fieldType": {
"description": "The type of field: \"textbox\", \"checkbox\", or \"combobox\".",
"type": "string"
},
"ref": {
"description": "The ref identifier of the form field widget.",
"type": "string"
},
"value": {
"description": "The value to set.",
"type": "string"
}
},
"required": [
"ref",
"value",
"fieldType"
],
"title": "SlateInspectorToolsetFormField",
"type": "object"
},
"type": "array"
}
},
"required": [
"fields"
],
"type": "object"
}
Output schema
{
"properties": {
"returnValue": {
"type": "boolean"
}
},
"required": [
"returnValue"
],
"type": "object"
}
SlateInspectorToolset.SlateInspectorToolset.Hover¶
Hover over a Slate widget, triggering any hover state or tooltip.
Input schema
{
"properties": {
"ref": {
"description": "Slate widget ref.",
"type": "string"
}
},
"required": [
"ref"
],
"type": "object"
}
Output schema
{
"properties": {
"returnValue": {
"type": "boolean"
}
},
"required": [
"returnValue"
],
"type": "object"
}
SlateInspectorToolset.SlateInspectorToolset.ListObservers¶
List all active observers as a JSON array for debugging. Each entry includes the observer identifier, whether it is the root observer, the root widget ref (if any), max depth, and cached snapshot size.
Input schema
{
"type": "object"
}
Output schema
{
"properties": {
"returnValue": {
"type": "string"
}
},
"required": [
"returnValue"
],
"type": "object"
}
SlateInspectorToolset.SlateInspectorToolset.Observe¶
Register an observer on a widget subtree so its refs are continuously kept up to date (~100ms tick). Call this on the window or panel you are about to work with. It ensures new widgets appearing in that subtree are assigned refs automatically. Unobserve when you are done. A shallow root observer (depth 0) already covers top-level windows.
Input schema
{
"properties": {
"maxDepth": {
"default": 30,
"description": "Maximum depth to walk from the root.",
"type": "integer"
},
"ref": {
"description": "Root widget ref to observe. Empty = all visible windows.",
"type": "string"
}
},
"required": [
"ref"
],
"type": "object"
}
Output schema
{
"properties": {
"returnValue": {
"type": "string"
}
},
"required": [
"returnValue"
],
"type": "object"
}
SlateInspectorToolset.SlateInspectorToolset.PressKey¶
Press and release a keyboard key on the currently focused Slate widget. Supports modifier prefixes: "Ctrl+C", "Shift+1".
Input schema
{
"properties": {
"key": {
"description": "Key name with optional modifiers, e.g. \"Enter\", \"Ctrl+A\", \"Shift+Tab\".",
"type": "string"
}
},
"required": [
"key"
],
"type": "object"
}
Output schema
{
"properties": {
"returnValue": {
"type": "boolean"
}
},
"required": [
"returnValue"
],
"type": "object"
}
SlateInspectorToolset.SlateInspectorToolset.Screenshot¶
Screenshot a Slate widget or the active editor window. Prefer this over SceneTools.take_screenshot for Editor UI; use SceneTools only for 3D viewport.
Input schema
{
"properties": {
"ref": {
"description": "Slate widget ref. Empty = active window.",
"type": "string"
}
},
"required": [
"ref"
],
"type": "object"
}
Output schema
{
"properties": {
"returnValue": {
"properties": {
"data": {
"description": "The image data encoded as a base64 string.",
"type": "string"
},
"mimeType": {
"description": "The format the image is encoded in.",
"type": "string"
}
},
"required": [
"mimeType",
"data"
],
"title": "ToolsetImage",
"type": "object"
}
},
"required": [
"returnValue"
],
"type": "object"
}
SlateInspectorToolset.SlateInspectorToolset.SelectOption¶
Select an option in a Slate combobox by its text label. Opens the dropdown, finds the matching text, and clicks it.
Input schema
{
"properties": {
"ref": {
"description": "Slate combobox ref.",
"type": "string"
},
"value": {
"description": "Exact option text to select.",
"type": "string"
}
},
"required": [
"ref",
"value"
],
"type": "object"
}
Output schema
{
"properties": {
"returnValue": {
"type": "boolean"
}
},
"required": [
"returnValue"
],
"type": "object"
}
SlateInspectorToolset.SlateInspectorToolset.Snapshot¶
Capture a Slate UI accessibility snapshot. Use this to read the current widget tree and discover refs for action tools (Click, Type, Hover, etc.). A shallow root observer (depth 0) covers top-level windows automatically. Before interacting with a specific window or panel, call Observe() on it to get deep coverage, then Snapshot that subtree to see its contents. Refs discovered by a previous Snapshot remain usable. You do NOT need to call Snapshot again before every action.
Input schema
{
"properties": {
"bIncludeSourceLocations": {
"default": false,
"description": "Include [src=File:Line] tags showing where each widget was created in C++.",
"type": "boolean"
},
"maxDepth": {
"default": 30,
"description": "Maximum depth (default 30).",
"type": "integer"
},
"ref": {
"description": "Subtree root ref. Empty = all windows.",
"type": "string"
}
},
"required": [
"ref"
],
"type": "object"
}
Output schema
{
"properties": {
"returnValue": {
"type": "string"
}
},
"required": [
"returnValue"
],
"type": "object"
}
SlateInspectorToolset.SlateInspectorToolset.Type¶
Type text into a Slate text input widget. Focuses the widget first, then sends one key event per character.
Input schema
{
"properties": {
"ref": {
"description": "Slate textbox ref.",
"type": "string"
},
"submit": {
"default": false,
"description": "Press Enter after typing.",
"type": "boolean"
},
"text": {
"description": "Text to type.",
"type": "string"
}
},
"required": [
"ref",
"text"
],
"type": "object"
}
Output schema
{
"properties": {
"returnValue": {
"type": "boolean"
}
},
"required": [
"returnValue"
],
"type": "object"
}
SlateInspectorToolset.SlateInspectorToolset.Unobserve¶
Remove an observer by its identifier.
Input schema
{
"properties": {
"identifier": {
"description": "The identifier returned by Observe().",
"type": "string"
}
},
"required": [
"identifier"
],
"type": "object"
}
Output schema
{
"properties": {
"returnValue": {
"type": "boolean"
}
},
"required": [
"returnValue"
],
"type": "object"
}
SlateInspectorToolset.SlateInspectorToolset.WaitFor¶
Check if text is present or absent in the Slate widget tree. Non-blocking: checks once and returns immediately. Poll to wait.
Input schema
{
"properties": {
"text": {
"description": "Text that must be present (empty = skip).",
"type": "string"
},
"textGone": {
"description": "Text that must be absent (empty = skip).",
"type": "string"
}
},
"required": [
"text",
"textGone"
],
"type": "object"
}
Output schema
{
"properties": {
"returnValue": {
"type": "boolean"
}
},
"required": [
"returnValue"
],
"type": "object"
}
SlateInspectorToolset.SlateInspectorToolset.Windows¶
List, select, or close top-level Slate editor windows.
Input schema
{
"properties": {
"action": {
"default": "list",
"description": "\"list\" returns JSON array, \"select\" brings to front, \"close\" destroys.",
"type": "string"
},
"index": {
"default": -1,
"description": "Window index for select/close.",
"type": "integer"
}
},
"type": "object"
}
Output schema
{
"properties": {
"returnValue": {
"type": "string"
}
},
"required": [
"returnValue"
],
"type": "object"
}