开发者

Any API to search Google Cache?

开发者 https://www.devze.com 2023-01-20 21:07 出处:网络
I am trying to search within Google Cache, so I need to fire this query: http://webcache.开发者_StackOverflowgoogleusercontent.com/search?q=cache:news.ycombinator.com/news+hacker+news

I am trying to search within Google Cache, so I need to fire this query:

http://webcache.开发者_StackOverflowgoogleusercontent.com/search?q=cache:news.ycombinator.com/news+hacker+news

And get some content like timestamp from the page. But when I do this using curl (ruby), it gives a permission denied error, i.e. scraping is blocked and that was expected.

So, is there any way to search google cache (either an API or some kind of workaround scraping) and extract some information like timestamp?


I didn't get any API but I can scrape it using hpricot or nokogiri in rails (curl in Rails gives permission denied error). I will put up the code once I figure out how to extract the time stamp from the above URL using these gems.

Any one has a better solution?


This looks like it could do it: http://code.google.com/apis/soapsearch/reference.html#1_2

0

精彩评论

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

关注公众号