loading…
Search for a command to run...
loading…
Enables fetching public repositories for a given GitHub username, returning curated data optimized for LLM context windows.
Enables fetching public repositories for a given GitHub username, returning curated data optimized for LLM context windows.
A Model Context Protocol (MCP) server that connects Large Language Models (like Claude) to the GitHub API.
This project demonstrates an understanding of AI infrastructure by building a secure, standardized bridge between an LLM's context window and an external data source. By using the MCP standard, the LLM can dynamically request live data without requiring custom, one-off API integrations.
This integration utilizes the standard MCP JSON-RPC architecture over stdio:
mcp SDK. It securely exposes specific tools and handles the JSON-RPC communication.fetch_public_repos: Takes a GitHub username as a string and returns a clean, extracted list of their public repositories (including name, URL, and description) optimized for an LLM's context window.git clone <your-repo-url>
cd <your-repo-folder>```
pip install -r requirements.txtYou can easily register this server with Claude Code so the LLM can use it dynamically. Run the following command in your terminal from the project directory:
claude mcp add github-portfolio python3 server.py
Once added, you can ask Claude Code a prompt like:
"Use the github-portfolio tools to fetch the public repositories for user1."
Claude will automatically format the JSON-RPC request, wake up the local Python server, execute the API call, and format the response.
If you want to test the server without Claude Code, a custom Python client is included. Run:
python3 client.py
This will launch a background process, connect via standard input/output, and fetch a hardcoded test request.
Добавь это в claude_desktop_config.json и перезапусти Claude Desktop.
{
"mcpServers": {
"github-portfolio": {
"command": "npx",
"args": []
}
}
}