Back

[SOLVED] Added SendGrid in .env and restarted but nothing sends

  • 0
  • Self Hosted
  • General
ZachHandley
28 Jul, 2023, 20:54

I set the port to 465 for APP_SMTP_SECURE my bad lmao

TL;DR
The user was having an issue with their SendGrid setup where emails were not sending. They discovered that the issue was with the `_APP_SYSTEM_EMAIL` parameter and fixed it. However, they started experiencing other issues where emails were being sent twice and they were getting rate limited. They also mentioned a bug with the resend button not working. The user later realized that they had set the wrong port for the `_APP_SMTP_SECURE` parameter.
ZachHandley
28 Jul, 2023, 20:54

that resend button not working is still a bug I believe

ZachHandley
28 Jul, 2023, 20:57

and now I'm rate limited after deleting and adding the 3 back

ZachHandley
28 Jul, 2023, 20:57

What's the rate limit?

ZachHandley
28 Jul, 2023, 20:59

@Steven after fixing the TLS it still errors, same error

ZachHandley
28 Jul, 2023, 21:00

3 of these

Drake
28 Jul, 2023, 21:00

Ya, a new issue if one doesn't exist might be good

ZachHandley
28 Jul, 2023, 21:00
TypeScript
_APP_SMTP_HOST=smtp.sendgrid.net
_APP_SMTP_PORT=587
_APP_SMTP_SECURE=tls
_APP_SMTP_USERNAME=apikey

my .env

ZachHandley
28 Jul, 2023, 21:01

I'm confusd

Drake
28 Jul, 2023, 21:02

What did you set _APP_SYSTEM_EMAIL_ADDRESS to?

ZachHandley
28 Jul, 2023, 21:02

ohhh I need to set that to the same as the sendgrid email?

ZachHandley
28 Jul, 2023, 21:04

also it looks like

ZachHandley
28 Jul, 2023, 21:04

in the logs

ZachHandley
28 Jul, 2023, 21:04

it sent each email twice

ZachHandley
28 Jul, 2023, 21:04

or tried to

Drake
28 Jul, 2023, 21:04

Yes, as the docs state

Drake
28 Jul, 2023, 21:05

What makes you say that?

ZachHandley
28 Jul, 2023, 21:06

It's hard to tell exactly but it looks like each person was repeated twice in the logs

ZachHandley
28 Jul, 2023, 21:06

wow that's a horrible formatting discord

ZachHandley
28 Jul, 2023, 21:06

can't make it wrap?

Drake
28 Jul, 2023, 21:20

🧐 i don't see that. after the worker started, i see 3 jobs each with different email

Drake
28 Jul, 2023, 21:26

the error is:

appwrite-worker-mails | ,503,SMTP server error: MAIL FROM command failed Detail: Only one sender per message, please appwrite-worker-mails | SMTP code: 503 in /usr/src/code/app/workers/mails.php:68

What's the output of:

TypeScript
docker compose exec appwrite-worker-mails vars | grep _APP_SYSTEM_EMAIL_ADDRESS
ZachHandley
28 Jul, 2023, 22:44

I fixed it, it was the _APP_SYSTEM_EMAIL parameter

Drake
28 Jul, 2023, 23:17

[SOLVED] Added SendGrid in .env and restarted but nothing sends

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more