Solved: SMTP send fails error 554 5.2.0 STOREDRV.Submission.Exception:SendAsDeniedException.MapiExceptionSendAsDenied

Our backend was programmed and configured to send e-mails using Microsoft 365 SMTP. Until one day an error was logged: Failed sending e-mail message 35922665: 554 5.2.0 STOREDRV.Submission.Exception:SendAsDeniedException.MapiExceptionSendAsDenied; Failed to process message due to a permanent exception with message Cannot submit message. smtp.office365.com, port 587. Microsoft suggested reason for this https://docs.microsoft.com/en-us/exchange/troubleshoot/mail-delivery/mapiexceptionnotfound-ndr Did not help us. […]