Firebase推送通知不起作用,我丢失了什么吗?

时间:2020-06-02 22:35:37

标签: ios firebase firebase-cloud-messaging

我正在尝试将带有FCM注册令牌的测试通知发送到设备,但是Firebase没有发送通知。

我有:

  • 在Firebase中创建了我的应用
  • 在Firebase的设置中添加了我的APNs身份验证密钥(也尝试过APNs证书)
  • 在我的Podfile中添加了Firebase / Messaging && Firebase / Core
  • 将GoogleService-Info.plist添加到我的项目中
  • 添加了后台模式(远程通知)和功能中的推送通知
  • following code添加到了我的应用程序代表
  • 甚至将FirebaseAppDelegateProxyEnabled = NO添加到了我的plist
  • 已在真实设备/模拟器上进行了测试。应用程序在后台打开&&
  • 也有notification images

1 个答案:

答案 0 :(得分:0)

我删除了FirebaseAppDelegateProxyEnabled = NO from my plist并添加了APN证书而不是密钥,并且可以使用