top of page

A Login Issue of Microsoft Graph API CLI

  • dragonedison
  • Jan 15, 2024
  • 1 min read

I tried to sign in with the command in the "Sign in" section of this page Get started with the Microsoft Graph command-line interface (CLI) - Microsoft Graph | Microsoft Learn. When I entered the code and password in the browser, I was always told that the code had expired as shown below.


The code always expires.
Something Went Wrong

I found out that I could log in using the InteractiveBrowse strategy. I just needed to change the command into "mgc login --scopes User.Read Team.ReadBasic.All Channel.ReadBasic.All ChannelMessage.Send --strategy InteractiveBrowser". However, I had another issue when I ran the "mgc users list" command, and I could not fix that.

Comments


Post: Blog2_Post
  • Facebook
  • Twitter
  • LinkedIn

©2024 by Every Light of Life. Proudly created with Wix.com

bottom of page