Created
December 23, 2017 09:05
-
-
Save n1lesh/2fc47c6d945cc83a9bf928289eb6e23a to your computer and use it in GitHub Desktop.
Firebase Cloud Messaging with Node.js - FCM 4
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const sendToTopics = (msg, title, topic, response) => { | |
const data = { | |
"data": { | |
"body": msg, | |
"title": title | |
} | |
} | |
data['to'] = '/topics/' + topic | |
sendNotifications(data) | |
response.sendStatus(200) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment