Wednesday, May 23, 2012

Twitter API - Reply to a retweet

I am writing a little twitter API (using Elliot Haughin's library) and I want to reply to a retweet that the app posts.



I have read the docs for statues/update, and have tried using '*in_reply_to_status_id*' with the value taken from '*user_mentions*', but it doesn't seem to work.



What am I doing wrong, or is there a better way to do it?



Code sample;



$answer = '@'.$retweet->entities->user_mentions[0]->screen_name.' thanks!!';
$this->tweet->call('post', 'statuses/update', array('status' => $answer, 'in_reply_to_status_id' => $retweet->id));




No comments:

Post a Comment