Decoupled the email format and made it configurable