I have a very simple app made with android studio, an web viewer for my forum app. I integrated push notfications to be able to send notifications like "Hi! There are some new subjects on our forum, check it out" and make people open the app. I followed the exact documentation from here https://pushbots.com/developer/docs/android-sdk-integration
I am now able to send notifications to all the users that have my application. My problem is that they dont see the notification unless they have the application opened. For example, if I test it and send a push notification, but i dont have the app opened, i wont receive anything. I want to be able to send notifications even if they have the app closed, that's my point, i want to make them open the app to see the new questions on my forum
What should i do?
Make use of what was formerly known as Google Cloud Messaging and is now known as Firebase Cloud Messaging. Can push messages to user phone even when app is closed
Related
I want to stop my Android App opening automatically when I click on the PUSH Notification send via Google FCM. I have changed the message type from Data Message to Notification message.
The PUSH I am sending via the server REST API has a promo code in it, but has nothing to do with my App really, so I dont want the Android App to open at all. I can't used the FCM Console to send the PUSH notification as each promo code is unique to the user and their pet, and there are thousands of them. I'm using the test http v1. api but the actual Android App has been built by someone else and I dont have access to the source code. What should I be looking out for ? Is the PUSH auto opening the App due to a call it makes and an intent in the app I can't change?
Thanks for any guidance.
In the startup I'm currently working, we have developed a push server that enables the user to receive push notification when new content uploaded in our database.
Our system currently stores how many push are send and through Google analytics we can see how many people interact with the push notification, yet we would like to know how many people in total receive the push notification.
How can we count how many devices recevie the push? Which method could we use? As an example users unistall the app but we still have them stored on our database, or users may opt-out from the push through system settings (both ios and android)
Thanks for the help!
You can achieve it using same analytics by which you are able to identify how many people interacted with push using analytics. you will have to call your analytics function for pushRecieved in broadCastReciever for your GCM implementation.
I am developing a small chat application using node.js for iOS and Android, Now my question is that one user created a account and logged-in using this application from iOS or Android, then the user deleted this application without log-out. How the server knows this device has deleted the application without log-out?. Since, while user again installing this application, the push notification is still arriving without the user log-in.
Apple has a feedback service to give you information about failed remote notifications. Basically you listen the messages from feedback.push.apple.com and you flag the devices returned from feedback service. So no further push notifications will be delivered to that device. When user installs your app again you can remove the flag and start delivering the notifications.
For the android part check this question; Is there an Android GCM equivalent to the iOS Push Notification Feedback Service?
I'm making an app for android and I wanted it to be able to receive a notification when ever a website changes it's content.
I'm fairly new to app development and have no idea where to start. Any help would be appreciated.
Thanks
First of all you must register your users with your website with a unique key. for e.g. GCM(Google cloud messaging registers user when the start the app.)
For detailed information about GCM go through this link
Note: GCM is free to use.
Then if Your website gets updated you must send a push notification to all registered users and in your mobile application you must register a broadcast receiver to receive that notification and display in your desired UI.
If you don't own the websites:
I think you would need a program (in your server or computer) querying the websites that you care about and comparing their HTTP info for update date. And if you see any updates, send notifications from your server to the app (using Google Cloud Messaging).
Other methods for knowing the last time it was modified: check last time website updated
If you do own the websites:
you could use Google Cloud Messaging every time you update to push a notification from the server.
And here they talk about it and even list some tutorials : GCM in stack overflow
Vogella's tutorial : link
This question already has answers here:
How to make a chat application in android? [closed]
(6 answers)
Closed 9 years ago.
I am developing an Android app in which I have to implement chat messaging. I would like one to one chat or a group chat.
But I have no idea how to start. Please help me with this stuff. Any help will be appreciated.
A simple chat mechanism will have 2 basic functionalities
Send the message to server (with info about the recipient)
Receive the message from server (designated for my user name)
First step is simple, we can create a web service which will accept the message with additional information about recipient(s). We can create it using any server side language.
Step 2, that is fetching the message from server can be done using 2 techniques, Pull the message (using polling) from server, or Push the message from server to android phone
Polling: In this, the android device will keep accessing server after a few seconds to check if there is a message available for user. This again can be implemented using a simple async task at the client side which will keep calling a web service after say 2-3 seconds. This is fine to use if we are planning to enable chatting only when user is accessing the app (no notifications like gmail or facebook), so that we can kill the polling service when not in use (otherwise it will eat up resources).
Push notifications: a better option is to use push notifications. Android provide Google cloud messaging or GCM (http://developer.android.com/google/gcm/index.html) which will help achieve push from server easily. Otherwise you can try a third party API like urbanairship or pushwoosh depending on your requirement. Push notifications will help the user to receive messages even when he is not using the app.
So in nutshell, a webservice to receive the messages and a push notification mechanism should be sufficient to implement a chat service in android.
Little bit about UrbanAirship
I used UA in one of my projects for push notifications as I needed to support both iOS and Android. If you just want to support Android GCM might also be a good option.
Coming back to UA, check this for sample code and usage: https://docs.urbanairship.com/display/DOCS/Home
The way it works is simple, when someone installs the app and is connected to internet, app registers itself to the UA service. A unique code is specified for each installed app (this is the time when you can capture the user name and unique code and store somewhere in your DB). Next UA provides an API using which you can push a message to designated recipient(s), using the unique codes which are available with UA. These messages can be received by android app and used as per the requirement. Even if the app is not running we can show a notification just like when we receive an email or a message
You can use an existing platform like Scringo. It gives you a one-on-one chat as well as group chat (both the client and the server) as well as the push notification service.