推送通知可从FCM控制台运行,但如果从API发送,则显示"InvalidApnsCredential"错误(仅在iOS设备上) [英] Push Notifications work from FCM console but if sent from API show “InvalidApnsCredential” error (only on iOS devices)

查看:97
本文介绍了推送通知可从FCM控制台运行,但如果从API发送,则显示"InvalidApnsCredential"错误(仅在iOS设备上)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

推送通知FMC API在iOS上不起作用

Push notification FMC API doesn't work on iOS

我试图验证我的APNS证书,看起来还可以

I tried to verify my APNS certificates and seems okay

在FMC控制台中,测试通知起作用并成功到达iOS设备

From FMC console testing notifications work and arrive successfully to iOS devices

端点网址 https://fcm.googleapis.com/fcm/send

请求标头:

Content-Type:application/json
Authorization:key=**SERVER_KEY**

请求有效内容正文:

{
    "to": "**FMC_DEVICE_TOKEN**",
    "priority": "high",
    "notification": {
        "title": "Title",
        "body" : "First Notification",
        "text": "Text"
    }
}

响应正文:

{
    "multicast_id": 6714208302733418144,
    "success": 0,
    "failure": 1,
    "canonical_ids": 0,
    "results": [
        {
            "error": "InvalidApnsCredential"
        }
    ]
}

推荐答案

这显然是Firebase当今的全球性问题.在过去3小时内,许多人一直在报告此错误.我希望明天能解决.

This is apparently a global issue from Firebase today. Many people have been reporting this error in the past 3 hours. I hope it's gonna be fixed tomorrow.

这篇关于推送通知可从FCM控制台运行,但如果从API发送,则显示"InvalidApnsCredential"错误(仅在iOS设备上)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆