facebook graph api - App Notifications API -


i want use api in iphone app app post notification user: https://developers.facebook.com/docs/concepts/notifications/ implemented in app: able correct permission: fb_permission_manage_notifications but not call work: ideas? (i respond:{"data":[],"summary":[]}

    nsdictionary * params = @{ @"access_token" : [[fbsession activesession] accesstoken], @"template" : @"this test", @"href" : @"www.blabla.com"};     nslog(@"%@",params);     nsurl *url = [nsurl urlwithstring:@"https://graph.facebook.com/766042719/notifications"];     afhttpclient *httpclient = [[afhttpclient alloc] initwithbaseurl:url];       [httpclient getpath:@"" parameters:params success:^(afhttprequestoperation *operation, id responseobject) {          nsstring* mystring = [[nsstring alloc] initwithdata:responseobject encoding:nsutf8stringencoding];         nslog(@"%@",mystring);    } failure:^(afhttprequestoperation *operation, nserror *error) {         nslog(@"%@",error);     }]; 

please make sure using app access token, instead of user access token. basic permission enough already, it's not related 'fb_permission_manage_notifications'

as documented @ https://developers.facebook.com/docs/concepts/notifications/:

apps can send notifications existing user has authorized app. no special or extended permission required.

...

applications can generate notifications issuing http post request /user_id/notifications graph api, app access_token.


Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -