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

New command: m365 pp website webrole get

Open appieschot opened this issue 1 year ago • 5 comments

Usage

m365 pp website webrole get

Description

Gets information about the specified webrole

Options

Option Description
-i, --id <id> The id of the webrole to retrieve details for.
--websiteId [websiteId] ID of the Power Pages website. Specify either websiteId or webName but not both.
--websiteName [websiteName] The unique name (not the display name) of the Power Pages website. Specify either websiteId or webName but not both.
-e, --environmentName <environmentName> The name of the environment where the Power Pages website is located.
--asAdmin Run the command as admin and retrieve the webrole for environments without explicitly assigned permissions.

Examples

Retrieve webrole for the site Contoso

m365 pp website webrole get --id 2ca3eaa5-140f-4175-8261-3272edf9f339 --websiteName Contoso --environmentName "Default-2ca3eaa5-140f-4175-8261-3272edf9f339"

Default properties

No response

Additional Info

https://learn.microsoft.com/en-us/power-apps/developer/data-platform/reference/entities/mspp_webrole

appieschot avatar Aug 29 '24 14:08 appieschot

LGTM. I don't have anything to add. We may open it up

Adam-it avatar Aug 29 '24 16:08 Adam-it

May I work on this! Need to complete this command for closing m365 pp website webrole remove command

ktskumar avatar Sep 27 '24 13:09 ktskumar

May I work on this! Need to complete this command for closing m365 pp website webrole remove command

Why do you need this command to finish the remove command exactly?

milanholemans avatar Sep 28 '24 22:09 milanholemans

Why do you need this command to finish the remove command exactly?

I have mistaken the options. I agree that we don’t need the webrole get command for the remove functionality if we’re only deleting based on the webrole's ID.

However, in this case, we're using the website name to retrieve the website id before proceeding with the removal. Could you please advise whether I should wait for the website get command to complete, or if I can proceed directly with deletion based on the website ID?

ktskumar avatar Sep 30 '24 00:09 ktskumar

However, in this case, we're using the website name to retrieve the website id before proceeding with the removal. Could you please advise whether I should wait for the website get command to complete, or if I can proceed directly with deletion based on the website ID?

I believe you can just work on the remove command just like it's specced, even with the websiteName option, right? It's perfectly possible that multiple commands share the same piece of code, that's why we create utils for repetitive tasks.

milanholemans avatar Sep 30 '24 07:09 milanholemans