【问题标题】:Firebase Cloud Messaging APIFirebase 云消息传递 API
【发布时间】:2017-11-28 13:47:06
【问题描述】:

我们正在使用适用于 iOS 和 Android 的 Firebase 云消息传递。只是想知道是否有可能创建一个 Web 应用程序,该应用程序有一个表单,我们可以同时向两个平台发送推送通知 - 假设我们知道要发送到的主题。 (可能使用 POST/cURL 请求)

【问题讨论】:

  • 使用 FCM 设备发送消息要求您的代码指定所谓的服务器密钥。顾名思义,此密钥只能在服务器或其他受信任的环境中使用。不可能安全地将消息一个设备直接发送到另一个设备。另见stackoverflow.com/a/39279716/209103
  • 在 Firebase 中安全发送消息的最简单方法是使用 Cloud Functions。请参阅此示例:firebase.google.com/docs/functions/…

标签: php firebase firebase-cloud-messaging


【解决方案1】:

是的,您可以使用 firebase 集成(网络推送通知)在某些网络浏览器中发送推送通知

请通过以下链接

https://developers.google.com/web/fundamentals/push-notifications/
https://www.w3.org/TR/push-api/
https://firebase.google.com/docs/cloud-messaging/js/client

【讨论】:

    猜你喜欢
    • 2016-10-10
    • 2018-03-24
    • 1970-01-01
    • 1970-01-01
    • 2019-07-12
    • 1970-01-01
    • 1970-01-01
    • 2017-04-27
    • 1970-01-01
    相关资源
    最近更新 更多