UNPKG

@mastra/core

Version:

Mastra is a framework for building AI-powered applications and agents with a modern TypeScript stack.

1 lines 576 B
{"version":3,"sources":["../src/events/pubsub.ts"],"names":[],"mappings":";;;AAEO,IAAe,SAAf,MAAsB;AAK7B","file":"chunk-4D4KB75Y.cjs","sourcesContent":["import type { Event } from './types';\n\nexport abstract class PubSub {\n abstract publish(topic: string, event: Omit<Event, 'id' | 'createdAt'>): Promise<void>;\n abstract subscribe(topic: string, cb: (event: Event, ack?: () => Promise<void>) => void): Promise<void>;\n abstract unsubscribe(topic: string, cb: (event: Event, ack?: () => Promise<void>) => void): Promise<void>;\n abstract flush(): Promise<void>;\n}\n"]}