import type { ChannelConfig, DeliveryResult, EmitOptions, EmitResult, EventEnvelope, EventFilter, EventPage, EventPageOptions, EventInput, EventRedactor, ReplayOptions, ReplayResult } from "./types.js"; import { type EventsStore } from "./storage.js"; import { type TransportDispatchOptions } from "./transports.js"; import { type EventTypeCatalog } from "./catalog.js"; export * from "./types.js"; export * from "./storage.js"; export * from "./filter.js"; export * from "./signing.js"; export * from "./transports.js"; export * from "./ssrf.js"; export * from "./catalog.js"; export * from "./app-event.js"; export { redactPaths, redactSensitiveKeys } from "./redaction.js"; export interface EventsClientOptions extends TransportDispatchOptions { store?: EventsStore; dataDir?: string; redactors?: EventRedactor[]; /** * Event type catalog used by the opt-in emit-time validator hook. Defaults * to the shared `defaultEventTypeCatalog`. */ catalog?: EventTypeCatalog; /** * Opt-in: when true, emitted events whose `type` is registered in the * catalog are validated and rejected (with `EventValidationError`) before * they are stored or delivered. Unregistered/free-form types always pass. * Defaults to false, so existing emitters are untouched. */ validateCatalogTypes?: boolean; } export interface ChannelMatchResult { channelId: string; matched: boolean; event: EventEnvelope; filters?: EventFilter[]; reason?: string; } export interface TestChannelOptions { honorFilters?: boolean; } export declare function createEvent>(input: EventInput): EventEnvelope; export declare class EventsClient { private store; private redactors; private transportOptions; private catalog; private validateCatalogTypes; constructor(options?: EventsClientOptions); addChannel(input: Omit & Partial>): Promise; listChannels(): Promise; removeChannel(id: string): Promise; emit>(input: EventInput, options?: EmitOptions): Promise>; listEvents(options?: EventPageOptions): Promise; listEventsPage(options?: EventPageOptions): Promise; listDeliveries(): Promise; deliver(event: EventEnvelope): Promise; matchChannel(id: string, input?: Partial): Promise; testChannel(id: string, input?: Partial, options?: TestChannelOptions): Promise; replay(options?: ReplayOptions): Promise; private appendEvent; private applyRedaction; private deliverWithRetry; } export declare function sanitizeChannelForOutput(channel: ChannelConfig): ChannelConfig; export declare function sanitizeChannelsForOutput(channels: ChannelConfig[]): ChannelConfig[];