Я использую fcm для отправки уведомлений из моего приложения для Android, и я реализовал все библиотеки, которые он мне запрашивал.
val topic = "highScores"
// See documentation on defining a message payload.
val message = Message.builder()
.putData("score", "850")
.putData("time", "2:45")
.setTopic(topic)
.build()
// Send a message to the devices subscribed to the provided topic.
val response = FirebaseMessaging.getInstance().send(message)
// Response is a message ID string.
println("Successfully sent message: " + response)
Я использую этот код для отправки уведомления, но строитель показываетнерешенным.