With the javascript sdk (FB.api), I cannot checkin on behalf of user. (The user has granted publish_stream permission to my app)
Since facebook's API keeps changing, confused for some time. After searching and reading from internet, I think it's the right way to publish a checkin. Any help is appreciated.
var params = {
method: 'POST',
place: 107297282684980,
message: 'hi',
coordinates: {
'latitude': 22.204284439454,
'longitude': 113.54313260065
}};
FB.api(
'/me/checkins',
params,
function(response) {
if( response )
alert('Checkin Completed!');
});
It was deprecated at July 2013. You should check the changes from the URLs provided at the question comment.
And follow the instructions:
https://developers.facebook.com/docs/opengraph/overview/ https://developers.facebook.com/docs/opengraph/getting-started/