How can I discover and read active Android notifications? - android

How can I discover and read active Android notifications? If there is any way to launch them directly?

If you're referring to the standard Android notifications from the NotificationManager, then No, there is no way to discover and read active notifications. If you have access to the Android source code, you could modify the NotificationManagerService to provide this type of behavior.
If you're only concerned about duplicating notifications, the NotifcationManager has a built in system for preventing duplicate notifications.
As far as "launching them directly", I'm not entirely clear on what you're trying to do. What is it that you're trying to do that you can't accomplish using the functionality outlined here: http://developer.android.com/guide/topics/ui/notifiers/notifications.html?

I don't know what you want to find out. did you mean the notification with other apps? or cloud to device message?(C2DM). If you want catch the messages from google(C2DM) you can catch the messages with broadcastreciever in your application service. check the c2dm or notification service in google docs

Related

Can an iOS or Android app interact with another apps interactive push notifications?

I'm looking to make an app for myself that will sleep until a push notification from another specific app comes through and then automatically accepts or declines the interactive push notification. Is it even possible to have an app that reacts to other apps push notifications? If it could react, then could it then interact with the notification?
I know that apps cant directly interact with the interfaces of others, but since this would be using push notifications I was hoping there would be something I could do. I cant find anything on this anywhere else or at least I don't know what to look for.
Not sure about IOS but in Android we could use to listen Broadcast to listen Broadscasts by system and other apps. But i think there has been some restrictions recently with Broadcast due to battery optimisation. Of-course you can achieve this with another app only if you know what broadcast they're triggering so you need to have some partnership with these other apps.
iOS:
I fairly doubt that it is possible on iOS with a straightforward API, but take a look at this post: https://stackoverflow.com/a/43523429/768567
Android:
For Android you could implement a NotificationListenerService: https://developer.android.com/reference/android/service/notification/NotificationListenerService
There is a repository on Github with some example code:
https://github.com/Chagall/notification-listener-service-example

Reading notification without NotificationListenerService in android

I'm currently working on app that read certain notifications and then silencing some of them. I've managed doing this using NotificationListenerService on Android 4.3+ but I would like to make it compatible for previous versions too. So is there anyway to listening to incoming notifications and getting its content?
I heard about AccesibilityService but I don't quite understand if it is possible to use it to read notifications' content and how. Any suggestions?
Thanks from adavnce!
It's possible with the accessibility service (event 64)
You can get at the notification object from this and then parse it.
There's a sample class of parsing the notification here: http://notifications-widget.googlecode.com/svn/trunk/NotificationsWidget/src/com/roymam/android/notificationswidget/NotificationParser.java

Notify android app regarding content changes in the server

Prior to posting this query here, I have gone through a similar requirement by a user in the post here
Based on research, what I understand is, push notification concept can be used to notify the application of any changes happening in the server, if and only if, the server control rests with us.
I have made an application which would display the data from a mobile website. Is there a way out by which I can notify the handset user of any change happening in the server, such that the user gets an alert in his handset, so that he can open the application and see what is the new addition/change that has occurred in the website, when I have no control over the server? Pardon me , if I sound totally dumb with this question. Had such a requirement and was curious to know the way out, if any.
This way you should build your own web service which will poll other service for changing and then push alert to android device via Google Cloud Messaging for Android (GCM).
But you also can poll this service with your own application in background service. This method is very bad because of battery drain and network connection using, but this is no need for 3rd party services
try noczone.com, they have custom notification service with an easy to use PHP sdk
https://noczone.com/?page=custom_alerts_sdk
i use it to let me know whenever i receive a support ticket or any new registrations.
and you will need to have their app installed to receive notifications on it
https://play.google.com/store/apps/details?id=com.wr.noc

How can we access notifications of other application in android?

Is there are a way to acess the notifications of other applications like
bluetooth notifications should be opened programatically?
For detecting missed calls see: Show Toast on Missed Call in android application
For SMS detection see: Android sms notification
You might also read up in the Android Developer docs on Intents (specifically on their use in broadcasting) and BroadcastReceiver.

IOS/Android Push Notifications - Basic question

I don't know if this question has already been answered. In my IOS/Android app, I wanted to monitor a URL for updates (for example, UPS Tracking). I would like to know if I'm using a API for tracking parcels, and even if the provider says that they don't support Push Notification, is there any other way for my app to enable Push Notifications? All I need is get notified by APN or Android Push notification when there is a change in the package status even if the provider doesn't support it.
Also, is this possible with Urban Airship?
Thanks.
Ideally, you will need to build your own backend server to sendout notifications using Googles C2DM service: http://code.google.com/android/c2dm/index.html
I'd assume you'd send the paracel ID to your server, capture it, then check for updates periodically. Then, once the status has changed, leverage C2DM and push out the notification to your client.
If you choose to have a service on the device check for this, I'd be cautious - you can easily chew up a lot of expensive data transfer, for not a lot of value.
If I understand your question correctly, I think the recommended solution is to use a service to periodically check the URL for updates and if the status has changed, push a notification to the user from your service.

Categories

Resources