Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add dkmqflx/nestjs-best-practices-plugin --skill nestjs-databasegit clone --depth 1 https://github.com/dkmqflx/nestjs-best-practices-pluginWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/dkmqflx/nestjs-best-practices-plugin/nestjs-database)<a href="https://agentmods.dev/skills/dkmqflx/nestjs-best-practices-plugin/nestjs-database"><img src="https://agentmods.dev/badge/skills/dkmqflx/nestjs-best-practices-plugin/nestjs-database.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00066 | $0.00542 |
| Opus 5 | $0.00033 | $0.00271 |
| Sonnet 5 | $0.00013 | $0.00108 |
| Haiku 4.5 | $0.00007 | $0.00054 |
Grade A, and why
nestjs-database scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 39 lines — stays where its author put it; the contents beside it link to each section on GitHub.
NestJS Database & ORM
Best-practices reference for integrating a database into NestJS through TypeORM, Prisma, or Mongoose. Covers async module configuration, repository injection, schema lifecycle (migrations vs synchronize), transactions, relation loading, projection, DTO mapping, and indexing/pagination. Examples favor TypeORM with Prisma notes where the idiom differs.
When to Apply
- Wiring
TypeOrmModule/MongooseModule/PrismaModulewithConfigService - Injecting repositories or model services into providers
- Choosing between
synchronizeand migrations for schema changes - Writing multi-step writes that must be atomic (transactions)
- Loading relations efficiently (avoiding N+1 queries)
- Selecting only needed columns / not over-fetching
- Returning data from controllers without leaking ORM entities
- Indexing queried columns and paginating large result sets
Rules
async-module-config- configure the data layer withforRootAsync+ConfigService; never hardcode credentialsrepository-pattern- inject repositories/services into providers; keep DB access out of controllersmigrations-not-synchronize- setsynchronize: falsein production and manage schema with migrationstransactions-for-multi-write- wrap multi-step writes in a transaction (QueryRunner/dataSource.transaction/prisma.$transaction)avoid-n-plus-one- load relations explicitly (relations/leftJoin/include); never query inside a loopselect-needed-columns- project specific fields; avoidSELECT *and over-fetchingseparate-entities-from-dtos- map ORM entities to response DTOs; don't expose persistence models directlyindex-and-pagination- index queried columns and paginate large results withtake/skip
How to Use
Read individual rule files in rules/ for the rationale plus incorrect/correct examples. Each rule is self-contained; apply the ones relevant to the change you are making. Default to TypeORM idioms; Prisma/Mongoose equivalents are noted inline where they differ.
What ships with it
8 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- rules/async-module-config.md 1.8 KB
- rules/avoid-n-plus-one.md 1.4 KB
- rules/index-and-pagination.md 1.6 KB
- rules/migrations-not-synchronize.md 1.5 KB
- rules/repository-pattern.md 1.7 KB
- rules/select-needed-columns.md 1.3 KB
- rules/separate-entities-from-dtos.md 1.5 KB
- rules/transactions-for-multi-write.md 2.0 KB
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 8d ago First seen · 39 lines · 66 tokens per session scan A e9c885356f2c
nestjs-database is a skill published in the GitHub repository dkmqflx/nestjs-best-practices-plugin (1 stars, last pushed 2mo ago), licensed MIT. It adds 66 tokens to every session and 542 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
supabase-cli
This skill should be used when user asks to "use supabase CLI", "supabase init", "supabase start", "run migrations", "deploy edge functions", "manage Supabase project", or works with the supabase command-line tool for local development and project management.
supabase-js
This skill should be used when user asks to "use supabase-js", "query Supabase database", "supabase auth", "supabase storage", "supabase realtime", "supabase edge functions", or works with the @supabase/supabase-js JavaScript/TypeScript SDK.
phoenix-contexts
Phoenix context design — creating/splitting contexts, Scope (1.8+), Ecto.Multi, PubSub, routers, plugs, controllers. Use when editing contexts, routers, or designing boundaries.
cloudflare-hyperdrive
Cloudflare Hyperdrive for Workers-to-database connections with pooling and caching. Use for PostgreSQL/MySQL, Drizzle/Prisma, or encountering pool errors, TLS issues, connection refused.
data-contract-migrations
Design and verify data contracts, schema changes, migrations, rollbacks, backfills, compatibility windows, tenant isolation, and API-to-database field mapping. Use when changing database schema, event payloads, persisted documents, analytics tables, multi-tenant data boundaries, or any user-visible data contract where…
neo4j-getting-started-skill
Orchestrates zero-to-running-app in 8 stages — prerequisites → context → provision → model → load → explore → query → build. Each stage reads its own reference file. Supports HITL and fully autonomous operation. Use when starting a new Neo4j project from scratch, provisioning Aura, generating synthetic data, building…