ios - Push notification/alternative that can timeout -


i working on application must notify user of server-initiated event. these notifications useful short space of time (30-60 seconds). reason, looking method can both deliver notification quickly, and, importantly, can somehow invalidate (retract/cancel/timeout) notification after has been delivered.

my understanding apns not suitable this. 'send , forget', giving no ability check/modify/delete notification. functionality integral app though, open suggestions methods or services might let me achieve this.

in mind there several options:

  1. server sends notification user. server later sends 'cancel' message user, removes notification.

  2. server sends notification user, has built in timer. timer monitored locally, , once elapses, notification removed.

  3. app periodically polls server , schedules/cancels local notification according server says.

my preference option 2, because self contained , efficient. 1 message initiates both scheduling , cancellation. option 3 has issues ios shutting down app if it's in background (not mention rate @ have poll server given notification useful ~30 seconds).

do services such urban airship offer functionality achieve this? other suggestions/complete work around methods? appreciated.

thanks time!

matt

edit: in interests of encouraging out of box thinking, idea might server initiates automated phone call app user. if user answers call, required information given them. if not, information no longer available. bit wacky, , instinct costly, i'm open anything!

anything happens asynchronously can done push notifications provides unidirectional, instant communication channel between , customers, no need strange phone calls (which can interrupt users' activities, bothering them).

you can go dual solution, in notify users of how many unread notifications have in inbox. can implement own in-app message inbox, connects servers , fetches relevant data (in case hasn't expired - if has, let user know -).

this way users able know how many notifications have been made available them, check ones still valid. urbanairship employs approach rich push feature.

apart this, need bear in mind push notifications can intrusive user, use them wisely or you'll see users unsubscribing them or worse, uninstalling app.


Comments

Popular posts from this blog

Change php variable from jquery value using ajax (same page) -

Pull out data related to my apps from Android Play Store and iOS App Store -

How can I fetch data from a web server in an android application? -