Skip to main content
Glama

MCP Server

by Nawaf-TBE

MCP (Model Context Protocol) Server

A Node.js/TypeScript server that implements the Model Context Protocol with integrations for GitHub and Notion.

🚀 Features

  • Express.js Server with TypeScript support
  • GitHub Integration using Octokit REST API
  • Notion Integration for task management
  • Docker Support for containerized deployment
  • Webhook Endpoints for GitHub event handling

📋 Prerequisites

  • Node.js 18+
  • Docker (optional)
  • GitHub Personal Access Token
  • Notion API Key and Database ID

🛠️ Installation

  1. Clone the repository
    git clone <your-repo-url> cd MCP
  2. Install dependencies
    npm install
  3. Set up environment variables
    cp env.example .env # Edit .env with your API keys
  4. Build the project
    npm run build

🔧 Configuration

Environment Variables

Create a .env file with the following variables:

# GitHub Personal Access Token GITHUB_TOKEN=your_github_token_here # Notion API Key NOTION_API_KEY=your_notion_api_key_here # Notion Database ID NOTION_DATABASE_ID=your_database_id_here # Node environment NODE_ENV=development

API Keys Setup

  1. GitHub Token:
    • Go to https://github.com/settings/tokens
    • Create a new token with repo scope
  2. Notion Integration:

🏃‍♂️ Running the Application

Development Mode

npm run dev

Production Mode

npm run build npm start

Docker

# Build and run docker-compose up --build # Run in background docker-compose up -d

📡 API Endpoints

  • GET / - Health check endpoint
  • POST /webhook/github - GitHub webhook handler

🛠️ Available Tools

GitHub Tools (src/tools/github.ts)

  • createIssueComment() - Post comments on GitHub issues
  • getIssue() - Get issue details
  • listIssues() - List repository issues

Notion Tools (src/tools/notion.ts)

  • createTaskInNotion() - Create tasks in Notion database
  • getPage() - Get page details
  • getDatabase() - Get database structure
  • queryDatabase() - Query database

🧪 Testing

Test the webhook endpoint:

curl -X POST http://localhost:3000/webhook/github \ -H "Content-Type: application/json" \ -d '{ "title": "Test Issue", "body": "This is a test issue", "number": 123 }'

📁 Project Structure

MCP/ ├── src/ │ ├── tools/ │ │ ├── github.ts # GitHub API integration │ │ └── notion.ts # Notion API integration │ ├── index.ts # Main server file │ └── workflow.ts # GitHub issue handling ├── dist/ # Compiled JavaScript ├── Dockerfile # Docker configuration ├── docker-compose.yml # Docker Compose setup ├── tsconfig.json # TypeScript configuration └── package.json # Dependencies and scripts

🤝 Contributing

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Add tests if applicable
  5. Submit a pull request

📄 License

This project is licensed under the ISC License.

-
security - not tested
F
license - not found
-
quality - not tested

A Node.js/TypeScript server implementing the Model Context Protocol that provides integrations with GitHub and Notion, allowing automated workflow between these platforms via API endpoints.

  1. 🚀 Features
    1. 📋 Prerequisites
      1. 🛠️ Installation
        1. 🔧 Configuration
          1. Environment Variables
          2. API Keys Setup
        2. 🏃‍♂️ Running the Application
          1. Development Mode
          2. Production Mode
          3. Docker
        3. 📡 API Endpoints
          1. 🛠️ Available Tools
            1. GitHub Tools (src/tools/github.ts)
            2. Notion Tools (src/tools/notion.ts)
          2. 🧪 Testing
            1. 📁 Project Structure
              1. 🤝 Contributing
                1. 📄 License
                  1. 🔗 Links

                    Related MCP Servers

                    • A
                      security
                      F
                      license
                      A
                      quality
                      A Model Context Protocol server that enables AI models to interact with GitHub's API, allowing for repository creation and management with descriptions, topics, and website URLs through natural language commands.
                      Last updated -
                      1
                      JavaScript
                    • -
                      security
                      F
                      license
                      -
                      quality
                      A Model Context Protocol server that enables AI assistants to perform GitHub operations including repository management, file operations, issue tracking, and pull request creation.
                      Last updated -
                      1
                      TypeScript
                    • -
                      security
                      -
                      license
                      -
                      quality
                      A Model Context Protocol server that supports remote connections and authenticates users via GitHub OAuth, allowing them to access tools based on their GitHub identity.
                      Last updated -
                      TypeScript
                    • -
                      security
                      F
                      license
                      -
                      quality
                      Model Context Protocol server that enables interaction with GitHub repositories, issues, pull requests, and search functionality through natural language.
                      Last updated -
                      TypeScript

                    View all related MCP servers

                    MCP directory API

                    We provide all the information about MCP servers via our MCP API.

                    curl -X GET 'https://glama.ai/api/mcp/v1/servers/Nawaf-TBE/MCP'

                    If you have feedback or need assistance with the MCP directory API, please join our Discord server