Bobj-C
Bobj-C

Reputation: 5426

How to send push notifications to users' devices, not just my own

I want to ask about what I need to make a Push Notification, I reed a lot of things and Succeeded send a push from my mac to my devices that exists in the organizer (using PushMeBaby source code). but also I'm confused about make it for other devices (all who has my app) and How I get their Token Device number ?

Just in Big title tell me what I need.

Thanks

Upvotes: 0

Views: 443

Answers (2)

Isaiah Turner
Isaiah Turner

Reputation: 2662

Not to promote other peoples stuff but there is an easy way to send notifications with premade code by xtify and Parse google them they are both free.

Upvotes: 0

Max
Max

Reputation: 16719

Use UIApplication's

- (void)registerForRemoteNotificationTypes:(UIRemoteNotificationType)types

The device token will be returned via callback:

- (void)application:(UIApplication *)application didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)deviceToken

Then you have to send deviceToken to your server. Note: deviceToken can change from time to time. So you have to check it every time and resubmit to your server if it changes.

Make sure that port 2195 is opened on your router. You should also register your application for remote notifications on Provisioning portal.

Upvotes: 1

Related Questions