Skip to main content
Glama
MCP GitHub CrunchTools

MCP GitHub CrunchTools

by crunchtools

Create Ruleset Tool

create_ruleset_tool

Create GitHub rulesets for an organization or a single repository, defining enforcement, target refs, bypass actors, and rules to control branch, tag, or push behavior.

Instructions

Create a ruleset on an organization, or on one repository.

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": {
      "org": "<org>",
      "name": "<name>",
      "enforcement": "<enforcement>"
    },
    "name": "create_ruleset_tool"
  }
}

Input Schema

NameRequiredDescriptionDefault
orgYesOrganization name (the repository owner when repo is given)
nameYesRuleset name
repoNoRepository name; omit for an organization ruleset
rulesNoRules, each {type, parameters}
targetNobranch, tag, push, or repository (organization only)branch
enforcementYesdisabled, active or evaluate (evaluate is Enterprise only)
bypass_actorsNoActors that may bypass the ruleset
ref_name_excludeNoRef patterns to skip
ref_name_includeNoRef patterns (~DEFAULT_BRANCH and ~ALL allowed); required for branch and tag rulesets
repository_name_excludeNoRepository name patterns to skip
repository_name_includeNoRepository name patterns (~ALL allowed); required for an organization ruleset, refused with repo
repository_name_protectedNoAlso match on rename protection

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv2.2.0

TDQS

C2.9/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It identifies this as a create operation and its scope, but omits permissions required, side effects, bypass behavior, enforcement implications, and failure modes.

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 description is concise and front-loads the operation and scope in a single sentence. However, it is arguably too sparse for a 12-parameter mutation tool, leaving no structured guidance.

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

Completeness2/5

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

This is a complex creation tool with 12 parameters, no annotations, and significant behavioral and safety implications. An output schema exists, but the description still lacks the guidance needed to use the tool correctly beyond its broad purpose.

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 description coverage is 100%, so parameter meanings are already documented in the schema. The description only echoes the org-versus-repo distinction and adds no meaningful parameter semantics beyond that.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description provides a clear verb and resource ("Create a ruleset") plus scope (organization or repository). It distinguishes creation from get/update/list ruleset tools implicitly, though it does not name alternatives.

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

Usage Guidelines2/5

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

It states the two possible scopes but gives no guidance on when to create an organization versus repository ruleset. There are no prerequisites, when-not-to-use cases, or references to sibling tools.

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