Email distribution problem

221 views
Skip to first unread message

Alex Mazloom

unread,
Jun 4, 2024, 5:04:54 PM6/4/24
to Google Apps Script Community
I have been using a script to send email messages to selected addresses that the script selects from a Google Sheet. The script normally sends about 400-500 messages. Since last week, the script is stopping in the middle and logs the following error. I cannot find any information on this error code. The script once stopped after sending 244 messages another time after 127.

Exception: Gmail operation not allowed. at sendMail(Code:155:14)

George Ghanem

unread,
Jun 4, 2024, 7:32:51 PM6/4/24
to google-apps-sc...@googlegroups.com
Is this a workplace account or a free Gmail account? You are probably hitting the cap on how many emails you can send per day.


On Tue, Jun 4, 2024, 2:04 p.m. Alex Mazloom <amaz...@mindtreasures.com> wrote:
I have been using a script to send email messages to selected addresses that the script selects from a Google Sheet. The script normally sends about 400-500 messages. Since last week, the script is stopping in the middle and logs the following error. I cannot find any information on this error code. The script once stopped after sending 244 messages another time after 127.

Exception: Gmail operation not allowed. at sendMail(Code:155:14)

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-c...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-script-community/60bf83f5-c7bc-4ef6-bfef-d943d0345150n%40googlegroups.com.

Alex Mazloom

unread,
Jun 4, 2024, 8:24:52 PM6/4/24
to Google Apps Script Community
This is a workplace which has a 2,000 message daily limit and I am not even close to this limit.

George Ghanem

unread,
Jun 4, 2024, 10:28:24 PM6/4/24
to google-apps-sc...@googlegroups.com
The limits are not emails, but contacts. I forget the actual cap numbers but you can only send it to that number of email addresses. If your emails are including others as copied, or bcc then you are also multiplying how many contacts you are sending to.

Check the GmailApp facility, there is a method for you to get a view of the cap and how many you have already used on the day.

Reply all
Reply to author
Forward
0 new messages