Dunno if Im missing something but here goes. Im trying to get an access_token for my application so that it can go and look up events for certain public groups on facebook, without requiring a user to be logged in.
Im trying to get an access_token from https://graph.facebook.com/oauth/access_token?client_secret=foobar&client_id=foobar&grant_type=client_credentials&format=json&sdk=ios
This returns a string: access_token=xxxx|ugtqdoWfvvo5_S-Fo2D7_I4rdbc
Thats nice and all, but its no json. Any insights on why the returned string is not json encoded ?
Note: Im using the Facebook ios SDK function like so [_facebook requestWithGraphPath:@"oauth/access_token" andParams:params andHttpMethod:@"POST" andDelegate:self];
This is a BUG: https://developers.facebook.com/bugs/325262010847554
Facebook's OAuth 2.0 implementation is clearly in violation of the spec: https://datatracker.ietf.org/doc/html/draft-ietf-oauth-v2-25#section-5.1
I'm using Server-side Web App flow and have the same issue that you describe for the iOS SDK.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With