I am looking forward to create a javascript API that contains most of the functions that facebook Javascript API provides.
FB.api FB.init FB.logout FB.getLog
They are using JSONP. It's widely used and is supported by javascript frameworks like JQuery.