N
Novu6mo ago
lena_dooms

Events to invalid receiver email

Hi! I was implementing some new emails and couldn't figure out an issue - some mails were not showing up on activity feed. Turns out I was sending an invalid receiver email (id instead of email). The weird part is that sending the trigger worked fine, it was acknowledged and even a transactionId was returned, but on the platform these triggers are already filtered out. This made it difficult to debug as the entire flow seemed to work. Is there any way to have this as part of input validation so a trigger with a bad email throws an error? Or have them show up on activity feed with the 'invalid configuration' like what happens for example if a 'sendAt' is in the past? Extra info: I am using the PHP SDK
6 Replies
Ask Inkeep
Ask Inkeep6mo ago
Hi @lena_dooms, I'm an AI assistant for Novu. While a team member reviews this question, I'll see if I can find relevant sources for your question. ----------------------------- While I generate an answer, here are some sources that might be helpful: * Trigger Event Lifecycle * Trigger event * Observability * Activity Feed -----------------------------
Ask Inkeep
Ask Inkeep6mo ago
Answer Currently, Novu's system primarily ensures the workflow is processed correctly and returns a transactionId as part of its idempotent operation, which means it acknowledges the request even when the email might be incorrect or improperly formatted. The system is designed to handle inputs as valid as long as they fit the basic structural requirements, and specific validation of email addresses does not occur at the triggering stage (1) . For the events not showing up in the activity feed when there is an invalid receiver email, it's crucial to note that Novu's activity feed will show the triggers as sent, but it may filter out those with invalid configurations before they reach the final notification stage. This is part of the system's design to ensure that only valid and deliverable notifications are processed (2) . Regarding your request for having invalid emails trigger an error, or show up on the activity feed with an 'invalid configuration' status, this is not currently supported as per the existing documentation. It's a valuable suggestion for improving the observability and debugging capabilities of the Novu platform. A potential workaround could be implementing a preliminary validation step in your application logic before sending the trigger to Novu. This could involve verifying email formats or ensuring that email addresses are correct before they are sent to Novu. For now, you might consider implementing additional checks in your application or suggesting this feature in Novu's community or GitHub repository to see if it can be included in future updates.
Pawan Jain
Pawan Jain6mo ago
@lena_dooms Thanks for the feedback. As you mentioned, you used id in place of valid email address, do you see error in activity feed related to this?
lena_dooms
lena_doomsOP6mo ago
Hi @Pawan Jain , thanks for the fast reply. No, there was no error in the activity feed related to this. The event didn't show up in the activity feed at all
Pawan Jain
Pawan Jain6mo ago
@lena_dooms Would you like to share example trigger code snippet, which showed above behaviour?
lena_dooms
lena_doomsOP6mo ago
Hi @Pawan Jain here is some extra info. Any request with a nonsense email has this behaviour. Above I have included a screenshot containing a transactionId that was acknowledged, but that didn't show up in our activity feed (dev environment). It goes a step further even: in the app it's also possible to test a workflow. If I trigger this with a nonsense email I enter an eternal loading screen because creating the trigger returns 201 but it's not found in the notifications
No description
No description
Want results from more Discord servers?
Add your server