PDA

View Full Version : Access news feed from Facebook using the iOS SDK




SimonBS
Aug 9, 2011, 04:28 AM
Hello,

I am trying to implement Facebook in my iPhone app and I have successfully authorized the app in the application delegate as shown in Facebook's guide. Now I can easily use Facebook around my application using the code below.

AppDelegate *appDelegate = (AppDelegate *)[[UIApplication sharedApplication] delegate];
facebook = [appDelegate facebook];
I would like to get the user's News Feed but when doing so using the following code I get an error.

[facebook requestWithGraphPath:@"me/home" andDelegate:self];
The error is:

The operation couldn’t be completed. (facebookErrDomain error 10000.)

{
error = {
message = "An unknown error has occurred.";
type = OAuthException;
};
}

I have read that the News Feed should be retrieved using me/home. The session seems to be active as I have no problem getting the user's wall posts using me/feed.

Does anyone know why I can't get the user's news feed? I have added the read_stream permission and when I log into my Facebook account I see that my application is registered as being able to read my news feed.

This app can: Access posts in my News Feed