Skip to main content
Glama
Ryan0204

github-repo-mcp

by Ryan0204

Repositorio de GitHub MCP

insignia de herrería

Tabla de contenido

Related MCP server: UIThub MCP Server

✨ Características principales

  • 💻 Compatible con Cursor, Windsurf, Claude Desktop y otros clientes MCP que admiten el protocolo stdio

  • 🔎 Explorar el contenido de cualquier repositorio público de GitHub

  • 📂 Navegar por los directorios y subdirectorios del repositorio

  • 📝 Ver el contenido de los archivos de código y texto

  • 📦 Fácil instalación a través del administrador de paquetes

Empezando

Prerrequisitos

Para instalar el servidor se requiere lo siguiente en su sistema:

  • Node.js 18+

  • npm o hilo

Paso 1. Instalación

Puedes instalar y ejecutar GitHub Repo MCP usando Smithery, NPX o configurando en mcp.json de tu IDE:

Sistema operativo Mac

npx github-repo-mcp

Windows NPX

cmd /c npx -y github-repo-mcp

Windows NPX a través de .cursor/mcp.json

{
  "mcpServers": {
    "github-repo-mcp": {
      "command": "wsl",
      "args": [
        "bash",
        "-c",
        "cmd /c npx -y github-repo-mcp"
      ],
      "enabled": true
    }
  }
}

Windows NPX a través de .cursor/mcp.json (si la ruta no está configurada)

# Find the full path to npx first
which npx
{
  "mcpServers": {
    "github-repo-mcp": {
      "command": "wsl",
      "args": [
        "bash",
        "-c",
        "'/home/[username]/.nvm/versions/node/v20.18.0/bin/npx github-repo-mcp'"
      ],
      "enabled": true
    }
  }
}

Instalación mediante herrería

Para instalar GitHub Repo MCP para Claude Desktop automáticamente a través de Smithery :

npx -y @smithery/cli install @Ryan0204/github-repo-mcp --client claude

Espere unos segundos o haga clic en el botón de actualización varias veces si no se registra. Si sigue sin registrarse, asegúrese de haber ingresado el comando correcto.

Paso 2. Configuración

El servidor MCP de GitHub Repo puede usar un token de GitHub para establecer límites de velocidad más altos al acceder a la API de GitHub.

Variables de entorno

Variable

Requerido

Por defecto

Descripción

GITHUB_TOKEN

No

Ninguno

Tu token de acceso personal de GitHub para límites de velocidad más altos

Configuración de un token de GitHub (opcional)

Aunque el servidor funciona sin autenticación, la API de GitHub tiene límites de velocidad mucho más bajos para solicitudes no autenticadas. Para aumentar tu límite de velocidad:

  1. Crea un token de acceso personal en https://github.com/settings/tokens

  2. Establezca el token como una variable de entorno en mcp.json:

{
  "mcpServers": {
    "github-repo-mcp": {
      "command": "...",
      "args": [
        ...
      ],
      "env": {
        "GITHUB_TOKEN": "Your_Github_Token"
      }
      "enabled": true,
    }
  }
}

Descripción general de las funciones

Herramientas de navegación del repositorio

El servidor proporciona tres herramientas principales para interactuar con los repositorios de GitHub:

1. getRepoAllDirectories

Enumera todos los archivos y directorios en la raíz de un repositorio de GitHub.

2. getRepoDirectories

Enumera el contenido de un directorio específico en un repositorio de GitHub.

  • Parámetros :

    • repoUrl : La URL del repositorio de GitHub

    • path : la ruta del directorio a buscar (por ejemplo, "src")

3. getRepoFile

Recupera y muestra el contenido de un archivo específico de un repositorio de GitHub.

  • Parámetros :

    • repoUrl : La URL del repositorio de GitHub

    • path : la ruta del archivo a buscar (por ejemplo, "src/index.js")

Ejemplos de uso

A continuación se muestran algunos ejemplos de cómo utilizar estas herramientas con un asistente de IA:

  1. Explorar la raíz de un repositorio : pídale a su asistente de IA que "me muestre el contenido del repositorio en https://github.com/Ryan0204/github-repo-mcp "

  2. Explorando un directorio específico : Pregunte "¿Qué archivos hay en el directorio src de https://github.com/Ryan0204/github-repo-mcp ?"

  3. Visualización de un archivo : Preguntar "Muéstrame el archivo README.md desde https://github.com/Ryan0204/github-repo-mcp "

Limitaciones

  • Limitación de velocidad : sin autenticación, la API de GitHub tiene límites de velocidad estrictos (60 solicitudes por hora)

  • Repositorios privados : solo se puede acceder a repositorios públicos a menos que se proporcione un token con los permisos adecuados

  • Archivos binarios : el servidor detecta extensiones de archivos binarios comunes y no mostrará su contenido

  • Archivos grandes : la API de GitHub tiene limitaciones en el tamaño de los archivos que se pueden recuperar

Solución de problemas

A continuación se presentan algunos problemas comunes y sus soluciones:

  • Límite de velocidad excedido : configure un token de GitHub como se describe en la sección Configuración

  • Comando no encontrado : asegúrese de que el paquete esté instalado globalmente

  • Errores de conexión : Verifique su conexión a Internet y el estado de la API de GitHub

Si encuentra algún problema, verifique la salida en busca de mensajes de error o cree un problema en el repositorio de GitHub.


¡Que lo disfrutes! ☺️

Available Tools

3 tools
getRepoAllDirectoriesD
ParametersJSON Schema
NameRequiredDescriptionDefault
repoUrlYesThe URL of the Github repo

TDQS

D1/5.0
Behavior1/5

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

Tool has no description.

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

Conciseness1/5

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

Tool has no description.

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

Completeness1/5

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

Tool has no description.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Tool has no description.

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

Purpose1/5

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

Tool has no description.

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

Usage Guidelines1/5

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

Tool has no description.

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

getRepoDirectoriesD
ParametersJSON Schema
NameRequiredDescriptionDefault
pathYesThe directory path to fetch
repoUrlYesThe URL of the Github repo

TDQS

D1/5.0
Behavior1/5

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

Tool has no description.

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

Conciseness1/5

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

Tool has no description.

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

Completeness1/5

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

Tool has no description.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Tool has no description.

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

Purpose1/5

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

Tool has no description.

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

Usage Guidelines1/5

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

Tool has no description.

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

getRepoFileD
ParametersJSON Schema
NameRequiredDescriptionDefault
pathYesThe file path to fetch
repoUrlYesThe URL of the Github repo

TDQS

D1/5.0
Behavior1/5

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

Tool has no description.

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

Conciseness1/5

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

Tool has no description.

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

Completeness1/5

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

Tool has no description.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Tool has no description.

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

Purpose1/5

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

Tool has no description.

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

Usage Guidelines1/5

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

Tool has no description.

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

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

  1. 3 tool updatesv1.0.0
    • First observedgetRepoAllDirectories
    • First observedgetRepoDirectories
    • First observedgetRepoFile

TDQS

D1.4/5.0

Scored across 3 tools

Disambiguation2/5

The tools have overlapping purposes with unclear boundaries: getRepoAllDirectories and getRepoDirectories appear to serve similar directory-related functions without descriptions to clarify their differences, while getRepoFile is distinct but the directory tools are ambiguous. This overlap will likely cause misselection between the two directory tools.

Naming Consistency4/5

The naming follows a consistent camelCase pattern (getRepoAllDirectories, getRepoDirectories, getRepoFile) with a clear verb_noun structure, though the lack of descriptions makes it harder to assess intent. There are no deviations in style, but the similarity in names for the directory tools slightly reduces clarity.

Tool Count2/5

With only 3 tools, this server feels thin for a GitHub repository domain, as it lacks essential operations like create, update, delete, or search. The limited scope suggests incomplete coverage, making it difficult for agents to perform comprehensive repository management tasks.

Completeness1/5

The tool surface is severely incomplete for a GitHub repository server: it only includes retrieval tools for directories and files, missing core CRUD operations (e.g., create repo, update files, delete items), search functionality, and lifecycle management. This will cause significant agent failures in handling typical repository workflows.

Maintenance

ActivityMaintained
ResponsivenessNo issues

Related MCP Connectors

Related MCP Servers