View list of messages

Does anyone know where i can look to find a tut that explains how to access the list of messages on a mail server for a specific email address on the mail server and output that list?