Send email using OAuth
-
25-10-2019 - |
Question
I am trying to send an email through gmail using oauth credentials. I cannot seem to find any smtp class in the framework, or open source alternatives that work with oauth access token.
I found these references on google developer's website Gmail IMAP and SMTP using OAuth - Overview and Gmail IMAP and SMTP using OAuth - Protocol, but I am not sure who to implement it.
- Are there any open source classes that support sending emails that are authenticated by oauth credentials?
- Is there any wrapper that helps write custom smtp calls ?
Thank you
Solution
I think you can just use SmtpClient in the System.Net.Mail namespace.
This Q covers how to do it in detail: Sending Email via GMail and .NET 4
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow