I need to do something similar to the Facepile social plugin for a site I’m working on. The problem is the client does not have have a Facebook page, but instead has a Facebook Group (with some 4000+ members).
I guess I could urge the client to move their group members to a page, and I might do that in the future. But before I do I want to research how we’re going to do Facebook-integration more thoroughly. For now I just need a quick fix.
While it’s possible to list group members (with a 500 limit), your main issue is going to be the identification of your visitor.
The facepile plugin, like the other official plugins, is automatically connected if the current user has an active facebook session (because it’s running on the facebook.com domain)
That allows it to display things like “xxx of your friends are already fan”, even if the user is not logged to your site.
But if you program your own, you won’t be able to access the current facebook session, you’ll need to create your own session, which means you’ll have to create a facebook application and have the user login to it before you can know how many of his friends are members of the group.
Also, there is no way to use the API to make a user join a group. This action has to be taken manually by the user.
Without an active user session, at best, you could list a random number of group members (using your own session key with the offline_access perm) and a link to the group.
If you want to list members of a group, here is the FQL query: