Recently, we created a Bebo version of our Doorbell application for Facebook.
Here is what I did:
- created a new app using the developer app. Used a new callback location.
- Updated my db to handle the larger sized userid and sessionkeys
- updated web server to handle the new callback location
- forked my fb source code to a new Bebo version
- included the new Bebo PHP library in my source files
- Change all $fb = new Facebook($apikey, $appsecret) to $bebo = new Bebo($apikey, $appsecret)
- Change all $fb->api_client calls to just $bebo-> calls, and manually tweaked the parameters to be associative arrays.
- Change all FBJS code to mock Ajax, where it can be, or remove otherwise
- go through each code path with tracing to figure out what bebo doesn't implement or implements differently.
What is nice, is that most of it just works. The tools are the same, the fb_* post variables are there. They just don't have complete parity with FB on the whole API yet, but they seem to be working on it.
The big gotchas are:
- The add method isn’t the same. On Bebo, it seems like a user must add your application to interact with it, and that add happens without any calls to your code. There is therefore less to handle in terms of user state than Facebook.
- The api calls are different. Facebook provides a nice wrapper for their REST implementation, and Bebo doesn’t have the same level of completeness in theirs. My next task is to write the same wrapper for Bebo.
- All callback parameters via Ajax are sent as POSTs rather than GETs regardless of how they are specified in the call.
Tags:
Programming
Post by John Maver
Jan 16, 2008
Jan 16, 2008