I'm trying to figure out how to send mails using the MailGun Golang API without having it sent 'on behalf of'.
This is how the From address currently looks (where foo.com is the sender's email domain and bar.com is my domain):
[email protected] on behalf of John Smith <[email protected]>
What do I need to do so that it looks like this instead:
John Smith <[email protected]>
I've set up SPF and DKIM according to the MailGun instructions and everything passes as being correct. I've also used SetDKIM(true)
when I'm sending out the mail. Is there some setting I'm missing or additional validation I need to do?