Retweets lookup: Standard v1.1 compared to X API v2
If you have been working with the standard v1.1 v1.1 GET statuses/retweets/:id, v1.1 GET statuses/retweets/:ids, the goal of this guide is to help you understand the similarities and differences between the standard v1.1 and X API v2 Retweets lookup endpoints.- Similarities
- Authentiation
- Users per request limits
- Differences
- Endpoint URLs
- Request limitations
- App and Project requirements
- Response data format
- Request parameters
Similarities
Authentication Both the standard v1.1 and X API v2 Retweets lookup endpoints (v1.1 GET statuses/retweets/:id and v1.1 GET statuses/retweeters/:ids) use OAuth 1.0a User Context or OAuth 2.0 Bearer Token. Users per request limits For both v1.1 and v2 GET endpoints the max number of users that will be returned by the Retweets lookup endpoint is 100 users. For the v2 Retweets lookup endpoint, there is no pagination token being passed, by default we give out 100 users and that’s the max that is returned.Differences
Endpoint URLs- Standard v1.1 endpoints:
- https://api.x.com/1.1/statuses/retweets/:id.json
(Returns a collection of the 100 most recent Retweets of the Post specified by the
idparameter) https://api.x.com/1.1/statuses/retweeters/ids.json(Returns a collection of up to 100 user IDs belonging to users who have Retweeted the Post specified by theidparameter)
- https://api.x.com/1.1/statuses/retweets/:id.json
(Returns a collection of the 100 most recent Retweets of the Post specified by the
- X API v2 endpoint:
- https://api.x.com/2/tweets/:id/retweeted_by (Returns a list of accounts who have Retweeted a given Post)
- At the JSON root level, the standard endpoints return Post objects in a statuses array, while X API v2 returns a data array.
- Instead of referring to Retweeted and Quoted “statuses”, X API v2 JSON refers to Retweeted and Quoted Tweets. Many legacy and deprecated fields, such as contributors and user.translator_type are being removed.
- Instead of using both favorites (in Post object) and favourites (in user object), X API v2 uses the term like.
- X is adopting the convention that JSON values with no value (for example, null) are not written to the payload. Post and user attributes are only included if they have a non-null values.
- A conversation_id field
- Two new annotations fields, including context and entities
- Several new metrics fields
- A new reply_setting field, which shows you who can reply to a given Post
Code examples
Get users who Retweeted a Post (v2)
cURL