我使用instagram api调用来检索各种细节,如媒体,关注者列表,后续列表等...即使用户有追随者api返回,有时与
{“pagination”:{},“meta”:{“code”:200},“data”:[]}
有时和
{“meta”:{“error_type”:“APINotAllowedError”,“code”:400,“error_message”:“您无法查看此资源”}}
以上api工作正常 . 获取媒体的api也是 .
以上api不起作用 . 也适用于以下列表和其他一些api
1 回答
您必须在每个API范围上授权访问令牌 . 并在沙盒模式下运行它 . 如果你想激活它(在你的情况下,你必须至少授权public_content和follower_list范围),访问此链接:
激活public_content:https://api.instagram.com/oauth/authorize/?client_id=[YOUR-CLIENT-ID]&redirect_uri=[YOURREDIRECT-URI]&response_type=token&scope=public_content
激活关注者列表:https://api.instagram.com/oauth/authorize/?client_id=[YOUR-CLIENT-ID]&redirect_uri=[YOUR-REDIRECT-URI]&response_type=token&scope=follower_list
参考:1 . https://www.instagram.com/developer/authorization/ 2. https://www.instagram.com/developer/sandbox/