RepoLens

Gallery · Architecture explained · Score · TypeScript

NestJS architecture: modules, API surface, dependency graph

A progressive Node.js framework for building server-side applications. Generated from nestjs/nest at 62647d3, MIT.

Scanned @nestjs/common, @nestjs/core, and platform-express. The rest of the monorepo is left out so the job stays small.

Files
430
Modules
43
API routes
1
Documents
17

TypeScriptNode.jsExpressFastify

Executive Summary

Stakeholders · High-level overview for leadership, product, and stakeholders

At a Glance

AspectSummary
WhatNestJS is a well-structured API service
Built WithExpress, Fastify + TypeScript, Node.js
Scale43 modules across 430 files
MaturityWell-structured (2/3 indicators)

What This System Does

NestJS is a Express, Fastify API service built with TypeScript, Node.js. It exposes 1 API endpoint, designed for programmatic access by client applications, mobile apps, or external services.

Business Capabilities

The system is organized around 8 functional domains, each representing a distinct business capability:

DomainCapabilityScale
Shared Utilitiespath packages/common/interfaces matches common13 modules, 228 files
Core Enginepath packages/core/router matches core20 modules, 164 files
OtherUncategorized module2 modules, 20 files
API Layerpath packages/core/middleware matches middleware1 modules, 8 files
Integrationspath packages/platform-express/adapters matches adapter1 modules, 4 files
Search & Discoverypath packages/common/index.ts matches index3 modules, 3 files
+2 moreAdditional functional areas—

Technical Foundation

LayerTechnologiesPurpose
ApplicationExpress, FastifyCore runtime framework
LanguageTypeScript, Node.jsPrimary development language
BuildViteCompilation and bundling
TestingVitestQuality assurance

Module Composition

The codebase follows a layered architecture with clear separation of concerns:

LayerCountKey ModulesResponsibility
Shared Libraries9interfaces, decoratorsProvides shared utilities and abstractions used across modules
Route/Page Modules1routerMaps URL paths to page components and handles navigation
core4injector, errorsSupporting application functionality
Other Modules1multerGeneral purpose functionality

Monorepo Structure

This is a npm/yarn workspaces monorepo containing 3 packages. This structure enables:

  • Independent versioning and deployment of packages
  • Shared code reuse across internal projects
  • Coordinated development with clear ownership boundaries

Key packages:

  • @nestjs/common — packages/common
  • @nestjs/core — packages/core
  • @nestjs/platform-express — packages/platform-express

Codebase Health

Overall Health: 🟡 70/100

MetricValueStatus
Internal imports1229 edges✅ Connected
External Packages27✅ Manageable
Circular Dependencies50🔴 50 detected
Orphan Files2⚠️ 2 unused
Key Insights
  • 🔴 Architectural concern — 50 circular dependencies detected. These create tight coupling and make testing difficult.

Key Data Flows

The system processes information through 6 identified flows:

  • internal Request Flow (critical) — Import chain starting from packages/core/internal — traces how this entry point depends on 5 downstream modules
  • core Request Flow (critical) — Import chain starting from packages/core — traces how this entry point depends on 5 downstream modules
  • internal Request Flow (critical) — Import chain starting from packages/common/internal — traces how this entry point depends on 1 downstream module
  • platform-express Request Flow — Import chain starting from packages/platform-express — traces how this entry point depends on 3 downstream modules
  • controllers Request Flow — Import chain starting from packages/common/interfaces/controllers — traces how this entry point depends on 1 downstream module

Strategic Observations

  • The codebase follows Core/kernel architecture — `packages/core/router`, `packages/core/injector`, `packages/core/helpers` (+23 more); high fan-in, Middleware pipeline — `packages/core/middleware`, Analysis pipeline — `packages/core/inspector`, Shared utility layer — `packages/common/utils`, `packages/common/module-utils`, `packages/core/helpers`; high fan-in, Integration adapters — `packages/platform-express/adapters`, `packages/core/adapters`, ⚠️ 50 circular dependency cycle(s) detected architectural patterns, providing a familiar structure for developers.
  • With 8 distinct domains, the system has clear separation of concerns suitable for team-based development.

This executive summary was generated from comprehensive repository analysis including dependency graphs, data flow detection, and architectural pattern recognition. Enable AI enhancement with `GITHUB_TOKEN` for strategic recommendations, risk assessments, and plain-language explanations tailored for non-technical stakeholders.

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

System Overview

Mixed audience · Concise technical overview readable by all

The Big Picture

NestJS is a medium-sized codebase with clear structure, containing 43 modules spread across 430 files.

DimensionDetails
Total Files430
Module Count43
Functional Domains8
API Endpoints1

Technology Stack

The system is built on a modern technology foundation:

LayerTechnologiesPurpose
RuntimeExpress, FastifyHTTP server and middleware, High-performance HTTP server
LanguageTypeScript, Node.jsPrimary development language
BuildViteCompilation and asset processing
QualityVitestAutomated testing

Architecture Patterns

The codebase follows 6 identified architectural patterns:

  • Core/kernel architecture — `packages/core/router`, `packages/core/injector`, `packages/core/helpers` (+23 more); high fan-in — A structured approach to organizing code and managing complexity.
  • Middleware pipeline — `packages/core/middleware` — A structured approach to organizing code and managing complexity.
  • Analysis pipeline — `packages/core/inspector` — A structured approach to organizing code and managing complexity.
  • Shared utility layer — `packages/common/utils`, `packages/common/module-utils`, `packages/core/helpers`; high fan-in — A structured approach to organizing code and managing complexity.
  • Integration adapters — `packages/platform-express/adapters`, `packages/core/adapters` — A structured approach to organizing code and managing complexity.
  • ⚠️ 50 circular dependency cycle(s) detected — A structured approach to organizing code and managing complexity.

Module Architecture

The system is organized into 4 architectural layers:

LayerModulesKey ExamplesResponsibility
Shared Libraries9interfaces, decoratorsProvides shared utilities and abstractions used across modules
Route/Page Modules1routerMaps URL paths to page components and handles navigation
core4injector, errorsSupporting application functionality
Other Modules1multerGeneral purpose functionality
Layer Details

Shared Libraries — 9 modules

  • packages/common/interfaces — 71 files — Core application module
  • packages/common/decorators — 29 files — Core application module
  • packages/core/helpers — 27 files — Utility and helper functions
  • packages/common/exceptions — 24 files — Core application module
  • +5 more modules

Route/Page Modules — 1 module

  • packages/core/router — 32 files — API layer and route handlers

core — 4 modules

  • packages/core/injector — 30 files — Core application module
  • packages/core/errors — 26 files — Core application module
  • packages/core/repl — 16 files — Core application module
  • packages/core/inspector — 15 files — Test infrastructure

Other Modules — 1 module

  • packages/platform-express/multer — 15 files — Core application module

Functional Domains

The following domains represent the largest functional areas by file count:

RankDomainScaleBusiness Capability
1Shared Utilities228 filespath packages/common/interfaces matches common
2Core Engine164 filespath packages/core/router matches core
3Other20 filesUncategorized module
4API Layer8 filespath packages/core/middleware matches middleware
5Integrations4 filespath packages/platform-express/adapters matches adapter
6Search & Discovery3 filespath packages/common/index.ts matches index
—+2 more—Additional domains

Route Summary

The system surfaces 1 API endpoint (ALL).

API Endpoints (1)
EndpointMethodsPurpose
*pathALLData operations

Dependency Graph

Codebase Health: 🟡 70/100

MetricValueAssessment
Internal Imports1229Modules are connected
External Packages27Lean dependencies
Circular Dependencies50⚠️ Needs attention
Orphan Files2⚠️ 2 unused

Monorepo Structure

This is a npm/yarn workspaces monorepo containing 3 packages:

PackageLocationDescription
@nestjs/commonpackages/commonUtility libraries
@nestjs/corepackages/coreCore functionality and shared code
@nestjs/platform-expresspackages/platform-expressPackage functionality

This system overview was generated from comprehensive repository analysis. Enable AI enhancement with `GITHUB_TOKEN` for narrative context, architectural rationale, technology trade-off analysis, and scalability recommendations.

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

Business Domains

Mixed audience · Codebase structure translated into business language

Overview

NestJS is organized into 8 functional domains, each representing a distinct area of business capability. This document maps the technical structure to business-oriented functional areas.

Quick Reference:

DomainModulesFilesPrimary Capability
Shared Utilities13228Cross-cutting utility functions
Core Engine20164Supporting business operations
Other220Supporting business operations
API Layer18External API interface layer
Integrations14Supporting business operations
Search & Discovery33Search and content discovery
Configuration22Application configuration
State Management11Application state and data flow management

1. Shared Utilities

Business Capability

path packages/common/interfaces matches common

This is a major domain with 13 modules and 228 source files.

Key Modules
ModulePurpose
packages/common/interfacesCore application module
packages/common/decoratorsCore application module
packages/core/helpersUtility and helper functions
packages/common/exceptionsCore application module
packages/common/pipesCore application module
Business Impact
  • Change Frequency Impact: High — Changes here affect 228 files
  • Domain Complexity: Complex (multiple modules)
  • Recommendation: Ensure comprehensive testing before modifying this domain

2. Core Engine

Business Capability

path packages/core/router matches core

This is a major domain with 20 modules and 164 source files.

Key Modules
ModulePurpose
packages/core/routerAPI layer and route handlers
packages/core/injectorCore application module
packages/core/errorsCore application module
packages/core/replCore application module
packages/core/inspectorTest infrastructure
Business Impact
  • Change Frequency Impact: High — Changes here affect 164 files
  • Domain Complexity: Complex (multiple modules)
  • Recommendation: Ensure comprehensive testing before modifying this domain

3. Other

Business Capability

Uncategorized module

This is a focused domain with 2 modules and 20 source files.

Key Modules
ModulePurpose
packages/platform-express/multerCore application module
packages/platform-express/interfacesCore application module
Business Impact
  • Change Frequency Impact: Low — Changes here affect 20 files
  • Domain Complexity: Simple

4. API Layer

Business Capability

path packages/core/middleware matches middleware

This is a focused domain with 1 module and 8 source files.

Key Modules
ModulePurpose
packages/core/middlewareRequest/response middleware
Business Impact
  • Change Frequency Impact: Low — Changes here affect 8 files
  • Domain Complexity: Simple

5. Integrations

Business Capability

path packages/platform-express/adapters matches adapter

This is a focused domain with 1 module and 4 source files.

Key Modules
ModulePurpose
packages/platform-express/adaptersCore application module
Business Impact
  • Change Frequency Impact: Low — Changes here affect 4 files
  • Domain Complexity: Simple

6. Search & Discovery

Business Capability

path packages/common/index.ts matches index

This is a focused domain with 3 modules and 3 source files.

Key Modules
ModulePurpose
packages/common/index.tsCore application module
packages/core/index.tsCore application module
packages/platform-express/index.tsCore application module
Business Impact
  • Change Frequency Impact: Low — Changes here affect 3 files
  • Domain Complexity: Moderate

7. Configuration

Business Capability

path packages/core/application-config.ts matches config

This is a focused domain with 2 modules and 2 source files.

Key Modules
ModulePurpose
packages/core/application-config.tsConfiguration management
packages/core/constants.tsCore application module
Business Impact
  • Change Frequency Impact: Low — Changes here affect 2 files
  • Domain Complexity: Simple

8. State Management

Business Capability

path packages/core/nest-application-context.ts matches context

This is a focused domain with 1 module and 1 source file.

Key Modules
ModulePurpose
packages/core/nest-application-context.tsCore application module
Business Impact
  • Change Frequency Impact: Low — Changes here affect 1 file
  • Domain Complexity: Simple

Domain Health Summary

MetricValueAssessment
Total Domains8Well-balanced
Avg Files/Domain54Appropriate size
Largest DomainShared Utilities (228 files)Consider breaking down
Domain Concentration53% in largest✅ Well distributed

Domain mapping is based on directory naming conventions and code organization patterns. Enable AI enhancement with `GITHUB_TOKEN` for business-language descriptions, stakeholder impact analysis, strategic recommendations, and cross-domain relationship narratives.

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

Architecture Overview

Engineers · Layered architecture and design patterns

Architectural Philosophy

NestJS follows a Core/kernel architecture — `packages/core/router`, `packages/core/injector`, `packages/core/helpers` (+23 more); high fan-in architecture with elements of Middleware pipeline — `packages/core/middleware`, Analysis pipeline — `packages/core/inspector`, Shared utility layer — `packages/common/utils`, `packages/common/module-utils`, `packages/core/helpers`; high fan-in, Integration adapters — `packages/platform-express/adapters`, `packages/core/adapters`, ⚠️ 50 circular dependency cycle(s) detected.

Pattern Analysis

Core/kernel architecture — `packages/core/router`, `packages/core/injector`, `packages/core/helpers` (+23 more); high fan-in

A structured approach to organizing code and managing complexity.

Benefits: Structured organization, maintainability, clarity

Middleware pipeline — `packages/core/middleware`

A structured approach to organizing code and managing complexity.

Benefits: Structured organization, maintainability, clarity

Analysis pipeline — `packages/core/inspector`

A structured approach to organizing code and managing complexity.

Benefits: Structured organization, maintainability, clarity

Shared utility layer — `packages/common/utils`, `packages/common/module-utils`, `packages/core/helpers`; high fan-in

A structured approach to organizing code and managing complexity.

Benefits: Structured organization, maintainability, clarity

Integration adapters — `packages/platform-express/adapters`, `packages/core/adapters`

A structured approach to organizing code and managing complexity.

Benefits: Structured organization, maintainability, clarity

⚠️ 50 circular dependency cycle(s) detected

A structured approach to organizing code and managing complexity.

Benefits: Structured organization, maintainability, clarity

System Layers

The system is organized into 8 functional layers, each encapsulating a distinct area of responsibility:

LayerResponsibilityScaleKey Insight
Shared Utilitiespath packages/common/interfaces matches common228 filesLarge domain — consider breaking down
Core Enginepath packages/core/router matches core164 filesLarge domain — consider breaking down
OtherUncategorized module20 filesStandard domain
API Layerpath packages/core/middleware matches middleware8 filesExternal interface — versioning important
Integrationspath packages/platform-express/adapters matches adapter4 filesStandard domain
Search & Discoverypath `packages/common/index3 filesStandard domain
Configurationpath `packages/core/application-config2 filesStandard domain
State Managementpath `packages/core/nest-application-context1 filesStandard domain

Module Layers

Modules are classified into 4 architectural roles:

Shared Libraries

Role: Provides shared utilities and abstractions used across modules

ModuleFilesDescription
packages/common/interfaces71Core application module
packages/common/decorators29Core application module
packages/core/helpers27Utility and helper functions
packages/common/exceptions24Core application module
packages/common/pipes21Core application module
+4 more—Additional modules
Route/Page Modules

Role: Maps URL paths to page components and handles navigation

ModuleFilesDescription
packages/core/router32API layer and route handlers
core

Role: Supporting application functionality

ModuleFilesDescription
packages/core/injector30Core application module
packages/core/errors26Core application module
packages/core/repl16Core application module
packages/core/inspector15Test infrastructure
Other Modules

Role: General purpose functionality

ModuleFilesDescription
packages/platform-express/multer15Core application module

Technology Foundation

LayerTechnologiesArchitectural Implication
ApplicationExpress, FastifyMiddleware pipeline, request/response cycle
LanguageTypeScript, Node.jsStatic typing enables tooling and refactoring confidence
BuildViteModern bundling and optimization
QualityVitestEnables confident refactoring

Scale & Complexity Analysis

DimensionValueAssessment
Total Files430large project
Module Count43medium complexity
Domain Spread8 domainsGood separation
API Surface1 endpointsCompact API

Dependency Health

Architecture Health Score: 🟡 70/100

MetricValueStatusRecommendation
Import Edges1229✅Healthy module connectivity
External Packages27✅Lean dependency set
Circular Deps50🔴Refactor to break cycles
Orphan Files2⚠️Review for dead code
Architectural Strengths
  • Testing infrastructure — Automated testing with Vitest supports confident evolution.
Concerns
  • Circular dependencies detected — 50 circular dependencies create tight coupling, complicate testing, and hinder refactoring. Priority: High.

Monorepo Architecture

This project uses a npm/yarn workspaces monorepo with 3 packages.

Package Structure
PackageLocationArchitectural Role
@nestjs/commonpackages/commonUtility libraries
@nestjs/corepackages/coreCore functionality and shared code
@nestjs/platform-expresspackages/platform-expressPackage functionality
Monorepo Benefits
  • Shared infrastructure — Common tooling and configurations
  • Atomic changes — Cross-package updates in single commits
  • Independent deployment — Each package can be released separately
  • Clear ownership — Package boundaries define team responsibilities

This architecture overview was generated from comprehensive dependency graph analysis and pattern detection. Enable AI enhancement with `GITHUB_TOKEN` for architectural narratives, design rationale explanations, scalability analysis, and refactoring recommendations.

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

Module Catalog

Engineers · Complete inventory of code modules with AI explanations

A complete inventory of all code modules in the repository, organized by location and size. Each module represents a distinct area of responsibility within the codebase.

Total modules: 43


Module Inventory

ModuleFilesRole
packages/common/interfaces71Application module · Critical shared infrastructure (imported by 49 modules)
packages/core/router32Core business logic and shared foundations · Critical shared infrastructure (imported by 33 modules)
packages/core/injector30Core business logic and shared foundations · Critical shared infrastructure (imported by 108 modules)
packages/common/decorators29Application module · Critical shared infrastructure (imported by 26 modules)
packages/core/helpers27Core business logic and shared foundations · Critical shared infrastructure (imported by 57 modules)
packages/core/errors26Core business logic and shared foundations · Critical shared infrastructure (imported by 29 modules)
packages/common/exceptions24Application module · Orchestrator (coordinates 23 modules)
packages/common/pipes21Application module · Orchestrator (coordinates 72 modules)
packages/core/repl16Core business logic and shared foundations · Orchestrator (coordinates 9 modules)
packages/common/utils15Shared utilities and helper functions · Critical shared infrastructure (imported by 65 modules)
packages/core/inspector15Core business logic and shared foundations · Critical shared infrastructure (imported by 23 modules)
packages/platform-express/multer15Application module · Leaf module (consumed only, 1 importer)
packages/common/module-utils10Shared utilities and helper functions · Orchestrator (coordinates 8 modules)
packages/common/services10Service layer and external integrations · Shared infrastructure (imported by 7 modules)
packages/common/serializer8Application module · Orchestrator (coordinates 14 modules)
packages/core/hooks8Core business logic and shared foundations · Orchestrator (coordinates 6 modules)
packages/core/middleware8Core business logic and shared foundations · Shared infrastructure (imported by 6 modules)
packages/core/exceptions7Core business logic and shared foundations · Shared infrastructure (imported by 11 modules)
packages/common/enums6Application module · Critical shared infrastructure (imported by 41 modules)
packages/common/file-stream5Application module · Connector (3 in, 3 out)
packages/platform-express/interfaces5Application module · Leaf module (consumed only, 3 importers)
packages/core/discovery4Core business logic and shared foundations · Orchestrator (coordinates 6 modules)
packages/core/guards4Core business logic and shared foundations · Shared infrastructure (imported by 7 modules)
packages/core/pipes4Core business logic and shared foundations · Shared infrastructure (imported by 7 modules)
packages/platform-express/adapters4Application module · Connector (1 in, 2 out)
packages/core/interceptors3Core business logic and shared foundations · Shared infrastructure (imported by 6 modules)
packages/core/interfaces3Core business logic and shared foundations · Shared infrastructure (imported by 6 modules)
packages/core/security3Core business logic and shared foundations · Connector (3 in, 4 out)
packages/core/adapters2Core business logic and shared foundations · Shared infrastructure (imported by 6 modules)
packages/core/services2Core business logic and shared foundations · Leaf module (consumed only, 3 importers)
packages/common/constants.ts1Application module
packages/common/index.ts1Application module
packages/common/internal.ts1Application module
packages/core/application-config.ts1Core business logic and shared foundations
packages/core/constants.ts1Core business logic and shared foundations
packages/core/index.ts1Core business logic and shared foundations
packages/core/internal.ts1Core business logic and shared foundations
packages/core/metadata-scanner.ts1Core business logic and shared foundations
packages/core/nest-application-context.ts1Core business logic and shared foundations
packages/core/nest-application.ts1Core business logic and shared foundations
packages/core/nest-factory.ts1Core business logic and shared foundations
packages/core/scanner.ts1Core business logic and shared foundations
packages/platform-express/index.ts1Application module

Module detection is based on the `module_roots` setting in your RepoLens configuration. Adjust this setting to change how modules are grouped.

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

Route Map

Mixed audience · Application routes and API endpoints with context

A complete listing of user-facing pages and backend API endpoints. This map shows every URL a user or client can interact with, along with the source file that handles each route.


API Endpoints (1)

Backend services that handle data operations and business logic.

MethodPathSource File
ALL*pathpackages/platform-express/adapters/express-adapter.ts

Paths starting with `/api/` are backend endpoints; all others are user-facing pages.

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

API Surface

Engineers · Backend API endpoints with usage examples

This page documents both the API endpoints the application exposes and the external services it integrates with. Use it as a reference for understanding the system's interfaces.


Internal API Endpoints

These are the backend services the application provides to handle incoming requests.

Total endpoints: 1

MethodPathImplementation
ALL*pathpackages/platform-express/adapters/express-adapter.ts

External API Integrations

Third-party services the application connects to, grouped by category.

No external API integrations were detected. This section populates automatically when RepoLens identifies SDK imports or API client usage in your codebase.


Documented Exports

Exported functions with JSDoc/TSDoc documentation. Documentation coverage: 66%

Function Documentation
packages/common/decorators/core/apply-decorators.ts

`applyDecorators()`

Function that returns a new decorator that applies all decorators provided by param Useful to build new decorators (or a decorator factory) encapsulating multiple decorators related with the same feature

Parameters:

  • decorators (any): one or more decorators (e.g., ApplyGuard(...))
packages/common/decorators/core/bind.decorator.ts

`Bind()`

Decorator that binds parameter decorators to the method that follows. Useful when the language doesn't provide a 'Parameter Decorator' feature (i.e., vanilla JavaScript).

Parameters:

  • decorators (any): one or more parameter decorators (e.g., Req())
packages/common/decorators/core/catch.decorator.ts

`Catch()`

Decorator that marks a class as a Nest exception filter. An exception filter handles exceptions thrown by or not handled by your application code. The decorated class must implement the ExceptionFilter interface.

Parameters:

  • exceptions (any): one or more exception types specifying the exceptions to be caught and handled by this filter.
packages/common/decorators/core/controller.decorator.ts

`Controller()`

Decorator that marks a class as a Nest controller that can receive inbound requests and produce responses. An HTTP Controller responds to inbound HTTP Requests and produces HTTP Responses. It defines a class that provides the context for one or more related route handlers that correspond to HTTP request methods and associated routes for example GET /api/profile, POST /users/resume. A Microservice Controller responds to requests as well as events, running over a variety of transports (read more here). It defines a class that provides a context for one or more message or event handlers.

`Controller()`

Decorator that marks a class as a Nest controller that can receive inbound requests and produce responses. An HTTP Controller responds to inbound HTTP Requests and produces HTTP Responses. It defines a class that provides the context for one or more related route handlers that correspond to HTTP request methods and associated routes for example GET /api/profile, POST /users/resume. A Microservice Controller responds to requests as well as events, running over a variety of transports (read more here). It defines a class that provides a context for one or more message or event handlers.

Parameters:

  • prefix (string|Array): string that defines a route path prefix. The prefix is pre-pended to the path specified in any request decorator in the class.

`Controller()`

Decorator that marks a class as a Nest controller that can receive inbound requests and produce responses. An HTTP Controller responds to inbound HTTP Requests and produces HTTP Responses. It defines a class that provides the context for one or more related route handlers that correspond to HTTP request methods and associated routes for example GET /api/profile, POST /users/resume. A Microservice Controller responds to requests as well as events, running over a variety of transports (read more here). It defines a class that provides a context for one or more message or event handlers.

Parameters:

  • options (object): configuration object specifying: - scope - symbol that determines the lifetime of a Controller instance. See Scope for more details. - prefix - string that defines a route path prefix. The prefix is pre-pended to the path specified in any request decorator in the class. - version - string, array of strings, or Symbol that defines the version of all routes in the class. See Versioning for more details.

`Controller()`

Decorator that marks a class as a Nest controller that can receive inbound requests and produce responses. An HTTP Controller responds to inbound HTTP Requests and produces HTTP Responses. It defines a class that provides the context for one or more related route handlers that correspond to HTTP request methods and associated routes for example GET /api/profile, POST /users/resume A Microservice Controller responds to requests as well as events, running over a variety of transports (read more here). It defines a class that provides a context for one or more message or event handlers.

Parameters:

  • prefixOrOptions (any): a route path prefix or a ControllerOptions object. A route path prefix is pre-pended to the path specified in any request decorator in the class. ControllerOptions is an options configuration object specifying: - scope - symbol that determines the lifetime of a Controller instance. See Scope for more details. - prefix - string that defines a route path prefix. The prefix is pre-pended to the path specified in any request decorator in the class. - version - string, array of strings, or Symbol that defines the version of all routes in the class. See Versioning for more details.
packages/common/decorators/core/inject.decorator.ts

`Inject()`

Decorator that marks a constructor parameter as a target for Dependency Injection (DI). Any injected provider must be visible within the module scope (loosely speaking, the containing module) of the class it is being injected into. This can be done by: - defining the provider in the same module scope - exporting the provider from one module scope and importing that module into the module scope of the class being injected into - exporting the provider from a module that is marked as global using the @Global() decorator #### Injection tokens Can be types (class names), strings or symbols. This depends on how the provider with which it is associated was defined. Providers defined with the @Injectable() decorator use the class name. Custom Providers may use strings or symbols as the injection token.

Parameters:

  • token (any): lookup key for the provider to be injected (assigned to the constructor parameter).
packages/common/decorators/core/injectable.decorator.ts

`Injectable()`

Decorator that marks a class as a provider. Providers can be injected into other classes via constructor parameter injection using Nest's built-in Dependency Injection (DI) system. When injecting a provider, it must be visible within the module scope (loosely speaking, the containing module) of the class it is being injected into. This can be done by: - defining the provider in the same module scope - exporting the provider from one module scope and importing that module into the module scope of the class being injected into - exporting the provider from a module that is marked as global using the @Global() decorator Providers can also be defined in a more explicit and imperative form using various custom provider techniques that expose more capabilities of the DI system.

Parameters:

  • options (any): options specifying scope of injectable
packages/common/decorators/core/optional.decorator.ts

`Optional()`

Parameter decorator for an injected dependency marking the dependency as optional. For example: ``typescript constructor(@Optional() @Inject('HTTP_OPTIONS')private readonly httpClient: T) {} ``

packages/common/decorators/core/use-guards.decorator.ts

`UseGuards()`

Decorator that binds guards to the scope of the controller or method, depending on its context. When @UseGuards is used at the controller level, the guard will be applied to every handler (method) in the controller. When @UseGuards is used at the individual handler level, the guard will apply only to that specific method.

Parameters:

  • guards (any): a single guard instance or class, or a list of guard instances or classes.
packages/common/decorators/core/use-interceptors.decorator.ts

`UseInterceptors()`

Decorator that binds interceptors to the scope of the controller or method, depending on its context. When @UseInterceptors is used at the controller level, the interceptor will be applied to every handler (method) in the controller. When @UseInterceptors is used at the individual handler level, the interceptor will apply only to that specific method.

Parameters:

  • interceptors (any): a single interceptor instance or class, or a list of interceptor instances or classes.
packages/common/decorators/core/use-pipes.decorator.ts

`UsePipes()`

Decorator that binds pipes to the scope of the controller or method, depending on its context. When @UsePipes is used at the controller level, the pipe will be applied to every handler (method) in the controller. When @UsePipes is used at the individual handler level, the pipe will apply only to that specific method.

Parameters:

  • pipes (any): a single pipe instance or class, or a list of pipe instances or classes.
packages/common/decorators/core/version.decorator.ts

`Version()`

Sets the version of the endpoint to the passed version

packages/common/decorators/http/header.decorator.ts

`Header()`

Request method Decorator. Sets a response header. For example: @Header('Cache-Control', 'none') @Header('Cache-Control', () => 'none')

Parameters:

  • name (any): string to be used for header name
  • value (any): string to be used for header value
packages/common/decorators/http/http-code.decorator.ts

`HttpCode()`

Request method Decorator. Defines the HTTP response status code. Overrides default status code for the decorated request method.

Parameters:

  • statusCode (any): HTTP response code to be returned by route handler.
packages/common/decorators/http/redirect.decorator.ts

`Redirect()`

Redirects request to the specified URL.

packages/common/decorators/http/render.decorator.ts

`Render()`

Route handler method Decorator. Defines a template to be rendered by the controller. For example: @Render('index')

Parameters:

  • template (any): name of the render engine template file
packages/common/decorators/http/route-params.decorator.ts

`UploadedFile()`

Route handler parameter decorator. Extracts the file object and populates the decorated parameter with the value of file. Used in conjunction with multer middleware for Express-based applications. For example: ``typescript uploadFile(@UploadedFile() file) { console.log(file); } ``

`UploadedFile()`

Route handler parameter decorator. Extracts the file object and populates the decorated parameter with the value of file. Used in conjunction with multer middleware for Express-based applications. For example: ``typescript uploadFile(@UploadedFile() file) { console.log(file); } ``

`UploadedFile()`

Route handler parameter decorator. Extracts the file object and populates the decorated parameter with the value of file. Used in conjunction with multer middleware for Express-based applications. For example: ``typescript uploadFile(@UploadedFile() file) { console.log(file); } ``

`UploadedFile()`

Route handler parameter decorator. Extracts the file object and populates the decorated parameter with the value of file. Used in conjunction with multer middleware for Express-based applications. For example: ``typescript uploadFile(@UploadedFile() file) { console.log(file); } ``

`UploadedFiles()`

Route handler parameter decorator. Extracts the files object and populates the decorated parameter with the value of files. Used in conjunction with multer middleware for Express-based applications. For example: ``typescript uploadFile(@UploadedFiles() files) { console.log(files); } ``

`UploadedFiles()`

Route handler parameter decorator. Extracts the files object and populates the decorated parameter with the value of files. Used in conjunction with multer middleware for Express-based applications. For example: ``typescript uploadFile(@UploadedFiles() files) { console.log(files); } ``

`UploadedFiles()`

Route handler parameter decorator. Extracts the files object and populates the decorated parameter with the value of files. Used in conjunction with multer middleware for Express-based applications. For example: ``typescript uploadFile(@UploadedFiles() files) { console.log(files); } ``

`Query()`

Route handler parameter decorator. Extracts the query property from the req object and populates the decorated parameter with the value of query. May also apply pipes to the bound query parameter. For example: ``typescript async find(@Query('user') user: string) ``

Parameters:

  • property (any): name of single property to extract from the query object
  • pipes (any): one or more pipes to apply to the bound query parameter

`Query()`

Route handler parameter decorator. Extracts the query property from the req object and populates the decorated parameter with the value of query. May also apply pipes to the bound query parameter. For example: ``typescript async find(@Query('user') user: string) ``

Parameters:

  • property (any): name of single property to extract from the query object
  • pipes (any): one or more pipes to apply to the bound query parameter

`Query()`

Route handler parameter decorator. Extracts the query property from the req object and populates the decorated parameter with the value of query. May also apply pipes to the bound query parameter. For example: ``typescript async find(@Query('user') user: string) ``

Parameters:

  • property (any): name of single property to extract from the query object
  • pipes (any): one or more pipes to apply to the bound query parameter

`Query()`

Route handler parameter decorator. Extracts the query property from the req object and populates the decorated parameter with the value of query. May also apply pipes to the bound query parameter. For example: ``typescript async find(@Query('user') user: string) ``

Parameters:

  • property (any): name of single property to extract from the query object
  • options (any): options object containing additional configuration for the decorator, such as pipes and schema

`Query()`

Route handler parameter decorator. Extracts the query property from the req object and populates the decorated parameter with the value of query. May also apply pipes to the bound query parameter. For example: ``typescript async find(@Query({ schema: z.object({ user: z.string() }) }) query) ``

Parameters:

  • options (any): options object containing additional configuration for the decorator, such as pipes and schema

Showing 30 of 97 documented exports.


Documentation Summary:

  • Total exports: 147
  • Documented: 97
  • Undocumented: 50
  • Coverage: 66%

HTTP method reference — GET: retrieve data, POST: create, PUT/PATCH: update, DELETE: remove.

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

Data Flows

Mixed audience · Major information flows through the system

Understanding Data Movement

Data flows describe how information moves through NestJS — from external inputs through processing layers to storage or presentation. Understanding these flows is essential for debugging, performance optimization, and architectural decisions.

Flow Summary

6 data flows identified in the codebase:

FlowTypeComplexityCritical
internal Request FlowIntegrationHigh (6 steps)🔴 Yes
core Request FlowIntegrationHigh (6 steps)🔴 Yes
internal Request FlowIntegrationLow (2 steps)🔴 Yes
platform-express Request FlowIntegrationMedium (4 steps)—
controllers Request FlowIntegrationLow (2 steps)—
API Integration FlowIntegrationMedium (5 steps)—

1. internal Request Flow 🔴 CRITICAL FLOW

Description

Import chain starting from packages/core/internal — traces how this entry point depends on 5 downstream modules

Characteristics
PropertyValue
Steps6
Modules Involved6
CriticalityCritical
Processing Steps
StepActionPurpose
1internal (entry point, imports 36 modules)Data acquisition
2instance-wrapper (shared infrastructure, used by 34 files)Processing step
3module (shared infrastructure, used by 29 files)Processing step
4container (shared infrastructure, used by 23 files)Processing step
5application-config (shared infrastructure, used by 19 files)Processing step
6exclude-route-metadata.interface (shared infrastructure, used by 5 files)Processing step
Flow Diagram
┌─ START ─┐
│ `internal` (entry point, imports 36 modules)       │
│         ↓
│ `instance-wrapper` (shared infrastructure, used... │
│         ↓
│ `module` (shared infrastructure, used by 29 files) │
│         ↓
│ `container` (shared infrastructure, used by 23 ... │
│         ↓
│ `application-config` (shared infrastructure, us... │
│         ↓
│ `exclude-route-metadata.interface` (shared infr... │
└─ END ───┘
Involved Modules
ModuleRole
internalCore application module
instance-wrapperCore application module
moduleCore application module
containerCore application module
application-configConfiguration management
exclude-route-metadata.interfaceAPI layer and route handlers
Dependencies

Shared libraries used: packages/common/utils, packages/common/module-utils

Insights
  • ⚠️ Critical path — Failures here have significant business impact
  • 📊 Consider adding monitoring and alerting
  • 🧪 Ensure comprehensive test coverage

2. core Request Flow 🔴 CRITICAL FLOW

Description

Import chain starting from packages/core — traces how this entry point depends on 5 downstream modules

Characteristics
PropertyValue
Steps6
Modules Involved6
CriticalityCritical
Processing Steps
StepActionPurpose
1core (entry point, imports 16 modules)Data acquisition
2application-config (shared infrastructure, used by 19 files)Processing step
3instance-wrapper (shared infrastructure, used by 34 files)Processing step
4module (shared infrastructure, used by 29 files)Processing step
5container (shared infrastructure, used by 23 files)Processing step
6modules-container (shared infrastructure, used by 9 files)Processing step
Flow Diagram
┌─ START ─┐
│ `core` (entry point, imports 16 modules)           │
│         ↓
│ `application-config` (shared infrastructure, us... │
│         ↓
│ `instance-wrapper` (shared infrastructure, used... │
│         ↓
│ `module` (shared infrastructure, used by 29 files) │
│         ↓
│ `container` (shared infrastructure, used by 23 ... │
│         ↓
│ `modules-container` (shared infrastructure, use... │
└─ END ───┘
Involved Modules
ModuleRole
coreCore application module
application-configConfiguration management
instance-wrapperCore application module
moduleCore application module
containerCore application module
modules-containerCore application module
Dependencies

Shared libraries used: packages/common/utils, packages/common/module-utils

Insights
  • ⚠️ Critical path — Failures here have significant business impact
  • 📊 Consider adding monitoring and alerting
  • 🧪 Ensure comprehensive test coverage

3. internal Request Flow 🔴 CRITICAL FLOW

Description

Import chain starting from packages/common/internal — traces how this entry point depends on 1 downstream module

Characteristics
PropertyValue
Steps2
Modules Involved2
CriticalityCritical
Processing Steps
StepActionPurpose
1internal (entry point, imports 9 modules)Data acquisition
2shared.utils (shared infrastructure, used by 29 files)Processing step
Flow Diagram
┌─ START ─┐
│ `internal` (entry point, imports 9 modules)        │
│         ↓
│ `shared.utils` (shared infrastructure, used by ... │
└─ END ───┘
Involved Modules
ModuleRole
internalCore application module
shared.utilsUtility and helper functions
Dependencies

Shared libraries used: packages/common/utils, packages/common/module-utils

Insights
  • ⚠️ Critical path — Failures here have significant business impact
  • 📊 Consider adding monitoring and alerting
  • 🧪 Ensure comprehensive test coverage

4. platform-express Request Flow

Description

Import chain starting from packages/platform-express — traces how this entry point depends on 3 downstream modules

Characteristics
PropertyValue
Steps4
Modules Involved4
CriticalityStandard
Processing Steps
StepActionPurpose
1platform-express (entry point, imports 3 modules)Data acquisition
2adapters → imports 1 moduleData acquisition
3express-adapter → imports 4 modulesData acquisition
4nest-express-body-parser.interface (leaf — no further dependencies)Data transformation
Flow Diagram
┌─ START ─┐
│ `platform-express` (entry point, imports 3 modu... │
│         ↓
│ `adapters` → imports 1 module                      │
│         ↓
│ `express-adapter` → imports 4 modules              │
│         ↓
│ `nest-express-body-parser.interface` (leaf — no... │
└─ END ───┘
Involved Modules
ModuleRole
platform-expressCore application module
adaptersCore application module
express-adapterCore application module
nest-express-body-parser.interfaceCore application module
Dependencies

Shared libraries used: packages/common/utils, packages/common/module-utils

Insights
  • Standard integration flow with 4 processing steps

5. controllers Request Flow

Description

Import chain starting from packages/common/interfaces/controllers — traces how this entry point depends on 1 downstream module

Characteristics
PropertyValue
Steps2
Modules Involved2
CriticalityStandard
Processing Steps
StepActionPurpose
1controllers (entry point, imports 2 modules)Data acquisition
2controller-metadata.interface (leaf — no further dependencies)Processing step
Flow Diagram
┌─ START ─┐
│ `controllers` (entry point, imports 2 modules)     │
│         ↓
│ `controller-metadata.interface` (leaf — no furt... │
└─ END ───┘
Involved Modules
ModuleRole
controllersCore application module
controller-metadata.interfaceCore application module
Dependencies

Shared libraries used: packages/common/utils, packages/common/module-utils

Insights
  • Standard integration flow with 2 processing steps

6. API Integration Flow

Description

External service integrations and backend processing

Characteristics
PropertyValue
Steps5
Modules Involved1
CriticalityStandard
Processing Steps
StepActionPurpose
1Frontend makes API requestProcessing step
2API route receives and validates requestInput validation
3Business logic is executedObservability
4External services may be calledProcessing step
5Response is formatted and returnedOutput generation
Flow Diagram
┌─ START ─┐
│ Frontend makes API request                         │
│         ↓
│ API route receives and validates request           │
│         ↓
│ Business logic is executed                         │
│         ↓
│ External services may be called                    │
│         ↓
│ Response is formatted and returned                 │
└─ END ───┘
Involved Modules
ModuleRole
1 API endpoints detectedAPI layer and route handlers
Dependencies

Shared libraries used: packages/common/utils, packages/common/module-utils

Insights
  • Standard integration flow with 5 processing steps

Import Network

The system has 1229 internal import edges connecting 430 source files.

Network Topology
MetricValueMeaning
Total Edges1229Direct import relationships
Hub Count0Central integration points
Avg Connections~2.9 per fileCoupling density

Flow detection uses naming conventions, import patterns, and dependency graph analysis. Enable AI enhancement with `GITHUB_TOKEN` for end-to-end flow narratives, failure mode analysis, data transformation descriptions, and performance bottleneck identification.

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

Architecture Diff

Mixed audience · Git diff analysis and impact assessment

No changes detected.

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

System Map

Mixed audience · Visual dependency graph with explanation

What is this? This visual diagram shows how different parts of your codebase connect to each other. Arrows indicate dependencies (which modules use which).

Showing: 30 modules and 84 relationships

Source: Real import analysis


Architecture Diagram

┌─────────────────────────────────────────────────────────────┐
│              🏗️  SYSTEM ARCHITECTURE MAP                    │
└─────────────────────────────────────────────────────────────┘

⚙️  CORE LOGIC
│
├── router (32 files)
│      → errors
│      → helpers
│      → exceptions
│      ... +5 more
├── injector (30 files)
│      → errors
│      → discovery
│      ╌→ inspector
│      ... +5 more
├── helpers (27 files)
│      → injector
│      → router
│      → exceptions
│      ... +4 more
├── errors (26 files)
│      → injector
├── repl (16 files)
│      → injector
│      → router
├── hooks (8 files)
│      → injector
├── middleware (8 files)
│      → router
│      → helpers
│      → injector
│      ... +3 more
├── exceptions (7 files)
│      → helpers
│      → injector
│      → adapters
│      ... +2 more
├── discovery (4 files)
│      → injector
├── guards (4 files)
│      → helpers
│      → injector
├── pipes (4 files)
│      → helpers
│      → injector
├── interceptors (3 files)
│      → helpers
│      → injector
├── interfaces (3 files)
├── security (3 files)
│      → middleware
│      → router
├── adapters (2 files)
│      → helpers
└── services (2 files)
│
🔌  INTEGRATION
│
└── adapters (4 files)
       → interfaces
│
🛠️  UTILITIES
│
├── interfaces (71 files)
│      → services
│      → enums
├── decorators (29 files)
│      → interfaces
│      → utils
│      → enums
├── exceptions (24 files)
│      → enums
│      → interfaces
│      → utils
├── pipes (21 files)
│      → decorators
│      → interfaces
│      → utils
│      ... +2 more
├── utils (15 files)
│      → decorators
│      → interfaces
│      → enums
│      ... +2 more
├── module-utils (10 files)
│      → interfaces
│      → services
│      → utils
├── services (10 files)
│      → decorators
│      → utils
├── serializer (8 files)
│      → decorators
│      → file-stream
│      → interfaces
│      ... +1 more
├── enums (6 files)
└── file-stream (5 files)
       → enums
       → services
       → utils
│
✅  TESTING
│
└── inspector (15 files)
       → errors
       → injector
       → helpers
       ... +2 more
│
📦  OTHER
│
├── multer (15 files)
└── interfaces (5 files)
│

Legend:
  →  imports / depends on
  ╌→ tests

Key Connections

Most depended-on modules (highest import count):

ModuleImported by
packages/core/injector82 modules
packages/common/utils58 modules
packages/common/interfaces48 modules
packages/core/helpers41 modules
packages/common/enums39 modules

Most dependent modules (highest dependency count):

ModuleDepends on
packages/common/pipes70 modules
packages/core/router47 modules
packages/core/injector41 modules
packages/common/decorators39 modules
packages/core/middleware34 modules

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

Developer Onboarding

Engineers · Quick start guide for new developers

Welcome to NestJS! 👋

This guide will help you get up to speed quickly. NestJS is a Express, Fastify project built with TypeScript, Node.js, containing 43 modules across 430 files.

What You'll Learn
  1. ✅ Repository structure and organization
  2. ✅ Technology stack and tools
  3. ✅ Key modules to understand first
  4. ✅ How data flows through the system
  5. ✅ How to start contributing

Quick Reference Card

AspectDetails
LanguagesTypeScript, Node.js
FrameworksExpress, Fastify
Build ToolsVite
TestingVitest
Size43 modules, 430 files
Domains8 functional areas
API1 endpoints

Repository Structure

Understanding the directory layout is your first step to navigating the codebase:

DirectoryPurposeStart Here?
packages/commonProject files—
packages/coreCore logic and foundations⭐ Yes
packages/platform-expressProject files—
Where to Begin

Focus on these directories first:

  1. `packages/core` — Core logic and foundations

Monorepo Navigation

This is a npm/yarn workspaces monorepo with 3 packages. Here's how to navigate:

PackageLocationWhat It Does
@nestjs/commonpackages/commonUtility libraries
@nestjs/corepackages/coreCore functionality and shared code
@nestjs/platform-expresspackages/platform-expressPackage functionality

Pro tip: Each package can typically be developed independently. Check the package's own README.md for specific setup instructions.


Technology Stack

LayerTechnologiesWhat to Learn
FrameworkExpress, FastifyUnderstand middleware chains and route handling
LanguageTypeScript, Node.jsStrong typing — check types when debugging
BuildViteUnderstand the build pipeline
TestingVitestRun existing tests to understand behavior

Core Modules to Understand

These are the most important modules by size and centrality. Understanding them will unlock the rest of the codebase:

PriorityModuleFilesTypeWhy It Matters
⭐ Highpackages/common/interfaces71Shared LibrariesShared code — reused throughout
⭐ Highpackages/core/router32Route/Page ModulesLarge module — core functionality
⭐ Highpackages/core/injector30coreLarge module — core functionality
Mediumpackages/common/decorators29Shared LibrariesShared code — reused throughout
Mediumpackages/core/helpers27Shared LibrariesShared code — reused throughout
Mediumpackages/core/errors26coreLarge module — core functionality
Lowpackages/common/exceptions24Shared LibrariesShared code — reused throughout
Lowpackages/common/pipes21Shared LibrariesShared code — reused throughout
Lowpackages/core/repl16coreKey system component
Lowpackages/common/utils15Shared LibrariesShared code — reused throughout

Key Routes

Understanding the routing structure helps you trace user interactions through the system.

API Endpoints
EndpointMethodsFilePurpose
*pathALLpackages/platform-express/adapters/express-adapter.tsData operations

How Data Flows

Understanding these flows helps you see how the system processes information end-to-end:

FlowDescriptionKey Modules
internal Request FlowImport chain starting from packages/core/internal — traces...internal, instance-wrapper
core Request FlowImport chain starting from packages/core — traces how this...core, application-config
internal Request FlowImport chain starting from packages/common/internal — trac...internal, shared.utils
platform-express Request FlowImport chain starting from packages/platform-express — tra...platform-express, adapters
controllers Request FlowImport chain starting from `packages/common/interfaces/contr...controllers, controller-metadata.interface

Debugging tip: When investigating issues, trace the data flow from input to output to identify where problems occur.


Getting Started Checklist

Follow these steps to set up your development environment:

1. Clone and Install
git clone <repository-url>
cd nestjs
npm install  # or yarn, pnpm
2. Explore the Structure
  • Review the directory structure above
  • Open the README.md for project-specific instructions
  • Look for CONTRIBUTING.md for contribution guidelines
3. Understand Core Modules

Start with the high-priority modules listed above. Read the code and comments to understand:

  • What problem each module solves
  • How modules interact with each other
  • What data structures are used
4. Run the Tests
npm test  # or: npx vitest run

Running tests helps you:

  • Verify your setup is correct
  • See expected behavior documented in test cases
  • Understand module interfaces through test examples
5. Make Your First Change

Start small:

  1. Find a small bug or typo to fix
  2. Make the change in a feature branch
  3. Run tests to ensure nothing breaks
  4. Submit a pull request for review

Common Pitfalls

New contributors often run into these issues:

  • Circular dependencies — This codebase has 50 circular imports. Be careful not to introduce more.
  • Monorepo boundaries — Remember to build dependent packages when making changes.
  • Environment setup — Check for .env.example files and ensure you have all required environment variables.
  • Branch naming — Follow the team's branch naming conventions (usually feature/, fix/, docs/).

Additional Resources

ResourcePurpose
README.mdProject overview and quick start
CONTRIBUTING.mdContribution guidelines (if exists)
CHANGELOG.mdRecent changes and release history
package.jsonAvailable scripts and dependencies
Root package.jsonMonorepo workspace configuration

This onboarding guide was generated from comprehensive repository analysis. Enable AI enhancement with `GITHUB_TOKEN` for narrative walkthroughs, common pitfall documentation, debugging tips, architecture deep-dives, and personalized contribution recommendations.

Welcome to the team! Happy coding! 🚀

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

GraphQL Schema

Engineers · GraphQL types, queries, mutations, and resolver map

libraries: type-graphql

Libraries and Frameworks

The following GraphQL libraries and frameworks were detected in the project dependencies:

LibraryStatus
type-graphqlDetected

Generated by RepoLens extended analysis. Schema detection is based on static analysis of source files and may not capture runtime-only definitions.

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

TypeScript Type Graph

Engineers · TypeScript interfaces, types, classes, and relationships

265 file(s) with type declarations · 140 interface(s) · 103 type alias(es) · 154 class(es) · 7 enum(s) · 116 relationship(s)

This document maps the type system of the project, showing how interfaces, classes, and type aliases relate to one another. Understanding these relationships helps navigate the codebase and identify coupling between modules.

Interfaces

140 interfaces define the data contracts used across the application:

InterfaceExtendsSource
ControllerOptionsScopeOptions, VersionOptionspackages/common/decorators/core/controller.decorator.ts
RequestMappingMetadata—packages/common/decorators/http/request-mapping.decorator.ts
ParameterDecoratorOptions—packages/common/decorators/http/route-params.decorator.ts
ResponseDecoratorOptions—packages/common/decorators/http/route-params.decorator.ts
RouteParamMetadata—packages/common/decorators/http/route-params.decorator.ts
SseOptions—packages/common/decorators/http/sse.decorator.ts
HttpExceptionOptions—packages/common/exceptions/http.exception.ts
DescriptionAndOptions—packages/common/exceptions/http.exception.ts
StreamableHandlerResponse—packages/common/file-stream/interfaces/streamable-handler-response.interface.ts
StreamableFileOptions—packages/common/file-stream/interfaces/streamable-options.interface.ts
GetOrResolveOptions—packages/common/interfaces/nest-application-context.interface.ts
INestApplicationContext—packages/common/interfaces/nest-application-context.interface.ts
NestApplicationOptionsNestApplicationContextOptionspackages/common/interfaces/nest-application-options.interface.ts
INestMicroserviceINestApplicationContextpackages/common/interfaces/nest-microservice.interface.ts
RouteConflictPolicy—packages/common/interfaces/router-options.interface.ts
ScopeOptions—packages/common/interfaces/scope-options.interface.ts
ShutdownHooksOptions—packages/common/interfaces/shutdown-hooks-options.interface.ts
VersionOptions—packages/common/interfaces/version-options.interface.ts
HeaderVersioningOptions—packages/common/interfaces/version-options.interface.ts
UriVersioningOptions—packages/common/interfaces/version-options.interface.ts
MediaTypeVersioningOptions—packages/common/interfaces/version-options.interface.ts
CustomVersioningOptions—packages/common/interfaces/version-options.interface.ts
VersioningCommonOptions—packages/common/interfaces/version-options.interface.ts
ControllerMetadata—packages/common/interfaces/controllers/controller-metadata.interface.ts
ExceptionFilterMetadata—packages/common/interfaces/exceptions/exception-filter-metadata.interface.ts
RpcExceptionFilterMetadata—packages/common/interfaces/exceptions/rpc-exception-filter-metadata.interface.ts
ClassTransformOptions—packages/common/interfaces/external/class-transform-options.interface.ts
CorsOptions—packages/common/interfaces/external/cors-options.interface.ts
CorsOptionsCallback—packages/common/interfaces/external/cors-options.interface.ts
HttpsOptions—packages/common/interfaces/external/https-options.interface.ts
TransformerPackage—packages/common/interfaces/external/transformer-package.interface.ts
ValidationError—packages/common/interfaces/external/validation-error.interface.ts
ValidatorOptions—packages/common/interfaces/external/validator-options.interface.ts
ValidatorPackage—packages/common/interfaces/external/validator-package.interface.ts
HttpArgumentsHost—packages/common/interfaces/features/arguments-host.interface.ts
WsArgumentsHost—packages/common/interfaces/features/arguments-host.interface.ts
RpcArgumentsHost—packages/common/interfaces/features/arguments-host.interface.ts
ArgumentsHost—packages/common/interfaces/features/arguments-host.interface.ts
CanActivate—packages/common/interfaces/features/can-activate.interface.ts
ExecutionContextArgumentsHostpackages/common/interfaces/features/execution-context.interface.ts
BeforeApplicationShutdown—packages/common/interfaces/hooks/before-application-shutdown.interface.ts
OnApplicationBootstrap—packages/common/interfaces/hooks/on-application-bootstrap.interface.ts
OnApplicationShutdown—packages/common/interfaces/hooks/on-application-shutdown.interface.ts
OnModuleDestroy—packages/common/interfaces/hooks/on-destroy.interface.ts
OnModuleInit—packages/common/interfaces/hooks/on-init.interface.ts
CookieSerializeOptions—packages/common/interfaces/http/cookie-options.interface.ts
CookiesOptions—packages/common/interfaces/http/cookie-options.interface.ts
HttpExceptionBody—packages/common/interfaces/http/http-exception-body.interface.ts
HttpRedirectResponse—packages/common/interfaces/http/http-redirect-response.interface.ts
RouteMatchingOptions—packages/common/interfaces/http/http-server.interface.ts
MessageEvent—packages/common/interfaces/http/message-event.interface.ts
ContentSecurityPolicyOptions—packages/common/interfaces/http/security-headers-options.interface.ts
SecurityHeadersOptions—packages/common/interfaces/http/security-headers-options.interface.ts
NestHybridApplicationOptions—packages/common/interfaces/microservices/nest-hybrid-application-options.interface.ts
PreRequestHook—packages/common/interfaces/microservices/pre-request-hook.interface.ts
ITransportServer—packages/common/interfaces/microservices/transport-server.interface.ts
MiddlewareConfigProxy—packages/common/interfaces/middleware/middleware-config-proxy.interface.ts
RouteInfo—packages/common/interfaces/middleware/middleware-configuration.interface.ts
MiddlewareConsumer—packages/common/interfaces/middleware/middleware-consumer.interface.ts
DynamicModuleModuleMetadatapackages/common/interfaces/modules/dynamic-module.interface.ts
IntrospectionResult—packages/common/interfaces/modules/introspection-result.interface.ts
ModuleMetadata—packages/common/interfaces/modules/module-metadata.interface.ts
NestModule—packages/common/interfaces/modules/nest-module.interface.ts
ConfigurableModuleBuilderOptions—packages/common/module-utils/configurable-module.builder.ts
ParseBoolPipeOptions—packages/common/pipes/parse-bool.pipe.ts
ParseDatePipeOptions—packages/common/pipes/parse-date.pipe.ts
ParseEnumPipeOptions—packages/common/pipes/parse-enum.pipe.ts
ParseFloatPipeOptions—packages/common/pipes/parse-float.pipe.ts
ParseIntPipeOptions—packages/common/pipes/parse-int.pipe.ts
ParseUUIDPipeOptions—packages/common/pipes/parse-uuid.pipe.ts
StandardSchemaValidationPipeOptions—packages/common/pipes/standard-schema-validation.pipe.ts
ValidationPipeOptionsValidatorOptionspackages/common/pipes/validation.pipe.ts
ParseFileOptions—packages/common/pipes/file/parse-file-options.interface.ts
IFile—packages/common/pipes/file/interfaces/file.interface.ts
PlainLiteralObject—packages/common/serializer/class-serializer.interceptor.ts
ClassSerializerInterceptorOptionsClassTransformOptionspackages/common/serializer/class-serializer.interceptor.ts
ClassSerializerContextOptionsClassTransformOptionspackages/common/serializer/class-serializer.interfaces.ts
PlainLiteralObject—packages/common/serializer/standard-schema-serializer.interceptor.ts
StandardSchemaSerializerInterceptorOptions—packages/common/serializer/standard-schema-serializer.interceptor.ts
StandardSchemaSerializerContextOptions—packages/common/serializer/standard-schema-serializer.interfaces.ts
ConsoleLoggerOptions—packages/common/services/console-logger.service.ts
LoggerService—packages/common/services/logger.service.ts
LogBufferRecord—packages/common/services/logger.service.ts
ApplicationProviderWrapper—packages/core/scanner.ts
ModulesScanParameters—packages/core/scanner.ts
FilterByInclude—packages/core/discovery/discovery-service.ts
FilterByMetadataKey—packages/core/discovery/discovery-service.ts
ContextIdResolver—packages/core/helpers/context-id-factory.ts
ParamsFactory—packages/core/helpers/external-context-creator.ts
ExternalContextOptions—packages/core/helpers/external-context-creator.ts
HandlerMetadata—packages/core/helpers/handler-metadata-storage.ts
ExternalHandlerMetadata—packages/core/helpers/interfaces/external-handler-metadata.interface.ts
ParamMetadata—packages/core/helpers/interfaces/params-metadata.interface.ts
ModuleFactory—packages/core/injector/compiler.ts
PropertyDependency—packages/core/injector/injector.ts
InjectorDependencyContext—packages/core/injector/injector.ts
ResolutionContext—packages/core/injector/injector.ts
HostComponentInfo—packages/core/injector/instance-wrapper.ts
ContextId—packages/core/injector/instance-wrapper.ts
PropertyMetadata—packages/core/injector/instance-wrapper.ts
InstanceMetadataStore—packages/core/injector/instance-wrapper.ts
ModuleRefGetOrResolveOpts—packages/core/injector/module-ref.ts
SettlementSignalRef—packages/core/injector/settlement-signal.ts
LazyModuleLoaderLoadOptions—packages/core/injector/lazy-module-loader/lazy-module-loader-options.interface.ts
ModuleOpaqueKeyFactory—packages/core/injector/opaque-key-factory/interfaces/module-opaque-key-factory.interface.ts
Edge—packages/core/inspector/interfaces/edge.interface.ts
EnhancerMetadataCacheEntry—packages/core/inspector/interfaces/enhancer-metadata-cache-entry.interface.ts
AttachedEnhancerDefinition—packages/core/inspector/interfaces/extras.interface.ts
OrphanedEnhancerDefinition—packages/core/inspector/interfaces/extras.interface.ts
Extras—packages/core/inspector/interfaces/extras.interface.ts
SerializedGraphJson—packages/core/inspector/interfaces/serialized-graph-json.interface.ts
SerializedGraphMetadata—packages/core/inspector/interfaces/serialized-graph-metadata.interface.ts
ModuleOverride—packages/core/interfaces/module-override.interface.ts
RouteDefinition—packages/core/router/paths-explorer.ts
PathSegment—packages/core/router/route-conflict-detector.ts
ParamProperties—packages/core/router/router-execution-context.ts
RouteDefinition—packages/core/router/router-explorer.ts
CustomHeader—packages/core/router/router-response-controller.ts
RedirectResponse—packages/core/router/router-response-controller.ts
ReadHeaders—packages/core/router/sse-stream.ts
WriteHeaders—packages/core/router/sse-stream.ts
ExceptionsFilter—packages/core/router/interfaces/exceptions-filter.interface.ts
ExcludeRouteMetadata—packages/core/router/interfaces/exclude-route-metadata.interface.ts
ResolvedRoute—packages/core/router/interfaces/resolved-route.interface.ts
Resolver—packages/core/router/interfaces/resolver.interface.ts
RouteConflict—packages/core/router/interfaces/route-conflict.interface.ts
IRouteParamsFactory—packages/core/router/interfaces/route-params-factory.interface.ts
RoutePathMetadata—packages/core/router/interfaces/route-path-metadata.interface.ts
RouteResolutionOptions—packages/core/router/interfaces/route-resolution-options.interface.ts
RouteTree—packages/core/router/interfaces/routes.interface.ts
CrossOriginRequestInfo—packages/core/security/cross-origin-protection.ts
CrossOriginExemptions—packages/core/security/cross-origin-protection.ts
ResolvedSecurityHeaders—packages/core/security/security-headers.ts
NestExpressBodyParserOptions—packages/platform-express/interfaces/nest-express-body-parser-options.interface.ts
NestExpressBodyParserOptionsMap—packages/platform-express/interfaces/nest-express-body-parser.interface.ts
ServeStaticOptions—packages/platform-express/interfaces/serve-static-options.interface.ts
MulterOptionsFactory—packages/platform-express/multer/interfaces/files-upload-module.interface.ts
MulterLimits—packages/platform-express/multer/interfaces/multer-options.interface.ts
MulterOptions—packages/platform-express/multer/interfaces/multer-options.interface.ts
MulterField—packages/platform-express/multer/interfaces/multer-options.interface.ts

Classes

154 classes provide concrete implementations:

ClassExtendsImplementsSource
BadGatewayExceptionHttpException—packages/common/exceptions/bad-gateway.exception.ts
BadRequestExceptionHttpException—packages/common/exceptions/bad-request.exception.ts
ConflictExceptionHttpException—packages/common/exceptions/conflict.exception.ts
ForbiddenExceptionHttpException—packages/common/exceptions/forbidden.exception.ts
GatewayTimeoutExceptionHttpException—packages/common/exceptions/gateway-timeout.exception.ts
GoneExceptionHttpException—packages/common/exceptions/gone.exception.ts
HttpVersionNotSupportedExceptionHttpException—packages/common/exceptions/http-version-not-supported.exception.ts
HttpExceptionIntrinsicException—packages/common/exceptions/http.exception.ts
ImATeapotExceptionHttpException—packages/common/exceptions/im-a-teapot.exception.ts
InternalServerErrorExceptionHttpException—packages/common/exceptions/internal-server-error.exception.ts
IntrinsicExceptionError—packages/common/exceptions/intrinsic.exception.ts
MethodNotAllowedExceptionHttpException—packages/common/exceptions/method-not-allowed.exception.ts
MisdirectedExceptionHttpException—packages/common/exceptions/misdirected.exception.ts
NotAcceptableExceptionHttpException—packages/common/exceptions/not-acceptable.exception.ts
NotFoundExceptionHttpException—packages/common/exceptions/not-found.exception.ts
NotImplementedExceptionHttpException—packages/common/exceptions/not-implemented.exception.ts
PayloadTooLargeExceptionHttpException—packages/common/exceptions/payload-too-large.exception.ts
PreconditionFailedExceptionHttpException—packages/common/exceptions/precondition-failed.exception.ts
RequestTimeoutExceptionHttpException—packages/common/exceptions/request-timeout.exception.ts
ServiceUnavailableExceptionHttpException—packages/common/exceptions/service-unavailable.exception.ts
UnauthorizedExceptionHttpException—packages/common/exceptions/unauthorized.exception.ts
UnprocessableEntityExceptionHttpException—packages/common/exceptions/unprocessable-entity.exception.ts
UnsupportedMediaTypeExceptionHttpException—packages/common/exceptions/unsupported-media-type.exception.ts
StreamableFile——packages/common/file-stream/streamable-file.ts
NestApplicationContextOptions——packages/common/interfaces/nest-application-context-options.interface.ts
InternalModuleClass——packages/common/module-utils/configurable-module.builder.ts
IntegrationModuleConfigurableModuleCls—packages/common/module-utils/interfaces/configurable-module-host.interface.ts
IntegrationModuleConfigurableModuleCls—packages/common/module-utils/interfaces/configurable-module-host.interface.ts
IntegrationModuleConfigurableModuleCls—packages/common/module-utils/interfaces/configurable-module-host.interface.ts
ParseArrayPipe—PipeTransformpackages/common/pipes/parse-array.pipe.ts
ParseBoolPipe—PipeTransformpackages/common/pipes/parse-bool.pipe.ts
ParseDatePipe—PipeTransformpackages/common/pipes/parse-date.pipe.ts
ParseFloatPipe—PipeTransformpackages/common/pipes/parse-float.pipe.ts
ParseIntPipe—PipeTransformpackages/common/pipes/parse-int.pipe.ts
ParseUUIDPipe—PipeTransformpackages/common/pipes/parse-uuid.pipe.ts
StandardSchemaValidationPipe—PipeTransformpackages/common/pipes/standard-schema-validation.pipe.ts
ValidationPipe—PipeTransformpackages/common/pipes/validation.pipe.ts
ParseFilePipeBuilder——packages/common/pipes/file/parse-file-pipe.builder.ts
ParseFilePipe—PipeTransformpackages/common/pipes/file/parse-file.pipe.ts
ClassSerializerInterceptor—NestInterceptorpackages/common/serializer/class-serializer.interceptor.ts
StandardSchemaSerializerInterceptor—NestInterceptorpackages/common/serializer/standard-schema-serializer.interceptor.ts
return——packages/common/serializer/standard-schema-serializer.interceptor.ts
ConsoleLogger—LoggerServicepackages/common/services/console-logger.service.ts
Logger—LoggerServicepackages/common/services/logger.service.ts
InvalidDecoratorItemExceptionError—packages/common/utils/validate-each.util.ts
ApplicationConfig——packages/core/application-config.ts
MetadataScanner——packages/core/metadata-scanner.ts
NestFactoryStatic——packages/core/nest-factory.ts
DependenciesScanner——packages/core/scanner.ts
DiscoverableMetaHostCollection——packages/core/discovery/discoverable-meta-host-collection.ts
DiscoveryModule——packages/core/discovery/discovery-module.ts
DiscoveryService——packages/core/discovery/discovery-service.ts
ExceptionHandler——packages/core/errors/exception-handler.ts
ExceptionsZone——packages/core/errors/exceptions-zone.ts
CircularDependencyExceptionRuntimeException—packages/core/errors/exceptions/circular-dependency.exception.ts
InvalidClassModuleExceptionRuntimeException—packages/core/errors/exceptions/invalid-class-module.exception.ts
InvalidClassScopeExceptionRuntimeException—packages/core/errors/exceptions/invalid-class-scope.exception.ts
InvalidClassExceptionRuntimeException—packages/core/errors/exceptions/invalid-class.exception.ts
InvalidExceptionFilterExceptionRuntimeException—packages/core/errors/exceptions/invalid-exception-filter.exception.ts
InvalidMiddlewareConfigurationExceptionRuntimeException—packages/core/errors/exceptions/invalid-middleware-configuration.exception.ts
InvalidMiddlewareExceptionRuntimeException—packages/core/errors/exceptions/invalid-middleware.exception.ts
InvalidModuleExceptionRuntimeException—packages/core/errors/exceptions/invalid-module.exception.ts
InvalidProviderExceptionRuntimeException—packages/core/errors/exceptions/invalid-provider.exception.ts
RequestScopedCreateExceptionRuntimeException—packages/core/errors/exceptions/request-scoped-create.exception.ts
RequestScopedGlobalEnhancerExceptionRuntimeException—packages/core/errors/exceptions/request-scoped-global-enhancer.exception.ts
RouteConflictExceptionRuntimeException—packages/core/errors/exceptions/route-conflict.exception.ts
RuntimeExceptionError—packages/core/errors/exceptions/runtime.exception.ts
UndefinedDependencyExceptionRuntimeException—packages/core/errors/exceptions/undefined-dependency.exception.ts
UndefinedForwardRefExceptionRuntimeException—packages/core/errors/exceptions/undefined-forwardref.exception.ts
UndefinedModuleExceptionRuntimeException—packages/core/errors/exceptions/undefined-module.exception.ts
UninstantiatedGlobalEnhancerExceptionRuntimeException—packages/core/errors/exceptions/uninstantiated-global-enhancer.exception.ts
UnknownDependenciesExceptionRuntimeException—packages/core/errors/exceptions/unknown-dependencies.exception.ts
UnknownElementExceptionRuntimeException—packages/core/errors/exceptions/unknown-element.exception.ts
UnknownExportExceptionRuntimeException—packages/core/errors/exceptions/unknown-export.exception.ts
UnknownModuleExceptionRuntimeException—packages/core/errors/exceptions/unknown-module.exception.ts
UnknownRequestMappingExceptionRuntimeException—packages/core/errors/exceptions/unknown-request-mapping.exception.ts
BaseExceptionFilterContextContextCreator—packages/core/exceptions/base-exception-filter-context.ts
ExceptionsHandlerBaseExceptionFilter—packages/core/exceptions/exceptions-handler.ts
ExternalExceptionFilterContextBaseExceptionFilterContext—packages/core/exceptions/external-exception-filter-context.ts
ExternalExceptionsHandlerExternalExceptionFilter—packages/core/exceptions/external-exceptions-handler.ts
GuardsConsumer——packages/core/guards/guards-consumer.ts
GuardsContextCreatorContextCreator—packages/core/guards/guards-context-creator.ts
Barrier——packages/core/helpers/barrier.ts
ContextCreator——packages/core/helpers/context-creator.ts
ContextIdFactory——packages/core/helpers/context-id-factory.ts
ContextUtils——packages/core/helpers/context-utils.ts
ExecutionContextHost—ExecutionContextpackages/core/helpers/execution-context-host.ts
ExternalContextCreator——packages/core/helpers/external-context-creator.ts
ExternalErrorProxy——packages/core/helpers/external-proxy.ts
RouterMethodFactory——packages/core/helpers/router-method-factory.ts
CookieSigner——packages/core/helpers/cookies/cookie-signer.ts
AbstractInstanceResolver——packages/core/injector/abstract-instance-resolver.ts
ModuleCompiler——packages/core/injector/compiler.ts
NestContainer——packages/core/injector/container.ts
HostSettlementRef——packages/core/injector/injector.ts
Injector——packages/core/injector/injector.ts
InstanceLinksHost——packages/core/injector/instance-links-host.ts
InternalProvidersStorage——packages/core/injector/internal-providers-storage.ts
ModuleRefAbstractInstanceResolver—packages/core/injector/module-ref.ts
Module——packages/core/injector/module.ts
SettlementSignal——packages/core/injector/settlement-signal.ts
SilentLoggerLogger—packages/core/injector/helpers/silent-logger.ts
InternalCoreModuleFactory——packages/core/injector/internal-core-module/internal-core-module-factory.ts
InternalCoreModule——packages/core/injector/internal-core-module/internal-core-module.ts
LazyModuleLoader——packages/core/injector/lazy-module-loader/lazy-module-loader.ts
ByReferenceModuleOpaqueKeyFactory—ModuleOpaqueKeyFactorypackages/core/injector/opaque-key-factory/by-reference-module-opaque-key-factory.ts
DeepHashedModuleOpaqueKeyFactory—ModuleOpaqueKeyFactorypackages/core/injector/opaque-key-factory/deep-hashed-module-opaque-key-factory.ts
TopologyTree——packages/core/injector/topology-tree/topology-tree.ts
DeterministicUuidRegistry——packages/core/inspector/deterministic-uuid-registry.ts
GraphInspector——packages/core/inspector/graph-inspector.ts
InitializeOnPreviewAllowlist——packages/core/inspector/initialize-on-preview.allowlist.ts
PartialGraphHost——packages/core/inspector/partial-graph.host.ts
SerializedGraph——packages/core/inspector/serialized-graph.ts
UuidFactory——packages/core/inspector/uuid-factory.ts
InterceptorsConsumer——packages/core/interceptors/interceptors-consumer.ts
InterceptorsContextCreatorContextCreator—packages/core/interceptors/interceptors-context-creator.ts
MiddlewareBuilder—MiddlewareConsumerpackages/core/middleware/builder.ts
MiddlewareContainer——packages/core/middleware/container.ts
MiddlewareResolver——packages/core/middleware/resolver.ts
RouteInfoPathExtractor——packages/core/middleware/route-info-path-extractor.ts
RoutesMapper——packages/core/middleware/routes-mapper.ts
ParamsTokenFactory——packages/core/pipes/params-token-factory.ts
PipesConsumer——packages/core/pipes/pipes-consumer.ts
PipesContextCreatorContextCreator—packages/core/pipes/pipes-context-creator.ts
ReplContext——packages/core/repl/repl-context.ts
ReplLoggerConsoleLogger—packages/core/repl/repl-logger.ts
DebugReplFnReplFunction—packages/core/repl/native-functions/debug-repl-fn.ts
GetReplFnReplFunction—packages/core/repl/native-functions/get-repl-fn.ts
HelpReplFnReplFunction—packages/core/repl/native-functions/help-repl-fn.ts
MethodsReplFnReplFunction—packages/core/repl/native-functions/methods-repl-fn.ts
ResolveReplFnReplFunction—packages/core/repl/native-functions/resolve-repl-fn.ts
SelectReplFnReplFunction—packages/core/repl/native-functions/select-relp-fn.ts
LegacyRouteConverter——packages/core/router/legacy-route-converter.ts
PathsExplorer——packages/core/router/paths-explorer.ts
RouteConflictDetector——packages/core/router/route-conflict-detector.ts
RouteParamsFactory—IRouteParamsFactorypackages/core/router/route-params-factory.ts
RoutePathFactory——packages/core/router/route-path-factory.ts
RouteSpecificitySorter——packages/core/router/route-specificity-sorter.ts
RouterExceptionFiltersBaseExceptionFilterContext—packages/core/router/router-exception-filters.ts
RouterExecutionContext——packages/core/router/router-execution-context.ts
RouterExplorer——packages/core/router/router-explorer.ts
RouterModule——packages/core/router/router-module.ts
RouterProxy——packages/core/router/router-proxy.ts
RouterResponseController——packages/core/router/router-response-controller.ts
RoutesResolver—Resolverpackages/core/router/routes-resolver.ts
SseStreamTransform—packages/core/router/sse-stream.ts
SecurityHeadersConfigurationErrorError—packages/core/security/security-headers.ts
Reflector——packages/core/services/reflector.service.ts
MulterModule——packages/platform-express/multer/multer.module.ts
MixinInterceptor—NestInterceptorpackages/platform-express/multer/interceptors/any-files.interceptor.ts
MixinInterceptor—NestInterceptorpackages/platform-express/multer/interceptors/file-fields.interceptor.ts
MixinInterceptor—NestInterceptorpackages/platform-express/multer/interceptors/file.interceptor.ts
MixinInterceptor—NestInterceptorpackages/platform-express/multer/interceptors/files.interceptor.ts
MixinInterceptor—NestInterceptorpackages/platform-express/multer/interceptors/no-files.interceptor.ts

Type Aliases

103 type aliases define computed or composite types:

TypeReferencesSource
EnhancerSubtypeENHANCER_KEY_TO_SUBTYPE_MAPpackages/common/constants.ts
InjectableOptionsScopeOptionspackages/common/decorators/core/injectable.decorator.ts
CustomDecoratorMethodDecorator, ClassDecorator, KEY, TKeypackages/common/decorators/core/set-metadata.decorator.ts
ParamDecoratorEnhancerParameterDecoratorpackages/common/decorators/http/create-route-param-metadata.decorator.ts
ParamData—packages/common/decorators/http/route-params.decorator.ts
Injectable—packages/common/interfaces/injectable.interface.ts
SelectOptionsNestApplicationContextOptionspackages/common/interfaces/nest-application-context.interface.ts
RouteConflictPolicyLevel—packages/common/interfaces/router-options.interface.ts
RouteResolutionStrategy—packages/common/interfaces/router-options.interface.ts
VersionValueVERSION_NEUTRALpackages/common/interfaces/version-options.interface.ts
VersioningOptionsVersioningCommonOptions, HeaderVersioningOptions, UriVersioningOptions, MediaTypeVersioningOptions, CustomVersioningOptionspackages/common/interfaces/version-options.interface.ts
Controller—packages/common/interfaces/controllers/controller.interface.ts
StaticOrigin—packages/common/interfaces/external/cors-options.interface.ts
CustomOriginStaticOriginpackages/common/interfaces/external/cors-options.interface.ts
ContextType—packages/common/interfaces/features/arguments-host.interface.ts
CustomParamFactoryTData, ExecutionContext, TOutputpackages/common/interfaces/features/custom-route-param-factory.interface.ts
Paramtype—packages/common/interfaces/features/paramtype.interface.ts
TransformT, ArgumentMetadatapackages/common/interfaces/features/pipe-transform.interface.ts
HttpExceptionBodyMessage—packages/common/interfaces/http/http-exception-body.interface.ts
ErrorHandlerTRequest, TResponse, Functionpackages/common/interfaces/http/http-server.interface.ts
RequestHandlerTRequest, TResponse, Functionpackages/common/interfaces/http/http-server.interface.ts
SecurityRequestHookTRequestpackages/common/interfaces/http/http-server.interface.ts
RawBodyRequestTpackages/common/interfaces/http/raw-body-request.interface.ts
ContentSecurityPolicyDirectiveValue—packages/common/interfaces/http/security-headers-options.interface.ts
ReferrerPolicyToken—packages/common/interfaces/http/security-headers-options.interface.ts
NestMicroserviceOptionsNestApplicationContextOptionspackages/common/interfaces/microservices/nest-microservice-options.interface.ts
InjectionTokenType, T, Abstract, Functionpackages/common/interfaces/modules/injection-token.interface.ts
OptionalFactoryDependencyInjectionTokenpackages/common/interfaces/modules/optional-factory-dependency.interface.ts
ProviderType, ClassProvider, T, ValueProvider, FactoryProvider, ExistingProviderpackages/common/interfaces/modules/provider.interface.ts
ConfigurableModuleOptionsFactoryFactoryClassMethodKey, ModuleOptionspackages/common/module-utils/interfaces/configurable-module-async-options.interface.ts
ConfigurableModuleCls—packages/common/module-utils/interfaces/configurable-module-cls.interface.ts
ParseArrayOptionsParseArrayPipeOptionspackages/common/pipes/parse-array.pipe.ts
UUIDVersion—packages/common/pipes/parse-uuid.pipe.ts
ValidationErrorFormat—packages/common/pipes/validation.pipe.ts
FileTypeValidatorContextFileValidatorContext, FileTypeValidatorOptionspackages/common/pipes/file/file-type.validator.ts
FileTypeValidatorOptionsExpected, Can, MIME, A, Matchpackages/common/pipes/file/file-type.validator.ts
FileValidatorContextIFilepackages/common/pipes/file/file-validator-context.interface.ts
MaxFileSizeValidatorContextFileValidatorContext, MaxFileSizeValidatorOptionspackages/common/pipes/file/max-file-size.validator.ts
MaxFileSizeValidatorOptionsMaximumpackages/common/pipes/file/max-file-size.validator.ts
JsonLogObjectLogLevelpackages/common/services/console-logger.service.ts
LogLevelLOG_LEVELSpackages/common/services/log-levels.constant.ts
Redactor—packages/common/services/utils/redact.util.ts
ColorTextFn—packages/common/utils/cli-colors.util.ts
ErrorHttpStatusCodeHttpStatus, BAD_GATEWAY, BAD_REQUEST, CONFLICT, FORBIDDEN, GATEWAY_TIMEOUT, GONE, HTTP_VERSION_NOT_SUPPORTED, I_AM_A_TEAPOT, INTERNAL_SERVER_ERROR, METHOD_NOT_ALLOWED, MISDIRECTED, NOT_ACCEPTABLE, NOT_FOUND, NOT_IMPLEMENTED, PAYLOAD_TOO_LARGE, PRECONDITION_FAILED, REQUEST_TIMEOUT, SERVICE_UNAVAILABLE, UNAUTHORIZED, UNPROCESSABLE_ENTITY, UNSUPPORTED_MEDIA_TYPEpackages/common/utils/http-error-by-code.util.ts
ConstructorTpackages/common/utils/merge-with-values.util.ts
IEntryNestModuleType, DynamicModule, ForwardReference, IEntryNestModulepackages/core/nest-factory.ts
DiscoveryOptionsFilterByInclude, FilterByMetadataKeypackages/core/discovery/discovery-service.ts
DiscoverableDecoratorT, CustomDecorator, KEYpackages/core/discovery/discovery-service.ts
ContextIdResolverFnHostComponentInfo, ContextIdpackages/core/helpers/context-id-factory.ts
HandleResponseFnHandlerResponseBasicFn, HandleSseResponseFnpackages/core/helpers/handler-metadata-storage.ts
HandlerResponseBasicFnTResult, TResponse, Observable, StreamableFilepackages/core/helpers/handler-metadata-storage.ts
HandleSseResponseFnTResult, Observable, TResponse, HeaderStream, TRequest, IncomingMessagepackages/core/helpers/handler-metadata-storage.ts
InstanceDecorator—packages/core/helpers/safe-instance-decorator.ts
CookieRecord—packages/core/helpers/cookies/parse-cookie-header.ts
ParamPropertiesWithMetatypeParamProperties, Tpackages/core/helpers/interfaces/external-handler-metadata.interface.ts
ParamsMetadataParamMetadatapackages/core/helpers/interfaces/params-metadata.interface.ts
ModuleMetatypeType, DynamicModulepackages/core/injector/container.ts
ModuleScopeTypepackages/core/injector/container.ts
InjectorDependencyInjectionTokenpackages/core/injector/injector.ts
HostCollection—packages/core/injector/instance-links-host.ts
SerializedGraphStatus—packages/core/inspector/serialized-graph.ts
CommonEdgeMetadata—packages/core/inspector/interfaces/edge.interface.ts
ModuleToModuleEdgeMetadata—packages/core/inspector/interfaces/edge.interface.ts
ClassToClassEdgeMetadata—packages/core/inspector/interfaces/edge.interface.ts
HttpEntrypointMetadata—packages/core/inspector/interfaces/entrypoint.interface.ts
MiddlewareEntrypointMetadata—packages/core/inspector/interfaces/entrypoint.interface.ts
Entrypoint—packages/core/inspector/interfaces/entrypoint.interface.ts
ModuleNode—packages/core/inspector/interfaces/node.interface.ts
ClassNode—packages/core/inspector/interfaces/node.interface.ts
Node—packages/core/inspector/interfaces/node.interface.ts
ModuleDefinitionForwardReference, Type, DynamicModulepackages/core/interfaces/module-definition.interface.ts
ModuleKey—packages/core/repl/repl-context.ts
ModuleDebugEntryInjectionTokenpackages/core/repl/repl-context.ts
ReplScope—packages/core/repl/repl-context.ts
ReplFnDefinitionFunction, Note, JavaScriptpackages/core/repl/repl.interfaces.ts
ReplFunctionClassReplContext, ReplFunctionpackages/core/repl/repl.interfaces.ts
SegmentKind—packages/core/router/route-conflict-detector.ts
SegmentKindOrMissing—packages/core/router/route-specificity-sorter.ts
RouterProxyCallbackTRequest, TResponsepackages/core/router/router-proxy.ts
AdditionalHeaders—packages/core/router/sse-stream.ts
AdditionalHeadersSourceAdditionalHeaderspackages/core/router/sse-stream.ts
StatusCodeSource—packages/core/router/sse-stream.ts
WritableHeaderStreamNodeJS, WritableStream, WriteHeaderspackages/core/router/sse-stream.ts
HeaderStreamWritableHeaderStream, ReadHeaderspackages/core/router/sse-stream.ts
ResolvedRouteHandler—packages/core/router/interfaces/resolved-route.interface.ts
ConflictKind—packages/core/router/interfaces/route-conflict.interface.ts
RoutesRouteTreepackages/core/router/interfaces/routes.interface.ts
CrossOriginAllowedReason—packages/core/security/cross-origin-protection.ts
CrossOriginDeniedReason—packages/core/security/cross-origin-protection.ts
CrossOriginDecision—packages/core/security/cross-origin-protection.ts
OptionObjectExtract, NonNullable, SecurityHeadersOptions, Kpackages/core/security/security-headers.ts
CreateDecoratorWithTransformOptionsCreateDecoratorOptions, TParam, TTransformedpackages/core/services/reflector.service.ts
ReflectableDecoratorTParam, CustomDecorator, KEYpackages/core/services/reflector.service.ts
VersionedRouteTRequest, TResponsepackages/platform-express/adapters/express-adapter.ts
Express—packages/platform-express/interfaces/nest-express-body-parser.interface.ts
NestExpressBodyParserTypeNestExpressBodyParserOptionsMappackages/platform-express/interfaces/nest-express-body-parser.interface.ts
NestExpressBodyParserOptionsForNestExpressBodyParserOptionsMap, ParserTypepackages/platform-express/interfaces/nest-express-body-parser.interface.ts
MulterInstance—packages/platform-express/multer/interceptors/any-files.interceptor.ts
MulterInstance—packages/platform-express/multer/interceptors/file-fields.interceptor.ts
MulterInstance—packages/platform-express/multer/interceptors/file.interceptor.ts
MulterInstance—packages/platform-express/multer/interceptors/files.interceptor.ts
MulterInstance—packages/platform-express/multer/interceptors/no-files.interceptor.ts
MulterModuleOptionsMulterOptionspackages/platform-express/multer/interfaces/files-upload-module.interface.ts

Enums

7 enums define named constant sets:

EnumSource
HttpStatuspackages/common/enums/http-status.enum.ts
RequestMethodpackages/common/enums/request-method.enum.ts
RouteParamtypespackages/common/enums/route-paramtypes.enum.ts
ShutdownSignalpackages/common/enums/shutdown-signal.enum.ts
VersioningTypepackages/common/enums/version-type.enum.ts
Scopepackages/common/interfaces/scope-options.interface.ts
UuidFactoryModepackages/core/inspector/uuid-factory.ts

Type Relationships

The following diagram shows inheritance, implementation, and reference relationships between types:

ControllerOptions
  ├── extends → ScopeOptions
  └── extends → VersionOptions
InjectableOptions
  └── uses → ScopeOptions
BadGatewayException
  └── extends → HttpException
BadRequestException
  └── extends → HttpException
ConflictException
  └── extends → HttpException
ForbiddenException
  └── extends → HttpException
GatewayTimeoutException
  └── extends → HttpException
GoneException
  └── extends → HttpException
HttpVersionNotSupportedException
  └── extends → HttpException
HttpException
  └── extends → IntrinsicException
ImATeapotException
  └── extends → HttpException
InternalServerErrorException
  └── extends → HttpException
MethodNotAllowedException
  └── extends → HttpException
MisdirectedException
  └── extends → HttpException
NotAcceptableException
  └── extends → HttpException
NotFoundException
  └── extends → HttpException
NotImplementedException
  └── extends → HttpException
PayloadTooLargeException
  └── extends → HttpException
PreconditionFailedException
  └── extends → HttpException
RequestTimeoutException
  └── extends → HttpException
ServiceUnavailableException
  └── extends → HttpException
UnauthorizedException
  └── extends → HttpException
UnprocessableEntityException
  └── extends → HttpException
UnsupportedMediaTypeException
  └── extends → HttpException
SelectOptions
  └── uses → NestApplicationContextOptions
NestApplicationOptions
  └── extends → NestApplicationContextOptions
INestMicroservice
  └── extends → INestApplicationContext
VersioningOptions
  ├── uses → VersioningCommonOptions
  ├── uses → HeaderVersioningOptions
  ├── uses → UriVersioningOptions
  ├── uses → MediaTypeVersioningOptions
  └── uses → CustomVersioningOptions
CustomOrigin
  └── uses → StaticOrigin
CustomParamFactory
  └── uses → ExecutionContext
ExecutionContext
  └── extends → ArgumentsHost
NestMicroserviceOptions
  └── uses → NestApplicationContextOptions
DynamicModule
  └── extends → ModuleMetadata
OptionalFactoryDependency
  └── uses → InjectionToken
IntegrationModule
  └── extends → ConfigurableModuleCls
ValidationPipeOptions
  └── extends → ValidatorOptions
FileTypeValidatorContext
  ├── uses → FileValidatorContext
  └── uses → FileTypeValidatorOptions
FileValidatorContext
  └── uses → IFile
MaxFileSizeValidatorContext
  ├── uses → FileValidatorContext
  └── uses → MaxFileSizeValidatorOptions
ClassSerializerInterceptorOptions
  └── extends → ClassTransformOptions
ClassSerializerContextOptions
  └── extends → ClassTransformOptions
JsonLogObject
  └── uses → LogLevel
ConsoleLogger
  └── implements → LoggerService
Logger
  └── implements → LoggerService
ErrorHttpStatusCode
  └── uses → HttpStatus
IEntryNestModule
  └── uses → DynamicModule
DiscoveryOptions
  ├── uses → FilterByInclude
  └── uses → FilterByMetadataKey
DiscoverableDecorator
  └── uses → CustomDecorator
CircularDependencyException
  └── extends → RuntimeException
InvalidClassModuleException
  └── extends → RuntimeException
InvalidClassScopeException
  └── extends → RuntimeException
InvalidClassException
  └── extends → RuntimeException
InvalidExceptionFilterException
  └── extends → RuntimeException
InvalidMiddlewareConfigurationException
  └── extends → RuntimeException
InvalidMiddlewareException
  └── extends → RuntimeException
InvalidModuleException
  └── extends → RuntimeException
InvalidProviderException
  └── extends → RuntimeException
RequestScopedCreateException
  └── extends → RuntimeException
RequestScopedGlobalEnhancerException
  └── extends → RuntimeException
RouteConflictException
  └── extends → RuntimeException
UndefinedDependencyException
  └── extends → RuntimeException
UndefinedForwardRefException
  └── extends → RuntimeException
UndefinedModuleException
  └── extends → RuntimeException
UninstantiatedGlobalEnhancerException
  └── extends → RuntimeException
UnknownDependenciesException
  └── extends → RuntimeException
UnknownElementException
  └── extends → RuntimeException
UnknownExportException
  └── extends → RuntimeException
UnknownModuleException
  └── extends → RuntimeException
UnknownRequestMappingException
  └── extends → RuntimeException
BaseExceptionFilterContext
  └── extends → ContextCreator
ExternalExceptionFilterContext
  └── extends → BaseExceptionFilterContext
GuardsContextCreator
  └── extends → ContextCreator
ContextIdResolverFn
  ├── uses → HostComponentInfo
  └── uses → ContextId
ExecutionContextHost
  └── implements → ExecutionContext
HandleResponseFn
  ├── uses → HandlerResponseBasicFn
  └── uses → HandleSseResponseFn
HandlerResponseBasicFn
  └── uses → StreamableFile
HandleSseResponseFn
  └── uses → HeaderStream
ParamPropertiesWithMetatype
  └── uses → ParamProperties
ParamsMetadata
  └── uses → ParamMetadata
ModuleMetatype
  └── uses → DynamicModule
InjectorDependency
  └── uses → InjectionToken
ModuleRef
  └── extends → AbstractInstanceResolver
SilentLogger
  └── extends → Logger
ByReferenceModuleOpaqueKeyFactory
  └── implements → ModuleOpaqueKeyFactory
DeepHashedModuleOpaqueKeyFactory
  └── implements → ModuleOpaqueKeyFactory
InterceptorsContextCreator
  └── extends → ContextCreator
ModuleDefinition
  └── uses → DynamicModule
MiddlewareBuilder
  └── implements → MiddlewareConsumer
PipesContextCreator
  └── extends → ContextCreator
ModuleDebugEntry
  └── uses → InjectionToken
ReplLogger
  └── extends → ConsoleLogger
ReplFunctionClass
  └── uses → ReplContext
RouteParamsFactory
  └── implements → IRouteParamsFactory
RouterExceptionFilters
  └── extends → BaseExceptionFilterContext
RoutesResolver
  └── implements → Resolver
AdditionalHeadersSource
  └── uses → AdditionalHeaders
WritableHeaderStream
  └── uses → WriteHeaders
HeaderStream
  ├── uses → WritableHeaderStream
  └── uses → ReadHeaders
SseStream
  └── extends → Transform
Routes
  └── uses → RouteTree
OptionObject
  └── uses → SecurityHeadersOptions
ReflectableDecorator
  └── uses → CustomDecorator
NestExpressBodyParserType
  └── uses → NestExpressBodyParserOptionsMap
NestExpressBodyParserOptionsFor
  └── uses → NestExpressBodyParserOptionsMap
MulterModuleOptions
  └── uses → MulterOptions

Generated by RepoLens static analysis. Type detection uses regex-based parsing and may not capture all advanced TypeScript patterns.

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

Dependency Graph

Engineers · Module dependency analysis with cycle detection

430 files · 1229 imports · 27 external packages · ⚠️ 50 circular dependency cycle(s) · 2 orphan file(s)

This document maps every import relationship in the codebase, identifies the most-connected modules, and flags circular dependencies that may complicate refactoring or increase build times.

Overview

MetricValue
Source files430
Import edges1229
External packages27
Circular dependencies50
Orphan files (no imports or importers)2

Circular Dependencies

50 circular dependency chains were detected. Circular imports can cause initialization errors, increase bundle sizes, and make modules harder to test in isolation. Consider refactoring shared logic into a separate module.

  1. packages/common/interfaces → packages/common/interfaces/features/can-activate.interface → packages/common/interfaces/features/execution-context.interface → packages/common/interfaces
  2. packages/common/interfaces/middleware/middleware-config-proxy.interface → packages/common/interfaces/middleware/middleware-consumer.interface → packages/common/interfaces/middleware/middleware-config-proxy.interface
  3. packages/common/decorators/core → packages/common/decorators/core/catch.decorator → packages/common/interfaces → packages/common/interfaces/http → packages/common/interfaces/http/http-server.interface → packages/common/interfaces/nest-application-options.interface → packages/common/interfaces/nest-application-context-options.interface → packages/common/services/logger.service → packages/common/decorators/core
  4. packages/common/decorators/core → packages/common/decorators/core/catch.decorator → packages/common/interfaces → packages/common/interfaces/http → packages/common/interfaces/http/http-server.interface → packages/common/interfaces/nest-application-options.interface → packages/common/interfaces/nest-application-context-options.interface → packages/common/services/logger.service → packages/common/services/console-logger.service → packages/common/decorators/core
  5. packages/common/services/logger.service → packages/common/services/console-logger.service → packages/common/services/logger.service
  6. packages/common/services/logger.service → packages/common/services/console-logger.service → packages/common/services/utils/is-log-level-enabled.util → packages/common/services/logger.service
  7. packages/common/interfaces/modules/dynamic-module.interface → packages/common/interfaces/modules/module-metadata.interface → packages/common/interfaces/modules/dynamic-module.interface
  8. packages/common/interfaces → packages/common/interfaces/nest-application.interface → packages/common/interfaces
  9. packages/common → packages/common/decorators → packages/common/decorators/core → packages/common/decorators/core/exception-filters.decorator → packages/common
  10. packages/common → packages/common/decorators → packages/common/decorators/http → packages/common/decorators/http/route-params.decorator → packages/common
  11. packages/common → packages/common/decorators → packages/common/decorators/http → packages/common/decorators/http/create-route-param-metadata.decorator → packages/common
  12. packages/common → packages/common/pipes → packages/common/pipes/parse-enum.pipe → packages/common
  13. packages/common → packages/common/pipes → packages/common/pipes/parse-float.pipe → packages/common
  14. packages/core/injector/instance-wrapper → packages/core/injector/constants → packages/core/injector/instance-wrapper
  15. packages/core/application-config → packages/core/injector/instance-wrapper → packages/core/injector/module → packages/core/application-config
  16. packages/core/errors/exceptions → packages/core/errors/exceptions/invalid-class-scope.exception → packages/core/errors/messages → packages/core/injector/injector → packages/core/errors/exceptions
  17. packages/core/injector/injector → packages/core/errors/exceptions/undefined-dependency.exception → packages/core/injector/injector
  18. packages/core/injector/module → packages/core/errors/exceptions → packages/core/errors/exceptions/invalid-class-scope.exception → packages/core/errors/messages → packages/core/injector/injector → packages/core/errors/exceptions/undefined-dependency.exception → packages/core/injector/module
  19. packages/core/errors/messages → packages/core/injector/injector → packages/core/errors/exceptions/undefined-dependency.exception → packages/core/errors/messages
  20. packages/core/injector/injector → packages/core/errors/exceptions/unknown-dependencies.exception → packages/core/injector/injector

...and 30 more cycles

External Dependencies

The codebase imports 27 external packages. These are third-party modules (not the language standard library):

Package
---------
@nestjs/common
@nestjs/core
@nestjs/microservices
@nestjs/platform-express
@nestjs/websockets
async_hooks
class-transformer
class-validator
cors
crypto
express
fast-safe-stringify
file-type
http
https
iterare
module
multer
os
path-to-regexp
perf_hooks
reflect-metadata
repl
rxjs
stream
uid
util

Generated by RepoLens import analysis. Dependency detection covers JavaScript and TypeScript (ES modules, dynamic import, CommonJS, re-exports; comments, strings, and type-only imports are skipped), Python (`import` / `from ... import`, including relative imports), and Go (`go.mod` module paths). Go `_test.go` files are not part of the graph.*

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

Architecture Drift

Mixed audience · Structural changes compared to baseline snapshot

No baseline found. Run repolens publish once to establish a baseline.

A baseline snapshot of the current architecture has been saved. On subsequent runs, this report will track structural changes across the following dimensions:

DimensionWhat is Tracked
ModulesNew, removed, or significantly resized modules
API EndpointsAdded or removed backend routes
DependenciesChanges to external package imports
FrameworksTechnology stack additions or removals
Circular DependenciesIncreases in dependency cycles
GraphQL SchemaType additions or removals
Codebase ScaleOverall file count changes

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

Security Hotspots

Engineers · Security anti-pattern detection with CWE classification

15 security finding(s) · 15 low severity · across 11 file(s)

This report identifies code patterns that are commonly associated with security vulnerabilities. Each finding includes the relevant CWE classification and a recommended remediation.

Severity Overview

SeverityCount
🔵 Low15

430 source files scanned · 11 files with findings

Prototype Pollution

Deep merge utilities may be vulnerable to prototype pollution if they don't check hasOwnProperty. Verify the implementation.

FileLinePatternSeverityCWE
packages/common/pipes/default-value.pipe.ts52Recursive object merge without prototype check🔵 LowCWE-1321
packages/common/pipes/validation.pipe.ts437Recursive object merge without prototype check🔵 LowCWE-1321
packages/common/services/console-logger.service.ts893Recursive object merge without prototype check🔵 LowCWE-1321
packages/common/utils/merge-with-values.util.ts15Recursive object merge without prototype check🔵 LowCWE-1321
packages/core/helpers/execution-context-host.ts43Recursive object merge without prototype check🔵 LowCWE-1321
packages/core/helpers/execution-context-host.ts50Recursive object merge without prototype check🔵 LowCWE-1321
packages/core/helpers/execution-context-host.ts58Recursive object merge without prototype check🔵 LowCWE-1321
packages/core/injector/injector.ts1045Recursive object merge without prototype check🔵 LowCWE-1321
packages/core/injector/instance-wrapper.ts675Recursive object merge without prototype check🔵 LowCWE-1321
packages/core/middleware/middleware-module.ts381Recursive object merge without prototype check🔵 LowCWE-1321
packages/core/router/router-explorer.ts257Recursive object merge without prototype check🔵 LowCWE-1321
packages/core/router/router-explorer.ts334Recursive object merge without prototype check🔵 LowCWE-1321
packages/core/router/router-explorer.ts522Recursive object merge without prototype check🔵 LowCWE-1321

ReDoS

Dynamic regex construction from user input can cause ReDoS. Use static regex or input validation.

FileLinePatternSeverityCWE
packages/common/pipes/file/file-type.validator.ts212Potentially catastrophic regex🔵 LowCWE-1333

Insecure Randomness

Math.random() is not cryptographically secure. Use crypto.randomUUID() or crypto.getRandomValues() for security tokens.

FileLinePatternSeverityCWE
packages/core/helpers/context-id-factory.ts14Math.random() for security-sensitive operation🔵 LowCWE-330

Affected Files

  • packages/common/pipes/default-value.pipe.ts
  • packages/common/pipes/validation.pipe.ts
  • packages/common/pipes/file/file-type.validator.ts
  • packages/common/services/console-logger.service.ts
  • packages/common/utils/merge-with-values.util.ts
  • packages/core/helpers/context-id-factory.ts
  • packages/core/helpers/execution-context-host.ts
  • packages/core/injector/injector.ts
  • packages/core/injector/instance-wrapper.ts
  • packages/core/middleware/middleware-module.ts
  • packages/core/router/router-explorer.ts

Generated by RepoLens security pattern analysis. Detection is regex-based and may produce false positives. Findings should be triaged by a security-aware engineer.

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples

Code Health Report

Mixed audience · Per-module health scores from complexity, coupling, docs, and security

430 files analyzed · Average health: 93/100 · 377 A, 21 B, 26 C, 6 D, 0 F

This report synthesizes complexity, coupling, documentation, and security signals into a single health score per module. Lower scores indicate higher risk and maintenance burden.

Overview

MetricValue
Files analyzed430
Average health score93/100
Average complexity9
Hotspots (score < 60)20

Grade Distribution

GradeCountMeaning
🟢 A (80–100)377Healthy — low complexity, well-documented
🔵 B (60–79)21Acceptable — minor improvements possible
🟡 C (40–59)26Needs attention — elevated complexity or coupling
🟠 D (20–39)6At risk — multiple quality signals degraded
🔴 F (0–19)0Critical — immediate refactoring recommended

Hotspots — Priority Refactoring Targets

These modules have the lowest health scores and should be prioritized for improvement:

ModuleScoreGradeComplexityCouplingDoc%Security
packages/core/injector/injector.ts30🟠 D21917↓ 12↑—1 (0 high)
packages/core/injector/instance-wrapper.ts30🟠 D13234↓ 9↑—1 (0 high)
packages/core/injector/module.ts30🟠 D6929↓ 12↑——
packages/core/nest-application.ts37🟠 D713↓ 21↑——
packages/core/middleware/utils.ts38🟠 D554↓ 3↑40%—
packages/core/router/router-explorer.ts38🟠 D382↓ 28↑—3 (0 high)
packages/common/services/logger.service.ts41🟡 C648↓ 5↑——
packages/core/scanner.ts42🟡 C724↓ 20↑——
packages/common/pipes/validation.pipe.ts44🟡 C892↓ 14↑—1 (0 high)
packages/common/interfaces/http/http-server.interface.ts45🟡 C472↓ 5↑——
packages/common/pipes/parse-array.pipe.ts45🟡 C391↓ 8↑——
packages/common/services/console-logger.service.ts45🟡 C1792↓ 7↑—1 (0 high)
packages/core/helpers/external-context-creator.ts45🟡 C423↓ 15↑——
packages/core/router/route-conflict-detector.ts45🟡 C662↓ 4↑——
packages/core/router/route-path-factory.ts45🟡 C423↓ 4↑——
packages/core/router/router-execution-context.ts45🟡 C851↓ 14↑——
packages/core/router/router-response-controller.ts45🟡 C531↓ 3↑——
packages/core/router/sse-stream.ts45🟡 C443↓ 0↑——
packages/core/security/security-headers.ts45🟡 C771↓ 0↑100%—
packages/platform-express/adapters/express-adapter.ts45🟡 C621↓ 4↑——

Most Complex Functions

These functions have the highest cyclomatic complexity and are the most likely sources of bugs:

FunctionFileLineComplexity
serializeNested()packages/common/services/console-logger.service.ts60971
lookup()packages/core/injector/injector.ts141351
isOptionalFactoryDependency()packages/core/injector/injector.ts53250
doneOnce()packages/platform-express/adapters/express-adapter.ts11349
canActivateFn()packages/core/router/router-execution-context.ts44442
identity()packages/core/injector/injector.ts85037
isCommentOnly()packages/core/router/sse-stream.ts5437
addExportedUnit()packages/core/injector/module.ts47035
getBodyProperty()packages/core/router/route-params-factory.ts2032
onClose()packages/core/router/router-response-controller.ts20532
errorHandler()packages/core/nest-application.ts44131
toClassInstance()packages/common/pipes/parse-array.pipe.ts11126
concatPaths()packages/core/router/route-path-factory.ts12226
add()packages/core/security/security-headers.ts26926
serializeCookie()packages/core/helpers/cookies/serialize-cookie.ts4025

All Modules by Health Score

Showing 50 of 430 modules (sorted worst-first)

ModuleScoreGradeLinesComplexityFan-InFan-Out
packages/core/injector/injector.ts30🟠 D17492191712
packages/core/injector/instance-wrapper.ts30🟠 D717132349
packages/core/injector/module.ts30🟠 D692692912
packages/core/nest-application.ts37🟠 D76671321
packages/core/middleware/utils.ts38🟠 D3805543
packages/core/router/router-explorer.ts38🟠 D54138228
packages/common/services/logger.service.ts41🟡 C3596485
packages/core/scanner.ts42🟡 C83272420
packages/common/pipes/validation.pipe.ts44🟡 C49589214
packages/common/interfaces/http/http-server.interface.ts45🟡 C7204725
packages/common/pipes/parse-array.pipe.ts45🟡 C2303918
packages/common/services/console-logger.service.ts45🟡 C97217927
packages/core/helpers/external-context-creator.ts45🟡 C40542315
packages/core/router/route-conflict-detector.ts45🟡 C4436624
packages/core/router/route-path-factory.ts45🟡 C2454234
packages/core/router/router-execution-context.ts45🟡 C70685114
packages/core/router/router-response-controller.ts45🟡 C4005313
packages/core/router/sse-stream.ts45🟡 C2504430
packages/core/security/security-headers.ts45🟡 C5087710
packages/platform-express/adapters/express-adapter.ts45🟡 C7786214
packages/platform-express/multer/multer/multer.utils.ts45🟡 C1573553
packages/common/services/utils/redact.util.ts46🟡 C2685610
packages/core/nest-application-context.ts48🟡 C54348311
packages/core/errors/messages.ts48🟡 C32033192
packages/common/pipes/file/file-type.validator.ts50🟡 C2153524
packages/core/injector/container.ts51🟡 C375292315
packages/common/decorators/http/route-params.decorator.ts54🟡 C11335646
packages/common/exceptions/http.exception.ts57🟡 C21129223
packages/core/nest-factory.ts58🟡 C43144216
packages/core/exceptions/base-exception-filter.ts59🟡 C1343233
packages/core/router/route-params-factory.ts59🟡 C843212
packages/core/security/cross-origin-protection.ts59🟡 C4253213
packages/core/middleware/route-info-path-extractor.ts60🔵 B2903936
packages/common/interfaces/http/security-headers-options.interface.ts67🔵 B1592820
packages/core/middleware/middleware-module.ts67🔵 B38728122
packages/common/decorators/http/create-route-param-metadata.decorator.ts69🔵 B1062628
packages/common/module-utils/configurable-module.builder.ts71🔵 B3762416
packages/core/services/reflector.service.ts71🔵 B2762420
packages/core/injector/module-ref.ts73🔵 B22631410
packages/core/metadata-scanner.ts74🔵 B1222190
packages/common/interfaces/nest-application-context.interface.ts75🔵 B1662036
packages/common/pipes/parse-float.pipe.ts75🔵 B1002015
packages/common/pipes/parse-enum.pipe.ts76🔵 B1221915
packages/common/utils/shared.utils.ts76🔵 B7219290
packages/core/adapters/http-adapter.ts76🔵 B6891931
packages/core/pipes/pipes-context-creator.ts76🔵 B1241935
packages/common/pipes/standard-schema-validation.pipe.ts77🔵 B1741817
packages/common/serializer/standard-schema-serializer.interceptor.ts77🔵 B1451816
packages/core/guards/guards-context-creator.ts77🔵 B1291825
packages/core/interceptors/interceptors-context-creator.ts77🔵 B1281835

Scoring Methodology

The health score (0–100) is computed from four dimensions:

FactorWeightHow It's Measured
Complexity–1/pt above 10, –2/pt above 30Cyclomatic complexity for JavaScript/TypeScript, Python, and Go (regex, not AST)
Function complexity–2/pt above 8 per functionHighest complexity function in the file
Coupling–1/5 units above 20Fan-in × Fan-out (import connections)
Documentation–10 if <50%, –5 if <80%JSDoc/TSDoc coverage of exports
Security–10/high, –5/medium findingSecurity anti-pattern findings in file

Generated by RepoLens code health analysis. Complexity covers JavaScript/TypeScript, Python, and Go. It is regex-based and may differ from AST-based tools. Scores are relative indicators, not absolute quality measures.

<!-- repolens:docs-badge --> ![Docs by RepoLens](https://github.com/CHAPIBUNNY/repolens) · Examples