Skip to main content
Glama

workspace_launch

Launch applications and detect when their windows appear, returning window details like title and process ID for automated interaction.

Instructions

Purpose: Launch an application and wait for its new window to appear, returning title, HWND, and PID. Details: Runs the command via ShellExecute, snapshots the window list before launch, then polls until a new HWND appears (compared by HWND, not title). Returns {windowTitle, hwnd, pid, elapsedMs}. Works for localized window titles (e.g. '電卓' for calc.exe) because detection is HWND-based, not title-based. timeoutMs default 10000. detach=true fires without waiting and returns no window info. Prefer: Use instead of run_macro({exec, sleep, get_windows}) combos. Follow with focus_window(windowTitle) to interact with the launched app. Caveats: Single-instance apps that reuse an existing window will not register as a new HWND — call get_windows first to check if the window is already open. detach=true returns immediately with no window title or hwnd. Examples: workspace_launch({command:'notepad.exe'}) → {windowTitle:'', hwnd:'...', pid:...} workspace_launch({command:'calc.exe', timeoutMs:15000})

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
commandYesExecutable name or full path (e.g. 'notepad.exe', 'calc.exe'). Shell interpreters (cmd.exe, powershell.exe, etc.) are blocked.
argsNoCommand-line arguments (max 20). Shell metacharacters (; & | ` $() ${}) are not allowed.
waitMsNoMilliseconds to wait for the window to appear (default 2000)
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden and does so effectively. It discloses key behavioral traits: how it works (ShellExecute, HWND-based detection), what it returns (title, HWND, PID, elapsedMs), timeout defaults, detach behavior, and caveats for single-instance apps. It doesn't mention permissions or rate limits, but covers most operational aspects clearly.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is well-structured with clear sections (Purpose, Details, Prefer, Caveats, Examples), front-loaded with key information, and every sentence adds value without redundancy. It efficiently covers complex functionality in a compact format.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (launching apps with HWND detection), no annotations, and no output schema, the description does a strong job. It explains the return values, behavioral nuances, and usage context. However, it could briefly mention error handling or what happens on failure, leaving a minor gap in completeness.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the baseline is 3. The description adds value by explaining the command parameter's purpose ('Executable name or full path') and providing examples (notepad.exe, calc.exe), and it clarifies the timeoutMs behavior (though note: description says timeoutMs default 10000, while schema has waitMs default 2000—this is a minor discrepancy but not contradictory). It also details detach=true usage, which isn't in the schema, enhancing parameter understanding.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description explicitly states the purpose with a specific verb ('Launch an application') and resource ('application'), and distinguishes it from siblings by detailing its unique HWND-based detection mechanism. It clearly differentiates from run_macro combos and get_windows, making its role distinct.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides explicit guidance on when to use this tool ('Prefer: Use instead of run_macro({exec, sleep, get_windows}) combos') and when not to ('Caveats: Single-instance apps that reuse an existing window will not register as a new HWND — call get_windows first to check if the window is already open'). It also mentions alternatives like detach=true for non-waiting launches.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Harusame64/desktop-touch-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server