tec*_*wei 5 push-notification ios firebase firebase-cloud-messaging
我知道这个问题在 android 中被问了很多时间,但在 ios 中没有。所以我已经用 FCM 测试了推送通知它工作正常。我的问题是它是否是一种创建自定义通知的方法,而不是让系统使用通知负载处理通知?
小智 2
-用户可以使用FCM发送数据消息。您需要发送的是,
PostMan Json 数据示例:
{ "data": {
"any key": "any value",
"any key 2": "any value 2"
},
"to" : "token received to mobile from FCM"
}
Run Code Online (Sandbox Code Playgroud)
“数据”内的有效负载可以根据要求进行更改。
移动端:
application(_:didReceiveRemoteNotification:) 重写方法会被触发。因此,开发人员需要从 iOS 中的 userInfo 属性中提取数据并使用它。
| 归档时间: |
|
| 查看次数: |
1288 次 |
| 最近记录: |