PLhery / node-twitter-api-v2

Strongly typed, full-featured, light, versatile yet powerful Twitter API v1.1 and v2 client for Node.js.
https://www.npmjs.com/package/twitter-api-v2
Apache License 2.0
1.29k stars 176 forks source link

[bug] Edit Tweet feature #392

Closed camiaei closed 1 year ago

camiaei commented 1 year ago

It seems that two other things (#383) need to be updated regarding the edit tweets implementation:

There are three components to a Tweet’s edit history:

[x] By default, the Tweet payload will contain an array of Tweet IDs that are part of a Tweet’s edit history. 
This information is specified by the edit_history_tweet_ids, which is a default field in the Tweet payload. 
This array will contain at least one ID, the ID of the original, unedited Tweet. When there is only one ID 
that means the Tweet has no edit history. 

[ ] You can get information such as whether a Tweet was editable at the time it was created, how much
 time, if any, is remaining for a Tweet to be edited, and how many edits remain by specifying edit_controls
 in your [tweet.fields](https://developer.twitter.com/en/docs/twitter-api/fields) parameter.

[ ] Finally, you can get the Tweet objects for each Tweet in a Tweet’s edit history, by specifying the 
edit_history_tweet_ids using the [expansion](https://developer.twitter.com/en/docs/twitter-api/expansions) parameter

https://developer.twitter.com/en/docs/twitter-api/edit-tweets

Cheers👋

alkihis commented 1 year ago

Thanks you for the link, looking forward to implement those changes this weekend.