android - 在 android 中使用 Parse 向多个用户发送推送通知

标签 android parse-platform

我想使用解析后端向多个用户发送推送通知。我可以在不创建 channel 的情况下使用 Facebook id 定位 friend 吗?(在我的应用程序中我集成了 Facebook)

如果不可能,请将创建 channel 的代码发送给我

最佳答案

Parse 有不同的可能性,具体取决于您拥有的帐户类型。我假设你有免费的,所以你不能用这种帐户向特定或多个用户发送推送通知。但是您可以通过网站 Controller 将它们发送给 iOS 或 Android 用户,这是您使用免费帐户的唯一选择。

我实际上鼓励您使用 channel 来这样做。我假设您已经按照解析网站 (https://parse.com/docs/android_guide) 中的说明进行了正确的初始化

// Create our Installation query
ParseQuery pushQuery = ParseInstallation.getQuery();
pushQuery.whereEqualTo("channels", "Giants"); // Set the channel
pushQuery.whereEqualTo("scores", true);

// Send push notification to query
ParsePush push = new ParsePush();
push.setQuery(pushQuery);
push.setMessage("Giants scored against the A's! It's now 2-2.");
push.sendInBackground();

我最终建议您阅读本指南:https://parse.com/docs/push_guide#sending-queries/Android

关于android - 在 android 中使用 Parse 向多个用户发送推送通知,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23798551/

相关文章:

java - 如何查询 Parse.com 类中的特定列值并将其设置为字符串?

android - 存储 WebView 以供离线浏览

android - "is library"项目被红叉

android - 如何在 google maps android 上添加标记?

php - AES加密 Android/AES解密 PHP

android - 如何恢复android中的消息?

java - 如何从解析中提取对象并将其显示在列表中,而无需在 android 中使用它们的 ID?

linux - 通过 Https 访问 Parse 仪表板

ios - 按日期解析的有组织的组合数组

ios - Parse 集成到 Swift 应用程序时出错