Skip to main content
Glama

Get Mac command status

get_mac_job
Read-onlyIdempotent

Returns a command's state (running, exited or failed) and exit code, and once it has ended its stdout and stderr (first 64 KiB each, with a cursor when more follows). stream with cursor reads a chunk from any point, also while it runs. wait_seconds (up to 40) waits for it to end, so one call replaces a polling loop. It never runs the command again. Read-only.

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": {
      "job_id": "<job_id>"
    },
    "name": "get_mac_job"
  }
}

Input Schema

NameRequiredDescriptionDefault
cursorNoByte offset to read from: next_cursor of the last read (default 0)
job_idYesCommand job ID (job_…) returned by exec_mac.
streamNoRead this stream as a chunk from cursor, also while the command runs
session_idNoMac session ID (ses_…). Optional: without it, the account's running Mac.
wait_secondsNoWait up to this long (0-40) for a running command to finish, instead of polling.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / properties / cursor
      Added value: +{
      +  "description": "Byte offset to read from: next_cursor of the last read (default 0)",
      +  "maximum": 9007199254740991,
      +  "minimum": 0,
      +  "type": "integer"
      +}
    • addedInput schema / properties / stream
      Added value: +{
      +  "description": "Read this stream as a chunk from cursor, also while the command runs",
      +  "enum": [
      +    "stdout",
      +    "stderr"
      +  ],
      +  "type": "string"
      +}
  2. Changed2 schema fields changed
    • changedInput schema / properties / session_id / description
      Previous value: -"Mac session ID (ses_…) returned by start_mac or list_mac_sessions."New value: +"Mac session ID (ses_…). Optional: without it, the account's running Mac."
    • changedInput schema / required
      Previous value: -[
      -  "session_id",
      -  "job_id"
      -]New value: +[
      +  "job_id"
      +]
  3. Changed2 schema fields changed
    • removedInput schema / $schema
      Removed value: -"http://json-schema.org/draft-07/schema#"
    • changedOutput schema / (root)
      Previous value: -{
      -  "$schema": "http://json-schema.org/draft-07/schema#",
      -  "additionalProperties": {},
      -  "description": "The JSON response of the NoMac API for this operation",
      -  "properties": {
      -    "error": {
      -      "additionalProperties": {},
      -      "description": "Present only when the call failed",
      -      "properties": {
      -        "code": {
      -          "description": "Stable machine-readable error code, for example insufficient_credit",
      -          "type": "string"
      -        },
      -        "message": {
      -          "description": "What went wrong and what to do next",
      -          "type": "string"
      -        }
      -      },
      -      "required": [
      -        "code",
      -        "message"
      -      ],
      -      "type": "object"
      -    }
      -  },
      -  "type": "object"
      -}New value: +null
  4. Changed1 schema field changed
    • addedInput schema / properties / wait_seconds
      Added value: +{
      +  "description": "Wait up to this long (0-40) for a running command to finish, instead of polling.",
      +  "maximum": 40,
      +  "minimum": 0,
      +  "type": "integer"
      +}
  5. First observed

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already cover the safety profile (readOnly, idempotent, non-destructive), yet the description adds behavior the annotations cannot convey: output is truncated to the first 64 KiB per stream with a cursor when more follows, and reads work mid-flight. "It never runs the command again" reinforces a non-obvious side-effect claim. It doesn't describe error responses for unknown or expired job IDs.

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?

Three tight sentences, led by what is returned and followed by the two operating modes (cursor-read and wait). Slightly dense phrasing ("stream with cursor reads a chunk from any point") costs a little readability but no sentence is filler.

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?

With no output schema and five parameters, the description carries real weight and does cover state enumeration, exit code, per-stream truncation, cursor resumption, and blocking wait. Minor gaps remain around failure modes (invalid or stale job_id, session_id fallback) that the schema only partially implies.

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 the baseline is 3. The description does add meaningful semantics on top: wait_seconds is framed as a polling-loop replacement capped at 40s, and stream/cursor is framed as a resumable chunk read that works during execution, which is more than the schema's field-level wording alone conveys.

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: returns a command's state (running/exited/failed), exit code, and post-completion stdout/stderr. It implicitly distinguishes itself from the writer sibling by naming the job ID provenance ("returned by exec_mac") and by declaring it never re-runs the command, so an agent can separate it from exec_mac and cancel_mac_job.

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?

Gives concrete when-to-use guidance: wait_seconds replaces a polling loop, and stream+cursor reads output while the command still runs. It does not explicitly say to use cancel_mac_job to stop a job or address what to do when a job is not found, but the primary usage decision (poll vs. wait vs. stream) is spelled out.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources