warning: Sending and receiving messages from WhatsApp through email
would bypass the end-to-end encryption and may leak data to the email providers (Check update). If your reason for reading this is for better data security, then this is may not the right approach.
This approach can help those who are looking to isolate WhatsApp to reduce hardware finger-printing, asymmetric association, receive non-sensitive messages.
Tasker android app.
Auto Notification android app.
MailTask android app.
I set my mail account using IMAP & SMTP in K-9 Mail and in Mail Task.
Tasker requires permissions to read notifications, exception in doze mode and Write Secure Settings Permission. Tasker will inform as and when these permissions are needed when setting up the app.
Since I used blissOS, I set 'Write Secure Settings Permissions' through the console [Alt+F1].
I set up two tasker profiles for this automation, 'WhatsApp to Email' and 'Email to WhatsApp'.
Gif demonstration of send and receiving WhatsApp messages through email.
If you'd like to see the demo on video and also listen to why I think app streaming could be thing; Check it out on YouTube.
That's all, if you have any queries hit me up on Twitter.
Using K-9 Mail's PGP encryption we can achive end-to-end encryption if both our email IDs used for whatsapp communication uses K-9 Mail configured with PGP.
Note: I'm not using this method in the above demonstration.
March 2021: Added note on encryption.