← all repositories
samchon/nestia

NestJS decorators that outrun class-validator by 20,000x

A TypeScript-native toolkit that replaces NestJS boilerplate with pure types, then auto-generates SDKs, tests, and AI chatbots from your API surface.

2.2k stars TypeScript AgentsRAG · SearchLLMOps · Eval
nestia
Velocity · 7d
+1.1
★ / day
Trend
steady
star history

What it does

Nestia is a collection of helper libraries for NestJS that swap runtime decorators for compile-time TypeScript types. You write plain types; it generates fast validators, Swagger docs, typed client SDKs, mock servers, and even E2E test suites. Lately it has grown AI-facing tools: an agentic library for LLM function calling (@agentica) and a “vibe coding” agent that scaffolds NestJS apps from prompts (@autobe).

The interesting bit

The speed claims are eye-watering: runtime validation 20,000× faster than class-validator, JSON serialization 200× faster than class-transformer, overall throughput up 30×. The trick is doing validation at the TypeScript compilation layer via the author’s typia library, so runtime work collapses to near-zero. The SDK generator is the other quiet win — it emits typed fetch wrappers (tRPC-style) plus an embedded mock server, giving frontend developers a backend contract without running the backend.

Key highlights

  • @nestia/core — drop-in decorators (@TypedBody, @TypedRoute, etc.) that read TypeScript types directly, no class-validator classes needed
  • @nestia/sdk — generates Swagger, client SDKs, mock simulators, and E2E test functions from server code alone
  • @nestia/editor — Swagger-UI bundled with an online TypeScript editor
  • AI extensions: @agentica for LLM function-calling agents, @autobe for prompt-to-NestJS scaffolding
  • CLI tool (nestia) wires the above together

Caveats

  • The 20,000× and 200× figures come from the project’s own benchmarks; independent verification isn’t cited in the README
  • The AI tools (@agentica, @autobe) live in separate repos (wrtnlabs/*) and appear to be newer, less documented satellites

Verdict

Worth a look if you’re running NestJS at scale and burning CPU on validation, or if you want typed SDKs without hand-writing OpenAPI specs. Skip it if you’re happy with class-validator performance or already locked into Zod-heavy stacks.

heatdrop uses Google Analytics to see which pages get read — nothing else. Your call. How we handle data.