Questions tagged [firebase-cloud-messaging]

Firebase Cloud Messaging (FCM) is the new version of GCM. It inherits the reliable and scalable GCM infrastructure, plus new features. It is a cross-platform solution that let user reliably deliver and receive messages and notifications at no cost. It supports Android, iOS, Desktop Web Browsers, the Mobile web with JavaScript or WebPush and Internet-of-Things (IoT) devices.

About Firebase Cloud Messaging

Firebase Cloud Messaging is a component of the Firebase suite of tools for cross-platform application development.

  • Send unlimited upstream/downstream messages
  • Send messages to individual devices or a user segment
  • Handle all aspects of queueing and delivery
  • Optimize for battery efficiency

Using FCM, you can notify a client app that new email or other data is available to sync. You can send notifications to drive user reengagement and retention. For use cases such as instant messaging, a message can transfer a payload of up to 4KB to a client app.

How does it work?

An FCM implementation includes an app server in your environment that interacts with FCM via HTTP or XMPP protocol, and a client app. Additionally, FCM includes the Notifications console, which you can use to send notifications to client apps.

Firebase Notifications is built on Firebase Cloud Messaging and shares the same FCM SDK for client development. For testing or for sending marketing or engagement messages with powerful built-in targeting and analytics, you can use Notifications. For deployments with more complex messaging requirements, FCM is the right choice.

Related tags

12555 questions
4
votes
1 answer

Android Firebase Push Notification with image from server(php) not showing image in notification while app in background

I am implemented android firebase push notificaiton with image using php(server). Notification with image working perfectly while app in foreground. But while app in background only notification received with title and message but image not…
sundar
  • 67
  • 1
  • 5
4
votes
6 answers

didReceiveRemoteNotification function doesn't called with FCM notification server

I'm using FCM server for remote notifications, it worked perfectly with sending and receiving notifications. My problem is when the device is in the background, this function func application(_ application: UIApplication,…
4
votes
1 answer

Android - firebase cloud messaging, two apps in one firebase project

I have two android applications. I am using only one firebase project for both of them, with both applications included in it. So I have only one google-services.json with specified keys for both my applications. I am trying to use firebase cloud…
4
votes
2 answers

Behavior of calling FirebaseInstanceId.getToken

I have two types of questions around FirebaseInstanceId.getToken(String authorizedEntity, String scope), one around calling this method multiple times and one around whether calling this method triggers FirebaseMessagingService.onNewToken(String…
hcabrams
  • 131
  • 9
4
votes
1 answer

Send Push message through FCM google-php-api HTTPv1 API

I'm trying to use the Google PHP API Client https://github.com/googleapis/google-api-php-client/ to send a FCM push notification through the Google HTTPv1 API. require_once 'vendor/autoload.php'; //-- loading the google api…
4
votes
1 answer

TypeError: Cannot Read Property child of undefined

I am trying to make a node.js firebase function to send a notification to the user each time a node is added or updated inside the 'Notifications' parent node in my realtime database. Here is my index.js- let functions =…
4
votes
1 answer

I want to handle exception generate from fcm if device token no longer valid

I face the issue that if device no longer exists the fcm response containing the error like that { "message": "Client error: `POST https://fcm.googleapis.com/v1/projects/internationalfriendspusher/messages:send'resulted in a `404 Not Found`…
4
votes
1 answer

Firebase statistics report (sends / impressions)

We are trying to monitor the status of our Firebase Cloud Messaging feature in our Android app. We regularly receive feedback from users who say they do not have them. By checking the Google Firebase reporting tool, we have found that, for the last…
Fran Palomares
  • 134
  • 1
  • 8
4
votes
2 answers

How to integrate FCM in node.js for push notifications?

I want to add the push notification thing using FCM in Node.js .For that I tried this and this and also this My nodejs code var FCM = require('fcm-node'); var serverkey = 'SERVERKEY'; var fcm = new FCM(serverkey); var message = { to :…
Neha
  • 389
  • 4
  • 8
  • 24
4
votes
2 answers

Not receiving Firebase Cloud Messaging Notifications in ios

I use the Firebase Cloud Messaging Notification in my ios's app, but when I tested the real machine, I found that I could not receive any push messages. I use the firebase unity package for ios. I checked all the steps, but I don't know where the…
4
votes
1 answer

Android with Firebase not receiving notification from Node.js Firebase app

I have an android app that successfully receives notifications from the Firebase console. I now intend to build a nodejs server where we can send these notifications to save logging into the firebase console, however, it appears that the node.js…
Wayneio
  • 3,466
  • 7
  • 42
  • 73
4
votes
0 answers

Application not whitelisted

I have been testing the Push notifications and notifications in xamarin.android application using Firebase Cloud Messaging, and am successfully receiving the notifications, however for the first time the applications starts normally, and then if I…
4
votes
3 answers

Fire base onMessageReceived isn't working at all

I've looked over all the answers I could find, the particular function of code isn't working even in foreground. I tried changing the manifest, changing the code, all i get in the logger are these 2 of these things: D/FA: Logging event (FE):…
4
votes
1 answer

Xamarin.iOS: Firebase push notifications not working

I am developing a Xamarin.Forms application with Xamarin.Android and Xamarin.iOS clients. For push notifications, I am using FirebasePushNotificationPlugin library. It works perfectly on Android, but not on iOS. On iOS the app simply closes down…
GregorMohorko
  • 2,739
  • 2
  • 22
  • 33
4
votes
0 answers

android - Get Data From Notification via Intent When App Not Running

I have an app using Firebase Notification and when the notification coming i want to open the application and get data from it. Now i'm using getLaunchIntent() to open app but it's only open when app is in backstack/running in background. If the…