Releases: onamfc/mcp-github-integration
Releases · onamfc/mcp-github-integration
v1.0.0 - Initial Release
GitHub MCP API Client
I am excited to announce the first stable release of the GitHub MCP API Client - a TypeScript package for interacting with the GitHub API through Model Context Protocol (MCP) server integration.
Highlights
This initial release provides a production-ready GitHub API client with 129 MCP tools covering all major GitHub operations. Built with TypeScript for type safety and designed for both direct use and MCP server integration.
Features
Core Functionality
- 129 MCP Tools - Comprehensive coverage of GitHub API operations
- Full TypeScript Support - Complete type definitions for all operations
- MCP Server Integration - Built-in MCP protocol server implementation
- Direct API Client - Use independently without MCP protocol
- Robust Error Handling - Custom error types with detailed status codes
- Structured Logging - Built-in logging with
@onamfc/developer-log
Supported GitHub Operations
- Repository Management - Create, update, delete, search, settings, administration
- Issue Tracking - Create, update, close, comments, search
- Pull Requests - Create, merge, list, get details
- Branch Operations - Create, delete, list, protect
- Commit Operations - List, get, compare
- Release Management - Create, update, delete, assets
- Content Operations - Read, write, delete files
- GitHub Actions - Workflows, runs, artifacts
- Webhooks - Create, update, delete, deliveries, redelivery
- Teams & Collaborators - Add, remove, permissions
- Search - Repositories, issues, PRs, code, commits, users, topics, labels
- Security - Dependabot, vulnerability alerts
- Repository Statistics - Insights and metrics
Installation
npm install @onamfc/mcp-github-integrationQuick Start
As Direct API Client
import { GitHubClient } from '@onamfc/mcp-github-integration';
const client = new GitHubClient({
token: process.env.GITHUB_TOKEN
});
// Get repository information
const repo = await client.getRepository('owner', 'repo');
// Create an issue
const issue = await client.createIssue({
owner: 'owner',
repo: 'repo',
title: 'Bug report',
body: 'Description of the issue',
labels: ['bug']
});As MCP Server
import { MCPServer } from '@onamfc/mcp-github-integration';
const server = new MCPServer(process.env.GITHUB_TOKEN);
// Handle MCP requests
const response = await server.handleRequest({
method: 'github_create_issue',
params: {
owner: 'owner',
repo: 'repo',
title: 'Bug report',
body: 'Description'
}
});Examples
Two complete working examples are included:
- basic-usage.ts - Demonstrates core operations
- setup-new-repo.ts - Automated repository setup with best practices
Run examples:
npm run build
GITHUB_TOKEN=your_token npm run example:basic
GITHUB_TOKEN=your_token npm run example:setup-repoConfiguration
Required Environment Variables
GITHUB_TOKEN- GitHub Personal Access Token
Recommended Token Scopes
repo- Full repository accessworkflow- GitHub Actions managementadmin:repo_hook- Webhook managementadmin:org- Team operations
Documentation
- Full API Documentation - See README.md
- Example Usage - See examples/README.md
- Type Definitions - Included with package
- GitHub API Docs - https://docs.github.com/en/rest
Technical Details
Built With
- TypeScript 5.9+ - Type safety and modern JavaScript features
- Octokit REST - Official GitHub REST API client
- ES2022 Modules - Modern module system
- Vitest - Fast unit testing framework
Testing
Comprehensive test suite with 51 passing tests covering:
- GitHubClient operations
- MCPServer request handling
- Error handling
- Logger functionality
Run tests:
npm test # Run once
npm run test:watch # Watch mode
npm run test:coverage # With coverageSecurity
- No secrets in code - Uses environment variables
- Token scope validation - Requires appropriate permissions
- Error sanitization - Sensitive data not exposed in errors
- Rate limit aware - Works within GitHub's 5,000 req/hour limit
Acknowledgments
Built with:
- Octokit - GitHub REST API client
- @onamfc/developer-log - Structured logging
- @onamfc/pkg-inspect - Package inspection utilities
Links
- TypeScript MCP Server: https://github.com/onamfc/mcp-starter-template-ts
- Issue Tracker: https://github.com/onamfc/mcp-github-integration/issues
- NPM Package: https://www.npmjs.com/package/@onamfc/mcp-github-integration
- GitHub API Documentation: https://docs.github.com/en/rest
License
MIT License - see LICENSE file for details.
Ready to automate your GitHub workflows? Get started with the Quick Start Guide or explore the examples.