You can use it as a template to create your own modules.
I added comments to variables and actions, where necessary.
You will need to set the default value for E-mail Settings Table in Variable Manager.
Settings list for some domains
Domen,Server,Port,Protocol,SSL
POP3
gmail.com,pop.gmail.com,995,POP3,Yes
yahoo.com,pop.mail.yahoo.com,995,POP3,Yes
outlook.com,pop-mail.outlook.com,POP3,995,Yes
hotmail.com,pop-mail.outlook.com,POP3,995,Yes
office365.com,outlook.office365.com,POP3,995,Yes
IMAP
gmail.com,imap.gmail.com,993,IMAP,Yes
yahoo.com,imap.mail.yahoo.com,993,IMAP,Yes
outlook.com,imap-mail.outlook.com, 993, IMAP, Yes
hotmail.com,imap-mail.outlook.com, 993, IMAP, Yes
The version of the browser - GeckFx 45.