taspinar / twitterscraper

Scrape Twitter for Tweets
MIT License
2.4k stars 581 forks source link

Can I obtain the replies of a tweet? #193

Closed VolodyaCO closed 5 years ago

VolodyaCO commented 5 years ago

If I have a tweet with an id, can I pass this id to twitterscrapper to obtain all replies of the original tweet?

taspinar commented 5 years ago

No, but you can obtain the replies to an person and then filter out the result.

VolodyaCO commented 5 years ago

@taspinar And how can I do that? The tweets that are replies to a person (with the option "filter:replies" in the advanced search) do not mention the id of the tweet they are replying to.

For example twitterscraper "cmilanoticia filter:replies" -l 1000 -bd 2019-06-13 -ed 2019-06-15 -o tweets.json gives only tweets that are replies to cmilanoticia, but I do not know which tweets reply to which tweet.

taspinar commented 5 years ago

Can you have a look at https://github.com/taspinar/twitterscraper/pull/100. I believe that is what you're looking for.

VolodyaCO commented 5 years ago

@taspinar So I'd have to modify tweet.py to implement what you are saying, right?

Because this reply_to_id idea is not implemented right now

taspinar commented 5 years ago

No not yet.

VolodyaCO commented 5 years ago

I modified tweet.py and got what I needed. Thanks @taspinar I will close this issue.