Skip to main content
Glama
Keyboard Maestro MCP Server

Keyboard Maestro MCP Server

by akari2600

trigger_and_capture

Trigger a macro, wait briefly, then return the resulting clipboard text or image for screenshot, OCR, or copy-based workflows.

Instructions

Trigger a macro and automatically capture the clipboard result. This is a convenience tool that combines trigger_macro + get_clipboard_result.

Use this when you want to:

  • Take a screenshot and see it immediately

  • Run a macro that copies something to clipboard and retrieve it

  • Perform OCR and get the extracted text

The macro runs first, then after a short delay the clipboard is captured and returned.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "macro": "<macro>"
    },
    "name": "trigger_and_capture"
  }
}

Input Schema

NameRequiredDescriptionDefault
delayNoMilliseconds to wait after triggering before capturing clipboard (default: 500)
macroYesThe macro name or UUID to trigger
valueNoOptional value to pass to the macro (available as %TriggerValue% in the macro)
machineNoName of the machine (defaults to first configured machine)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

A4.1/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does disclose the non-obvious execution ordering: the macro runs first, then after a delay the clipboard is captured and returned. It leaves failure behavior unspecified - what is returned if the macro errors, clips nothing, or the clipboard is empty - so the disclosure is good but not complete.

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

Conciseness4/5

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

Front-loads the purpose, then uses a scannable bullet list of scenarios, and closes with the execution order. The final sentence partially restates the opening line, though it does add the delay timing, so it is efficient but not perfectly tight.

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 four-parameter composition tool with no annotations and no output schema, the description covers what it does, when to use it, and the run-then-capture ordering. The main remaining gap is how the captured result is shaped or reported when the macro produces nothing, which an agent would want to know before relying on it.

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

Parameters3/5

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

Schema coverage is 100%, so all four parameters including delay, macro, value, and machine are already documented. The description only echoes the delay semantics ('after a short delay') and adds no syntax or usage detail beyond the schema, which is the expected baseline when the schema does the heavy lifting.

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?

States a specific verb and resource ('Trigger a macro and automatically capture the clipboard result') and explicitly frames itself as the composition of trigger_macro + get_clipboard_result, so an agent can tell it apart from those siblings immediately.

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?

Provides three concrete when-to-use scenarios (screenshot-and-see, copy-to-clipboard retrieval, OCR) and names the two primitives it combines, giving clear context for selecting it. It never states when not to use it, e.g. that a plain trigger_macro suffices when no clipboard value is needed, so it stops short of the full 5.

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