Push Notification from server - android

I have developed an app in which i am collecting data from server through parsing. So , i want to add push notification in my app whenever the service adds new data. I have searched the web bt cldn't fnd smthn useful.

The best way is to either get a webserver with cronjob this will send information directly to your mobile ... or, to make an backgroundservice in your application.
It's not a simple thing to do, in the upcomming few days I'll be posting a tutorial on http://p-xr.com wich explains it in detail.

Related

What is the workflow to get live data updates from NodeJS/MongoDB API?

I need to fetch live data in Android App from a NodeJS/MongoDB API. For exemple, I have a list of tasks on the Android screen (fetched from the API). Then one of this documents (tasks) have changed in the MongoDB, the Android screen needs to update the data on the screen once this data have been changed on the server.
Can anyone help with some workflow? I am not looking for code. Ideias (Arquitecture/Libs) only.
Thanks in advance!
You can do this in two way.
Use silent push notification.
When data change in server then server send push notification
to app.
App receive notification Then app get call API to update Data.
Your app sends a request(s) to server periodically (After some
interval of time)
Reference link for same: link1, link2

How to push notification to android app, when new data is available at server?

What i did is :
I have used JobScheduler. In every two hours, it checks weather there is a new data available or not in Server->Database->Table. If new data available it retrieves the data and notifies to the subscriber.
Kindly any one suggest me weather this is right approach or not?
Is there any other way to do so?
Can I implement PUB/SUB concept here..
If yes, How?
I am using Godaddy Hosing..
No,its not a good way
You may try like this
1) Integrate FCM Push notification at Backend side(PHP etc)
2) Take Legacy Server Key for Push notification from Firebase
3) Wherever you will get update of data send notification using Device Token
4)at app side you need to add code for handle push notification
for more help refer this URL

How to send notification to user when a record is added in the DB

I'm developing an Android application , i have to develop an activity that contains a simple communications board .
The information that i want show are contained in a database , When the user started the activity the informations are downloaded , parsed and Showed to users.
Now i would implement a function That notify to the user When a new information is inserted in the db.
Now what that i don't understand is:
I need to implement a service that runs in background and polls the database and notify to the user when a information is inserted or can i use only the GMC (now FCM) ?
If i don't want use GCM there are another solution to do this ?
I have read some thread in stack overflow and there are different solution but i don't understand what is the best solution for my problem.
Speaking at a high-level, here's what I would do.
If I didn't want to use GCM then I would write my own service to make an http request to my backend web server to check if any new information is available. If any new info is received save it to my local Android database and refresh the app. I'd use Android's AlarmManager to start this service every so often (hourly, daily, whatever frequency I want).

Receive notification at particular time from webservice

In my application i need one functionality say: Appointment. Appointment will be created from website.
Once it is created, at particular time(Say appointment time) webservice will be triggered and send
response.From android, i have to wait for that particular response and catch that response and i will
send to notification.the question is ..how do i find that webservice is sending response,and how do i
recieve that response whenever service sends response.
It will be more helpful if any1 provide me with clear answer...
Thanks in Advance...
What you're looking for is called push notifications.
Google provides this through c2md (deprecated) and the new, but nearly the same, GCM.
You can find a lot of info about this by searching those 2 terms.
Also I can recommend using UrbanAirship.com, as they simplify the process greatly and are free up until a great amount of notifications.
They've got extensive documentation and examples on how to send and receive from both client as server.

Can I send periodic messages to my Android app users?

Is it possible to make a app on Android such that whoever downloads this app receives a message from me weekly? I want to be the only person who can write on this message board and no one else. If this is possible, where should I start looking for tutorials about doing this sort of stuff?
You can create a RSS/Atom feed for yourself. Your android app can then just sync to this feed. Update the feed as often as you like. If you like this approach I can give more details.
yes , you can send periodic messages see this
in that SendMessage(); function is there so you have to make code for send message to recipient

Categories

Resources