-3

I am expecting the facebook comment from this URL

http://graph.facebook.com/comments?id=http://de.richarddawkins.net/articles/faschist-oder-nicht

But getting this error message

{
   "error": {
      "message": "An access token is required to request this resource.",
      "type": "OAuthException",
      "code": 104,
      "fbtrace_id": "ABZp42kZtrD"
   }
}
andyrandy
  • 72,880
  • 8
  • 113
  • 130
  • The error is pretty clear. You need to register the application with facebook and provide the access token in the request body – VladNeacsu Jan 12 '17 at 15:10
  • I'm voting to close this question as off-topic because the solution is clearly shown in the question itself. – John Weisz Jan 12 '17 at 16:11

1 Answers1

0

As the error message tells you, the API call requires an Access Token. You can use an App Access Token for this.

For example:

http://graph.facebook.com/comments?id=http:...&access_token=xxx

More information:

andyrandy
  • 72,880
  • 8
  • 113
  • 130
  • Do you know how to append access_token with given URL ? – Umesh Kushwaha Jan 12 '17 at 14:22
  • Now i am getting this response { "error": { "message": "Invalid OAuth access token.", "type": "OAuthException", "code": 190, "fbtrace_id": "CPIvNZoNrr6" } } – Umesh Kushwaha Jan 12 '17 at 14:45
  • Is this a valid format https://graph.facebook.com/comments?id=http://localhost:3000/articles/faschist-oder-nicht&access_token?client_id=XXXXXXXXXXX&client_secret=XXXXXXXXXX&grant_type=client_credentials – Umesh Kushwaha Jan 12 '17 at 14:52