Getting it into your agent
It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.
git clone --depth 1 https://github.com/JoaoEquer/Oficinanpx agentmods add skills/joaoequer/oficina/nestjs-crud-patternWrote 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/joaoequer/oficina/nestjs-crud-pattern)<a href="https://agentmods.dev/skills/joaoequer/oficina/nestjs-crud-pattern"><img src="https://agentmods.dev/badge/skills/joaoequer/oficina/nestjs-crud-pattern.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.00073 | $0.01049 |
| Opus 5 | $0.00036 | $0.00524 |
| Sonnet 5 | $0.00015 | $0.00210 |
| Haiku 4.5 | $0.00007 | $0.00105 |
Grade A, and why
nestjs-crud-pattern 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 2d 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 — 87 lines — stays where its author put it; the contents beside it link to each section on GitHub.
⚠️ Deprecated: no active Wibi backend uses NestJS — the 3 real backends (
dream-book-api,dream-book-api-agent,simple-management-api) are Express + Prisma in a manual Clean Architecture shape. Kept for historical reference, or in case a future project explicitly picks NestJS. For the real production stack, useexpress-prisma-pattern.
NestJS CRUD — house pattern
Every CRUD domain follows exactly the same shape. The project's first module is the mold; the rest copy its form. Do not invent variations.
Per-domain structure
src/modules/<domain>/
├── <domain>.controller.ts # HTTP only: receives request, returns response. Zero business logic.
├── <domain>.service.ts # Business logic. Depends on the repository ABSTRACTION, never on Prisma directly.
├── <domain>.repository.ts # Abstract class (contract) + Prisma implementation in the same file.
├── dto/
│ ├── create-<domain>.dto.ts
│ └── update-<domain>.dto.ts
└── <domain>.module.ts # Wiring: binds the contract to the implementation via provider token.
Cross-cutting concerns (PrismaService, guards, context decorators) live in src/shared/.
The repository contract (DIP in practice)
// <domain>.repository.ts
export abstract class TaskRepository {
abstract create(workspaceId: string, data: CreateTaskDto): Promise<Task>;
abstract findAll(workspaceId: string): Promise<Task[]>;
abstract findById(workspaceId: string, id: string): Promise<Task | null>;
abstract update(workspaceId: string, id: string, data: UpdateTaskDto): Promise<Task>;
abstract softDelete(workspaceId: string, id: string): Promise<void>;
}
@Injectable()
export class PrismaTaskRepository extends TaskRepository {
constructor(private readonly prisma: PrismaService) { super(); }
// ... implementation: EVERY query filters by workspaceId
}
// <domain>.module.ts
@Module({
controllers: [TaskController],
providers: [
TaskService,
{ provide: TaskRepository, useClass: PrismaTaskRepository },
],
})
export class TaskModule {}
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.
- 2d ago Changed · +2 lines 028eefb2182f
- 8d ago First seen · 85 lines · 73 tokens per session scan A c10fb0eb4755
nestjs-crud-pattern is a skill published in the GitHub repository JoaoEquer/Oficina (2 stars, last pushed 6d ago), licensed MIT. It adds 73 tokens to every session and 1,049 once invoked, about $0.0004 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
nestjs
Use when building or structuring a NestJS backend — feature modules, providers and DI wiring, provider scopes and request-lifecycle order, where to bind guards/pipes/interceptors/filters, and testing with Test.createTestingModule. NOT a bare Express/Fastify service with no DI (that is nodejs), NOT framework-agnostic…
agent-operated-software
Use when designing, building, operating, or diagnosing an ongoing application whose live backend or control loop includes OpenRig agents, including applications with a Markdown, YAML, or JSON agent control plane or a thin surface over specialist agent roles.
nestjs-database
Implement data access patterns, Scaling, Migrations, and ORM selection in NestJS. Use when implementing TypeORM/Prisma repositories, migrations, or database patterns in NestJS.
claude-api
Use this skill when the user is building against Anthropic APIs or SDKs, including @anthropic-ai/sdk, anthropic, or Agent SDK integrations.
nextjs-pages-router
Set up tRPC in Next.js Pages Router with createNextApiHandler, createTRPCNext, withTRPC HOC, SSR via ssr option and ssrPrepass, SSG via createServerSideHelpers with getStaticProps, and server-side helpers for getServerSideProps prefetching.
non-json-content-types
Handle FormData, file uploads, Blob, Uint8Array, and ReadableStream inputs in tRPC mutations. Use octetInputParser from @trpc/server/http for binary data. Route non-JSON requests with splitLink and isNonJsonSerializable() from @trpc/client. FormData and binary inputs only work with mutations (POST).