Milan1111
Milan1111

Reputation: 185

Facebook iOS Graph API Event

I want to get info about the Facebook event. I have event's id. I found code like (1), but always getting error:

FBSDKLog: Error for request to endpoint '/642xxxxxxxx/event': An open FBSession must be specified for calls to this endpoint.

even if I add some code to open FBSession. Is there any way to do it without FB UI with login user etc. ?

(1)

[FBRequestConnection startWithGraphPath:@"/642xxxxxxxx/event"
                                      parameters:nil
                                      HTTPMethod:@"GET"
                               completionHandler:^(
                                                   FBRequestConnection *connection,
                                                   id result,
                                                   NSError *error
                                                   ) {
                                   /* handle the result */
                               }];

Upvotes: 0

Views: 271

Answers (1)

Tobi
Tobi

Reputation: 31479

Is 642xxxxxxxx the event_id, or a user_id? If it's the first case, you just need to call /642xxxxxxxx, if it's the last case, you'll need to call /642xxxxxxxx/events.

See

Upvotes: 1

Related Questions