Page 1 of 5

Push Notifications are not working in iOS Devices, token undefined

Posted: Fri Dec 12, 2014 6:00 am
by Rajesh Gehlawat

I looked through this issue on the tutorials but didn't found anything that solves my problem.

I've made the an application and added the development/production push notification certificate for iOS, but when I send a push from appery.io site, it gives me status "Error" with the following error "Device Token has a length of [9] and not the required 64 bytes! ", I checked the DB token value appears to be undefined.

Furthermore, in the database only one device is added, if I try the app in another iPhone it gives me success registration but no device is added to the DB, only accepts one row and the token value appears as "undefined" as well.

Looking forward for a reply. Thanks


Push Notifications are not working in iOS Devices, token undefined

Posted: Fri Dec 12, 2014 6:04 am
by Rajesh Gehlawat

Attached is the screenshot of the database and push notifications screens.

Image

Image


Push Notifications are not working in iOS Devices, token undefined

Posted: Fri Dec 12, 2014 7:04 am
by Evgene Karachevtsev

Hello Rajesh,

Please look at this link, hope you'll find the useful information there:
https://getsatisfaction.com/apperyio/...


Push Notifications are not working in iOS Devices, token undefined

Posted: Fri Dec 12, 2014 7:51 am
by Rajesh Gehlawat

Hey Evgene,

Thanks for the quick reply. I have already looked into that ticket. But didn't get the solution.

Initially, I tested the iOS push notifications and found out the certificate is not correct. It was giving the below error:

Error occurred while loading the keystore: Invalid keystore password! Verify settings for connecting to Apple...

So I uploaded two diff certificates from my account one for production and one for the development, after adding those I got a separate error, Below is the error:

Device Token has a length of [9] and not the required 64 bytes!

The app is currently in Development and dev certificate is being used.

And the token in DB is blank again.

My app name is "Hang with me". Can you please look into it.


Push Notifications are not working in iOS Devices, token undefined

Posted: Fri Dec 12, 2014 11:04 am
by EJLD

Hi There, in fact I am interested in that solution 'coz I still have the same issue.
I put it aside thinking to get another iOS device to test.
It seems I am not the only one, the problem must come from somewhere else.
looking forward to hear from you guys.
Thks in advance
Eric


Push Notifications are not working in iOS Devices, token undefined

Posted: Fri Dec 12, 2014 7:55 pm
by Rajesh Gehlawat

Any update please?


Push Notifications are not working in iOS Devices, token undefined

Posted: Fri Dec 12, 2014 11:11 pm
by Illya Stepanov

Hi Rajesh,

Here what you can try:

  1. Re-set all your push certificates in 'Push notifications settings';

  2. Re-link your Database to your app;

    -- build and install on a device again.


Push Notifications are not working in iOS Devices, token undefined

Posted: Sat Dec 13, 2014 11:20 pm
by EJLD

Hi Rajesh, like to know if you can succeed with that Re-set/Re-link, 'coz it never worked for me. Thks, Eric


Push Notifications are not working in iOS Devices, token undefined

Posted: Mon Dec 15, 2014 7:03 am
by Rajesh Gehlawat

Hey Illya,

I am still getting the same error after re-linking the DB and resetting the certificates.

Token value is undefined again. Attached are the screenshots.

Image

Image


Push Notifications are not working in iOS Devices, token undefined

Posted: Mon Dec 15, 2014 7:04 am
by Rajesh Gehlawat

Didn't worked for me too