Push Notifications don't work on iOS

213 views Asked by At

I have an issue with push notifications using Arrow.

In development mode, everything is fine, registrations are correctly send and notifications are well received on both android and iOs.

In production, no problem for registration. Each device is stocked into Arrow and I can see it in my account with its device_token.

When I try to send a notification to users, only Android users receive them. Nothing on iOs. I took an Apple Push Services certificate and transformed it into P12 file.

Here is my registration code :

var Cloud = require("ti.cloud");
 // Subscribes the device to the 'news_alerts' channel
 // Specify the push type as either 'android' for Android or 'ios' for iOS
    Cloud.PushNotifications.subscribeToken({
        device_token: deviceToken,
        channel: 'news_alerts',
        type: Ti.Platform.name == 'android' ? 'android' : 'ios'
    }, function (e) {
        if (e.success) {
            Ti.API.info('Subscribed');
        } else {
            Ti.API.info('Error:\n' + ((e.error && e.message) || JSON.stringify(e)));
        }
    });
}

Subscriptions are OK, Development mode is ok, Android on production is OK...

Any idea ?

Thanks !

0

There are 0 answers