Facebook实时更新仅返回“changed_fields”:[“feed”]而不是实际注释 [英] Facebook Real Time Update return only "changed_fields":["feed"] and not the actual comment

查看:119
本文介绍了Facebook实时更新仅返回“changed_fields”:[“feed”]而不是实际注释的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在试图以正确的方式实施Facebook实时更新。 ( https://developers.facebook.com/docs/reference/api/realtime/ )。

I'm trying to implement Facebook Real Time Update in a proper manner. (https://developers.facebook.com/docs/reference/api/realtime/).

所有内容都是按照此页面中的说明完成的,但是从Facebook返回的JSON缺少有趣的信息。

Everything is done according to the instructions given in this page, but the returned JSON from Facebook is missing interesting information.

JSON是例如:

{"object":"user","entry":[{"uid":"1408932149","id":"1408932149","time":1370253930,"changed_fields":["feed"]}]}

但事件引发的事件是在Facebook页面的评论。我想要更多的信息。例如,帖子的id,评论的id和类似的重要信息。

But the event that induced the event was a comment on a facebook-page. I want more information. For example the id of the post, id of the comment and similar vital information.

为什么Facebook只返回字段feed已更改,而不是id评论?

Why is Facebook only returning that the field "feed" changed and not the id of the comment?

Regards,
Jonas

Regards, Jonas

推荐答案

一旦我意识到这一点,理由就相当容易了。

The reason for this was fairly easy once I realised it.

它是Facebook的开发者页面( https://developers.facebook.com/docs/reference/api/page/#realtime )。这个问题是结果,如果只做一个步骤1,并且没有做第2步和第3步。

It the Facebook developer page for pages (https://developers.facebook.com/docs/reference/api/page/#realtime). This question is the result if one only does step 1 and fails in doing step 2 and 3.

完成后,仔细使用该页面的access_token,一切都开始现在工作正常。不是真的在Facebook承诺的五秒钟内,但还不错。

Having done that, and carefully using the access_token for the page, everything started working and now it works fine. Not really within the five seconds promised by Facebook, but good enough.

我还发现使用一个api,如Facebook SDK for .NET( http://facebooksdk.net/ )可以是非常有益的,但它可能会使得更难了解Facebook提供的api。

I have also found that using an a api such as Facebook SDK for .NET (http://facebooksdk.net/) can be very rewarding, but it might make it harder to understand the api presented by Facebook.

这篇关于Facebook实时更新仅返回“changed_fields”:[“feed”]而不是实际注释的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆