I was after this same thing a few weeks ago and was told there is no
way to get this information from the official Twr. API as of now...
But somehow twitfave does this.
And they have an API:
http://twitfave.com/home/about/api
The portion you need is in getting information about a single tweet
-
I personally from one machine have most of Twitter in the past 2
months indexed. Yes it's possible. The Twitter Advocates who are
dickheads [yeah you guys] suspended all of my apps but one [luckily I
don't use my personal account of course for my work when I mentioned
methods for this].