Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Suggested answer

the remote server returned an error: (401) unauthorized - When sending emails from Dynamics 365 F&O

(1) ShareShare
ReportReport
Posted on by 72
Hi All, 
 
I am hoping someone can help me. 
 
I am getting the error below when i am trying to send and email from Dynamics:
 
System.Net.WebException: The remote server returned an error: (401) Unauthorized.
   at System.Net.HttpWebRequest.GetResponse()
   at Microsoft.Dynamics.Platform.Integration.Exchange.HttpExecutor.Send(IHttpExecutorRequest request)
   at Microsoft.Dynamics.Platform.Integration.Exchange.ExchangeProxy.<>c__DisplayClass20_0.<SendMessage>b__0()
   at Microsoft.Dynamics.Platform.Integration.Exchange.ExchangeProxy.SendMessage(MailMessage sourceMessage, Guid correlationId)
   at Dynamics.AX.Application.SysMailerExchange.`sendMessage(MailMessage _message, Boolean _interactive, Guid _correlationId)
 
Can you advise why this is?
 
 
Any help you can provide will be much appreciated. 
 
Kind regards,
 
Hetal 
 
  • Suggested answer
    Hana Xue Profile Picture
    Microsoft Employee on at
    the remote server returned an error: (401) unauthorized - When sending emails from Dynamics 365 F&O
    Hi,
    The error message "The remote server returned an error: (401) Unauthorized" usually means that the system is encountering a problem with the verification or authorization email sending process.
    • Verify that email settings are configured correctly. Make sure email parameters, SMTP server, username, password and any other relevant settings are accurate.
    • The error message specifically mentions "401 Unauthorized," which is usually related to authentication issues. Double check the email account credentials used to send the email.
    • The error message mentions "An error occurred during format mapping run". Review the email format mapping settings to make sure they are configured correctly. Check for any issues with format conversion or files. You can test sending an email with different attachments to see if the problem is specific to this file.
    • Verify the email address to which you want to send the email. Test the email sending process with simplified messages and attachments to isolate issues.
    If there is no problem with the above, as Ramit said, you can try to contact the developer for debugging, or check the relevant logs.
    Hope these suggestions are useful.
    Best Regards,
    Hana
  • Suggested answer
    Ramit Paul Profile Picture
    22,572 Most Valuable Professional on at
    the remote server returned an error: (401) unauthorized - When sending emails from Dynamics 365 F&O
    There can be multiple things to look at.
     
    I would check my email parameter by "Test connection" if fine that means system can send email.
     
    I would then check other standard report if those can be sent from system by using email as destination.
     
    if above two are fine, there must be issue with the payment advice destination setup and vendor email details.
     
    If everything is fine, I would re-import the payment format from ER repos from ER workspace and try.
     
    if everything is fine, I would debug by a developer to see what is the issue.
     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Jonas ”Jones” Melgaard – Community Spotlight

We are honored to recognize Jonas "Jones" Melgaard as our April 2025…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 294,261 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 233,013 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,158 Moderator

Leaderboard

Product updates

Dynamics 365 release plans