Receiving a GMAIL error: "Error encountered while sending using Gmail API", Precondition check failed.

Problem Symptoms

Attempting to send or sync an email from a Google connected account you are receiving the following error from our API:

SendMailException
Error encountered while sending using Gmail API

 

Description

This error message typically occurs when the Google API returns a "precondition check failed" message to our API service. Example:

<HttpError 400 when requesting https://gmail.googleapis.com/upload/gmail/v1/users/me/messages/send?uploadType=resumable&alt=json returned "Precondition check failed.">

 

Resolution

Several items to check:
1) Your trial period could have expired (if you use one). Check your status at admin.google.com
2) There is no email address that you use in FROM field created in your G Suite.
3) Your email address is not a Gmail account. It is possible to be a Google Account but not a Gmail account (for example if you use the account for YouTube but have never enabled Gmail).
4) You may need to enable the Gmail feature or Gmail API access in your G Suite.
5) Ensure this is NOT a service account
6) Ensure the APP is trusted in the Google Workspace account.
7) Make sure this is the PRIMARY account, not impersonating / alias

 

Resources

There are a lot resources and possible causes for the error,  "

Updated

Was this article helpful?

0 out of 0 found this helpful

Have more questions? Submit a request

Comments

0 comments

Please sign in to leave a comment.