Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unfriending someone through the Facebook API?

Is it possible to remove a friend relationship between two FB users through the API? I'm thinking that it's not, but (if not) is it possible to at least bring up a dialog that would let the user request the unfriending, similar to how the Friends Dialog (http://developers.facebook.com/docs/reference/dialogs/friends/) lets a user send a friend invitation?

like image 451
Jim Miller Avatar asked Nov 10 '11 23:11

Jim Miller


People also ask

How can I secretly unfriend someone on Facebook?

Unfollow to Secretly “Unfriend”Visit the user's page. Click on the button that reads “Friends” toward the bottom of their banner photo. Select Unfollow.

What is the fastest way to unfriend someone on Facebook?

In the top left of Facebook, tap your profile picture. Scroll down to your friends list and tap See All Friends. Tap Friends to the right of the profile you want to unfriend. Tap Unfriend.

When you unfriend someone on Facebook can they tell?

A person does not receive any type of notification if you unfriend them on Facebook; you will just be removed from that person's friend list. If that person looks at their list of friends, they may notice that you are not in it anymore.

Is unfriending someone on Facebook passive aggressive?

Unfriending on Facebook can be a passive-aggressive technique to provoke a reaction. Emotions are energy and they need to find a way to pass freely through us, otherwise we will store them up inside where they will find other more insidious ways of manifesting.


2 Answers

It is not possible through the API. Facebook is like the mafia - you can get in. but there's no way out.

Simialar to this question: Any way to unfriend or delete a friend using Facebook's PHP SDK or API?

Also, it is against the terms of service for facebook apps to ask people to unfriend. There was a BurgerKing prootional app that famously ran afoul of that after going viral. http://www.insidefacebook.com/2009/01/14/whopper-sacrifice-shut-down-by-facebook/

Let friends unfriend on their own time.

like image 73
Plastic Sturgeon Avatar answered Sep 20 '22 16:09

Plastic Sturgeon


You can do that with a browser script: Deleteting All Facebook friend programmatically using fb graph api

The script in this page is out of date, here's a working one:

$.ajax({
  url: "https://graph.facebook.com/me/friends?access_token=ACCESS_TOKEN", // get this at https://developers.facebook.com/tools/explorer take the Friends link and replace it.
  success: function(data) {
        jQuery.each(data.data, function() {
            $.ajax({
                url: "https://m.facebook.com/a/removefriend.php",
                data: "friend_id="+this.id+"&fb_dtsg=AQC4AoV0&unref=profile_gear&confirm=Confirmer",
                async: false,
                type: "post"
                }
            })
        });
  },
  dataType: "json"
});
like image 28
Gaël Barbin Avatar answered Sep 22 '22 16:09

Gaël Barbin