Nestjs Architecture

Use when the user asks about NestJS modules, structuring a NestJS module with providers, dependency injection scopes, dynamic modules, module boundaries or a NestJS monorepo. Produces a NestJS module layout. Not for guards, interceptors, pipes or @nestjs/cqrs recipes (use nestjs-patterns).

45 stars 6 forksSoftware Development

Install

skills CLI (Claude Code, Cursor, Codex and more)
npx skills add j4flmao/agent-skills --skill nestjs-architecture
Manual install
git clone --depth 1 https://github.com/j4flmao/agent-skills.git /tmp/agent-skills
mkdir -p ~/.claude/skills
cp -r /tmp/agent-skills/skills/backend/nestjs/architecture ~/.claude/skills/nestjs-architecture

Personal skills live in ~/.claude/skills. Use .claude/skills in a project folder to share a skill with your team.

From the SKILL.md

# NestJS Architecture

## Purpose
Structure NestJS applications with module-based architecture — domain modules, shared modules, dynamic modules, monorepo projects, and provider scoping.

## Agent Protocol

### Trigger
User request includes: `NestJS module structure`, `NestJS architecture`, `NestJS project layout`, `NestJS DI`, `NestJS modules`, `NestJS monorepo`, `NestJS providers`.

### Input Context
- NestJS version (10+)
- Architecture style (modular, monorepo, microservices)
- Database (TypeORM, Prisma, MikroORM, Mongoose)
- Transport (HTTP, WebSocket, TCP, RabbitMQ)

### Output Artifact
Module structure, provider registration, module exports, monorepo layout, DI setup.

### Response Format
Produce artifact directly. No preamble, no postamble, no explanations.

### Completion Criteria
- Root module imports feature modules
- Each domain has its own module with controllers, services, repositories
- Modules export only what other modules need
- Global modules registered sparingly (shared infra only)
- Dynamic modules configured with forRoot/forFeature

### Max Response Length
4096 tokens

## Architecture Decision Trees

### Module Organization: Feature vs Shared vs Core

| Module Type | Contains | Export Strategy | Example |
|-------------|----------|----------------|---------|
| Feature | Controllers, Services, Repositories | Only what others need | UsersModule, OrdersModule |
| Shared | Reusable utilities, guards, filters | Everything | CommonModule |
Read the full skill on GitHub

Details

Skill name
nestjs-architecture
Path
skills/backend/nestjs/architecture/SKILL.md
License
MIT
Repo updated
17 November 2026

FAQ

What does the Nestjs Architecture skill do?

Use when the user asks about NestJS modules, structuring a NestJS module with providers, dependency injection scopes, dynamic modules, module boundaries or a NestJS monorepo. Produces a NestJS module layout. Not for guards, interceptors, pipes or @nestjs/cqrs recipes (use nestjs-patterns).

How do I install the Nestjs Architecture skill?

skills CLI (Claude Code, Cursor, Codex and more): npx skills add j4flmao/agent-skills --skill nestjs-architecture. Skills go in ~/.claude/skills (personal) or .claude/skills (project), and Claude loads them automatically when a task matches the description.

Is Nestjs Architecture popular?

It lives in j4flmao/agent-skills, which has 45 GitHub stars and 6 forks.

Related skills

Agent Observability

45

j4flmao/agent-skills

Use when the user asks about agent observability, tracing agent reasoning, debugging an agent loop, OpenTelemetry GenAI spans for LLM calls, LLM cost tracking per agent, agent audit logs or hallucination/eval monitoring in production. Produces instrumentation config, trace schema, dashboards, alerts and cost attribution. Not for generic service tracing without LLMs (use devops-opentelemetry).

DevOps & Cloud

AI Agent Architectures

45

j4flmao/agent-skills

Use when the user asks to build an AI agent, design an agent that calls tools and keeps memory, write an agent system prompt or pick an agent framework (Claude Agent SDK, OpenAI Agents SDK, LangGraph). Produces an architecture brief covering loop, tools, memory, guardrails and evals, routing depth to child skills. Not for workflow patterns (use ai-agentic-workflows).

AI, LLMs & Agents

AI Agent Core Loop

45

j4flmao/agent-skills

Use when the user asks about the agent loop, ReAct vs plan-and-solve, re-planning, Reflexion, an agent stuck in a loop, max iterations or termination conditions. Produces a loop spec or patch with state, success predicate, caps and no-progress detection. Not for overall agent design (use ai-agent-architectures) or tool schemas (use tool-calling-principles).

AI, LLMs & Agents

Nestjs Patterns

45

j4flmao/agent-skills

Use when the user asks about NestJS guards, interceptors, pipes, exception filters, custom decorators, @nestjs/cqrs or NestJS microservices (@MessagePattern). Produces NestJS request-pipeline and CQRS code. Not for module layout and DI scopes (use nestjs-architecture).

Software Development

Multiplayer Netcode

45

j4flmao/agent-skills

Use when the user asks about multiplayer netcode, client-side prediction and server reconciliation, entity interpolation, rollback netcode, GGPO, lag compensation for a shooter or choosing a transport. Produces gameplay netcode design and code. Not for server tick and fleet design (use authoritative-server or scaling-architecture).

Software Development

Nodejs Architecture

45

j4flmao/agent-skills

Use when the user asks about Node.js backend architecture, choosing Express vs Fastify vs Hono, Node project structure, middleware order, central error handling or env validation with Zod. Produces a Node service layout. Not for one framework in depth (use nodejs-express-skill, nodejs-fastify or nodejs-hono).

Software Development

Browse the most popular Claude skills, all software development skills, or write your own with the skills generator.