Query Voicemail Server

Greetings,

I am new to Asterisk VM. I am exploring a way to query a VoiceMail server that would return a list of phone numbers that left messages on my voicemail. The data could be in any form - XML,text within a SIP header, etc

Is there a SIP message or any other protocol that could support it? Does Asterisk expose such an API?

Would appreciate if anyone could throw some light.
Thanks,
AB