106: Push It to the Limit

Published: April 5, 2016, 1 a.m.

Discussion\n\nPush Notification Overview\n\n\nNotifications\n\n\nIntended for user\nCertificate required\nCan be disabled\nRemote vs. Local\n\n\nLocal - schedule by the app on device\n\n\nBest example is Reminders app\nSchedule by\n\n\n elapsed time or exact time\n location based\n\n\n\n\nRemote - come from your server\n\n\n\n\nActions\n\n\nInteractive Notifications\nCategories\n\n\nText Input\n\n\nNew type of \u201cAction\u201d\nBehavior is \u201c.textInput\u201d\n\n\nAPNS (Apple Push Notification Service)\n\n\nDevice token created by APNS, need to store on server, associated with particular client app\nPayload must include aps, but can also include custom values, as well\nPayload \u201caps dictionary\u201d: alert (string or dictionary), badge, sound, content-available, category\nPayload alert dictionary: title, body, title-loc-key, title-loc-args, action-loc-key, loc-key, loc-args, launch-image\nSilent notifications (content-available == 1) wakes your app in the background so that you can fetch data, etc.\nFeedback service, how to discover tokens that are no longer active\nDevice tokens are 32 bytes, may be increasing to 100 bytes soon\nNew provider API released in 2015\n\n\nHTTP/2\n\n\nnotification requests to APNS get a response\nmultiplexed\nbinary\n\n\nNotification requests\n\n\nPOST\njson\n\n\nNotification responses\n\n\n200 OK\n400 BAD REQUEST with json payload and reason\n\n\nInstant Feedback\n\n\nAllows you to learn about inactive tokens in the notification response via 410 status code in the response\n\n\nSimplified Certificate Handling\n\n\nNow one certificate for all push actions\n\n\nPush notifications payload size increased from 2KB to 4KB