如何使用 Facebook 应用程序向用户写入通知
我正在开发一个大学考试应用程序,使用 Appengine 和 Gwt (Google 产品),我想以这种方式实现 Facebook: - 使 FB 用户能够通过 facebook 登录应用程序(这是否实现了 oAuth2.0 流程,所以现在我拥有用户的访问令牌及其权限) - 由于该应用程序是为了在教授发布一些课程材料时收到通知(这全部由 appengine 处理),因此我想在教授发布一些材料时通过墙贴或我的注释通知用户应用程序向用户写入有关新发布材料的信息。
我一直在网上浏览每一个资源,但找不到答案:有很多类似的问题,但没有答案。
编写 POST 不是问题,目前我正在尝试使用 api graph explorer。 我设法在用户的墙上/便条上写字,就像他自己写一样,或者(如果用户喜欢该应用程序)给所有喜欢的人写墙上的帖子/便条(但对每个人都一样)。
但我没有找到一种方法来向每个用户发送个性化的墙贴/注释,以响应某些已发布的特定材料。 FB 不允许这样做,因为被认为是垃圾邮件?
i'm developing an application for a university exam, using Appengine and Gwt (Google products) and i'd like to implement Facebook this way:
- give the ability to a FB user to login to the application through facebook (did this implementing the oAuth2.0 flow, so now i have the user's access token and his permissions)
- since the application is for being notified when a professor publishes some material for his course (this is all handled by appengine), i'd like to notify the user when a professor publishes some material, through a wall post or a note from my application in a way that it writes to the user something about the new published material.
I've been looking through EVERY single resource online, and couldn't find an answer: a lot of similar questions but no answers.
Writing the POST is not a problem, and for the moment i'm trying with the api graph explorer.
I manage to write on the user's wall/note as if he's writing himself or (if the user likes the application) write all the likers a wall post/note (but the same to everyone).
But i don't find a way to send personalized wall posts/notes to every user in response to some specific material published.
FB doesn't allow to do this because is considered spamming?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您不能直接将内容发布到用户的墙上作为通知他们的方式 - 墙上的帖子旨在成为用户在您的应用程序中发布的内容(例如,他们在您的应用程序中发现一些有趣的内容并选择与他们的用户分享)朋友,所以他们点击“分享”按钮)。
您可以尝试使用应用程序生成的请求(http://developers.facebook.com/docs/频道/#requests)。这将增加用户的书签计数器,当他们单击它时,他们将进入您的应用程序,您可以向他们显示最新新闻。
或者,您可以请求您的应用程序的“电子邮件”权限,并在出现新情况时向用户发送电子邮件通知。
You can't directly post things to your user's wall as a way of notifying them - wall posts are intended to be things the user posts from within your app (for instance, they find something in your app interesting and choose to share it with their friends, so they click a 'Share' button).
You could try using an App-Generated Request (http://developers.facebook.com/docs/channels/#requests). This will increment the user's Bookmark Counter, and when they click on it they will enter your app and you can show them the latest news.
OR, you could ask for the 'email' permission for your app, and send the user an email notification when something is new.