cli-microsoft365 icon indicating copy to clipboard operation
cli-microsoft365 copied to clipboard

New command: search. Closes #5344

Open MartinM85 opened this issue 1 year ago • 3 comments

Closes #5344

MartinM85 avatar Mar 04 '24 11:03 MartinM85

A few notes:

  • without option resultsOnly, the output to csv and markdown is empty, I think it's caused by the complex structure of searchResponse
  • with option resultsOnly, the output to csv, markdown and text is not useful at all for users, but it seems to me to be out of the scope of #5344

The class has name SearchSearchCommand, because of some conventions.

MartinM85 avatar Mar 04 '24 11:03 MartinM85

Thank you, we'll try to have a look at it ASAP!

milanholemans avatar Mar 04 '24 12:03 milanholemans

@MartinM85 awesome work 👏🤩 We are getting a lot closer. Let's do another round before we move forward.

One thing I noticed is the additional scopes we will need to add for this command image

Were the first is not that bad but the second one Sites.ReadWrite.All seems like a huge overkill 😮. Why would a search endpoint need write permissions anyway 🤔. I need to research this a bit. @waldekmastykarz what do you think?

I just checked and it seems only Sites.Read.All is enough 🤔

Adam-it avatar May 03 '24 23:05 Adam-it

Ready to merge 🚀 Along the way, I should do a small fixup

Adam-it avatar May 16 '24 22:05 Adam-it

@waldekmastykarz I double-checked over my own app registration and it seems we need to add MS Graph Sites.Read.All scope to our PnP Management Shell app

Adam-it avatar May 16 '24 22:05 Adam-it

Merged manually. You Rock 🤩👏

Adam-it avatar May 20 '24 00:05 Adam-it