I have to build a feature in my application which allows user to send a skype message.
For this I have installed skype lite client for Android (although offically the download has been currently withdrawn from Skype).
Now how to initiate the activity from my application OR simply send the chat message without bringing it front, assuming I have skype installed in Android & also signed in already.
Any help ? Thanks.
Unless the application, Skype in this case, has some publicly available Intents you can send (like Twidroid has for tweeting) it is not possible.
Alternatively you could find some kind of a Skype proxy web-service that you could call from within your application to relay the messages.
Related
Environment:
Ejabberd Version : 16.04
Smack-android-4.1.0
I have created an Android chat application with a XMPP server. However due to Google play permission issue I had to narrow down the feature from app which supported receiving incoming message notifications when the app is in the background.
As an alternative I received the following suggestion from GooglePlay Review Team.
Once you’ve removed this permission, you might consider using Firebase
Cloud Messaging (FCM) if your app’s message delivery requires a
temporary exemption from battery optimization. Please set high
priority only if the message is time-critical and requires the user’s
immediate interaction, and be aware that setting your messages to high
priority contributes to more battery drain compared to normal priority
messages
So at the moment users can send messags via the app. But when he close the app, he will be considered as an offline user, and will not receive any notifications from app. When he opens the app again, he will get all the offline messages those were saved the Ejabberd server.
I want to enhance the current app so that even though a user had closed the app he will still receive a notification when some one sends a message to him (Similar to whatsapp)
Is there a module in ejabberd which integrates the server with FCM and handles this?
If we can not achieve this by Ejabberd, is there a 3rd party library to support this?
If not do we have to write an Erlang module from scratch?
I found similar questions in the internet but I could not find any working solution. Since I am not much experienced with Erlang and would be glad to hear your solutions/ideas on this. Thanks in advance.
This can be achieved in Ejabberd with offline_message_hook. This hook is trigger when sending a message to the receiver and receiver in an offline state. So create a custom module using this hook and you can send a push notification to FCM and APNs servers.
Refer this blog -- https://jasonrowe.com/2011/12/30/ejabberd-offline-messages/
Looks like you need to try apply approach below:
Create REST API for store of user tokens with JID's of users
Create custom hook for fetch XML packages.
Integrate into project the epns library(this library can send FCM/APNS)
In custom hook call the spawn function where will be get the user token from DB by JID and creating payload with sending FCM/APNS notification
we have a web application using responsible html, it is seamlesly usable from mobile browsers...
We would like to send "event" (push notification) to users phones (device!). Standard notification with icon of our app and short text. Pending intent would be just open our web application in browser (URL).
So, question is how to do this without need of client application installed on target phone which would provide registration of such device (send it to our server, who will use it later to let firebase to notify such device).
Is it possible to create a device registration from browser (chrome)? Either to google account used in device or ask to fill it ...
How are web notification related? If I understood it correctly, a page with our app needs to be opened to receive web notification. What about instant apps?
Yeah, we could create a very simple application which would be linked (google play) from our web application - which would provide JUST registration a receiving of push notification. And than just open a browser. But it looks to me as unnecessary, because push client is part of android system. The only what we need to send device ID to our server...
Thanks for any idea. Ideally, a link to documentation or proof-of-concept on github (-: because I believe it is a standart situation.
PS: And sure, as always, at the end we would like to have it multi platform. And no, we prefer not to use non-system providers like pushy ...
I wanted to create a chat browser that would send the message to an android app. For example, I do not have an app that my friend uses. However, I don't want to install the app. I will use this browser to send the message to my friend in his app. And when my friend gets this message in his app and he replies from his app, Me on the other hand will receive the message in this browser.
Are you developing both apps? If so, check out something like Firebase: https://www.firebase.com/. It is suited for exactly what you are looking for. Real-time updates to all clients that are connected.
These neat little App_Script created for Android with browser compatibility should do the trick. This takes both an input box and a message box.
Doing the desired function of sending and recievings Messages.
Documentation here
you will need to be in the same source Code as the other user or a mirror App like viber on the example you provided, on the other hand you could create an application to send regular texts to mobile phones, but that's another subject.
I'm making a NodeJS server and an Android app that goes with it. I need to send alerts to my mobile app users that's coming from the web server. Something like a a chat app on the server and the android users getting the messages also (Facebook messenger?).
I have the server ready and Android app communicating to its database (for user login/getting user info/etc) using REST. I just need to figure out how to send info to the Android app WITH THE SERVER INITIATING COMMUNICATION. Any advice on where to start?
Start by looking at Google Cloud Messaging.
It's a free service that accepts messages from your server-based program and queues it to be sent to phones with your app when the phones are online.
Here is the overview on Android Developers.
YES!
Working with NodeJS, you have probably already heard of Socket.IO.
I'd say: Start there!
For your app to communicate with the server, there's also the java lib. These are great tools to start making any good real time service.
After you get along with this, you should also check GCM as #krisLarson suggested. And talkign about GCM, you have Node-GCM to make your work even easier.
Good luck!
How can i send a data from Server to android directly without waiting for the request received from the Android.
I have found one solution that is C2DM but it require separate Google account to use it Now i am afraid if i install the same app on two different android will it work or not
Plz suggest if u have some other mechanism.
Note: I dont want to use Network socket.
It will work. You need a gmail account registered for each android device AND a gmail account registered for sending out C2DM.
Alternatively you should make your own C2DM by polling your server at a regular interval (not recommended though).