gpt4 book ai didi

android - Android 和 iOS 推送通知中最多可以显示多少个字符?

转载 作者:IT老高 更新时间:2023-10-28 22:16:13 26 4
gpt4 key购买 nike

在不截断文本的情况下,Android 推送通知中可以显示的最大字符数是多少?

iPhone 的文档指出,通知负载的总和必须小于 256 字节,但我无法为 Android 找到类似的东西。

最佳答案

安卓

Firebase 云消息传递 (FCM) 中的消息大小限制为 4 KB。 https://firebase.google.com/docs/cloud-messaging/concept-options#notification-messages-with-optional-data-payload

<罢工> https://firebase.google.com/docs/cloud-messaging/server#choose

GCM 中的消息大小限制为 4 KB。 (已弃用) https://developer.android.com/google/gcm/server.html#params

C2DM 中的消息大小限制为 1024 字节。 (已弃用) https://developers.google.com/android/c2dm/#limitations


iOS

对于常规远程通知,最大大小为 4KB(4096 字节)

https://developer.apple.com/library/content/documentation/NetworkingInternet/Conceptual/RemoteNotificationsPG/CreatingtheNotificationPayload.html

自从 iOS 8 推出以来,已改为 2 kbytes!

https://forums.aws.amazon.com/ann.jspa?annID=2626

With iOS 8, Apple introduced new features that enable some rich new use cases for mobile push notifications — interactive push notifications, third party widgets, and larger (2 KB) payloads. Today, we are pleased to announce support for the new mobile push capabilities announced with iOS 8. We are publishing a new iOS 8 Sample App that demonstrates how these new features can be implemented with SNS, and have also implemented support for larger 2KB payloads.

在 iOS 中大小限制为 256 字节

关于android - Android 和 iOS 推送通知中最多可以显示多少个字符?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9487223/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com