[英]Is there dry_run functionality for APN?
While implementing notification sending functionality for android and ios, I ran into the issue where dry run is needed.在为 android 和 ios 实现通知发送功能时,我遇到了需要试运行的问题。
For FCM, this solved the problem but the issue still remains for APN.对于 FCM, 这解决了问题,但问题仍然存在于 APN。 Is there the dry run functionality for APN?
APN 是否有试运行功能?
You can try using validate_only
in FCM v1 API.您可以尝试在 FCM v1 API 中使用
validate_only
。
The Content Available option with below value initialized did the work for me.初始化为以下值的可用内容选项为我完成了工作。
The official documentation states as below:官方文档说明如下:
Suppose you include the content-available key with a value of 1 to send out a silent notification to your users.
假设您包含值为 1 的 content-available 键,以向您的用户发送静默通知。 In that case, it will not alert the user in any way (update badge count/play a sound/show a notification), but it will wake your app up in the background, allowing you to fetch new content and prepare it for the next time the user opens your app.
在这种情况下,它不会以任何方式提醒用户(更新徽章计数/播放声音/显示通知),但它会在后台唤醒您的应用程序,让您获取新内容并为下一次准备用户打开您的应用程序的时间。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.