facebook fql - FB图形API用户搜索只返回uid, first_name, last_name, use



目前正在试验FB GRAPH API资源管理器工具,目的是通过他们的名字和姓氏搜索(任何)用户。

由于这个错误(https://developers.facebook.com/bugs/331209630309433),我不能通过浏览器测试名称搜索,所以我不得不转而调查执行搜索时返回的数据类型。

为此,我的测试FQL查询格式如下:
SELECT uid, username, first_name, last_name, sex, website, about_me , activities , email, current_location, birthday_date, books, interests, work, .... {any other field}
FROM user 
WHERE uid in ({list of known/random user ids})

我注意到查询为所有用户的uid、username、first_name、last_name和性别字段返回值,但为其他任何字段返回空/null。

是什么原因造成的?这是因为这些用户不是我的"FB朋友",他们的权限设置不返回这些字段到FB G API,或两者兼而有之,或任何其他原因?

另外,我注意到大多数用户在他们的公共FB网站上有一些链接/信息在"收藏>其他"部分-这如何映射到FB G API以及如何检索?

请多多指教。

约翰·史密斯

您需要为其余详细信息设置权限。默认情况下,只显示用户的基本信息。

更新1

设置这个,用于设置权限。

更新2

看,你不能访问你的朋友以外的用户的详细信息(只有基本信息将是可见的)。对于朋友,我运行了以下查询,并得到了预期的结果(在设置所需的权限之后):

SELECT uid, username, first_name, last_name, sex, website, about_me , activities , email, current_location, birthday_date, books, interests, work
FROM user 
WHERE uid in (select uid2 from friend where uid1=me())

相关内容

最新更新