Using client.discovered_api('gmail', 'v1')
, I'm sending an email using the gmail.users.messages.send
function
It sends my messages fine, but when the quota of email is exceeded, there is no error.
I receive 200 OK and it all looks good.
"id": "15289b1d6b652c17", "threadId": "15289b1d6b652c17","labelIds": ["SENT"]
But for each message above the quota, I receive an email from Bounce (nobody@gmail.com) telling me:
You have reached a limit for sending mail.
This page says that I should receive 429 error code
, but I don't.
Any idea what could go wrong? Or if there is a way to query the quota?
Edit: After investigations, even though email from nobody is received telling me quota is reached, the original email is sent anyway (meaning it's possible to go over the quota at the expense of receiving many nobody emails).
Edit2: I reported a problem on their API page, but still didn't hear anything from anyone. The lack of response is baffling.
Edit 3: Turns out their solution is just broken by design. There is a delay for updating the quota (can be more than 30 minutes... you can send a lot of emails in 30 min), so it lets you send and after tells your users that your message wasn't send after all (although it may have, given the tests I did). Totally unreliable. No information in the bounce to figure out what message was actually rejected. When you send 100 emails campaign on behalf of users, this is just not working.