Mailgun api returns (The SSL connection could not be established, see inner exception.)

Hi,

I have problem sending emails (API http request - .Net Core) using Mailgun from the server.

If I am using the localhost, then the emails are being sent correctly but as soon as I publish the app on the server and try to send the email I get (The SSL connection could not be established, see inner exception.)

I am not sure if it’s server SSL issue, Mailgun issue or Cloudflare issue.

I wonder if someone faced this issue before.

I spend the last 3 days (few hours a day) trying to fix this issue but I am not getting anywhere.

Thanks

the CNAME I am using with the Mailgun is (email . descod . net)

I’m confused on what this has to do with Cloudflare? It sounds like something on the server is causing issues with the SSL connection to Mailgun.

I think it’s to do with resolving the SSL, I think it has nothing to due with Cloudflare but I just wanted to know if someone faced this issue before.

Hi,

I was able to fix this issue by republishing the SSL certificate and most importantly restarting the server.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.