Skip to main content
Glama

Create repository

gh_create_repo

Creates a new GitHub repository for a specified owner after policy checks, then verifies its identity, visibility, description, and init state.

Instructions

Additive write: create exactly one repository at the canonical OWNER/REPO target after ordinary write policy, exact prospective-repository target policy, and the separate repository-creation fine gate allow it. The mutation is attempted once, then exact authoritative readback verifies repository identity, visibility, description, and initialization when GitHub exposes that evidence. It never retries an ambiguous creation and cannot delete, rename, transfer, or otherwise administer an existing repository.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
repoYesGitHub repository name without the owner prefix.
ownerYesGitHub repository owner or organization login.
privateNo
auto_initNo
descriptionNoOptional repository description.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlNo
repoYes
ownerYes
warningNo
is_privateNo
request_idNo
descriptionNo
initializedNo
name_with_ownerNo
write_completedYes
readback_completedYes
precondition_checkedYes
state_matches_requestedYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed26 schema fields changedv0.8.1
    • changedInput schema / properties / description / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "maxLength": 65536,
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / description / description
      Added value: +"Optional repository description."
    • removedInput schema / properties / name
      Removed value: -{
      -  "title": "Name",
      -  "type": "string"
      -}
    • addedInput schema / properties / owner
      Added value: +{
      +  "description": "GitHub repository owner or organization login.",
      +  "maxLength": 39,
      +  "minLength": 1,
      +  "pattern": "^[A-Za-z0-9](?:[A-Za-z0-9-]{0,38})$",
      +  "title": "Owner",
      +  "type": "string"
      +}
    • addedInput schema / properties / repo
      Added value: +{
      +  "description": "GitHub repository name without the owner prefix.",
      +  "maxLength": 100,
      +  "minLength": 1,
      +  "pattern": "^[A-Za-z0-9_.-]{1,100}$",
      +  "title": "Repo",
      +  "type": "string"
      +}
    • changedInput schema / required
      Previous value: -[
      -  "name"
      -]New value: +[
      +  "owner",
      +  "repo"
      +]
    • changedOutput schema / description
      Previous value: -"Result of creating a repository."New value: +"Authoritative outcome of one exact-target repository creation attempt."
    • addedOutput schema / properties / description
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Description"
      +}
    • addedOutput schema / properties / initialized
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "boolean"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Initialized"
      +}
    • addedOutput schema / properties / is_private
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "boolean"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Is Private"
      +}
    • removedOutput schema / properties / message
      Removed value: -{
      -  "title": "Message",
      -  "type": "string"
      -}
    • removedOutput schema / properties / name
      Removed value: -{
      -  "title": "Name",
      -  "type": "string"
      -}
    • addedOutput schema / properties / name_with_owner
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Name With Owner"
      +}
    • addedOutput schema / properties / owner
      Added value: +{
      +  "maxLength": 39,
      +  "minLength": 1,
      +  "title": "Owner",
      +  "type": "string"
      +}
    • addedOutput schema / properties / precondition_checked
      Added value: +{
      +  "title": "Precondition Checked",
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / readback_completed
      Added value: +{
      +  "title": "Readback Completed",
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / repo
      Added value: +{
      +  "maxLength": 100,
      +  "minLength": 1,
      +  "title": "Repo",
      +  "type": "string"
      +}
    • addedOutput schema / properties / request_id
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Request Id"
      +}
    • addedOutput schema / properties / state_matches_requested
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "boolean"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "title": "State Matches Requested"
      +}
    • addedOutput schema / properties / url / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedOutput schema / properties / url / default
      Added value: +null
    • removedOutput schema / properties / url / type
      Removed value: -"string"
    • addedOutput schema / properties / warning
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Warning"
      +}
    • addedOutput schema / properties / write_completed
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "boolean"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "title": "Write Completed"
      +}
    • changedOutput schema / required
      Previous value: -[
      -  "name",
      -  "url",
      -  "message"
      -]New value: +[
      +  "precondition_checked",
      +  "write_completed",
      +  "readback_completed",
      +  "state_matches_requested",
      +  "owner",
      +  "repo"
      +]
    • changedOutput schema / title
      Previous value: -"RepoCreate"New value: +"RepositoryCreateResult"
  2. First observedv0.1.0

TDQS

A4.1/5.0
Behavior5/5

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

Despite annotations already indicating non-read-only and non-destructive behavior, the description significantly enriches understanding with specific behavioral details: single attempt, authoritative readback verification, no retry on ambiguous creation, and explicit prohibition on delete/rename/transfer. This exceeds annotation coverage.

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 two dense sentences that efficiently convey purpose, constraints, and verification behavior. It is front-loaded and every clause adds meaning, though the policy language is somewhat convoluted and could be simplified.

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?

Given the presence of an output schema and annotations, the description covers the essential behavioral context well: additivity, idempotency constraints, readback verification, and non-administrative scope. It does not detail exact prerequisites or error conditions, but the mention of policies/gates provides sufficient context for a write tool.

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 60%, covering owner, repo, and description, while private and auto_init lack descriptions. The tool description indirectly references these fields through readback verification (visibility, description, initialization) but does not explain parameters directly. This meets the baseline for high schema coverage without full compensation.

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 explicitly states 'create exactly one repository' with a canonical OWNER/REPO target, making the purpose unmistakable. It also distinguishes this from sibling create tools (e.g., gh_create_issue, gh_create_pr, gh_create_release_exact) by focusing on repository creation.

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

Usage Guidelines3/5

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

The description provides context about write policies and gates but does not explicitly state when to use this tool versus alternatives. It implies usage for repository creation but lacks clear exclusions or comparisons with sibling tools, such as when to prefer gh_get_repo for read-only checks.

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