N
Novu8mo ago
ujwal1373

Export Templates data

I am trying to understand the data model of Novu. For templates, I see that there are couple of collections - notificationtemplates and messagetemplates. If a template has been created, where does it go? If two templates have the same name, how to distinguish them based solely on the collections?
6 Replies
Ask Inkeep
Ask Inkeep8mo ago
Hi @ujwal1373, I'm an AI assistant for Novu. While a team member reviews this question, I'll look through relevant sources and see if I can provide suggestions. Please tag @Ask Inkeep with any follow-up questions. ----------------------------- While I generate an answer, here are some sources that might be helpful: * Workflows * Trigger Event Lifecycle * Get workflows * Send Your First Notification ----------------------------- Answer In Novu, the concept of "notification templates" has been evolved into what is now referred to as "workflows". A workflow in Novu acts as the blueprint for the notifications that will be sent, encapsulating the entire flow and rules of messages being sent across different channels. Each workflow will have a name and an identifier to uniquely identify it (1) . When you create a template in Novu, it essentially becomes part of a workflow. If two templates have the same name, they can be distinguished by their identifiers (IDs). Every item in Novu, including workflows (previously known as notification templates), should have a unique identifier allowing you to differentiate between them, even if they share the same name (2) . For managing specific message formats or content within a workflow, Novu supports creating steps that define the specifics of how a notification should be presented or sent on different channels. The distinction you made between "notificationtemplates" and "messagetemplates" aligns with how Novu separates the concept of workflows (the overarching process that includes triggering conditions and steps across channels) and the templates or steps within those workflows that specify message content for each channel. To summarize, in Novu: - Workflows act as the container for your notification logic, including conditions for sending and what channels to use. - Templates or steps within those workflows define the specific content and presentation of messages. - Unique identifiers are used to distinguish between workflows or templates, even if they share the same name. This integration of workflows and templates provides a flexible structure for managing notifications across multiple channels, allowing for detailed custo
Ask Inkeep
Ask Inkeep8mo ago
mization and control over the notification process (1) (2) .
Ask Inkeep
Ask Inkeep8mo ago
Got it. Tagging @Support for additional help.
Tomer Barnea
Tomer Barnea8mo ago
Hey @ujwal1373 check this resource out: https://docs.novu.co/getting-started/how-novu-works#architecture. High level, notificationtemplates are different messagetemplates, as each notification templates includes multiple message templates (steps), as for the name, the templates is identified by id, not the name, is that helpful?
Pawan Jain
Pawan Jain8mo ago
@ujwal1373 as shared by tomer, a workflow has steps and each step has messageTemplate
No description
Pawan Jain
Pawan Jain8mo ago
yellow highlighted text is used for mongodb collection
Want results from more Discord servers?
Add your server