我正在努力让它发挥作用:https://developers.facebook.com/blog/post/465/ https://developers.facebook.com/blog/post/465/
Step 1:我正在获取访问令牌:
Step 2:我通过curl发帖
curl -F 'access_token=myAccessToken' -F 'message=Hello World!' -F 'id=http://example.com' https://graph.facebook.com/feed
myUrl 所在位置http://example.com http://example.com
我收到此错误,无法解析为有效的用户 ID:
{"error":{"message":"(#100) http:\/\/example does not resolve to a valid user ID","type":"OAuthException","code":100}}
Step 3:如果我首先将我的 url 发布到 linter,并获取其 ID:
https://developers.facebook.com/tools/debug/og/object?q=http%3A%2F%2Fexample.com https://developers.facebook.com/tools/debug/og/object?q=http%3A%2F%2Fexample.com
https://graph.facebook.com/10150096126766188 https://graph.facebook.com/10150096126766188
curl -F 'access_token=myAccessToken' -F 'message=Hello World!' -F 'id=10150096126766188' https://graph.facebook.com/feed
然后我收到“用户尚未授权应用程序执行此操作”错误:
{"error":{"message":"(#200) The user hasn't authorized the application to perform this action","type":"OAuthException","code":200}}