nomad-cli / houston

Apple Push Notifications; No Dirigible Required
http://nomad-cli.com
MIT License
2.93k stars 229 forks source link

Should use apns-priority:5 instead of an empty sound string for silent push notificaitons #155

Closed rsaunders100 closed 3 years ago

rsaunders100 commented 7 years ago

This stackoverflow answer has a good explanation of this issue.

In the houston docs it says

To send a silent push notification, set sound to an empty string ('')

Instead we can set the apns-priority to 5

Send the push message at a time that takes into account power considerations for the device. Notifications with this priority might be grouped and delivered in bursts. They are throttled, and in some cases are not delivered.

The default is priory 10 which is disallowed for silent push.

Notifications with this priority must trigger an alert, sound, or badge on the target device

Which is why it's believed you need to send a sound to get silent push working.

From my testing using an empty sound string causes a vibration of the app.

rsaunders100 commented 7 years ago

It seems the priority property is supported in houston, so I think the problem is just with the docs.

rsaunders100 commented 7 years ago

Although it seems it's not possible to set the apns-priority header from the command line tool