How to send a push notification from the Firebase console to a specific GCM/FCM device token ID

Jaime Montoya picture Jaime Montoya · May 18, 2019 · Viewed 7.6k times · Source

In Urban Airship, when I am composing a notification, I can target specific users by searching for a Urban Airship channel_id (device ID):

enter image description here

enter image description here

enter image description here

enter image description here

I sent from Urban Airship the push notification that I am showing above, and I received it successfully. Now I want to do the same thing, send a push notification to a specific device, but now using the Firebase console. The problem is that in Firebase, in the step where I need to specify the target, it only allows me to choose User segment or topic. I was expecting to see a third option: Target specific users (for sending notifications to one or many specific GCM/FCM device token IDs. So my alternative is to add a GCM/FCM device token ID to a topic and then send the push notification to that topic, which is something that I have successfully done before. Nonetheless, that would be a workaround and not the way I would prefer to do this. Is it possible to send push notifications to specific users (by defining the target GCM/FCM device token IDs) from the Firebase console? Thank you.

UPDATE 1: See how the Firebase console (https://console.firebase.google.com/) only shows User segment and Topic as the Target:

enter image description here

Answer

BlackBlind picture BlackBlind · May 18, 2019

First Step: enter image description here

Second Step: enter image description here

Third Step: enter image description here