Back to Explore

nestjs/swagger

GitHub
5 updates · last 90 days1 watchersOpen source

Last release:

@nestjs/swagger is an OpenAPI (Swagger) module for the Nest (Node.js) framework. It helps you generate and expose OpenAPI documentation for your Nest-based server-side applications.

Project status

  • The nestjs/swagger (node.js OpenAPI Swagger module for Nest) source appears actively maintained, with the most recent upstream push on 2026-09-02 and multiple recent updates in August 2026.
  • Update cadence looks relatively frequent in the last couple of months (for example, updates on 2026-08-17, 2026-08-27, and 2026-08-28), suggesting an active development and release stream rather than maintenance mode.

AI summary generated

AI-generated from public sources. May be inaccurate. Report

Recent updates

  • 12.0.1

    Release 12.0.1 is a small bug fix plus dependency maintenance. The code changes focus on fixing inline ESM output generation by hoisting static namespace imports so synchronous metadata factories do not emit lazy `require()` or `await import()` expressions.

  • 12.0.0

    Release 12.0.0 moves @nestjs/swagger to native ESM, requiring Nest 12 and updating how the package exports are resolved. It also introduces Standard Schema support via a new standardSchemaConverter option, and changes nullable OpenAPI spelling based on the JSON Schema/OpenAPI document version.

    BreakingFeatures
  • 11.4.7

    Release 11.4.7 focuses on improving Nest Swagger plugin behavior and metadata generation, including better handling of enum-based ApiResponse statuses, readonly mode import path rebasing, and deep partial substitution for plugin-generated DTO metadata. It also expands the public TypeScript API surface for OpenAPI object-model types and adds support for custom OpenAPI extensions on ApiHeader parameters.

    SecurityFeatures
  • 11.4.6

    Release 11.4.6 adds new Swagger plugin capabilities for richer parameter documentation, including inferring OpenAPI parameter enums from literal union types and allowing custom OpenAPI extensions on ApiQuery parameters. It also fixes several schema generation edge cases related to mapped type collisions, DeepPartialType array handling, response schema typing, and MIME type content wrapper reference behavior. Code changes further adjust Swagger UI HTML template replacement behavior to safely preserve certain user-provided characters.

    Features
  • 11.4.5

    Release 11.4.5 adds Swagger plugin output support for TypeScript Record and index-signature types by generating OpenAPI schemas that include additionalProperties. It also updates swagger-ui-dist and bumps js-yaml for a security fix. The code changes also show additional, undocumented tooling and dev-dependency upgrades.

    SecurityFeatures
  • 11.4.4

    Release 11.4.4 adds OpenAPI TagObject support for a new optional Tag summary field (OpenAPI 3.2), and it warns when @ApiTags is given hierarchy fields (parent/kind) since those are not used at the root tag level. It also updates tag.kind handling to be free-form, and includes at least one schema-generation bug fix related to nullable usage with discriminator.

    Features
  • 11.4.3

    Release 11.4.3 focuses on multiple Swagger/OpenAPI schema generation fixes, including improved enum handling (const enums in query params, and enum metadata for string and number literal unions) and preserving response example/examples for scalar built-in types. It also introduces new decorators related to endpoint inclusion and additional schema generation improvements. The code diff includes more functionality than the release notes describe, including OpenAPI 3.1 webhook support and new document options for example truncation and route filtering.

    Features
  • 11.4.2

    Release 11.4.2 includes two targeted bug fixes in the Swagger NestJS plugin. It improves schema generation when enum metadata comes from plugin data that falls back to Object, and it adjusts controller-level response decorator handling so error-only Api*Response decorators do not suppress the auto-inferred default 2xx response.

  • 11.4.1

    Release 11.4.1 is a small bug fix in the NestJS Swagger plugin related to how @ApiOperation is auto-generated from controller method comments. It prevents duplicate property keys when the user already set those keys in an explicit @ApiOperation({ ... }) decorator.

  • 11.4.0

    Release 11.4.0 adds OpenAPI 3.2 hierarchical tag support and improves Swagger generation for optional query parameters by auto-setting `required: false` for optional `@Query()` parameters. It also includes multiple plugin and schema-generation bug fixes around regex handling, @throws rendering, OpenAPI version validation, and preservation of example metadata for named types.

    Features
  • 11.3.2

    Release 11.3.2 contains a targeted fix for @nestjs/swagger's plugin that remaps import paths from rootDir to outDir when generating type references. The code change primarily affects how relative import/require paths are computed inside the plugin utilities.

  • 11.3.1

    Release 11.3.1 contains targeted bug fixes for schema generation (handling oneOf/anyOf combinators and enumName references) and fixes relative import path depth when TypeScript outDir changes the emitted file layout. It also hardens the Swagger UI init options serialization by replacing a hardcoded function placeholder sentinel with a per-call UUID.

    Security
  • 11.3.0

    NestJS Swagger 11.3.0 adds new schema helper utilities (generateSchema, DeepPartialType), supports async patchDocumentOnRequest, and introduces excludeDynamicDefaults and autoFillEnumName plugin options. The release also includes multiple bug fixes around nullable handling (notably when nullable is combined with allOf), enum/schema generation, and metadata generation behavior in SWC readonly mode and monorepo/workspace setups.

    Features