Skip to main content
Glama

Set Window State

window_set_state

Change a window's state to minimize, restore, maximize, fullscreen, or hide/show the owning app, using a window handle. Requires Accessibility permission.

Instructions

Change a window's state: minimize, restore, maximize, fullscreen, hide (owning app), or show (owning app). Requires Accessibility permission.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
stateYes
windowHandleYesA windowHandle from window_list or window_get_active.
Behavior4/5

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

Annotations already indicate a non-read-only, non-destructive operation. The description adds valuable context beyond annotations by clarifying that hide/show affect the owning app, not just the window, and by stating the Accessibility permission requirement. This goes beyond what structured fields convey.

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 two succinct sentences, front-loaded with the verb and resource, and enumerates states in a clean parentheses list. Every word contributes without redundancy.

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?

For a straightforward state-change tool with two required parameters and no output schema, the description covers the action, permission need, and state specifics. It lacks detail on return values or failure behavior, but these are less critical for this type of mutating action.

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?

With 50% schema coverage, the schema documents windowHandle but not the state enum. The description compensates by listing all state values and adding the important nuance that hide/show apply to the owning app, providing meaning beyond the schema's bare enum.

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 uses the specific verb 'Change' with the resource 'a window's state' and enumerates all possible states (minimize, restore, maximize, fullscreen, hide, show), clearly distinguishing it from sibling window tools (focus, move, close).

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

Usage Guidelines3/5

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

The enumerated states imply when to use this tool, but there is no explicit guidance on when to choose this over alternatives like window_focus or window_move. The Accessibility permission requirement provides context but not comparative usage direction.

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/sitharaj88/macctl'

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