-1

I'm trying to get a user's facebook calendar events. I added the permission user_events, and this is the request I use -

var request = FBSDKGraphRequest(graphPath:"/me/events", parameters: nil);

    request.startWithCompletionHandler { (connection : FBSDKGraphRequestConnection!, result : AnyObject!, error : NSError!) -> Void in
        if error == nil {
            println(result["data"]!)
        } else {
            println("Error Getting Friends \(error)");
        }
    }

This code doesn't return anything, can you help me fix it?

Thanks!

EDIT

When I checked my upcoming events list it was empty, the data I need is the birthdays in the events/calendar.

5
  • “the data I need is the birthdays in the events/calendar” – those are not actually events, and therefor you can’t get them via /me/events. (And not via any other endpoint either.)
    – C3roe
    Commented Jul 3, 2015 at 11:54
  • Is there another way to get facebook friends birthdays?
    – Omer
    Commented Jul 3, 2015 at 11:57
  • There is no way to get all friends birthdays. And, even if it was, are you sure the world needs the 1000th birthday app?
    – Tobi
    Commented Jul 3, 2015 at 11:58
  • facebook reminds you about friend birthdays anyway ;)
    – andyrandy
    Commented Jul 3, 2015 at 12:25
  • “Is there another way to get facebook friends birthdays?” – only for friends that have logged in to the app as well, and granted permission to access their birthday.
    – C3roe
    Commented Jul 3, 2015 at 17:38

1 Answer 1

0

Have you requested the user_events permission upon Login? I guess not...

1
  • I did request the user_events permission
    – Omer
    Commented Jul 3, 2015 at 11:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.