I hired a developer to create an android app. The work had been done. I received myapp.apk. It's working properly.
Now, I want to to add push notifications function to the app. The developer is not available again. I did not received any source code. I just received the myapp.apk.
I found that I can extract myapp.apk. After extraction, there is a file called AndroidManifest.xml and many other files and folder.
Can I add push notifications by modifying AndroidManifest.xml file? If yes, what are further steps needed? If no, what are all possible methods to add the push notifications to myapp.apk?
It is much more complicated than just modifying the AndroidManifest file.
Typically, there would be three things to do:
Setup code in your app to receive a Push Notification. This is usually done in a BroadcastReceiver.
Register with some type of service such as Google Cloud Messaging, Firebase Cloud Messaging, or Parse.
You will likely need some type of code on a server that determines when to send your Push Notifications and what the content will be.
Doing it through Google Cloud Messaging / Firebase Cloud Messaging is the more common and robust approach. You can find information about it here.
You could also do it through a service called Parse. I have used Parse in the past and it was much easier to setup than Google Cloud Messaging but is more basic. You can find information about Parse here.
If you are looking for the easiest possible way to send basic Push Notifications, I would go with Parse. There is still a good amount of setup to do, but it is the easiest option that I am aware of.
Related
I want to develop a website that will be able to send push notifications to a mobile application that would be able to run on both android and iOS.
For the last couple of years, I am working as a web developer so developing the website is not something that I am worried about, but I have never developed a mobile application before, the mobile app would only receive notifications from the website so the main functionality would be in the website.
Can anyone suggest me what the best approach is and what I have to learn to be able to do this?
Thank you in Regards
I guess, you have 2 options.
You can either use Firebase FCM
https://firebase.google.com/docs/cloud-messaging/
or use a third party which is called OneSignal
https://onesignal.com/.
If you are looking for an easier way then I recommend using OneSignal instead. You just need to define API Key in your build.gradle and initialize OneSignal in onCreate().
The best approach, in my opinion, would be to use firebase (https://firebase.google.com/products/cloud-messaging/). I think it is better because it is a unique framework for both ios and android and you don't need to worry about the user device when sending the message(you could build an interface in your backend code to handle this but why doing something that already exists and it is free).
The flow is something like this:
on the first start the app(either ios or android) must send its firebase ID to your server so that you can store it (simple http request will od it) and set up a listener for the incoming push messages
when you need to send a push message all you need to do is an http request and you can trigger it with js from your website. The request will contain data such as the firebase id of the receiving device(which you have previously stored)
Firebase Cloud Messaging also have some really nice features like upstream messages(push messages from the device to the server, but you need an xmpp server to listen for them) and topics to send the same notification to many users at the same time
I think the best approach would be to create a node server where the website would be running on and then use Firebase Cloud Messaging (FCM) to send notifications
EDIT: FCM supports both Android and iOS
I have Python2.7 and installed this modules: feedparser, Kivy, plyer and setuptools-17.0.
I am developing a simple Android app with a web-viewer inside and the core functionality is that I parse a simple XML and whenever a new feed is posted I want the user to receive a push-notification on his Android Device.
I have my own web-server and also I've tried different push services on the web, but they are trials or very limited. Can someone please give me guidance on how to manage the push-service? Maybe a couple of hints on which modules I need to get my job done.
You will need to create a couple of services that interact with Google's GCM
You will need a callable URL that can process the registrations of the device when the app is first started.
You also need to send a JSON file with the data to be sent when you have a new notification to be sent.
All of this is fairly straightforward in Python.
You can get more information here.
https://developers.google.com/cloud-messaging/
You will need a Google account to setup GCM
I have an android application where push notifications are implemented by GCM.
I need to change this. I need that with the new release (the app is already in the Store and people already use push with GCM) all the mechanism will be handle from Parse.
Can I simply delete everything concerning GCM and implement everything concerning PARSE and then upload the version of the application and be sure that everything will run the same?
Has anybody an idea if there will be conflicts with doing this? I'm thinking about devices that already have a GCM token for example.
You should try it and see. I think when implementing Parse, the registration ID (unique to every app <--> device) will be generated again. I've written a couple of articles on the topic which are not directly useful but can help in other ways.
Just make sure you follow this thoroughly.
I am looking to create an Android app that uses a MySQL database located on a server. When certain changes are made to this database, I'd like a push notification to be sent to some app users. My question is, is the Google Cloud Messaging Service required to implement this? This page http://developer.android.com/google/gcm/index.html seems to suggest that using the Google Developers Console is also required. If so, is it possible to export this project into Eclipse? Thanks in advance.
My question is, is the Google Cloud Messaging Service required to implement this?
Yes and no, if you want to do real push messages then yes it is required however if you dont want to use GCM you can use XMPP to send messages to devices
Push notification can be generated using alarm in android.See this.
But here you are looking to send push notification after certain changes in your database which is located in your server,for that GCM will be a better option.You can find an excellent tutorial of GCM here.
I am currently developing an app where users create posts that are stored on a server. When another user shows interest in a post by clicking a button, I want to notify the author of the post using push notifications. I have already set up the data storage using cloud endpoints with Google App Engine. Is there anyway I can use these endpoints to implement push notifications? If not is there another easy way to implement push notifications given my current setup? I have already read about Google Cloud Messaging on the developers page but was somewhat confused. I have kept track of the registration id's but I don't really know where to go from there. Thanks in advance.
You can use the HTTP interface to the GCM servers as described in this
Android developers page.
The easiest way to do it is by downloading the Google Cloud Messaging for Android Library using the Android SDK Manager, which will give you a jar that handles all the complexity of setting up the requests and responses to GCM.
Towards the bottom of that page, there is a sample Java application for push notifications on App Engine which you can use to get familiar with sending push notifications and then adapt to your needs.