Search code examples
mobilepush-notificationpushibm-cloudchatroom

In a mobile app on BlueMix, how the users can be easily grouped (authorization)


I am building a mobile app based on the BlueList example on Bluemix. I need to add a feature that the login users can be grouped and only users within certain groups get the notification. Like a chatroom app. What is an easy to use BlueMix services to help to implement this? Thanks a lot for your help. Zheng


Solution

  • Sounds like you need to create some tags for user subscriptions. You do not need to implement any kind of further authorization to enable what you are trying to do.

    Simply create a tag in your push application and name it whatever you'd like. You can do this through the Push Dashboard or through the REST API. Once a tag is created you can subscribe individual users to that tag. Then you'll be able to send out a push notification to that tag and only users subscribed to that tag will get the notification.

    If you are using the IBM Push Notifications service check out these docs:

    https://www.ng.bluemix.net/docs/services/mobilepush/using_tags.html

    If using the Push service (deprecated):

    http://mbaas-gettingstarted.ng.bluemix.net/android#subscriptions