简体   繁体   English

第2次执行facebook.request时,返回OAuthException错误代码2500

[英]when do facebook.request 2nd times, return OAuthException error code 2500

I try to get the album list from my facebook account, but there are more than 25 albums in my account, facebook only return 25 album when in each query. 我尝试从我的facebook帐户获取相册列表,但是我的帐户中有25个以上的相册,facebook在每次查询时仅返回25个相册。

  1. first time I query the album first 25 albums list by normal use 第一次我按正常使用情况查询专辑的前25张专辑列表

      facebook.request(me/albums); 

    and it returns album list successfully. 并成功返回相册列表。

  2. I use following to query next 25 albums, it will return Error code 2500 我使用以下查询下25张专辑,它将返回错误代码2500

     facebook.request(me/albums?after=.......); 

getting respose is 得到休息是

response = {"error":{"message":"An active access token must be used to query information about the current user.","type":"OAuthException","code":2500}}

If I add the access token manually in my request strings, like this 如果我在请求字符串中手动添加访问令牌,就像这样

    facebook.request(me/albums?after=.......&access_token=......);  

It will return erro code 190 它将返回错误代码190

 response = {"error":{"message":"Malformed access token ...............?access_token=...............","type":"OAuthException","code":190}}

Did I do something wrong? 我做错什么了吗?

I found that the it will get problems with Error code 2500 when using command facebook.request. 我发现使用命令facebook.request时它将出现错误代码2500的问题。

The same command is working fine when query in Graph API Explorer website, but won't work when code running. 在Graph API Explorer网站中查询时,相同的命令可以正常工作,但是在运行代码时则无法使用。

So finally I changed my way to get my album list. 所以最后我改变了获取专辑清单的方式。 using FQL Query, then this problem solved. 使用FQL查询,则此问题得以解决。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 使用facebook图表api发布时出现OAuthException 2500错误 - Error OAuthException 2500 while posting with facebook graph api Facebook-错误代码-2500无效访问令牌 - Facebook - Error Code - 2500 Inactive Access Token 错误代码2500 Facebook图形API - Error code 2500 Facebook graph api Appcelerator Android Facebook登录错误代码2500 - Appcelerator Android Facebook login error code 2500 注销后无法使用 Facebook 登录第二次 - Login with Facebook cannot do login 2nd time after logout 当我返回到第一个活动时,第二个活动未调用第二个活动的onCreate()函数 - When I return back to 1st Activity the onCreate() function of 2nd Activity is not called in 2nd time 从第一个活动转到第二个活动时出错 - error when going from 1st activity to 2nd activity 在Facebook张贴在好友墙上时,Android中的Oauth错误消息“缺少消息或附件”,“类型”:“ OAuthException”,“代码”:100 - Oauth error message “Missing message or attachment”, “type”:“OAuthException”,“code”:100 in android while Facebook post on friends wall Graph API Android抛出错误代码2500 - Graph api android throws error code 2500 当多次单击活动导航时,为什么第二个活动生命周期方法调用两次 - When multiple clicks on activity navigation click, why 2nd activity lifecycle methods calling double times
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM