Skip to main content

Start-CloudPC

Powers on one or more Windows 365 Cloud PCs.

Description

Issues POST /deviceManagement/virtualEndpoint/cloudPCs/{id}/powerOn against Microsoft Graph beta, which is an asynchronous operation: Graph returns 204 No Content immediately and the actual power-on action happens in the background.

The cmdlet accepts Cloud PC objects from Get-CloudPC, exact Cloud PC names, or Cloud PC IDs. It supports -WhatIf / -Confirm and defaults to ConfirmImpact = 'High'. Use -Force to suppress the confirmation prompt in automation.

Requires the CloudPC.ReadWrite.All scope; the cmdlet automatically re-authenticates via Connect-CloudPC if the current Graph session does not already have it.

Syntax


Start-CloudPC -CloudPC <Object> [-Force] [-PassThru] [-WhatIf] [-Confirm] [<CommonParameters>]

Start-CloudPC -Id <string> [-Force] [-PassThru] [-WhatIf] [-Confirm] [<CommonParameters>]

Parameters

NameTypeRequiredAliasesDescription
CloudPCObjectYesA WindowsCloudPC.CloudPC object (as returned by Get-CloudPC), or a Cloud PC name or ID.
Accepts pipeline input.
ForceSwitchParameterNoSuppress the confirmation prompt. Equivalent to -Confirm:$false.
IdStringYesCloudPcIdThe Cloud PC ID (GUID) when you do not have a CloudPC object handy.
PassThruSwitchParameterNoEmit a WindowsCloudPC.PowerOnResult object describing the outcome of each power-on request.
By default the cmdlet is silent on success.

Graph endpoints

/beta/deviceManagement/virtualEndpoint/cloudPCs/{id}/powerOn

Example 1

Start-CloudPC -Id '8ab4e59b-1866-4ce9-8bc8-92856e61edf4' -Force -PassThru

Powers on a single Cloud PC by ID without prompting and emits the request result.

Example 2

Start-CloudPC -CloudPC 'CPC-brad-U2O0S' -Force

Resolves a Cloud PC by exact name and sends the power-on request.

Example 3

Get-CloudPC -Type Dedicated | Start-CloudPC -WhatIf

Previews which dedicated Cloud PCs would be powered on without sending requests.

Source

View Start-CloudPC.ps1 on GitHub