We should extend the output of the m365 status command with information about the appId and tenant used in authentication.
We should extend the output from:
{
"connectedAs": "name"
}
to:
{
"connectedAs": "name",
"appId": "123",
"appTenant": "common"
}
Rationale
After experimenting with a custom AAD app, today, while trying to create an app reg using the CLI, I got an "Insufficient privileges to complete the operation" error. After scratching my head for a sec I realized, that it's because the app reg I was using yesterday had no scopes for managing AAD apps. That's not obvious when you check status, because it only shows the user or app name. Unless you know to check the token, it's not trivial to figure out and is something that we should communicate more clearly.
We should extend the output of the
m365 statuscommand with information about the appId and tenant used in authentication.We should extend the output from:
{ "connectedAs": "name" }to:
{ "connectedAs": "name", "appId": "123", "appTenant": "common" }Rationale
After experimenting with a custom AAD app, today, while trying to create an app reg using the CLI, I got an "Insufficient privileges to complete the operation" error. After scratching my head for a sec I realized, that it's because the app reg I was using yesterday had no scopes for managing AAD apps. That's not obvious when you check status, because it only shows the user or app name. Unless you know to check the token, it's not trivial to figure out and is something that we should communicate more clearly.