Google App Engine Java Sending mail from an alternate email address

Is there a way to change the From email address to a different email address in the Google engine. Right now, I want to send addresses from my domain that are related to the Google engine, not the email address or primary address. i.e.: my account address is XXX@gmail.com , but I want the email to be sent from no-reply@mydomain.com.

thank,

+3
source share
1 answer

Here is the documentation

Here is the relevant section:

Message msg = new MimeMessage(session);
msg.setFrom(new InternetAddress("admin@example.com", "Example.com Admin"));

A little further he points out a disclaimer:

, setFrom() MimeMessage. , , Google.

no-reply@mydomain.com . , no-reply@mydomain.com . , . , , , , .

+2

Source: https://habr.com/ru/post/1756603/


All Articles