modular-monolith-mcp
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
@leonardocrdso/modular-monolith-mcp
An MCP (Model Context Protocol) server that provides 35 architecture rules, 16 anti-patterns, 3 decision trees, and 8 code templates for building Modular Monolith applications. Search, validate, and scaffold modules following best practices.
Installation
Using npx (recommended)
npx @leonardocrdso/modular-monolith-mcpAdding to Claude Code
claude mcp add modular-monolith-mcp -- npx @leonardocrdso/modular-monolith-mcpManual configuration
Add to your MCP client settings:
{
"mcpServers": {
"modular-monolith-mcp": {
"command": "npx",
"args": ["@leonardocrdso/modular-monolith-mcp"]
}
}
}Related MCP server: Guardian MCP Toolkit
Tools
search-rule
Search architecture rules by name, keyword, or ID. Also searches anti-patterns.
query: "thin-routes"
query: "boundary"
query: "data-isolation"search-by-context
Find relevant rules for a given situation. Describe your problem in natural language.
context: "my modules are importing internal files from each other"
context: "I need to decide between sync and async communication"list-rules
List all rules or filter by category.
category: "module-boundaries"
category: "module-communication"validate-module
Validate a module directory structure against Modular Monolith conventions. Checks for required files (service, types, index.ts) and recommended files (repository, validation, routes).
path: "/project/src/modules/orders"check-imports
Analyze imports across modules to detect boundary violations. Finds direct imports that bypass public APIs (index.ts).
path: "/project/src/modules"get-template
Generate code templates for scaffolding module files. Returns ready-to-use TypeScript with architecture rule references.
template: "service" moduleName: "orders"
template: "module-scaffold" moduleName: "user-management"
template: "repository" moduleName: "payments"Available templates: module-scaffold, service, repository, types, validation, public-api, route-handler, integration-client
Resources
modular://catalog— Full catalog of all 35 rules grouped by categorymodular://rule/{id}— Individual architecture rule by IDmodular://anti-pattern/{id}— Individual anti-pattern by IDmodular://decision-tree/{id}— Architectural decision tree by ID
Prompts
architecture-review
Generates a structured architecture review prompt with relevant Modular Monolith rules embedded as context.
Parameters:
code(required) — The source code to reviewlanguage(optional) — Programming language (e.g.typescript,python)focus_categories(optional) — Comma-separated categories to focus on
module-design
Generates a prompt to help design a new module with proper structure, boundaries, and communication patterns.
Parameters:
module_name(required) — Name of the module to designdescription(required) — Brief description of what this module doesresponsibilities(required) — Comma-separated list of responsibilities
Categories
10 categories covering 35 rules and 16 anti-patterns:
Category | Description |
| Module Structure |
| Module Boundaries |
| Module Communication |
| Data Isolation |
| Dependency Management |
| Routes & Controllers |
| Shared Kernel |
| Testing Strategy |
| External Integrations |
| Migration & Evolution |
Decision Trees
3 interactive decision trees for common architectural choices:
create-vs-expand-module— Create a new module vs expand an existing onesync-vs-async-communication— Sync service calls vs async eventswhen-to-extract-microservice— When to extract a module into a microservice
Ecosystem
Use together with @leonardocrdso/clean-code-mcp for complete code quality coverage — architecture rules (this server) + Clean Code principles (clean-code-mcp).
Development
# Install dependencies
bun install
# Run in development mode
bun run dev
# Build
bun run buildLicense
MIT
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Stateless advisor + validator for Conducted Development: kickoff, artifact validation, rule checks.
Evidence-backed architecture-quality analysis for Python agent applications.
AI Agent with Architectural Memory. Impact analysis (free), tests and code from the graph (pro).
30+ deterministic dev and delivery tools: linting, metrics, diagrams, model advice, AI-text checks.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceProvides AI-powered architecture analysis and visualization of codebases, exposing 17 MCP tools for querying components, dependencies, and generating interactive diagrams.6MIT
- FlicenseNot gradedqualityCmaintenanceReal-time architecture governance tool that enforces Clean Architecture, DDD, SOLID, TDD, and Security rules across 8 languages using 11 specialized agents.-
- AlicenseNot gradedqualityCmaintenanceServes the architectural graph of a hexagonal-architecture codebase to coding agents via stdio, providing tools to analyze dependencies, check violations, and inspect structural changes.7 npmMIT
- AlicenseAqualityBmaintenanceProvides read-only structural analysis of codebases, surfacing architecture smells with traffic-light ratings and rendering dependency relationships as Mermaid flowcharts.4MIT