application skillA
application is agent-read markdown (skill) from softtor/nestjs-hexagonal: Use when creating application layer artifacts for a NestJS bounded context — use cases, CQRS command/query handlers, DTOs, ports (cross-module interfaces), application services, or read model projections. Supports three patterns: plain UseCase (A), CQRS native (B), and Handler-as-Orchestrator (C)..
Indexed from public GitHub and served as immutable, content-addressed versions. Install it pinned to an exact SHA-256 with the mdr CLI, and every file is verified against the hash recorded here before it reaches your agent. The deterministic audit below grades the latest version, and the same file always earns the same grade.
What the file says
> **Note:** Examples use `companyId` as the multi-tenant identifier. Replace with your project's term (e.g., `organizationId`, `tenantId`).
# Application Layer
This skill covers everything inside a bounded context's `application/` directory:
use cases, CQRS handlers, DTOs, ports, application services, and Redis read models.
---
## 1. Pattern Selection
Work through this flowchart before writing a single line of code.
```
Does the module already use CQRS (CommandBus / QueryBus)?
├── No → Pattern A (plain UseCase + TOKEN)
└── Yes →
Is this a simple read (findById) with no RBAC or transformation?
├── Yes → Skip use case — inject repository directly in controller
└── No →
Does orchestration span multiple services (QueryBus calls,
multiple ports, complex enrichment)?
├── Yes → Pattern C (Handler as Orchestrator)
└── No → Pattern B (CQRS Command/Query)
Need read model / projections?
└── CQRS R/W separation: write side → Pattern B/C, read side → Redis query handler
(see references/read-model-patterns.md)
Reusable logic between 2+ handlers?
…Read the whole file at its exact version.
How to install
mdr add softtor/nestjs-hexagonal/application@git:20260920.ed50a26mdr add softtor/nestjs-hexagonal/application@sha256:92b1b087e0246803Pin to a label to follow the author's releases, or to a sha256 to freeze the exact bytes forever. Either way the resolved hash is written to mdr.lock, and mdr install reproduces it on any machine.
[](https://markdownregistry.com/a/art_kknio23iboj32fsd)
1 badge views in 30 days
Versions
| version | committed | commit | size | audit | |
|---|---|---|---|---|---|
| git:20260920.ed50a26 latest | 2026-09-20 | ed50a26 | 18,175 B | A | view · diff |
| git:20260327.3ac41d8 | 2026-03-27 | 3ac41d8 | 18,173 B | A | view · diff |
| git:20260327.2694398 | 2026-03-27 | 2694398 | 18,080 B | A | view · diff |
| git:20260326.a4e1dae | 2026-03-26 | a4e1dae | 17,939 B | A | view |
Audit of the latest version
- pass: Frontmatter block present
- pass: Frontmatter declares a name
- pass: Frontmatter declares a description
- pass: Size between 200 bytes and 200 KB (18175 bytes)
- pass: No zero-width or bidi control characters
- pass: No instruction hidden inside an HTML comment
- pass: No link to an exfiltration or paste host
- pass: No credential-shaped string
- pass: No instruction to send local credentials anywhere
- pass: No text hidden with inline styles
- pass: No prompt-injection phrasing
- pass: No curl or wget piped into a shell
- pass: No recursive delete of root, home or parent
- pass: No instruction to read or print local credentials
- pass: No base64 blob over 200 characters
- pass: No link to a raw IP address
- pass: No script tag
Source
softtor/nestjs-hexagonal · 5 stars · license MIT · pushed 2026-09-23 · branch main
API
GET https://markdownregistry.com/api/v1/artifacts/art_kknio23iboj32fsd GET https://markdownregistry.com/api/v1/resolve?ref=softtor/nestjs-hexagonal/application GET https://markdownregistry.com/api/v1/blob/92b1b087e0246803f95e1f4fa5cf068f2db77bc189c96d0a6a215c5e4ec1694f
Your agent does the legwork. You hear about the deals worth your word. Hand yours the standing instructions at modelranch.com and it joins the network that reads files like this one.