Send notifications in batch with the Push API

APNs an GCM have always provided a way to send notifications in batch.

It would be useful to see this feature for the Push API, which unfortunately doesn’t have it yet, meaning that you have to make an HTTP request for each endpoint. If you want to send a web push notification to N users at a time with a single API request you can still use a service like Pushpad which makes the hard work for you.

Continue reading “Send notifications in batch with the Push API”

Service worker: importScripts never updates scripts

Pushpad is a service for web push notifications. In order to add push notifications to their websites, our customers need to install the service worker that we provide on their websites.

Initially we just asked customers to copy and paste the whole content of the service worker. However this meant that for every update we made to the script, our customers had to take action.

Then we discovered importScripts Continue reading “Service worker: importScripts never updates scripts”

The Push API and its wild unsubscription mechanism

The working draft of the Push API currently doesn’t offer a good way to manage unsubscriptions.

The problems arise in the following scenarios:

  • The user blocks the notifications from the browser preferences
  • The endpoint is replaced because it has expired

Continue reading “The Push API and its wild unsubscription mechanism”

Add push notifications to WordPress in a few minutes

In this tutorial we’ll see how to add push notifications to your WordPress blog. Notifications are real push notifications, meaning that they are delivered even when the user is not on your website. This way you can re-engage users when you publish new contents.

We are going to use the official Pushpad plugin. Continue reading “Add push notifications to WordPress in a few minutes”