If you are trying to use a personal account to log in to the app and call the Graph Mail API to send an email, then follow this:
First, you'll need to register an app in your tenant that allows personal accounts to log in.
Next, use the authorization code flow to authenticate your personal account and generate an access token. Note that when logging in to a user and requesting a token, you need to change /{tenant_id}
to /common
.
Finally, call the POST /me/sendMail
API to send the email.
By the way, MS 365 license is not required for personal or social accounts. But for work accounts, MS 365 license is necessary.
Hope this helps.
If the reply is helpful, please click Accept Answer and kindly upvote it. If you have additional questions about this answer, please click Comment.