Anatomy of a notification
A notification in Novu is designed to provide complete visibility and control over its lifecycle.Sample Notification Object
Key Components
-
Identification
_id
: Unique identifier for the notification._environmentId
: Links the notification to a specific environment (e.g., staging, production)._organizationId
: Identifies the organization that owns the notification.
-
Transaction and timing
transactionId
: Tracks individual notification transactions for auditing and debugging.createdAt
: Timestamp indicating when the notification was created.
-
Channel and delivery
channels
: Specifies the delivery channel, such as in-app notifications, email, SMS, or push notifications.
-
Subscriber details
subscriber
: Contains user-specific data:firstName
,lastName
,email
,phone
: Information about the recipient._id
: A unique identifier for the subscriber.
-
Notification workflow
template
: Links the notification to a predefined message format:_id
: Identifier for the workflow.name
: Workflow name.triggers
: Events or actions that initiate the notification (e.g., user sign-up, order confirmation).
-
Jobs
jobs
: Tracks tasks associated with processing and delivering the notification.
Notification APIs
Notifications
Query notifications and update messages individually or in batches via the Novu API.