I think the Search API could do this, but this has to be licensed.
Speak with your sales rep, I don't know the pricing.
You will get an API guide with a fairly good description of the Search API.
You can write it in C++, C#, VB.NET, and maybe even VBS.
Cheers