- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我正在构建一个连接到 Facebook 的 all_mutual_friends API 的 iOS 应用
https://developers.facebook.com/docs/graph-api/reference/user-context/all_mutual_friends/
该应用已通过审核并获准连接到此 API。
当我根据文档进行图形调用时:
let params = ["fields":"context.fields(all_mutual_friends.fields(picture.width(500).height(200)))"]
FBSDKGraphRequest(graphPath: "/\(facebookID)", parameters: params, HTTPMethod: "GET").startWithCompletionHandler { (connection, result, error) in
print("result: \(result)")
print("error: \(error)")
}
我得到以下结果:
result: {
context = {
id = dXNlcl9jb250ZAXh0OgGQ8qbGU5YUiZAKn8g4zuCb1LCMGj3PiCXfe7B72X5DoKkbMpHZA395xRT0iV8D84NQIZBCjJ3VRKC9uNUrMZCiwIeZBOSTRndZCQKi4pgiIgLoxI3xAZD;
};
id = 10208913134493418;
}
上面的响应是当我们有一个安装了该应用程序的共同 friend 时。
谁知道如何获取共同好友列表?
如果我是此人的 Facebook 好友,我会成功收到进行相同图形调用的共同好友列表。这是响应:
context = {
"all_mutual_friends" = {
data = (
{
"first_name" = Mary;
picture = {
data = {
height = 200;
"is_silhouette" = 0;
url = "https://...";
width = 200;
};
};
}, //... 24 more results
这很好,因为有数据,但仅限于 25 个共同好友。有没有办法将限制提高到 25 以上?
最佳答案
根据您在上面提到的 Facebook 文档:
The All Mutual Friends API must be called from your server to obtain the full list of mutual friends. Calling this API in JavaScript, Android, or iOS client code will omit some of the results.
这解释了您面临的限制。 :)
关于ios - Facebook all_mutual_friends 不工作,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41843557/
我正在构建一个连接到 Facebook 的 all_mutual_friends API 的 iOS 应用 https://developers.facebook.com/docs/graph-api
我是一名优秀的程序员,十分优秀!