How to list mails in personal mailbox by accessing without a user and using Microsoft Graph SDK?

Chong Liu 40 Reputation points

when i debug in, and throw an exception named ErrorInvalidUser with error message "The requested user '' is invalid."

java code is in the attachement named App.txt企业微信截图_16984007351466


Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
9,138 questions
{count} votes

Accepted answer
  1. CarlZhao-MSFT 31,976 Reputation points

    Hi @Chong Liu

    Do not try to use the application token to retrieve mail for the personal account, it can only be used for your work account.

    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.

0 additional answers

Sort by: Most helpful