我正在尝试通过 facebook graph api 搜索公共帖子。
我通过执行以下代码获得了访问令牌:
dynamic tokenInfo =
fb.Get(
String.Format(
"/oauth/access_token?client_id={0}&client_secret={1}&grant_type=client_credentials",
ConsumerKey,
ConsumerSecret));
var appAccessToken = (string)tokenInfo.ToString();// tokenInfo.access_token;
我把这个访问令牌放在我的网址中,如下所示:
https://graph.facebook.com/search?access_token=111111111111111|xxxxxxxxxxxxxx-xxxxxx&type=post&metadata=1&callback=display&q=voyage&since=2013-07-10&limit=500000
但我收到以下消息:
/**/ display({
"error": {
"message": "(#15) Requires session when calling from a desktop app",
"type": "OAuthException",
"code": 15
}
});