hessonit
hessonit

Reputation: 13

Android Google Cloud Messaging between users

I'm trying to use GCM to establish communication between some users. They should send to each other their GPS location. Is it even possible? There is a subscribeToCloudMessage method but I don't know whether it will be useful or not.

Info: Server works fine (Google app-engine) with all the required keys.

Upvotes: 1

Views: 293

Answers (1)

Eran
Eran

Reputation: 393841

It's possible for one app to send a message to another app via Google Cloud Messaging if the sending app knows the registration ID of the recipient app. Usually when a app register to Google Cloud Messaging, it sends it's Registration ID to a server, and that server sends GCM notifications. If you want the app to send the notifications directly, you must send each device (where the app is installed) the Registration IDs of other devices that it needs to send messages to.

Upvotes: 1

Related Questions