Unread channels with multi tenant - getstream-io

I develop an mobile app with multi tenant. Like slack, the user can switch on multiple workspaces.
Is there a way to get unread channels and/or unread messages filtered by team id ? In order to get unread channels for each team ?

Related

Adding facebook like notification feature to MERN app with isRead flag

I am trying to add facebook like notification feature for my app. Instead of different notification for different user I have general notifications which are common to all the users. And for every user I want to have isRead flag so that I can show the user read and unread notifications. So, the question is, how should I design my model and how should I achieve the isRead functionality??
One idea in my mind is to create a notification collection with all the notification and have a field of readBy in which I will store the userId of all the users who have read this notification. And while showing the notifications to the user I can check whether his name is in the readBy field or not and show read or unread notification accordingly.
But is this method efficient? If not please suggest any more efficient method.

App Center Push Notifications rate limits

I have implemented App Center Push notifications in my Xamarin forms app, with several messaging strategies.
send same message to list of users.
Note
The App Center Push to User feature limits notifications to 100 users and up to a maximum of 1,000 target devices.
In my logic I break the messages into 100 user blocks.
send unique message to each user (1 user/push).
My question is there a rate limit on how many times I can hit API per minute, per hour etc?
When sending the individual custom messages and group messages, if i need to send to 1000 users, that's 1000 or 10 API hits.
Or did I miss a way to do this in documentation?
I believe that closest you can get as of now - is assigning userIds on SDK side, or using install IDs, and then setting up Push campaigns based on batches of those fields, manually.
Refer to those pages for more details:
Install ID
User ID
App Center is retiring Push Notifications. Means this is no longer a concern and different path will have to be taken.
https://devblogs.microsoft.com/appcenter/app-center-mbaas-retirement/

Retrieve invited users with Telegram Bot API

I have a Telegram channel and a Telegram bot using Node.js and PSQL. With a command (for example /how), I need to return to the user the number of user which has been invited to the channel by this user (and has joined).
How can I retrieve this list of users ?
If by "invited" you mean users who sent others a link to the channel then Telegram API does not provide such functionality.
However, channel administrators can add users to the channel and those should be sent as regular Message updates with new_chat_members field set, all you have to do is log those updates to the database and then fetch it with your command.

Track sms conversation with twilio and there is multiple conversation between two numbers

I am building customer service application and I have integrated Twilio for all SMS operations.
Now when customer request for the service system will generate one ticket and details will be messaged on customer's number.
and then the customer can message to my Twilio number which is service center specific(I mean each service center has been assigned one Twilio number) and service center executive can reply him back so I want to make this SMS conversation.
I can use cookies twilio SMS conversations but it won't work in the case when my application will first message as I can only set cookie when my server is actually acting as a server which will be only in receiving SMS
which is narrated in Application Initiated Conversations section in above article.
and another problem is there can be multiple tickets for single user with particular service center so how to manage it.
Any help is appreciated.
Twilio developer evangelist here.
SMS is a simple protocol that has no idea of different conversations, simply a chronologically ordered set of messages. There are two ways to get around this.
You can either insist that your user include an ID for the ticket they are referring to so that you can parse it out of the message and associate it to the right conversation.
Alternatively, you can add more than one number per service centre that can be used for different conversations.
Let me know if that helps at all.

Get all channels associated with a PubNub subscribe key

Is it possible to get all the channels associated with a Pubnub subscribe key?
All channels that were ever created using this key?
Thanks,
You can get a list of all channels that are actively subscribed to using a Global Here Now call - http://www.pubnub.com/docs/web-javascript/presence#gobal_here_now
There is no option to get a list of channels that were "created" in the past but are not active now. Here are a couple of alternatives that could work for you.
Stream Controller (Channel Groups)
With channel groups, you can manage subscriptions to channels centrally. By assigning a channel group to each user, you can list all channels (active or inactive) that were added to their channel group. PubNub maintains the subscription list for all channel groups and here's how you will retrieve them
http://www.pubnub.com/docs/web-javascript/stream-controller#listing_channels_within_group
Presence Callbacks
PubNub allows you to specify a HTTP callback URL that is triggered when a channel becomes "active" or "inactive". This way, your server will be notified whenever a channel is "created" and you can persist that information to a database so you can query at a later time.

Resources