N
Novuβ€’9mo ago
Sasha Trytiak

search logic in get push notifications request and read/unread status

Hello! I use API for get only push notifications via /notifications endpoint and have few questions: - I want to get it by some custom type (for example system_push, team_push). I know that novu has feeds or topic but as I understood it's only for in-app messages. Maybe I can use search query for that but I didn't found info for which data this search works. - How I can check read/unread status for push notifications? Or is it only for in-app notifications? I want to show it in push notifications custom list inside app. I didn't find some fields inside notification object. Thank a lot in advance for help 😌
9 Replies
Ask Inkeep
Ask Inkeepβ€’9mo ago
Hi @Sasha Trityak, 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: * How to send push notifications to Flutter apps (Android & iOS) with FCM using Novu * Backend SDK methods * How to send web push notifications with FCM and Novu * Introduction -----------------------------
Ask Inkeep
Ask Inkeepβ€’9mo ago
Answer For filtering notifications by custom types like system_push or team_push, Novu supports filtering notifications by custom payload data. This feature allows querying notifications based on custom data contained within their payloads, facilitating the filtering of notifications by types such as system_push or team_push if these are defined within the payload of your notifications. This can be achieved by specifying the custom payload data while querying the notifications endpoint (1) . Regarding checking the read/unread status of push notifications, Novu's documentation primarily discusses the handling of seen/unseen statuses for in-app notifications. It doesn't explicitly detail managing read/unread statuses for push notifications. Typically, push notifications' read/unread status management is handled within the receiving application's logic, as push notifications themselves are transmitted and displayed at the OS level without direct feedback to the sending server regarding their read status. However, you might consider utilizing the Novu system to track these statuses by employing custom logic in your application to record when a user interacts with a push notification, then reflecting this interaction in your application or back to Novu as an event (2) . In practice, for managing custom types and read/unread statuses within your application, you might need to implement additional logic or use the provided Novu features creatively to meet your requirements.
Pawan Jain
Pawan Jainβ€’9mo ago
@Sasha Trityak 1. Feeds/Tabs are for in-app notifications. Topics are not related to any channel. it is just a grouping of some subscribers. A workflow can be triggered to a topic. Search param is for subscriberId or email 2. Currently we don't support read/seen status for push notifications. Do you want to filter only push notifications by custom payload data? To fetch all push messages you can use get messages api with channel param value as push
Sasha Trytiak
Sasha TrytiakOPβ€’9mo ago
2. Yes, only push notifications for showing tabs with different push-notifications tabs thank you for the fast answers ❀️
Pawan Jain
Pawan Jainβ€’9mo ago
We do support this for in-app messages. I see we should support it for push as well. We have not received any request for push yet. https://docs.novu.co/api-reference/subscribers/get-in-app-notification-feed-for-a-particular-subscriber
No description
Pawan Jain
Pawan Jainβ€’9mo ago
Sharing this request team. is that a blocker for you to use Novu?
Sasha Trytiak
Sasha TrytiakOPβ€’9mo ago
@Pawan Jain hi! all good, we decided to use in-app notifications in all workflows and parse then it in custom notification center. And maybe you can give advice how to create Tabs via API and then parse in-app notifications via Tabs ids? Because I found solution only for Novu notification center, but we cannot use it in mobile
Pawan Jain
Pawan Jainβ€’9mo ago
@Sasha Trityak Get tabs/feeds using this api https://docs.novu.co/api-reference/feeds/get-feeds each in-app message will have _feedId field (if feeds are enabled in the in-app editor). You can map these two
Sasha Trytiak
Sasha TrytiakOPβ€’9mo ago
@Pawan Jain thanks. Can I filter in app notifications by feedId via API or I need to do it from client side only?
Want results from more Discord servers?
Add your server