Skip to main content
Glama

Connect a GitHub repository

connect_github
Destructive

Connect the GitHub repository an app is deployed from, so its deploys check themselves: every successful production deploy (policy production) — and every PR preview, with one comment on its pull request (policy all) — starts a check answered on the commit under the app's merge gate. When the GitHub App cannot see the repository yet, the answer carries install_url for an admin of the team to open; call it again after. Needs an admin key.

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": {
      "app_id": "<app_id>",
      "repo": "<repo>"
    },
    "name": "connect_github"
  }
}

Input Schema

NameRequiredDescriptionDefault
repoYesowner/name of the GitHub repository this app is deployed from, e.g. 'acme/shop'
teamNoAct in another of your teams, by its name or id (whoami lists them). Omitted: the key's own team
app_idYesApp id from list_apps or create_app
policyNoproduction (default): every successful production deploy is checked; all: PR previews too; off: connected, nothing checked

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior4/5

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

Annotations already flag destructiveHint=true and openWorldHint=true, so the description's job is to add context — and it does: it requires an admin key, describes the install_url handoff path, and characterizes the side effects (comments on PRs, checks attached to commits). It stops short of saying whether reconnecting overwrites an existing connection or how to detach one.

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

Conciseness3/5

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

The core statement is front-loaded, but the first sentence is a dense 40-word clause with nested dashes and parentheticals that takes effort to parse. The admin-key requirement lands last and arguably deserves earlier placement given it is a hard precondition.

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 mutating, open-world tool with no output schema, the description covers the main unknowns: auth level (admin key), the policy scope of effects, and the failure-recovery path via install_url. Missing only whether the call is idempotent and what the returned payload looks like beyond the install_url case.

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% and each parameter carries its own description, including the enum values, so the schema does the heavy lifting. The description reinforces what 'policy production' and 'policy all' mean in terms of observable outcomes but adds little syntax-level detail beyond that.

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 specific verb and resource ('Connect the GitHub repository an app is deployed from') and explains the downstream effect precisely: deploys trigger checks under the app's merge gate, with per-policy scope. It is clearly distinguishable from siblings like create_app, list_apps, or update_app.

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 an explicit re-invocation rule: when the GitHub App cannot see the repository, the answer carries install_url for an admin to open and the tool should be called again afterward. It also ties the policy parameter to when checks run, though it doesn't explicitly name sibling alternatives such as update_app for changing an already-connected repo.

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.