implementing push notifications in your ionic app

Implementing push notifications in your IONIC app

A couple of years ago, services began emerging that brought the simplicity of typical pub/sub systems to push notifications. Instead of having to manually track your user's phone IDs individually, these services allow you to simply subscribe your users to desired channels to receive push notifications from.

For example, if a user wants to be notified when a course on Javascript is published on Thinkster, we could subscribe them to a channel called "javascript" that thousands of other users could also be subscribed to. However, to trigger a push notification to all of these users would only take one line of code - simply publish a push notification to the "javascript" channel and all of our users will receive it. Compare this to querying your database that contains your user's phone IDs, segmenting which users want to be notified about Javascript, and then sending out notifications individually for each of them to APNS/GCM. Yuck!

There are a few services out there that provide this pub/sub functionality, but at this point in time, we highly recommend using Parse for managing your push notifications. Here's why:

  • It's widely adopted and battle hardened from usage across 100,000+ apps
  • It's free to send an unlimited number of push notifications as long as you have < 1 million users (!!!) registered on your app (after that you have to pay a measly five cents per thousand additional users)
  • Their plugins and API are insanely easy to use

We will do an overview of a couple other services available to you later on in this course, but in general the setup across these various services are very similar!

 

 

Share this post