Hi,
I am currently trying to switch to Business Central base notifications as opposed to our previous fully-customized email notifications. I have a workflow setup which is supposed to send an email notification when a Purchase order is approved. The workflow seems to be working in terms of approval, however the notification is not working at all.
I checked the NOTIFICATION ENTRY DISPATCHER and I got the following error for all tests that I have done so far.
Transaction failed. The server response was: 5.2.252 SendAsDenied; <smtp email address> not allowed to send as <approver email address>; STOREDRV.Submission.Exception:SendAsDeniedException.MapiExceptionSendAsDenied; Failed to process message due to a permanent exception with message [BeginDiagnosticData]Cannot submit message. 0.35250:C8330000, 1.36674:01000000, 1.61250:00000000, 1.45378:02000000, 1.44866:00000000, 1.36674:7A000000, 1.61250:00000000, 1.45378:05000000, 1.44866:00140000, 1.36674:0A000000, 1.61250:00000000, 1.45378:16000000, 1.44866:BD1D0000, 1.36674:0E000000, 1.61250:00000000, 1.45378:D61D0000, 1.44866:28020000, 16.55847:DE0F0000, 17.43559:0000000030020000000000000000000000000000, 20.52176:140FEE931100F01F1F001336, 20.50032:140FEE938117F01F2C000000, 0.35180:03000136, 255.23226:0A000000, 255.27962:7A000000, 255.27962:0A000000, 255.27962:0E000000, 255.31418:4A000000, 0.35250:4800D13D, 1.36674:0A000000, 1.61250:00000000, 1.45378:02000000, 1.44866:3A000000, 1.36674:32
I have also checked the SMTP setup and the test email works fine from there. I am stumped, is this an O365 issue that I need to fix in O365 admin portal or is this a configuration issue in notification setup or finally could this be a security issue somewhere? Appreciate all your help.
aaa
Great work, thanks for sharing.
Hi,
Thanks for all your input, Marco. It may not be the exact answer but your input pointed me in the right direction.
Now my approval notifications are working. I did the following:
The main takeaways here are setting the authorization email sendAs access, in Exchange Admin, for all Approver email accounts. The other, is to set Authenticated SMTP in the Exchange Admins as well.
Hello,
If you are using legacy SMTP Server in NAV app or BC app, then you may want to use a catch all account for SMTP server and not an actual user's account. All users that need to send approval should be able to send as the SMTP Server catch all address. Furthermore, the following.
More information here:
docs.microsoft.com/.../admin-how-setup-email
Hope it helps.
Thanks.
Hey Marco,
Huzza! It worked. Thanks for that. The error is not very intuitive though, as it says that the authentication account is not allowed to send as the approver but in O365 you actually have to grant send as access to the approver account.
Once you explained it though, it made sense that the approver account has to be given access to send as. :)
May I ask as well, what is the alternative to this, you mentioned OAUTH2? It's not really ideal to add my authentication account to everyone's SendAs access.
EDIT: Actually this did not seem to work. :(
I don't know how but I tested the approval notification with your suggestion and I received the email, but upon closer inspection I noticed that this was not the approval that I sent.
I further tested this by creating more approval notifications and alas all showed the same error.
Hello,
If you are using SMTP Server setup, then this is the authentication account to send SMTP messages via Exchange Online. The sender (that sends the approval), must have send as permissions to send as the authentication account.
If you are using enhanced email, you are using OAUTH2 for authentication and the setup has been made much simpler. But yes, it is a setup requirement to overcome in Office 365 / Exchange Online. Good that the send test Email works.
Thank you.
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,151 Super User 2024 Season 2
Martin Dráb 229,963 Most Valuable Professional
nmaenpaa 101,156