A comprehensive MCP (Model Context Protocol) server that provides tools to execute and automate Agent Rules Kit from MCP-compatible AI applications.
Listen to a brief introduction about Agent Rules Kit:
English Version
https://github.com/user-attachments/assets/7d65c696-245d-421d-9ddc-90331a92c9b2
Spanish Version
https://github.com/user-attachments/assets/8e91d651-c15f-4892-a250-684ab60d8594
This MCP server integrates with Agent Rules Kit, a powerful CLI tool that generates Cursor rules (.mdc files) for multiple technology stacks and MCP tools integration. Agent Rules Kit helps AI agents better understand project structure, patterns, and best practices across different frameworks.
This MCP server acts as a bridge between AI applications and Agent Rules Kit:
- Project Analysis: AI agents can use
get_project_infoto understand the current project's technology stack - Automated Installation: The
install_rulestool automatically installs the most appropriate Cursor rules - Interactive Setup: The
setup_project_rulesprompt provides a complete automated workflow - Resource Access: Built-in documentation and guides help agents understand available options
AI agents can use this MCP server to:
- π€ Automatically detect project technology stacks
- β‘ Install appropriate rules without manual intervention
- π Access documentation about supported frameworks and tools
- π Update rules when project requirements change
- π― Follow best practices for each technology stack
Key capabilities of Agent Rules Kit:
- π― Multi-Stack Support: 15+ frameworks including Laravel, Next.js, React, Angular, Vue, and more
- ποΈ Architecture-Aware: Specialized rules for different architectural patterns (MVC, DDD, Hexagonal, etc.)
- π§ MCP Tools Integration: Multi-select support for popular MCP tools (PAMPA, GitHub, Memory, Filesystem, Git)
- π¦ Version Detection: Automatic framework version detection with version-specific optimizations
- π οΈ Multiple Tools: Automatic project analysis and rule installation
- π Resources: Built-in documentation and guides accessible via MCP
- π― Prompts: Automated templates for project configuration
- π Intelligent Detection: Automatically recognizes 15+ technology stacks
- π Two execution modes:
- STDIO: For direct integration with MCP clients
- HTTP: For remote connections via HTTP/REST
# Install dependencies
npm install
# Compile TypeScript
npm run build# Development with watch mode
npm run dev:stdio
# Production
npm start# Development
npm run dev:http
# Production
npm run start:httpThe HTTP server will be available at http://localhost:3001 by default.
Starts the Agent Rules Kit system by executing the corresponding terminal command.
Optional parameters:
config_path(string): Path to configuration fileport(number): Port to run the service (default 3000)mode(string): Execution mode - "dev" or "prod"
Analyzes the current project to automatically detect the technology stack.
Optional parameters:
project_path(string): Path to the project to analyze (default: current directory)
Supported stacks:
- Frontend: React, Vue, Angular, Next.js, Astro
- Backend: Node.js, NestJS, Laravel, Spring Boot, Django, FastAPI
- Mobile: React Native
- Others: Go, Java, Python, PHP
Automatically installs appropriate Cursor rules based on the detected stack.
Optional parameters:
stack(string): Specific stack to install (auto-detected if not specified)project_path(string): Project path (default: current directory)force(boolean): Force installation even if rules already exist
Example automated flow:
{
"name": "install_rules",
"arguments": {
"project_path": "/path/to/project",
"force": true
}
}agent-rules-kit://documentation: Complete project documentationagent-rules-kit://stacks: Detailed list of supported technology stacksagent-rules-kit://usage-guide: Usage guide for AI agents
Automated prompt that configures Cursor rules for any project automatically.
Parameters:
project_path(optional): Project pathforce_reinstall(optional): Force reinstallation
Add to Claude Desktop configuration (claude_desktop_config.json):
{
"mcpServers": {
"agent-rules-kit": {
"command": "node",
"args": ["/path/to/agent-rules-kit-mcp/dist/index.js"]
}
}
}For HTTP connections, the following endpoints are available:
- GET
/health- Server status - GET
/info- Server information - GET
/tools- List of available tools - POST
/tools/call- Execute a tool
Example HTTP call:
curl -X POST http://localhost:3001/tools/call \
-H "Content-Type: application/json" \
-d '{
"name": "install_rules",
"arguments": {
"project_path": "/path/to/project",
"force": true
}
}'# Clean compiled files
npm run clean
# Compile
npm run build
# Watch mode for development
npm run dev- Node.js >= 18.0.0
- The
agent-rules-kitcommand must be available in the system PATH
src/
βββ index.ts # Main MCP server (STDIO mode)
βββ http.ts # MCP server HTTP mode
βββ tools.ts # Common tool, resource and prompt definitions
βββ functions.ts # MCP function implementations
βββ handlers.ts # Resource and prompt handlers
- Agent Rules Kit Repository - Main CLI tool
- Agent Setup Guide - Instructions for AI agents
- Model Context Protocol - Official MCP documentation
MIT