I am using Appgyver to develop my app and have a couple of questions regarding push notifications.
I’ve managed to set up the app in IOS’s testflight but tried to push notification from console but it is not working even though I’ve already registered the device already.
May I know if there are any tools available in Backendless that allows me to test the push notification?
Please, make sure that the added IOS certificate works correctly. How exactly did you add the device to your application? By using registration API or via the console?
I would suggest you to try also sending messages through API and then check the status of that mail. What message status do you see?
You can use the following documentation to do this:
Not exactly sure what the messageId is for the “Get message status” api but I’ve tried with both message:{id} and {id}. The error seems to suggest that the device token is invalid/bad. May I know if this is something that I did wrongly while configuring the push notification in Backendless or the issue lies in Appgyver, when I am getting the device token? The same error messaged pops up at both android and IOS.
It is interesting situation since you should receive message status in any case.
Have you tried once more to send push notification from Console after device registration?
If not, please create push message template and use it to send message to your registered device. Please note, that Backendless can remove invalid devices automatically so check your registered devices after this operation.
Also, could you try to obtain message status directly using Postman or cURL? For that send one more message via your app to obtain fresh message id. Please note that message ID has next pattern “message:{id}”.
Yes, I’ve just tried pushing notification from console after registering my device but no notification received. Can I just double check if the settings for the push template is right?
I am not very good at coding and does not have the platform to perform API calls using Postman / cURL but I tried using Appgyver test api call and got the following error message when I tried to retrieve message status
I’ve noticed that the error states deviceid = null, may I know if there is a format/structure to follow for deviceid? Currently I am just parsing a randomly generated 4 digit for deviceid when a user register its device.
Your last message was very useful. “BadDeviceToken” is response from Apple APN service.
There are several reasons why you can receive this error.
One of them is mismatch of device token and environment. In other words, your token can be issued for prod environment while your certificate is for “dev” environment.
I did consider that possibility before, because currently Appgyver only allows me to build the app using distribution cert which would explain the mismatch of device token that you mentioned about.
However, I tried the same message test with android (live in playstore) + server key from Firebase and it shows the same result. Therefore, I am wondering if there’s anything that I did wrongly.
I have consulted with our IOS developer about your case. It seems that I misguided you a little bit and I am sorry for that.
To receive push notifications for IOS device you need to install your app on that device and make registration of device using our SDK. Backendless SDK during device registration will pick existing device ID or create new one basing on your app package name.
The same situation for Android devices - you need to create application and register it to Google C2DM server before sending push notifications from your website.
There are alternatives for push notifications which do not require native apps such as third-party services or browser-specific notifications.
Can I clarify, what do you mean by “make registration of device using our SDK.”? We are using Appgyver as our front-end, which I believe do not support installation of any libraries / entering any codes.
I mean that to receive push notifications on IOS and Android devices you will need to install native versions of your application on this devices.
You cant have just web application and send push notifications to IOS and Android devices. Apple and Google won’t deliver your push messages (you in this situation already - you receive error messages from APN and Firebase).
I mean that to receive push notifications on IOS and Android devices you will need to install native versions of your application on this devices.
The application is on Testflight on IOS and live in production on Android already. I am running the API when I am using the device, not on Appgyver.
You cant have just web application and send push notifications to IOS and Android devices.
Does this mean I am unable to directly blast a push notification from Backendless? We are only planning to use the push notification feature to make announcements on the application.
We would like to go live by end of next week and the push notification bit is the last feature that we want to implement. Would it be possible to connect through Backendless slack?
Would it be possible to connect through Backendless slack?
It is better to keep our conversation here. Our Slack channel only for simple yes/no questions.
The application is on Testflight on IOS and live in production on Android already. I am running the API when I am using the device, not on Appgyver.
Does this mean I am unable to directly blast a push notification from Backendless?
I thought that you have only we app. Since you also have and native apps you will be able to send push notifications to the devices which have installed your apps.
So we are going back to responses from APNS and Firebase.
However, I tried the same message test with android (live in playstore) + server key from Firebase and it shows the same result. Therefore, I am wondering if there’s anything that I did wrongly.
Could you please provide message status with this error message?
Sorry for the late response. We’ve managed to somehow get the message status to be published for android device. But when we tried to push with the push notification composer, we are not receiving any notification.