Substratum.Mcp
2.60.0
See the version list below for details.
dotnet tool install --global Substratum.Mcp --version 2.60.0
dotnet new tool-manifest
dotnet tool install --local Substratum.Mcp --version 2.60.0
#tool dotnet:?package=Substratum.Mcp&version=2.60.0
nuke :add-package Substratum.Mcp --version 2.60.0

Substratum MCP Server
Model Context Protocol server for the Substratum .NET framework. Lets AI assistants like Claude, Cursor, and Windsurf scaffold, analyse, and upgrade your Substratum projects with expert-level fluency.
Install
dotnet tool install -g Substratum.Mcp
The tool command is dotnet-sub-mcp.
Register with your AI client
Claude Code / Claude Desktop
{
"mcpServers": {
"substratum": {
"command": "dotnet-sub-mcp"
}
}
}
Cursor / Windsurf / other MCP clients
Same config — any MCP client that supports stdio servers works. When the client exposes a workspace root, the server picks it up automatically; most tool calls then don't need a projectPath argument.
What it gives your AI
13 tools
Every tool is annotated (ReadOnly, Destructive, Idempotent, OpenWorld) so clients render correct permission UIs, and every structured tool declares an outputSchema.
| Tool | Hints | Purpose |
|---|---|---|
scaffold |
Destructive | Unified scaffolder. kind: project, entity, endpoint, event, job, service, doc_group, permission |
analyze_project |
ReadOnly | Roslyn scan — returns entities, endpoints, permissions, DbContexts, events, jobs |
design_validate |
ReadOnly | Structural validation + optional LLM qualitative review via sampling |
generate_code |
Destructive | Endpoint handler logic, validators, seeders. intent: logic, validation, seeder |
read_config |
ReadOnly | Reads appsettings.json, optionally scoped to a section |
update_config |
Destructive | Deep-merges a config object into a feature section |
db |
Destructive | EF operations. action: migrate_add, update, sql. Asks for confirmation via elicitation. |
upgrade |
Destructive | Cross-version migration. action: analyze, endpoints, generics, renames. Dry-run by default. |
build |
Idempotent | dotnet build with parsed diagnostics and streaming progress |
fs_list |
ReadOnly | List project files filtered by extension |
fs_read |
ReadOnly | Read a file (optional line range) |
fs_write |
Destructive | Write to a file (creates parent dirs) |
run_command |
Destructive | Allow-listed dotnet CLI commands (build, test, restore, ef, tool, …) |
6 resources
Static content — loaded once by the client, referenced as often as the AI needs without burning tool round-trips:
| URI | Content |
|---|---|
substratum://conventions |
Full framework coding conventions (25+ categories) |
substratum://schema/appsettings |
JSON Schema for appsettings.json |
substratum://skills |
Skill-pack catalog |
substratum://skills/{name} |
One skill pack. 14 packs: result_pattern, permissions, auth_strategy, live_events, multi_tenancy, file_and_image, localization, background_jobs, database_design, entity_design, ef_core, endpoint_design, validation, security |
substratum://guides |
Setup-guide catalog |
substratum://guides/{name} |
One setup guide. 7 guides: overview, user-and-roles, permission-hydrator, session-validator, api-key-auth, basic-auth, database-seeder |
Resource template parameters use AllowedValues completions — your AI client can tab-complete valid skill/guide names.
5 prompts
Orchestrated multi-step workflows — the AI follows a single prompt instead of planning 10+ tool calls itself:
| Prompt | Does |
|---|---|
new_feature |
End-to-end: design → validate → scaffold entity → migration → endpoints → logic → validators → build |
full_crud |
Generates all 5 CRUD endpoints for an existing entity |
upgrade_project |
Safe upgrade: analyse → dry-run → confirm → apply → build |
review_design |
Reviews a design against conventions + skills, with LLM qualitative feedback |
design_for_domain |
Produces a validated backend design from a natural-language domain description |
MCP capabilities used
This server takes full advantage of modern MCP features — not just basic tools/call:
- Tool annotations — clients render correct permission UIs
- Structured outputs — typed records with declared
outputSchema - Progress notifications —
build,upgrade,db,scaffoldstream progress - Cancellation tokens — every async tool cancels cleanly
- Roots —
projectPathfalls back to the client's workspace root - Sampling —
design_validatecan ask the LLM for qualitative feedback - Elicitation — destructive ops (
db action=update,upgrade dryRun=false) ask the user to confirm - Completions — skill/guide resource templates offer tab-complete
What you can ask your AI to do
- "Scaffold a Products feature with CRUD endpoints" — uses the
new_featureprompt end-to-end - "Add a permission for exporting invoices and gate the endpoint" —
scaffold kind=permission+ endpoint update - "Analyse my project and tell me what's missing" — Roslyn scan flags missing FKs, indexes, naming violations
- "Upgrade this project to the latest Substratum" —
upgrade_projectprompt: analyse → dry-run → confirm → apply → build - "Design a backend for a multi-tenant SaaS" —
design_for_domainprompt produces a validated JSON design
About Substratum
Substratum is an opinionated, production-grade application framework built on ASP.NET Core. Authentication, authorization, database, caching, logging, OpenAPI docs, cloud storage, push notifications, real-time events, and background jobs — all pre-wired and configured via appsettings.json.
- Main package: Substratum
- Source generator: Substratum.Generator
- CLI tool: Substratum.Tools (
dotnet-sub) - Repository & full docs: github.com/aljaff94/Substratum
License
MIT — do anything you want with it.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
This package has no dependencies.
| Version | Downloads | Last Updated |
|---|---|---|
| 3.0.0-alpha.1 | 51 | 6/11/2026 |
| 2.60.0 | 98 | 5/29/2026 |
| 2.50.1 | 94 | 5/26/2026 |
| 2.50.0 | 99 | 5/25/2026 |
| 2.40.0 | 98 | 5/25/2026 |
| 2.30.0 | 102 | 5/23/2026 |
| 2.26.1 | 124 | 5/15/2026 |
| 2.26.0 | 98 | 5/14/2026 |
| 2.25.0 | 104 | 5/10/2026 |
| 2.24.0 | 114 | 4/17/2026 |
| 2.23.0 | 103 | 4/17/2026 |
| 2.22.0 | 111 | 4/17/2026 |
| 2.21.0 | 110 | 4/17/2026 |
| 2.20.0 | 107 | 4/17/2026 |
| 2.19.0 | 110 | 4/17/2026 |
| 2.18.0 | 106 | 4/17/2026 |
| 2.15.0 | 118 | 4/11/2026 |
| 2.14.0 | 107 | 4/11/2026 |
| 2.12.0 | 107 | 4/11/2026 |
| 2.10.0 | 112 | 4/10/2026 |