Xeno Framework LogoXeno.JS
Next-Gen Architecture for Node.js

Enterprise-grade DDD & CQRS framework for Node.js

Discover Xeno, a type-safe architectural framework designed to eliminate runtime magic, providing explicit Inversion of Control, absolute domain isolation, and deterministic execution pipelines.

terminal — xeno-cli
$ npm install @xeno-js/cli
$ xeno my-xeno-app
✔ Scaffolding completed successfully!
Agnostic & Decoupled Architecture

How Xeno can power virtually any Node.js runtime

Because Xeno core is completely independent of any specific HTTP server or transport driver, its modular Dependency Injection and CQRS Mediator allow it to power virtually any Node.js runtime environment.

CLI

CLI & Console Applications

Execute migration scripts, scheduled cron jobs, or queue message workers using directly the AppBuilder and ServiceContainer without opening any HTTP port.

Background WorkersHover details
Desktop

Desktop Apps (Electron / Tauri)

Manage complex desktop business logic inside the Main Process leveraging local SQLite storage and strict type-safety architectures.

Local Domain-Driven DesignHover details
Edge

Serverless & Edge Computing

Run stateless, high-performance serverless APIs and webhooks utilizing NodeRequestContext execution context isolation and Zod validation.

AWS Lambda / VercelHover details
Flexible

Alternative HTTP Frameworks

Modernize or protect legacy web stacks by mounting Xeno's core middleware pipeline, authentication guardrails, and error handling monads.

Express, Koa, NestJS, NativeHover details
CLI

CLI & Console Applications

Execute migration scripts, scheduled cron jobs, or queue message workers using directly the AppBuilder and ServiceContainer without opening any HTTP port.

Background WorkersHover details
Desktop

Desktop Apps (Electron / Tauri)

Manage complex desktop business logic inside the Main Process leveraging local SQLite storage and strict type-safety architectures.

Local Domain-Driven DesignHover details
Edge

Serverless & Edge Computing

Run stateless, high-performance serverless APIs and webhooks utilizing NodeRequestContext execution context isolation and Zod validation.

AWS Lambda / VercelHover details
Flexible

Alternative HTTP Frameworks

Modernize or protect legacy web stacks by mounting Xeno's core middleware pipeline, authentication guardrails, and error handling monads.

Express, Koa, NestJS, NativeHover details
Core Value Proposition

Why choose Xeno?

Engineered specifically for teams and developers seeking deep control over their dependency graph, request lifecycles, and domain architectures in Node.js.

Architecture

Zero-Magic & Explicit IoC

No hidden magic or runtime directory auto-scanning. Every dependency, module, and lifecycle (singleton, scoped, transient) is declared programmatically and transparently.

Compile-Time Safety

Strongly-Typed Service Registry

Contracts mapped statically via TypeScript. If you modify a service signature, the compiler immediately flags any non-compliant injections before runtime.

Node.js AsyncLocalStorage

Async Context Isolation

Eliminates parameter drilling completely. Automatically tracks correlation IDs, tenant IDs, and user identities across asynchronous execution flows.

Mediator & Pipelines

CQRS & Composite Pipelines

Clean separation of Commands and Queries with built-in cross-cutting pipelines: Zod Validation, Authorization, Idempotency, Concurrency Retry, and Caching.

Developer Experience

Fluent AppBuilder Config

A .NET-inspired fluent bootstrapper leveraging SetupActions to assemble your application cleanly, securely, and strongly-typed.

Result Monad

Deterministic Error Handling

Replaces unhandled exceptions with functional Result<T, E> monads and AppErrors, forcing safe error-state checks before payload extraction.

Database & Unit of Work

Type-Safe Drizzle ORM

SQL-first approach supporting PostgreSQL and SQLite/libSQL with an integrated Unit of Work pattern for atomic transaction blocks and automatic rollbacks.

Cockatiel Integration

Built-in Network Resiliency

RemoteDataSource combining Axios with robust resiliency patterns like retries, circuit breakers, and timeouts for external HTTP microservices.

Tooling (@xeno-js/cli)

Official CLI Scaffolding

Instant project initialization and module code generation through interactive prompts or rapid flags (--full / --empty) to bootstrap in seconds.

Fluent Architecture

Built with clarity, driven by types.

Configure loggers, database connectors, and transient dependencies in a fully type-safe manner. Xeno's fluent API design ensures your application bootstrap sequence remains clean, predictable, and completely transparent.

src/main.ts
import { AppBuilder, LOG_LEVEL, TOKENS } from '@xeno-js/core'

export const XenoApp = new AppBuilder<MyRegistry>()
   .addLogger((config) => {
            config.level = LOG_LEVEL.INFO
            config.console = true
    })
   .addDb((opts, config) => {
            opts.connectionString = config.getOrThrow('DATABASE_URL')
    })
   .addServices((srv) => {
        srv.addTransient('MY_SERVICE', (c) => new MyService(c.resolve(TOKENS.LOGGER)))
   })

await XenoApp.build()
TypeScript 5.x StrictUTF-8
Interactive experience

See the demo and understand how Xeno feels in practice.

A focused walkthrough designed to show the architecture, the developer experience, and the clarity behind each building block.

Architecture in action

See how commands, queries, and pipelines compose into a predictable runtime flow.

Type-safe bootstrap

Explore the fluent setup experience with modules, services, and explicit dependencies.

Fast onboarding

Understand the framework in minutes through a compact, practical walkthrough.

Trace Inspector
1. AuthGuard Middleware0.4ms

Context resolved via AsyncLocalStorage

2. Mediator PipelineZod Validated

Executing CreateOrderCommand payload

3. Result Monad HandledHTTP 201 OK

Safe payload envelope returned successfully

Status: Deterministic0 unhandled exceptions
Support Open Source

Help keep Xeno independent and sustainable.

Xeno is an independent, MIT-licensed open-source project. Building and maintaining an enterprise-grade framework takes countless hours of research, coding, and documentation. Your support buys precious time to keep the engine running.

Are you using Xeno in production? Reach out directly at xeno-js@outlook.it for enterprise support.