Skip to main content
Glama

Get Active Window

window_get_active
Read-only

Get the active macOS app and focused window, including a windowHandle for follow-up automation. Requires Accessibility permission.

Instructions

Get the frontmost application and its focused window, with a windowHandle for follow-up calls. Requires Accessibility permission.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior4/5

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

Annotations already declare readOnlyHint=true and destructiveHint=false. The description adds value by mentioning that Accessibility permission is required, which is a key behavioral prerequisite not captured in the annotations. It also explains the output's role in chaining, going beyond the structured metadata.

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 concise sentences that pack the core purpose, output details, and a critical prerequisite without any redundant wording. Every phrase earns its place.

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

Completeness5/5

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

Given the simple 0-parameter, read-only tool with strong annotations and no output schema, the description adequately covers the essential usage, permission requirement, and the purpose of the returned handle. It is complete for its intended simplicity.

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?

The tool has zero parameters, so the schema is trivially 100% covered. The description adds meaningful context about the return value (frontmost application, focused window, windowHandle), which is more than sufficient for a parameterless tool.

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 clearly states it gets the frontmost application and focused window, specifying a concrete verb and resource. It distinguishes itself from siblings like window_list (list all windows) or window_focus (set focus) by focusing on retrieving the active window and providing a handle for follow-up calls.

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

Usage Guidelines4/5

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

The description provides clear context for when to use this tool: to obtain the frontmost application and focused window, with the windowHandle intended for follow-up calls. However, it does not explicitly name alternative tools or state when not to use it, so it lacks explicit exclusions.

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