Skip to main content
Glama

watch_pull

Idempotent

Track a GitHub pull request's checks and post status updates, failures, and logs to its thread so agents can monitor CI progress.

Instructions

Watch a GitHub pull request's checks. Each change-sweep tick reads it once and records on its thread where the checks on its head stand (ci: status pending, success or failure, the failing jobs, and the last 4 KB of the first failing job's log), with a notice when it is first seen open (pr_opened), when a check fails (ci_failed) and when every check has finished (checks_done), each once per head commit. A pull request the workspace already tracks (one the change flow opened, or a session registered on its task) answers with its thread (created: false); otherwise a thread is made for it in channel_id, or the workspace's public pull-requests channel. The repository must be on this workspace's github or github_branch egress allowlist. A pull request another workspace tracks is a conflict.

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": {
      "workspace_id": "<workspace_id>",
      "repo": "<repo>",
      "pull_number": "<pull_number>"
    },
    "name": "watch_pull"
  }
}

Input Schema

NameRequiredDescriptionDefault
repoYesowner/name
titleNoa new watch thread's title; owner/name#N when omitted
channel_idNowhere a new watch thread goes; the workspace's pull-requests channel when omitted
pull_numberYes
workspace_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv479.0.0

TDQS

A4.3/5.0
Behavior5/5

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

Beyond the annotations it discloses real side effects: a thread may be created in channel_id or the workspace's public pull-requests channel, and notifications (pr_opened, ci_failed, checks_done) fire once per head commit. It also explains the idempotent behavior explicitly ('created: false' when the workspace already tracks the PR), plus the allowlist precondition and cross-workspace conflict failure mode — information the annotations (readOnlyHint=false, idempotentHint=true) cannot convey on their own.

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?

The purpose is front-loaded and nearly every clause carries useful detail (log excerpt size, notification names, once-per-head-commit semantics, default channel). The tradeoff is density: two long nested sentences packed with implementation jargon ('change-sweep tick') make it harder to scan than it needs to be.

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 tool that both reads and creates state, with no output schema, the description covers the important behavior: side effect of thread creation, notification lifecycle, prerequisite allowlist, and conflict condition. It is slightly thin on the return payload beyond the 'created' flag and on how to handle the allowlist/conflict errors, which prevents a 5.

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 60%, and the description mostly repeats what the schema already documents (channel_id fallback to the public pull-requests channel). It adds one genuinely new constraint tying repo to the egress allowlist, but says nothing about pull_number or workspace_id beyond their obvious roles, and does not clarify title behavior for new threads.

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 states a concrete verb and resource ('Watch a GitHub pull request's checks') and immediately defines the mechanism and scope: polling per change-sweep tick, recording CI state and failing jobs onto the PR's thread. It also distinguishes the two possible outcomes (existing tracked PR vs. newly created thread), so an agent knows exactly what the call is and is not.

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?

It gives a clear condition for use (this is how a PR's checks get watched and surfaced as notifications on a thread) and states prerequisites: the repo must be on the github/github_branch egress allowlist, and a PR tracked by another workspace is a conflict. It does not, however, name the alternative sibling (e.g. register_thread_pull) or say when not to use this tool, so it stops short of explicit routing.

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

Deploy Server

Other Tools