man*_*ale 9 facebook facebook-graph-api
我是Facebook应用程序开发的新手.我想为我的应用程序创建一个测试用户,但是当我尝试使用API时
https://graph.facebook.com/APP_ID/accounts/test-users?installed=true&
name=FULL_NAME&permissions=read_stream&method=post&access_token=APP_ACCESS_TOKEN
Run Code Online (Sandbox Code Playgroud)
它显示以下错误:
{
"error": {
"type": "OAuthException",
"message": "(#15) The method you are calling must be called
with an app secret signed session"
}
}
Run Code Online (Sandbox Code Playgroud)
我已阅读并按照上述步骤操作
https://developers.facebook.com/docs/authentication/
问题仍然存在.请指导我,我该怎么办?
谢谢.
jBi*_*Bit 15
您需要获得有效的访问令牌 - 应用程序访问令牌将执行此操作.要使用此功能:
https://graph.facebook.com/oauth/access_token?client_id=YOUR_APP_ID&client_secret=YOUR_APP_SECRET&grant_type=client_credentials
Run Code Online (Sandbox Code Playgroud)
用您的相应值替换YOUR_APP_ID和YOUR_APP_SECRET.
这将返回一个有效的访问令牌,您可以在其中替换APP_ACCESS_TOKEN:
https://graph.facebook.com/APP_ID/accounts/test-users?installed=true&name=FULL_NAME&permissions=read_stream&method=post&access_token=APP_ACCESS_TOKEN
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
7624 次 |
| 最近记录: |