API improvements

Sucessful authentication now simply returns the mailbox.
Module now simply accepts a dependencies object.