I have been trying to setup sendgrid on SQL Database Mail but all the time it says Cannot send mail to mail server.
This is what i have done.
I have tried using [email protected] and sendgrid account password in Database Mail Config wizard for Basic authentication, but sendgrid suggested they don't accept Basic authentication. Please help how and where should i pass the api key if not under Basic Authentication ? I tried updating with msdb.dbo.sysmail_add_account_sp nad updating records but it too didn't resolve and send email from Database mail.
Any help/ guidance would be greatly appreciated or if you had faced this how have you resolved it.

Hi the solution is as follows
Create a dbmail profile
SMTP Authentication
Thats it. Send a test email.
If it still doesn't work, if you are on AWS EC2 ensure that security group allows outbound port:25
Here is the link from sendgrid about apikey authentication. https://docs.sendgrid.com/for-developers/sending-email/upgrade-your-authentication-method-to-api-keys
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With