【发布时间】:2018-08-15 18:23:42
【问题描述】:
我正在尝试使用 this API:
但是当我没有设置正文键时,我得到了这个错误:
{
"error": {
"code": 400,
"message": "body parameter is invalid or empty.: 'Body' cannot be null."
}
}
所以我的问题是是否有办法在 android 中发送静默通知(在 ios 中我知道有 content-available flag)
Tnx 提前!
【问题讨论】:
-
使用数据节点代替正文的通知节点。 firebase.google.com/docs/cloud-messaging/concept-options
-
我看到 Sarahm 使用的是 AppCenter API,而不是直接使用 FCM。 @killer,这将通过 AppCenter API 工作吗?
-
我的问题我没看清楚。
-
可以直接使用 Firebase API 吗?我试过了,但没有任何运气,似乎我必须在应用程序中单独设置 firebase
标签: android push-notification visual-studio-app-center silent-notification