Introduction to development for notification mail sending with Gmail

Do you mean SMTP with oAuth authentication instead of Basic authentication? Or are you looking to send mail via some other pathway?

Discourse does not support SMTP oAuth authentication, so the simplest approach is probably having Discourse hand off email to a local mail server configured in such a way that submits the mail with necessary authentication.

Google’s supported mechanism for this seems to be: