Skip to main content
zerotal

Documentation


Documentation / @zerotal/notifications / NotificationSent

Class: NotificationSent

Defined in: notifications/src/events.ts:58

Emitted after a notification is delivered (or fails) through one channel — distinct from MessageSent, which is mail-specific. One notification dispatched to N channels fires N of these.

Constructors

Constructor

new NotificationSent(className, channel, notifiable, ok, durationMs, error?): NotificationSent

Defined in: notifications/src/events.ts:59

Parameters

className

string

The notification class name, e.g. "OrderShippedNotification".

channel

string

The channel it went out on: "mail" | "database" | "slack" | "sms" | "broadcast".

notifiable

string

The recipient identity (email or id).

ok

boolean

durationMs

number

error?

string

Returns

NotificationSent

Properties

className

readonly className: string

Defined in: notifications/src/events.ts:61

The notification class name, e.g. "OrderShippedNotification".


channel

readonly channel: string

Defined in: notifications/src/events.ts:63

The channel it went out on: "mail" | "database" | "slack" | "sms" | "broadcast".


notifiable

readonly notifiable: string

Defined in: notifications/src/events.ts:65

The recipient identity (email or id).


ok

readonly ok: boolean

Defined in: notifications/src/events.ts:66


durationMs

readonly durationMs: number

Defined in: notifications/src/events.ts:67


error?

readonly optional error?: string

Defined in: notifications/src/events.ts:68