@xemahq/events
v0.2.0
Published
<p align="center"> <svg width="680" height="120" viewBox="0 0 680 120" fill="none" xmlns="http://www.w3.org/2000/svg" role="img" aria-label="@xemahq/events"> <rect width="680" height="120" rx="14" fill="#0B1020"/> <g transform="translate(28,34)">
Downloads
5,159
Readme
@xemahq/events
Typed CloudEvents descriptors, registry, and generators
Overview
The framework-agnostic core for typed events: a CloudEvents 1.0 envelope built
on the official cloudevents SDK, typed event descriptors, a descriptor
registry, payload validation, a pluggable transport interface, and AsyncAPI /
event-catalog generators. Pure types, zod schemas, and small helpers — no
NestJS, no frontend, no query-cache knowledge. The NestJS and frontend layers
build on top of this package.
When to use it
- Use it to declare typed event descriptors and validate or generate documentation for them, independent of any framework.
Installation
pnpm add @xemahq/eventsUsage
import { EventRegistry } from '@xemahq/events';
const registry = new EventRegistry();
registry.register(myEventDescriptors);
const descriptor = registry.getOrThrow(eventType);License
Apache-2.0 © Xema — xema.dev
