有效负载格式FCM推送通知web
我目前正在使用以下格式使用API向客户端发送推送通知。有效负载格式FCM推送通知web,web,push-notification,notifications,firebase-cloud-messaging,web-push,Web,Push Notification,Notifications,Firebase Cloud Messaging,Web Push,我目前正在使用以下格式使用API向客户端发送推送通知。 { "notification": { "title": "Hey There", "body": "Welcome to Site", "web_link": "https://google.com" }, "fcm_options": { "lin
{
"notification": {
"title": "Hey There",
"body": "Welcome to Site",
"web_link": "https://google.com"
},
"fcm_options": {
"link":"https://www.google.com"
},
"to" : "eJW_5V9f5PPK48Ta1vDS8V:APA91bETTwu2UYTzSwjlaXEjv-p4nl61S-xgZIL3hWn9s6HWUR4fghtxctA0nb4dwxkRTJ5EXveCTwDsq4EviuZrxkFQHHJtovR7LeaTfTsbpYtpOdidEWNroTKMfbwG3xV0gJBlUpe"
}
通知已发送,但在后台显示通知时单击链接时,浏览器上的链接不会打开。
我尝试了多种格式,但似乎都不起作用。
{
"notification": {
"title": "Hey There",
"body": "Welcome to Site",
"web_link": "https://google.com"
},
"fcm_options": {
"link":"https://www.google.com"
},
"to" : "eJW_5V9f5PPK48Ta1vDS8V:APA91bETTwu2UYTzSwjlaXEjv-p4nl61S-xgZIL3hWn9s6HWUR4fghtxctA0nb4dwxkRTJ5EXveCTwDsq4EviuZrxkFQHHJtovR7LeaTfTsbpYtpOdidEWNroTKMfbwG3xV0gJBlUpe"
}