RE: How to email using SuiteScript in Sandbox?
const senderId = 35111 // employee id
const recipientEmail = [‘firstTest@gmail.com’, ‘secondTest@company.com’];
const recipientCCEmail = [‘thirdTest@gmail.com’, ‘fourthTest@company.com’];
email.send({
author: senderId,
recipients: recipientEmail,
cc: recipientCCEmail,
subject: ‘Test: license code’,
body: `There is not enough license code for this order.
Please add more license code for sku: 1234`,
relatedRecords: {
entityId: recipientId
}
});
I get an email on my company’s email on (35111) and next to the subject I get (officially to: firstTest… secondTest… officially cc: thirdTest… fourthTest.
None of the other email is getting an email. I release the Script, this is on sandbox, only the sender is receiving the email.
None of the other email is getting an email. I release the Script, this is on sandbox, only the sender is receiving the email.
Hi Chris,
That makes total sense to why the external email shows in parentheses. Thanks for fast respond, explanation and the link with additional information.