简体   繁体   English

使用Twitter Streaming API获取最新推文

[英]Get latest tweets using Twitter Streaming API

How can i get a list containing the latest (eg 200) tweets(along with the tweet info) on Twitter? 如何在Twitter上获取包含最新(例如200条)推文(以及推文信息)的列表? I don't want to search for a specific user or keyword, nor to get the auth user tweets. 我既不想搜索特定的用户或关键字,也不想获取auth用户的推文。

If the above scenario is possible, then how could i get the next 200 tweets? 如果上述情况可行,那么我如何获得下200条推文?

In case it matters, I am using JavaScript and parsing returned JSON object to get the data i need. 万一重要,我正在使用JavaScript并解析返回的JSON对象以获取所需的数据。

Thank you 谢谢

You can get good source code using link here. 您可以在此处使用链接获取良好的源代码。

get_tweets.php can be used for getting real time tweets and filling them to your database . get_tweets.php可用于获取实时tweet并将其填充到数据库中 And using simple database operation you can easily extract last 200 tweets because you already getting their tweet time info inside json object. 使用简单的数据库操作,您可以轻松提取最后200条tweet,因为您已经在json对象中获取了它们的tweet时间信息。

parse_tweets.php also can be used for putting them into the database in parsed form. parse_tweets.php也可以用于将它们以已解析的形式放入数据库中。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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