开发者

How to find tweets that contain a URL?

Is there a possibility to search for tweets which link to a specific URL or, even better, domain?

There is already a service doing this, but I can't figure out how to do it myself via开发者_JAVA百科 the twitter-Api...

http://backtweets.com/api

It seems rather impossible to just collect all tweets which include a URL, expand the URL, save them all and just then look for certain URLs..


New solution:

You can use the api method get-tweet-search from Twitters api. To find tweets containing an url you have to pass the parameter q="url:stackoverflow.com". Unfortunately you must have an access token to do this call.

More info how to use Twitters search operators can be found at https://developer.twitter.com/en/docs/tweets/search/guides/standard-operators.


This answer is now soon 8 years old. Twitter have changed their api since.

Old answer:

Hope this might be to any help.

http://search.twitter.com/search.atom?q=<query>
You can use .atom (xml) and .json. Just remeber to url-encode the string.

Example:
http://search.twitter.com/search.json?q=stackoverflow.com

Read the Documentation Here


Why dont you use site:"google.com" keyword. It returns the tweets that has at least one url on google.com domain link with your other constraint.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜