How to initiate an action from and email, through an Alexa Dot's smart light switch

When I search for “IMAP” I see a lot about IMAP problem examples, where can I find some working examples?