开发者

Default FB search

I read documentation about FB API, and FB graph, and still not sure how to do something. I'm creating unique client for FB and G+, and when i log in with some user (with no friends for example) I need to make default search, and to try to add friend. However, when i do any kind of FQL search, i receive almost empty results, with no publicly shown data that i receive when i use FB mobile application, or just when i try to find someone on FB. Is there any chance to do that, and what kind of token i need to have. It would be silly to create FB application, and wait for users to approve permissions for me, so later I can search for them, and add them as friends or so... Is there any example, or any suggestion how to do that, i searched, and searched, and still nothing :(

Thanks in advance

Edit: Well, i'm trying to use Graph API (i don't know if i can use any other).

I want to create application that i will be able to use as same application for facebook and google social network. So i need to login, and than to search for people (like in regular FB), and to add them as friends etc. So, i'm trying to search for people with giv开发者_开发知识库en string (i know that), to find info about user (i need permission and token, even if those info is public, or in other words, user needs to authorize my application, so i can later allow people who use my app to search for user, and have public info)

So, my question is, if there is any way to search user and his public info, available on FB application on mobile devices ?


Go to http://developers.facebook.com/docs/reference/api/ and CTRL+F for Searching section. You can use that to search for Facebook users.

But, as you said, you won't have the current user access_token, so you won't be able to perform the search. And if you try to use /search with an app access_token the response message is:

{
    "error": {
        "type": "OAuthException",
        "message": "A user access token is required to request this resource."
     }
}

So you need to create a Facebook App and get user permissions to perform the searches you want.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜