XMPP Notfication service instead of GCM / APNS - client

How does device receive Android GCM push notification?
Hi,
In the link above the steps of GCM and Blackberry notifcation services are explained.
I'm wondering if it is possible to change the GCM (android) / APNS (iOS) to one central notfication service with XMPP? This because I want to build a server and client with XMPP and want to communicate between these as well with messages and notifications.
Thereby, with the setup of a webview in a android application and GCM sending notifications to the device, GCM is not reliable. Not all messages are send to the device. I'm not sure yet how this works for APNS, but the app will be used on different platforms and it would be nice if there is just one way of sending notifications.
Anybody experience with this? Or is there another way of implementing the notifcations?

iOS does not allow you to run apps in background (except of voice apps). This means that you cannot have a XMPP stream in the background with iOS. For iOS there is no other solution than APNS if you are not a voice app. Android does not have these restrictions. Windows Phone 7.X hast the same restrictions as iOS, I don't know how Blackberry handles this.

Related

The triggered notifications are not receiving in to the android devices

The triggered notifications are not receiving in to the android devices, and these scenario's are failing to receive the notification.
1) When the Android/iOS mobile app doesn't has the internet but notifications are triggered from the FCM Console or FCM Api(We developed the api to trigger notifications). Few minutes later Android/iOS mobile app get internet access, immediately Android/iOS mobile app should get all triggered notifications. But Android mobile app doesn't receive the any notifications, iOS mobile app able to receive the all notifications.
2) We have Scheduler to schedule the notifications by Daily basis, the android mobile app is not receiving the scheduled notifications from the FCM Server, but iOS mobile app received all scheduled notifications from the FCM Server.
Kindly requesting you please help me to resolve these scenario.
Let me know if you require more information on my side.
Push notifications are managed by firebase service for Android. Google software decides how to queue and when to push notifications to the device. If you are pushing iOS notifications through firebase, Apple service decides when to push notifications to the device. That means that these services doesn't have to follow the same pattern. The real question is if all notifications are received finally by android device or not. If all there is no error in your code. What you can do is to set higher priority for android notifications. Google service takes in count traffic, battery state and several other factors when sending notifications to device. If Android device does not receive any notifications during lets say 1 hr, you should revisit your code.

Clickatell sending blank message to iphone from sandbox account

I'm using clickatell sandbox account, when i try to send sms to iphone using send sms api receiving only blank message.
PS: In Andriod it's working fine
Since no adjustments are required between iOS and Android, and the Android device received your message, the problem is likely with the handset.
Suggestions:
Ensure that network coverage is strong
Ensure that the mobile number(s) is not in roaming mode
Ensure that phone memory capacity is not full
Restart the iPhone to refresh the device on the network (keep the device off for +-10mins)
Check if any phone applications or settings may filter out messages, or consider swapping the sim to another phone to test
After checking all of these, you can try again
Should you still have an issue, I recommend contacting Clickatell support on support#clickatell.com. They would be able to run live coverage tests for you.

Can a web application use a personal phone to send a text message

I have a client who sends about 5000 SMS messages each month. They are currently doing this from an iPhone, by actually typing the message in to the phone. (I think the messages are quite repetitive, and are often addressed to groups).
The reason that they are not using an online message gateway is purely the cost. We can use a gateway here in Australia (such as Amazon SMS) for about 7.5 cents for transactional (and 2.5 cents for promotional, though I don't know if this is reliable enough).
When the client uses their own iPhone, the SMS is included in their plan, and costs them nothing extra.
I am building a web-based application for the client and the question is 'Can I send SMS via a handset connected to the client's desktop PC'. I think the answer is no, but would like to be surprised. The application is responsive, so what about if they triggered the messages from a browser on the phone? Still no?
If you could use an Android phone instead an iPhone, you could create a small gateway app on the Android that can send text messages without the need for the user's intervention.
It could work like this:
The Android app would have a simple REST interface, a good start could be https://github.com/NanoHttpd/nanohttpd.
An endpoint in the Android app could send messages, see Sending SMS programmatically without opening message app
The software on the computer would use the rest endpoint on the Android phone to send the message.
This wouldn't work on the iPhone because it doesn't allow an app to send a text message without the user's intervention.

Slow APNS on IBM Bluemix

I developed a PHP backend for a mobile app that runs as an Bluemix CF app. I use custom PHP code to send push notifications via APNS. Everything works but the connection to APNS is extremly slow. The same app uses GCM for push Android devices and this works great. Any advice?
It is not uncommon to see a delay in APNs Push Notifications as seen in some of the other posts:
Apple's APNS Delivery is Sometimes Slow
How much delay of ios push notification?
In regards to PHP specifically I also found a post about delay in connection:
Pushing notifications using ApnsPHP is slow
Finally I will share with you a document from Apple showing the architecture of APNs in order to get a better idea of how and where the delay may occur:
Apple Push Service

How is whatsapp fetching message in background in windows phone?

After the latest update of Whatsapp on Widows Phone Store, I have noticed that now, once they show the toast of message on my device, then they mark the message as delivered (notify the sender that the message has reached my device).
After I let the toast notification go away, I switched off all my data connection and opened Whatsapp and found that that particular message in my app. This is happening consistently on both wp7 and wp8 device. This was happening even when I had disabled background agent! Beside background agent of an app does not run all the time.
So my questions is, on windows phone platform, where the app is not allowed to run in background all the time, how is Whatsapp application getting those messages? Is it using any particular api/hack to get(in app) those messages when it's not on foreground.
The question you have asked has two parts: one for wp7 and the other for wp8. I will anser each one by one.
Windows phone 7
Based on my research, I have found that whatsapp is still using audio streaming api on wp7 devices to stream messages in the background i.e. when the app is not running. Whatsapp was criticized of using this API as constantly using this causes battery drainage as well as hampers the music experience of the user.
Windows Phone 8
Once whatsapp moved to wp8 they stopped using the Audio API and moved to VOIP API. Note that whatsapp doesn't use VOIP for any purpose but their manifest shows usage of VOIP api, and after reading many articles I have come to the conclusion that they are using this API to activate background agent and pool messages in the background.
While sending raw push of type 4, the background agent for VOIP is activated in which you can practically do anything from reading the payload to establishing a new socket connection subjected to restriction on usage of certain APIs
I have also found out that even if a user disables bg agents for an app some essential bg agent still continue to run for eg bg agents in audio stream API and VOIP API.
I hope this answers your question.
Go through this link
Push notification for Windows Phone
What will help you to understand is
The server maintains a maximum of 30 notifications (regardless of type) for each URI. Once the limit of 30 is reached, all new messages sent to the server are discarded until the device reconnects and the queue can be flushed.
In windows phone there is something called raw notifications, these are different from push notifications, push notifications display a notification, but raw notifications triggers a background task that can run under certain api restrictions for about 15 seconds. (I think, I'm not sure about the time duration), I think what whatsapp does is that it downloads the message and saves it in a local database which is maintained in the device. When whatsapp is opened it will read the local database and also sync with the server.
Please correct me if I am wrong.

Resources