I've already talked to at least half a dozen people that want to "integrate Drupal with Facebook". In some ways, that is a meaningless statement, since integration will be very specific to your site or service that happens to be built with Drupal.
But, I think we can join forces and at least have a solid module that can be extended.
Right now, I'm thinking along the lines of the pathauto module: it has a series of *.inc files (e.g. pathauto_node.inc) that allow it to work
Here are some ideas:
* facebookapi_event.inc (for event and date) -- post an event in Drupal, have it post to Facebook as well
* facebookapi_node.inc -- post a node, have it post as a Note to Facebook
What about "social networking"? Can we show Facebook information embedded directly in / extended from a Drupal user profile?
Update: it has been pointed out to me that I wasn't clear on the value for "Facebook Applications". If you make FunkyService.com and build it with Drupal, you'll still have to do some custom work for your special FunkyService. But, ideally, utilizing this kind of an API module, it would be as simple as a hook_facebookapi or a facebookapi_funkyservice.inc in order to work with FB.
Let's make Drupal a great platform for making Facebook Apps with....

Comments
Sounds like a good plan to
Sounds like a good plan to me! I'll be playing around with integrating parts of a Drupal installation with the Facebook API in the coming months.
JD Leonard
Group messaging end-run? AND group archiving
We've been thinking alot about how drupal could integrate with Facebook as a tool for nonprofit/social/political organizing, and there's no question that the biggest problem with Facebook as an organizing tool is the inability to send messages to any group with more than 999 members. I haven't yet dug into the new platform release but I would LOVE to think of a way of using messaging via Drupal, perhaps synched with Facebook profiles, to access a group's member list and be able to communicate outside the (hopefully temporary) limits of facebook.
The other way I'd like to use Drupal is to make selected group content accessible in a view-only way to people who aren't on Facebook. Some groups want to use Facebook as their primary social space but still need to offer a window on that space to folks who aren't into the whole Facebook scene.
FB open to the intarwebs
This is really the biggie. Until you can search Google and get results that live in Facebook (aka at least parts are open)...it's a problem.
evil closed-ness
good point. I'm adding this to the "changing FB for social change" blog post now in progress.
I am definately interested
I am definately interested in integrating Drupal in meaningful way with Facebook. Every solution is going to be very unique, but its going to be something that will soon be requirement of many of the Social Networking sites we build. As you mentioned events and notes would definately be the starting place. But what about organic groups and facebook groups, do you think there could be any crossover. We have one client who has a large social networking site across Canada that organizes groups based on highschool and university campuses and he is finding that his biggest competitor right now is facebook. It's a Christian parachurch organization that has students start groups with many of the similar functions as facebook has. So for them, and for us, this is of high interest.
Another possible application we are looking at is for a fantasy sports social networking website. They would like to see shared friend lists. So for example a user is logged into their site (built on Drupal) and they see there buddy list. It would be great if their friends in the buddy list that were also their friends on facebook had a little facebook icon beside them. As well we are looking at creating something that will show an entire list of their facebook friends dividing them into two categories: those that are also part of their drupal-based site and those note. For those that are not there could be link for the user to invite that friend to join.
Those are just some of my initial thought and inclinations and I am interested in joinging forces on this matter.
~Chris
Scrap current facebook.module and PHP4 support
Could we takeover the namespace of the current version of the Facebook module? The current module uses someone else's php4 library and adds the proper drupal hooks. It isn't working properly, and was not updated for the 1.0 version of the API.
I attempted to upgrade the module to get as close to "The Drupal Way™" (drupal_http_request, xml_parser_* functions). Trying to have it support PHP4 was too troublesome for me. So my second loaded question, support PHP4 or not?
ah ha
I hadn't realized that there was one...I looked, but someone missed it. So, usually, no, you can't just steal someone elses namespace :P
I'll try and get in touch with the author.
Did you attach your upgrade to the issue queue?
And yeah, I'm OK with PHP5 only. Other folks?
The module named "Facebook"
The module named "Facebook" allows users to authenticate against their facebook account to login to a Drupal site. This would likely be valuable functionality to incorporate into a general facebook module. Otherwise it would make sense for it to be renamed "Facebook Authentication". Something to suggest to the author as a possibility as either incorporating that into a facebook module in general, which if its true that he has let it go out of date and it is not working, he might be thankful for.
My "Upgrade" got as far as
My "Upgrade" got as far as starting to parse the tags, and then I got frustrated with the xml_parser_* functions. I got diverted to something else before I had time to do it with SimpleXML.
If we can't take the namespace, I say we get the API for working w/ Facebook's API into that project, since that fits in with the scope of that original project. The distributed auth/shared login functionality can be put into it's own separate module or include.
Agreed
It really should be facebook_auth.module, and facebook.module is the API. People could turn on different modules as needed.
I'm all for taking over the
I'm all for taking over the namespace. While I personally have no use for PHP4, I'm sure there are plenty of others who do so I think PHP4 should be supported as best as it can. I don't know enough about XML and REST stuff to understand whether this is very difficult/troublesome or not.
J.D.
JD Leonard
SimpleXML
What makes supporting PHP4 hard (for me) is the lack of the SimpleXML library that was added in PHP5. Working with XML in PHP4 is about as pleasant as slamming your hand in a car door, multiple times.
the facebook-platform now
the facebook-platform now comes with a php4 and a link to a thiird party backport of simplexml
http://downloads.sourceforge.net/ister4framework/simplexml44-0_4_4.tar.gz
there is an ongoing
there is an ongoing discussion on the devel list, it seems Drupal is going to drop PHP4 support in the near future. I think it would be straightforward to work purely on PHP5.
Yep, PHP5 +1
API stuff like this is not appropriate for random shared hosting, so PHP5 is fine.
Yeah Facebook!
We're doing a big Facebook - Drupal 5 app. We have some pretty specific code to our app, but will absolutely want to be a part of this. Moshe is working on redoing the facebook.module to do SSO and auto-login within the Facebook App environment and was planning on replacing that module all together, but I agree that facebook_auth is prolly a better name.
And we're requiring PHP5 for this, no way we want to mess with the unofficial PHP4 FB Client Library, PHP5 all the way!
I could really see when this
I could really see when this could come in handy :)
Drupal can become a much better looking facebook front end.
Great to see this development happening
Hello,
It's awesome to see the Drupal community jumping onto FB quickly. Its great to see Drupal as one of the first big CMSs to start hooking into FB.
On that note, I've started developing a FB API module for a project I'm working on. I've made a few posts to this thread on drupal.org and I'm hoping to get some pre-release code up soon.
The module I'm working on is one of those things that serendipitously evolved into a generic releasable module, but wasn't intended in that way.
Maybe it'll help somebody, or maybe it will provide a few ideas for this group.
Will post a link in a bit ..
Cheers,
Get the code out?
Would be great to get the code out soon~ish, even if it's not done yet, so other folks can work on it as well. I'm about to start some code, but I'd love to collaborate instead...
2 minutes
Hows 2 minutes for soonish? :-)
The link
Here's the link to my "brainstorming" Facebook API module.
NOTE: This module doesn't have any direct relation to ProjectOpus.com, I just used our docs site to host the file.
Thoughts?
James.
Update
I know many people read these threads everyday. So just an FYI, I've got some other stuff to get to for most of today. Hopefully I'll have some cleaned up code ready mid-week. With any luck I'll be able to add a few wrapper functions to allow easier access to some of the common FB API endpoints.
Cheers,
James.
Updated code ..
I've updated the code in my Facebook API module and split the package up into two modules.
The updates are roughly:
Check it out here --> http://docs.projectopus.com/releases/facebook_api
Cheers,
PS: I don't have a CVS account for Drupal.org yet, do you think this code is worth enough while for me to get one? I, personally, feel this still needs a bit of cleaning up before it's worthy of being contributed..
James.
Yes
It is worthy...the problem is, we're going to have to figure out how to get a facebook api module....the CVS maintainers might be a little tricky about the existing module.
The main benefit from getting it in now is so that other people can work on it and file issues. It doesn't need to be perfect. eg. I filed issues against Gavin's facebook_auth code, and he fixed them :P
Should play nice with existing facebook.module
Yeah, I agree.
Also, my module should be able to play nice with the existing facebook.module or facebook_auth.module . The facebook_api.module does a check to see if the Facebook class exists before it includes, or potentially re-includes, the facebook API client. I have all three running at the same time without issue. That said, I didn't test that aspect much ..
the one who has the facebook
the one who has the facebook module is around
i can see he's posted things recently.
so probably could get him to turn over the name space.
Contact him
Gavin -- you going to contact him and see about you and James becoming co-maintainers? Or shall I?
I think it might be better
I think it might be better that you do it.
I'm not entirely sure as to what your plan is.
http://drupal.org/user/96907
My plan?
Why, it's EVIL of course :P
Step 1
Step 1. FacebookAPI.module
Step 2. ???
Step 3. TOTAL WORLD DOMINATION
mwaaa haaa haaa.
Cheers,
Bill
FunnyMonkey
Tools for Teachers
FunnyMonkey