ストーリーを公開しようとしていますが、Open Graphが次のエラーを返します:domain = com.facebook.sdk、code = 5
私はこれらの権限を使用します:
[NSArray arrayWithObjects: @ "status_update" @ "publish_actions" @ "publish_stream" @ "user_likes" @ "create_event", nil];
そして、私が履歴を作成するために使用するコード:
NSMutableDictionary * item = [FBGraphObject graphObject];
[Item setObject: @ "http://mysite.com.br/cardapio/6/burger-de-carne" forKey: @ "object"];
NSMutableDictionary * action = (<FBOpenGraphAction> NSMutableDictionary *) [FBGraphObject graphObject];
[Action setObject: item forKey: @ "Like"];
[FBRequestConnection startForPostWithGraphPath: @ "me/og.like" graphObject: action completionHandler: ^ (* FBRequestConnection connection, id result, NSError * error)
{ NSString * alertText;
if(! error)
{ alertText = [NSString stringWithFormat: @ "Open Graph Posted action, id:% @", [Result objectForKey: @ "id"]];
Else {
alertText = [NSString stringWithFormat: @ "error:% @ domain =, code =% d", error.domain, error.code]; }
[[[UIAlertView alloc] initWithTitle: @ "Result" message: alertText delegate: nil cancelButtonTitle: @ "Thanks!" otherButtonTitles: nil] show];
}];