Memungkinkan AI assistant untuk menulis, memvalidasi, dan mengoptimalkan query CodeQL untuk analisis keamanan dan kualitas kode menggunakan CodeQL CLI.
Juga dikenal sebagai advanced-security/codeql-development-mcp-server
- Stars
- 39
- Tools
- —
- Unduhan, 30 hari
- —
- Versi terbaru
- —
- Commit terakhir
- 13 Nov 2026
- Lisensi
- —
Apa itu CodeQL Development MCP?
CodeQL Development adalah MCP server. Memungkinkan AI assistant untuk menulis, memvalidasi, dan mengoptimalkan query CodeQL untuk analisis keamanan dan kualitas kode menggunakan CodeQL CLI.
Ringkasan dibuat dari README proyek
Tentang CodeQL Development MCP server
Menulis dan mengoptimalkan security query untuk berbagai bahasa pemrograman adalah kemampuan yang ditawarkan server ini bagi developer yang menggunakan AI assistant. Server ini menyediakan bridge khusus antara large language model dan CodeQL CLI, yang memungkinkan agent untuk menangani kompilasi query, eksekusi, dan operasi database. Server ini mendukung sepuluh bahasa berbeda, termasuk Python, JavaScript, Java, C/C++, Rust, dan Swift, menjadikannya tool yang serbaguna untuk tugas analisis keamanan dan kualitas kode.
Untuk menggunakan server ini, Anda harus sudah menginstal CodeQL CLI dan tersedia di system path Anda. Server ini dapat diintegrasikan ke IDE seperti VS Code atau Cursor melalui ekstensi VSIX, atau digunakan dengan agentic tools lainnya melalui mode transport stdio atau HTTP. Meskipun server ini mengodifikasi praktik pengembangan tingkat lanjut melalui prompt dan resource bawaan, performanya bergantung pada ukuran database CodeQL yang sedang dianalisis. Setup ini memerlukan Node.js v25.6.0 atau versi terbaru serta pilihan LLM yang ingin Anda gunakan.
Apa yang bisa Anda lakukan dengannya
- 1Automated query developmentAI assistant dapat menulis dan mengompilasi query CodeQL baru untuk mengidentifikasi kerentanan keamanan tertentu.
- 2Validating query accuracyDeveloper dapat menggunakan tool pengujian terintegrasi untuk memastikan security query mereka menghasilkan hasil yang diharapkan.
- 3Multi-language security analysisServer ini memungkinkan AI agent untuk melakukan analisis keamanan di berbagai macam bahasa pemrograman.
- 4Managing CodeQL databasesAI agent dapat melakukan operasi database yang diperlukan untuk menjalankan security scan.
Ditulis berdasarkan README proyek. Setiap use case diperiksa terhadap kutipan dari README tersebut.
Cara menginstal CodeQL Development MCP
Format diverifikasi 10 Nov 2026Tambahkan ke CursorTambahkan ke GooseInstal CodeQL Development MCP di Claude Code
$ claude mcp add codeql-development-mcp-server -- npx -y codeql-development-mcp-serverInstal CodeQL Development MCP di Cursor
~/.cursor/mcp.json
{
"mcpServers": {
"codeql-development-mcp-server": {
"command": "npx",
"args": [
"-y",
"codeql-development-mcp-server"
]
}
}
}Instal CodeQL Development MCP di VS Code
.vscode/mcp.json
{
"servers": {
"codeql-development-mcp-server": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"codeql-development-mcp-server"
]
}
}
}Instal CodeQL Development MCP di VS Code CLI
$ code --add-mcp '{"name":"codeql-development-mcp-server","type":"stdio","command":"npx","args":["-y","codeql-development-mcp-server"]}'Instal CodeQL Development MCP di Claude Desktop
claude_desktop_config.json
{
"mcpServers": {
"codeql-development-mcp-server": {
"command": "npx",
"args": [
"-y",
"codeql-development-mcp-server"
]
}
}
}Instal CodeQL Development MCP di Codex
$ codex mcp add codeql-development-mcp-server -- npx -y codeql-development-mcp-serverInstal CodeQL Development MCP di Codex config.toml
~/.codex/config.toml
[mcp_servers.codeql-development-mcp-server] command = "npx" args = ["-y", "codeql-development-mcp-server"]
Instal CodeQL Development MCP di Gemini CLI
$ gemini mcp add -s user codeql-development-mcp-server npx -- -y codeql-development-mcp-serverInstal CodeQL Development MCP di Gemini settings.json
~/.gemini/settings.json
{
"mcpServers": {
"codeql-development-mcp-server": {
"command": "npx",
"args": [
"-y",
"codeql-development-mcp-server"
]
}
}
}Pengecekan otomatis
Berjalan 14 Nov 2026Laporan lengkap →Lolos checks otomatis kami. Ini bukan audit keamanan: baca kodenya dan berikan server akses paling terbatas yang dibutuhkannya. Cara kerja checks · Yang perlu diperbaiki untuk menambah poin
- Source repository terhubung dan dapat dijangkauadvanced-security/codeql-development-mcp-server is public and reachablegithub.com/advanced-security/codeql-development-mcp-server ↗Lolos
- Nama paket mencantumkan repositori ini sebagai sumbernyacodeql-development-mcp-server names advanced-security/codeql-development-mcp-server as sourcenpmjs.com/package/codeql-development-mcp-server ↗Lolos
- Provenance build (atestasi Sigstore)Sigstore attestation for codeql-development-mcp-servernpmjs.com/package/codeql-development-mcp-server/v/2.27.4#pro ↗Lolos
- Lisensi open source (OSI)No licenseTemuan
- Ada commit atau release dalam satu tahun terakhirLast commit or release 2026-11-06github.com/advanced-security/codeql-development-mcp-server ↗Lolos
- OpenSSF ScorecardTidak diperiksa
- Nama package tidak mirip dengan package populerNo popular package one edit away from codeql-development-mcp-serverLolos
- Tidak ada advisory kritis pada paket atau dependensinyaTidak diperiksa
- Tidak ada instruksi tersembunyi untuk model0 tool descriptions and the README read; no override phrases, credential paths or hidden charactersLolos
- Tools yang bersifat destruktif telah diberi labelTidak diperiksa
- Endpoint remote merespons handshake MCPTidak diperiksa
README
Lihat di GitHubCodeQL Development MCP Server
Enabling AI-assisted CodeQL query development through the Model Context Protocol
A comprehensive Model Context Protocol (MCP) server designed specifically for agentic AI development of CodeQL (QL) code. This server provides tools, prompts, and resources to help AI assistants write, validate, and optimize CodeQL queries for security analysis and code quality.
Features
- Comprehensive Tool Suite - Wraps CodeQL CLI commands for query compilation, execution, testing, and database operations
- Multi-Language Support - Supports CodeQL query development for 10 languages including Python, JavaScript, Java, C/C++, Rust, Swift, and more
- AI-Optimized Prompts - Built-in prompts and resources that guide AI assistants through CodeQL development workflows
- Test-Driven Development - Integrated testing tools for validating query accuracy with expected results
- Flexible Transport - Supports both stdio and HTTP transport modes for different integration scenarios
Limitations
- Requires CodeQL CLI to be installed separately
- Performance depends on the size of CodeQL databases being analyzed
- Some advanced CodeQL CLI features may not yet be exposed as tools
Project Status
Active Development - This project is actively maintained and used in production environments for AI-assisted CodeQL development.
Background
The codeql-development-mcp-server project is maintained by GitHub's CodeQL Expert Services team and builds (and hopefully improves) on the concepts from the advanced-security/codeql-development-template repository template.
The main advantages of using the codeql-development-mcp-server are:
- Agnostic of development environment
- Agnostic of calling Large Language Model (LLM)
- MCP server tools codify advanced CodeQL development practices
Roadmap
Development priorities and open issues are tracked in GitHub Issues.
Contributing
We welcome contributions! Whether it's bug fixes, new features, documentation improvements, or additional language support, please see CONTRIBUTING.md for guidelines.
Please note that this project is released with a Contributor Code of Conduct. By participating in this project you agree to abide by its terms.
Requirements
Environment
- Node.js v25.6.0 or later (nodejs.org)
- Some calling LLM Bring your own LLM, but some LLMs are (much) better than others.
External Dependencies
- CodeQL CLI - Must be installed and available in PATH (github.com/github/codeql-cli-binaries)
Quick Start
VS Code extension via VSIX (recommended for IDEs)
If you run ql-mcp inside VS Code or a compatible fork such as Cursor, install the vscode-codeql-development-mcp-server extension from a VSIX archive — it bundles the server, auto-registers ql-mcp, and discovers the CodeQL CLI. Download the .vsix from GitHub Releases and install it via Extensions: Install from VSIX… in the Command Palette, or build it from source with npm run package:vsix. See the VS Code Extension guide for details.
For Copilot CLI or other non-IDE agentic tools, use one of the methods below.
Install via npm
No repository clone needed — install from npmjs.org:
# Install globally
npm install -g codeql-development-mcp-server
Or run on-demand without installing globally:
npx -y codeql-development-mcp-server
VS Code Configuration
Add to your mcp.json file:
| OS | Location |
|---|---|
| Linux | ~/.config/Code/User/mcp.json |
| macOS | ~/Library/Application Support/Code/User/mcp.json |
| Windows | %APPDATA%\Code\User\mcp.json |
{
"servers": {
"ql-mcp": {
"command": "npx",
"args": ["-y", "codeql-development-mcp-server"],
"type": "stdio"
}
}
}
Install from GitHub Release archive
- Download the latest release from GitHub Releases
- Extract the archive:
tar -xzf codeql-development-mcp-server-vX.X.X.tar.gz -C /path/to/destination
Installing from Source
git clone https://github.com/advanced-security/codeql-development-mcp-server.git
cd codeql-development-mcp-server
npm install && npm run build
Server + extension only (no Go client):
npm run buildalso builds the Goclient/CLI (requires a Go toolchain). To build or package only the server and VS Code extension, usenpm run build:server-and-extensionornpm run package:vsix— neither touchesclient/.
Verification
- Restart VS Code
- Open Command Palette (
Ctrl+Shift+P/Cmd+Shift+P) - Run "GitHub Copilot: List MCP Servers"
- Confirm
ql-mcpappears
Supported Languages
| Language | CodeQL Identifier |
|---|---|
| GitHub Actions | actions |
| C/C++ | cpp |
| C# | csharp |
| Go | go |
| Java/Kotlin | java |
| JavaScript/TypeScript | javascript |
| Python | python |
| Ruby | ruby |
| Swift | swift |
Documentation
- Public Installation Guide - Install and run without cloning the repository
- Getting Started Guide - Detailed installation and setup instructions
- Tools Reference - Complete list of available MCP tools
- Prompts Reference - MCP prompts for CodeQL development workflows
- Resources Reference - MCP resources for CodeQL learning and reference
- Testing Strategy - Multi-layer testing approach
License
This project is licensed under the terms of the GitHub CodeQL Terms and Conditions. Please refer to LICENSE for the full terms.
Maintainers
This repository is maintained by the team specified in CODEOWNERS.
Support
This project uses GitHub issues to track bugs and feature requests. Please search existing issues before filing new ones to avoid duplicates.
This project comes with no expectation or guarantee of support, with more details in the SUPPORT.md document.
Acknowledgement
This project builds upon the CodeQL CLI and the broader CodeQL ecosystem developed by GitHub. Special thanks to the GitHub Advanced Security team and the open-source community for their contributions.
Pertanyaan tentang CodeQL Development MCP
Bagaimana cara menambahkan CodeQL Development MCP ke Claude Code?
Jalankan claude mcp add codeql-development-mcp-server -- npx -y codeql-development-mcp-server di terminal Anda. Tambahkan --scope user agar tersedia di semua proyek.
Bagaimana cara menambahkan CodeQL Development MCP ke Cursor?
Buka ~/.cursor/mcp.json dan tambahkan server di bawah mcpServers, menggunakan config Cursor yang ditunjukkan di bagian instalasi di atas.
Apakah server ini memerlukan CodeQL CLI?
Ya, CodeQL CLI harus diinstal secara terpisah dan tersedia di PATH Anda.
Bahasa pemrograman apa saja yang didukung untuk pengembangan CodeQL?
Server ini mendukung 10 bahasa termasuk Python, JavaScript, Java, C/C++, Rust, Swift, Go, C#, Ruby, dan GitHub Actions.
Bagaimana cara menginstal server ini via npm?
Anda dapat menginstalnya secara global menggunakan 'npm install -g codeql-development-mcp-server' atau menjalankannya secara on-demand dengan 'npx -y codeql-development-mcp-server'.