web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
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 102
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 
 
I have the same question (0)
  • Suggested answer
    Ramit Paul Profile Picture
    22,803 Most Valuable Professional on at
    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.
     
  • Suggested answer
    Hana Xue Profile Picture
    Microsoft Employee on at
    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

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Giorgio Bonacorsi Profile Picture

Giorgio Bonacorsi 617

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 461 Super User 2026 Season 1

#3
Syed Haris Shah Profile Picture

Syed Haris Shah 298 Super User 2026 Season 1

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans