开发者

How to query old tweets?

开发者 https://www.devze.com 2023-03-27 17:39 出处:网络
I\'m coding a PHP class to query old tweets base on the Twitter Search API but I noticed they only return tweets not older than a week, I see sites like http://snapbird.org/ that allows you to look fo

I'm coding a PHP class to query old tweets base on the Twitter Search API but I noticed they only return tweets not older than a week, I see sites like http://snapbird.org/ that allows you to look for really old tweets so I guess this is possible? Or is there another way to do开发者_运维问答 it?

Thanks in advance!


Umm, just to throw it out there. Did you end up trying to click on the Github fork link in the website you linked to in your question? It was easy to miss, it links to a library that solves your issue . . https://github.com/remy/snapbird

I imagine if you want to build your own class instead, looking through this one to see how it's done behind the scenes would help you out the most.


An alternative method might be to regularly query twitter then save the results to a database such as MySql. Unfortunately you would have to anticipate what your users would be searching for, so maybe not very useful.

0

精彩评论

暂无评论...
验证码 换一张
取 消