Skip to content

Type Alias: BusNamespace<Domain, Subjects, FilterPayload, Schemas>

Makaio Framework


Makaio Framework / bus-core / BusNamespace

Type Alias: BusNamespace<Domain, Subjects, FilterPayload, Schemas>

Section titled “Type Alias: BusNamespace<Domain, Subjects, FilterPayload, Schemas>”

BusNamespace<Domain, Subjects, FilterPayload, Schemas> = object

Defined in: ../../../packages/bus-core/src/types/namespace.ts:13

A registered bus namespace with domain, subjects, and pre-computed filter payload type.

Domain extends string = string

The namespace domain string (e.g., ‘adapter:codex-mcp’)

Subjects extends SubjectRecord | BusSubjects = SubjectRecord

The subject record mapping subject keys to payload types

FilterPayload = unknown

Pre-computed intersection of all filterable payloads for type-safe withFilter

Schemas extends Record<string, SubjectSchema> = Record<string, SubjectSchema>

The original schema record; drives narrow literal types on subjects.$meta (e.g., local: false)

readonly optional __filterPayload?: FilterPayload

Defined in: ../../../packages/bus-core/src/types/namespace.ts:29

Phantom property for type extraction. Never accessed at runtime. Enables ExtractFilterPayload<T> to infer the FilterPayload type parameter without relying on complex nested generic inference.


name: Domain

Defined in: ../../../packages/bus-core/src/types/namespace.ts:19


subjects: BusSubjects<FlatSubjectDefinitions<Domain, Schemas>, Domain>

Defined in: ../../../packages/bus-core/src/types/namespace.ts:20

scopedBus(context?): Promise<ScopedBus<Domain, Subjects, FilterPayload>>

Defined in: ../../../packages/bus-core/src/types/namespace.ts:22

MakaioBusContext

Promise<ScopedBus<Domain, Subjects, FilterPayload>>

  • BusNamespace

    • `{ name: Domain; subjects: BusSubjects<FlatSubjectDefinitions<Domain, Schemas>, Domain>;

    scopedBus(context?: MakaioBusContext): Promise<ScopedBus<Domain, Subjects, FilterPayload>>;

    /**

    • Phantom property for type extraction. Never accessed at runtime.
    • Enables ExtractFilterPayload<T> to infer the FilterPayload type parameter
    • without relying on complex nested generic inference. */ readonly __filterPayload?: FilterPayload; }`
type BusNamespace = {
name: Domain;
subjects: BusSubjects<FlatSubjectDefinitions<Domain, Schemas>, Domain>;
scopedBus: (context?: MakaioBusContext) => Promise<ScopedBus<Domain, Subjects, FilterPayload>>;
__filterPayload?: FilterPayload | undefined;
};