InnoGE / laravel-msgraph-mail

Laravel Mail driver for Microsoft Office 365 using the MSGraph API
MIT License
26 stars 7 forks source link

[Question]: ErrorInvalidUser #16

Closed davidvandertuijn closed 6 months ago

davidvandertuijn commented 7 months ago

What happened?

code: ErrorInvalidUser message: The requested user 'example@domain.tld' is invalid.

.env MAIL_FROM_ADDRESS="example@domain.tld"

Any idea why i receive this error, the customer say the user exists in Azure.

How to reproduce the bug

Mail::send()

Package Version

1.1

PHP Version

8.1

Laravel Version

10.43

Which operating systems does with happen with?

macOS

Notes

No response

geisi commented 7 months ago

@davidvandertuijn Please check if the Azure App has sufficient permissions to send emails from every user in the tenant.

https://geisi.dev/blog/getting-rid-of-deprecated-microsoft-office-365-smtp-mail-sending/

davidvandertuijn commented 7 months ago

@geisi permissions

davidvandertuijn commented 6 months ago

@geisi It appears that the Active Directory administrator created a user, which was properly linked to the correct domain, but the primary email address was set to a different domain. This is not something I can observe directly, but it is unrelated to this library. You may close the issue.