Send customized notifications when triggering events via topic.

We have a use case where we want to send customized notifications to subscribers of a topic. We have been sending some notifications to individual subscribers and adding some information related to the user in the payload.
body_params = {
name: workflow_name,
to: { subscriberId: user_id},
payload: payload
}
body_params = {
name: workflow_name,
to: { subscriberId: user_id},
payload: payload
}
We want to add a new type of event where we add multiple subscribers to a topic and then trigger the event.
body_params = {
name: workflow_name,
to: [{ type: 'Topic', topicKey: topic_key}],
payload: payload
}
body_params = {
name: workflow_name,
to: [{ type: 'Topic', topicKey: topic_key}],
payload: payload
}
However, we are losing the ability to send the data related to every unique user. I am not able to find anything related to this in the docs.
7 Replies
Rishabh-PriceLabs
Rishabh-PriceLabsOP4mo ago
cc: @Pawan Jain
Pawan Jain
Pawan Jain4mo ago
So you want to send different payload to each subscriber?
Rishabh-PriceLabs
Rishabh-PriceLabsOP4mo ago
Yes
Pawan Jain
Pawan Jain4mo ago
Currently it is not possible with topic
Rishabh-PriceLabs
Rishabh-PriceLabsOP4mo ago
So the alternative is to trigger the event individually for each subscriber right?
Novu_Bot
Novu_Bot4mo ago
@Rishabh-PriceLabs, you just advanced to level 3!
Pawan Jain
Pawan Jain4mo ago
Yes
Want results from more Discord servers?
Add your server