简体   繁体   中英

Twitter API: current_user_retweet not seen even with include_my_retweet=1 option

Am working with retweet feature with Twitter API. I currently need to check if a current tweet has already been retweeted by a given user. I checked the doc, twitter has options to check the retweet_count, but does not say retweeted by whom?

Is there a way to find that? Suppose a given tweet has 10 for retweeted_count i need to find the 10 users who had retweeted it Or is there a way to find if the current user has retweeted the tweet by passing the user_id or screen name.

I am slightly aware that there is a data point, current_user_retweet but for some reason am not able to get that. Is there any parameters other than include_my_retweet, that should be added to get this data point?

Thanks.

See the Re-tweeted by feature of the API

I'm copying and pasting the following from Twitter engineer Marcel Molina.

We've just deployed two new resources for the retweet API:

  • /statuses/:status_id/retweeted_by
  • /statuses/:status_id/retweeted_by/ids

The first will return up to the first 100 user representations of those who have retweeted the tweet specified in the url by :status_id. The second will return just the ids of those retweeters for the cases where that's all you care about. Though up to the first 100 users will be returned by default, these resources both support the :count and :page parameters if you'd like to pull down fewer users. It should be noted though that for operational efficiency you can't use the :count and :page parameters to go beyond the first 100 retweeters.

Full docs here: http://apiwiki.twitter.com/Twitter-REST-API-Method%3A-GET-statuses-id ... http://apiwiki.twitter.com/Twitter-REST-API-Method%3A-GET-statuses-id ...

In conjunction with these additions we also want to provide a "retweet_count" parameter in the status payload for convenience. The code for this is mostly done but there are some details around cache invalidation that will likely push out the availability of the retweet_count parameter for a few weeks while we work on an infrastructure change to obviate these cache invalidation issues. But we just wanted to give you a heads up about that too! PS Thanks to everyone for weighing in on the naming of these resources ( http://twitter.com/twitterapi/status/10538921196 ) -- Marcel Molina Twitter Platform Team http://twitter.com/noradio

more information can be found here in the Twitter API google group:

http://groups.google.com/group/twitter-api-announce/browse_thread/thread/226a38d3002d7cb6

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM