Closed Martin36 closed 5 years ago
I solved it. Had to change the emailConfig
to use the host for EU instead
const emailConfig = {
apiKey: 'XXXXXXXXXXXXXXX',
domain: 'mg.bandmate.xyz',
host: 'api.eu.mailgun.net'
};
Thanks for this @Martin36 this saved me from spending another 6hrs on the issue!
Close the issue @Martin36 ;)
mailgun-js@0.22.0 Windows 10 Node version: 10.3.0
I get this error when trying to send mails using a custom domain:
Error: Domain not found: mg.bandmate.xyz at IncomingMessage.res.on (C:\Users\Martin\Documents\BandMate\server\node_modules\mailgun-js\lib\request.js:327:17) at IncomingMessage.emit (events.js:187:15) at endReadableNT (_stream_readable.js:1090:12) at process._tickCallback (internal/process/next_tick.js:63:19)
It works when I send a mail from this domain using curl and everything works when I use the sandbox domain but when I change to the custom one that error shows. Here is the code that I use for sending the email: