通过 Facebook API 发送私人消息
可能的重复:
Facebook Api - 向朋友发送私人消息
我知道事实并非如此正式可以通过 FB API 发送私人消息。 SO 中的每个线程也都这么说。但我使用的是 RockMelt 浏览器,当您邀请某人时,会向他们发送一条私人消息。意味着可以通过 API 发送私人消息。更重要的是,Facebook 对此表示同意。
你猜猜他们是如何使用它的吗?这是使用套接字的 HTTP POST 技巧吗?顺便说一句,我们将仅在用户发起的操作上使用此功能。
Possible Duplicate:
Facebook Api - send private messages to friends
I know that it is not officially possible to send private messages through FB API. Every thread in SO says so too. But I was using RockMelt browser and when you invite somebody, a private message is sent to them. Means it is possible to send private messages through API. More importantly, Facebook is okay with it.
Any guesses on how they are using it? Is it some HTTP POST trick using sockets? BTW, we are going to use this feature only on user initiated actions.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
使用新的消息传递框架可以读取消息,仅适用于注册开发人员。
阅读此页面 - 这就是我目前所知道的所有内容:
http:// /developers.facebook.com/docs/reference/api/message
然而,发送却不是。
Reading messages is possible with the new messaging framework, available to registered developers only.
Have a read of this page - that's about all that I'm aware of currently:
http://developers.facebook.com/docs/reference/api/message
Sending, however, is not.
您现在可以通过图表查看和回复 Facebook 页面上的消息 API,但您仍然无法发起对话,只能回复已向您发送消息的用户。
从上面链接的文档:
*您可以通过使用以下参数 [conversation id, message] 向 /CONVERSATION_ID/messages 发出 HTTP POST 来回复用户的消息。对话 ID 类似于 t_id.216477638451347.*
You can now view and respond to messages on Facebook Pages via the Graph API but you still can't initiate a conversation, only respond to a user that has already messaged you.
From the docs linked above:
*You can reply to a user's message by issuing an HTTP POST to /CONVERSATION_ID/messages with the following parameters [conversation id, message]. A conversation ID look like t_id.216477638451347.*
您可以使用 CHAT API 来完成此操作。但它仅限于纯文本消息。
You can do it using CHAT API. But it is limited plain text messages.