Skip to content
Back to search

nestjs

MarketplaceWorks with Claude CodeGitHub

Official NestJS plugins for coding agents.

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/nestjs--agent-skills/badge.svg)](/listings/nestjs--agent-skills)

HTML

<a href="/listings/nestjs--agent-skills"><img src="/api/listings/nestjs--agent-skills/badge.svg" alt="findsafeskills safety rating" /></a>

Install

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

The skills live in [`skills/`](skills). Install them for one project (committed with the code, so everyone on the team gets them) or for your user account (every project on your machine).

Any agent, with npm

npx @nestjs/skills add

copies every skill into `.agents/skills/`, which Codex and Cursor read. Choose where with `--agent`:

| `--agent` | Folder | Read by | | --- | --- | --- | | `agents` (default) | `.agents/skills/` | Codex, Cursor and other Agent Skills readers | | `claude` | `.claude/skills/` | Claude Code (and Cursor) | | `cursor` | `.cursor/skills/` | Cursor | | `all` | `.agents/skills/` and `.claude/skills/` | Codex, Cursor and Claude Code at once (Cursor reads both folders) |

npx @nestjs/skills add --agent claude              # Claude Code, this project
npx @nestjs/skills add --agent all                 # Codex, Cursor and Claude Code
npx @nestjs/skills add --agent agents --global     # every project on your machine (~/.agents/skills)
npx @nestjs/skills add nestjs nestjs-auth          # only some skills
npx @nestjs/skills list                            # what's in the package
npx @nestjs/skills remove                          # remove what it installed

`--agent` also takes several targets (`--agent agents,claude` or repeated). `--dir <path>` installs anywhere else. The installer only replaces or removes folders it installed itself (it leaves a `.nestjs-skills` marker in each); `--force` replaces a same-named folder that it didn't. Pin the version for the team with `npm i -D @nestjs/skills` and `npx nestjs-skills add`. Programmatic use: `import { listSkills, skillsDir } from '@nestjs/skills'`.

Claude Code

As a plugin, from this repository's marketplace:

claude plugin marketplace add nestjs/agent-skills
claude plugin install nestjs@nestjs

Or inside a session: `/plugin marketplace add nestjs/agent-skills`, then `/plugin install nestjs@nestjs`. Skills from the plugin are namespaced (`nestjs:nestjs-auth`).

Without the plugin: `npx @nestjs/skills add --agent claude` (add `--global` for `~/.claude/skills/`).

To preconfigure a repository for your team, add this to its `.claude/settings.json`; each contributor still runs the install once:

{
  "extraKnownMarketplaces": {
    "nestjs": { "source": { "source": "github", "repo": "nestjs/agent-skills" } }
  },
  "enabledPlugins": { "nestjs@nestjs": true }
}

Codex

Codex reads skills from `.agents/skills/` in the repository (and in parent folders up to the repository root) and from `~/.agents/skills/` for your user.

Cursor

Cursor reads skills from `.agents/skills/` and `.cursor/skills/` in the project, and from `~/.agents/skills/` and `~/.cursor/skills/` for your user. It also loads `.claude/skills/` and `.codex/skills/`.

Any agent, by hand

Copy (or symlink) the skill folders to where your agent loads skills. `.agents/skills/` covers Codex and Cursor at once:

git clone https://github.com/nestjs/agent-skills.git
mkdir -p .agents/skills && cp -R agent-skills/skills/* .agents/skills/

For every project on your machine, use `~/.agents/skills/` instead. A symlink (`ln -s "$PWD/agent-skills/skills/nestjs-auth" ~/.agents/skills/`) keeps a copy current with `git pull`.

Keep each folder whole: `SKILL.md` links to its `references/` with relative paths, and the skills refer to each other by name.

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

.claude-plugin/marketplace.json · Manifest · 14 lines
  1. {
  2. "name": "nestjs",
  3. "owner": { "name": "NestJS", "url": "https://nestjs.com" },
  4. "description": "Official NestJS plugins for coding agents.",
  5. "plugins": [
  6. {
  7. "name": "nestjs",
  8. "source": "./",
  9. "description": "NestJS skills: start a project, add features, authentication and authorization, databases, tests, production setup and observability, with the current APIs and the mistakes agents make in Nest apps.",
  10. "category": "development",
  11. "tags": ["nestjs", "typescript", "node", "backend"]
  12. }
  13. ]
  14. }
README.md · README · 142 lines
  1. # NestJS agent skills
  2. Official [Agent Skills](https://agentskills.io) for building and extending [NestJS](https://nestjs.com) applications with coding agents. They give an agent what its training data lacks:
  3. - the current APIs, which are often newer than the model;
  4. - Nest's first-party packages;
  5. - the mistakes that still pass tests: a sign-in that leaks which emails exist, `@IsOptional()` letting `null` through to a 500, a rate limiter that never sees the user, an event stream that outlives a revoked key, and many more.
  6. Each skill is a folder with a `SKILL.md` that holds its rules, plus `references/` with longer recipes. Every recipe was run on the released packages. The skills work with any agent that reads the Agent Skills format: Claude Code, Codex, Cursor and others.
  7. ## Skills
  8. | Skill | Use when |
  9. | --- | --- |
  10. | `nestjs` | creating or extending a NestJS application: starting a project, layout, module system, where the docs are, common mistakes |
  11. | `nestjs-feature` | adding or changing endpoints: where code goes, modules and providers, validation (Zod with `@Body({ schema })` or class-validator), status codes, errors, HTTP options, Server-Sent Events |
  12. | `nestjs-auth` | adding or changing authentication or authorization: `@nestjs/authentication` (passwords, sessions, tokens, API keys) and `@nestjs/authorization` (policies) |
  13. | `nestjs-data` | adding or changing persistence: `@nestjs/drizzle` and `@nestjs/typeorm`, migrations, safe updates, paging, transactions |
  14. | `nestjs-testing` | writing, running or fixing tests: unit, service and end-to-end tests, overriding providers and global guards, signing test users in |
  15. | `nestjs-production` | preparing for production: configuration, logs, observability with NestJS Observe, health checks, rate limiting, OpenAPI, shutdown, deployment |
  16. Agents load a skill when its description matches the task, so there's nothing to invoke by hand.
  17. ## Install
  18. The skills live in [`skills/`](skills). Install them for one project (committed with the code, so everyone on the team gets them) or for your user account (every project on your machine).
  19. ### Any agent, with npm
  20. ```bash
  21. npx @nestjs/skills add
  22. ```
  23. copies every skill into `.agents/skills/`, which Codex and Cursor read. Choose where with `--agent`:
  24. | `--agent` | Folder | Read by |
  25. | --- | --- | --- |
  26. | `agents` (default) | `.agents/skills/` | Codex, Cursor and other Agent Skills readers |
  27. | `claude` | `.claude/skills/` | Claude Code (and Cursor) |
  28. | `cursor` | `.cursor/skills/` | Cursor |
  29. | `all` | `.agents/skills/` and `.claude/skills/` | Codex, Cursor and Claude Code at once (Cursor reads both folders) |
  30. ```bash
  31. npx @nestjs/skills add --agent claude # Claude Code, this project
  32. npx @nestjs/skills add --agent all # Codex, Cursor and Claude Code
  33. npx @nestjs/skills add --agent agents --global # every project on your machine (~/.agents/skills)
  34. npx @nestjs/skills add nestjs nestjs-auth # only some skills
  35. npx @nestjs/skills list # what's in the package
  36. npx @nestjs/skills remove # remove what it installed
  37. ```
  38. `--agent` also takes several targets (`--agent agents,claude` or repeated). `--dir <path>` installs anywhere else. The installer only replaces or removes folders it installed itself (it leaves a `.nestjs-skills` marker in each); `--force` replaces a same-named folder that it didn't. Pin the version for the team with `npm i -D @nestjs/skills` and `npx nestjs-skills add`. Programmatic use: `import { listSkills, skillsDir } from '@nestjs/skills'`.
  39. ### Claude Code
  40. As a plugin, from this repository's marketplace:
  41. ```bash
  42. claude plugin marketplace add nestjs/agent-skills
  43. claude plugin install nestjs@nestjs
  44. ```
  45. Or inside a session: `/plugin marketplace add nestjs/agent-skills`, then `/plugin install nestjs@nestjs`. Skills from the plugin are namespaced (`nestjs:nestjs-auth`).
  46. Without the plugin: `npx @nestjs/skills add --agent claude` (add `--global` for `~/.claude/skills/`).
  47. To preconfigure a repository for your team, add this to its `.claude/settings.json`; each contributor still runs the install once:
  48. ```json
  49. {
  50. "extraKnownMarketplaces": {
  51. "nestjs": { "source": { "source": "github", "repo": "nestjs/agent-skills" } }
  52. },
  53. "enabledPlugins": { "nestjs@nestjs": true }
  54. }
  55. ```
  56. ### Codex
  57. Codex reads skills from `.agents/skills/` in the repository (and in parent folders up to the repository root) and from `~/.agents/skills/` for your user.
  58. ### Cursor
  59. Cursor reads skills from `.agents/skills/` and `.cursor/skills/` in the project, and from `~/.agents/skills/` and `~/.cursor/skills/` for your user. It also loads `.claude/skills/` and `.codex/skills/`.
  60. ### Any agent, by hand
  61. Copy (or symlink) the skill folders to where your agent loads skills. `.agents/skills/` covers Codex and Cursor at once:
  62. ```bash
  63. git clone https://github.com/nestjs/agent-skills.git
  64. ```
  65. ```bash
  66. mkdir -p .agents/skills && cp -R agent-skills/skills/* .agents/skills/
  67. ```
  68. For every project on your machine, use `~/.agents/skills/` instead. A symlink (`ln -s "$PWD/agent-skills/skills/nestjs-auth" ~/.agents/skills/`) keeps a copy current with `git pull`.
  69. Keep each folder whole: `SKILL.md` links to its `references/` with relative paths, and the skills refer to each other by name.
  70. ## Updating
  71. - **Claude Code plugin:** `claude plugin marketplace update nestjs`, then `claude plugin update nestjs@nestjs`, or turn on auto-update for the marketplace in `/plugin`.
  72. - **npm:** `npx @nestjs/skills@latest add` again: it replaces the copies it installed, dropping files a skill no longer has.
  73. - **Copies by hand:** `git pull` and copy the folders again (symlinked folders update with the pull).
  74. ## Compatibility
  75. Written for NestJS 12 (`@nestjs/core` 12.x) on Node.js 20 or later. The recipes were run on:
  76. - Nest 12.5.1;
  77. - `@nestjs/authentication` 0.1.6 and `@nestjs/authorization` 0.1.4;
  78. - `@nestjs/drizzle` 0.0.2 with Drizzle 1.0 rc, and `@nestjs/typeorm` 12.0.3 with TypeORM 1.1;
  79. - `@nestjs/throttler` 6.8, `@nestjs/swagger` 12.1, `@nestjs/terminus` 12.2, `@nestjs/config` 12.1 and `@nestjs/observe` 0.3.
  80. The skills tell the agent to check the installed version and the [documentation](https://docs.nestjs.com/llms.txt) before relying on what it remembers.
  81. ## Format
  82. Each `SKILL.md` follows the [Agent Skills specification](https://agentskills.io/specification):
  83. - `name` matches the folder;
  84. - `description` says when the skill applies, under 1,024 characters;
  85. - the frontmatter uses only portable fields (`name`, `description`, `license`, `compatibility`), so the same files work in every agent and can be uploaded to the Claude apps.
  86. The repository is also a Claude Code plugin (`.claude-plugin/plugin.json`), its own marketplace (`.claude-plugin/marketplace.json`), and the npm package `@nestjs/skills` (the skills, the plugin manifests, and the `nestjs-skills` installer; no dependencies).
  87. ## Contributing
  88. Keep `SKILL.md` files short: rules and pitfalls in the file, longer code in `references/`, one level deep. Before adding an API or a pitfall, check it against the docs and run it on a released version.
  89. Validate the frontmatter, links and versions, and test the installer:
  90. ```bash
  91. npm run validate
  92. npm test
  93. claude plugin validate --strict .
  94. ```
  95. A release bumps `version` in both `package.json` and `.claude-plugin/plugin.json` (`npm run validate` checks they match), then `npm publish`, which runs the same checks first.
  96. ## License
  97. [MIT](LICENSE)

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.