2
我在我的Node.js项目中发送了FCM集成,我向IOS用户发送了一些通知,我需要管理通知计数,即徽章计数在整个设备中会有所不同,但我正在向特定主题发送通知给这些设备被订阅。有没有办法将不同的徽章数量发送给同一主题中的不同用户?
我的有效载荷是:
var payload = {
notification: {
title: "Title...",
body: "Notification Body...",
sound: "customeSound.caf",
badge : "?"
},
data: {
testData: "custom data"
}
},
topic = "topicName";
admin.messaging().sendToTopic(topic, payload)
.then(function (response) {
// See the MessagingTopicResponse reference documentation for the
// contents of response.
console.log("Successfully sent message:", response);
})
.catch(function (error) {
console.log("Error sending message:", error);
});
});
感谢您的答复@AL,但这是我不想使用,我已经接近FCM。如果我将通过APNS ID进行分组,我将使用本地APNS系统。 –
嗨@aatifshaikh不幸的是,如果您继续使用FCM,这将会如何。 –
:(谢谢反正@AL。 –