Restore-MgDeviceManagementVirtualEndpointCloudPc
Restore a specific cloudPC object to a previous state from a snapshot. Use this API to trigger a remote action that restores a Cloud PC device to a previous state.
Note
To view the beta release of this cmdlet, view Restore-MgBetaDeviceManagementVirtualEndpointCloudPc
Syntax
Restore-MgDeviceManagementVirtualEndpointCloudPc
-CloudPcId <String>
[-ResponseHeadersVariable <String>]
[-AdditionalProperties <Hashtable>]
[-CloudPcSnapshotId <String>]
[-Headers <IDictionary>]
[-PassThru]
[-ProgressAction <ActionPreference>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Restore-MgDeviceManagementVirtualEndpointCloudPc
-CloudPcId <String>
-BodyParameter <IPathsM2Hnp9DevicemanagementVirtualendpointCloudpcsCloudpcIdMicrosoftGraphRestorePostRequestbodyContentApplicationJsonSchema>
[-ResponseHeadersVariable <String>]
[-Headers <IDictionary>]
[-PassThru]
[-ProgressAction <ActionPreference>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Restore-MgDeviceManagementVirtualEndpointCloudPc
-InputObject <IDeviceManagementActionsIdentity>
[-ResponseHeadersVariable <String>]
[-AdditionalProperties <Hashtable>]
[-CloudPcSnapshotId <String>]
[-Headers <IDictionary>]
[-PassThru]
[-ProgressAction <ActionPreference>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Restore-MgDeviceManagementVirtualEndpointCloudPc
-InputObject <IDeviceManagementActionsIdentity>
-BodyParameter <IPathsM2Hnp9DevicemanagementVirtualendpointCloudpcsCloudpcIdMicrosoftGraphRestorePostRequestbodyContentApplicationJsonSchema>
[-ResponseHeadersVariable <String>]
[-Headers <IDictionary>]
[-PassThru]
[-ProgressAction <ActionPreference>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
Restore a specific cloudPC object to a previous state from a snapshot. Use this API to trigger a remote action that restores a Cloud PC device to a previous state.
Permissions
Permission type | Least privileged permissions | Higher privileged permissions |
---|---|---|
Delegated (work or school account) | CloudPC.ReadWrite.All | Not available. |
Delegated (personal Microsoft account) | Not supported. | Not supported. |
Application | CloudPC.ReadWrite.All | Not available. |
Examples
Example 1: Code snippet
Import-Module Microsoft.Graph.DeviceManagement.Actions
$params = @{
cloudPcSnapshotId = "A00009UV000_93aff428-61f2-467f-a879-1102af6fd4a8"
}
Restore-MgDeviceManagementVirtualEndpointCloudPc -CloudPCId $cloudPCId -BodyParameter $params
This example shows how to use the Restore-MgDeviceManagementVirtualEndpointCloudPc Cmdlet.
Parameters
-AdditionalProperties
Additional Parameters
Type: | Hashtable |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-BodyParameter
. To construct, see NOTES section for BODYPARAMETER properties and create a hash table.
Type: | IPathsM2Hnp9DevicemanagementVirtualendpointCloudpcsCloudpcIdMicrosoftGraphRestorePostRequestbodyContentApplicationJsonSchema |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-CloudPcId
The unique identifier of cloudPC
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-CloudPcSnapshotId
.
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Confirm
Prompts you for confirmation before running the cmdlet.
Type: | SwitchParameter |
Aliases: | cf |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Headers
Optional headers that will be added to the request.
Type: | IDictionary |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-InputObject
Identity Parameter To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
Type: | IDeviceManagementActionsIdentity |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-PassThru
Returns true when the command succeeds
Type: | SwitchParameter |
Position: | Named |
Default value: | False |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ProgressAction
{{ Fill ProgressAction Description }}
Type: | ActionPreference |
Aliases: | proga |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ResponseHeadersVariable
Optional Response Headers Variable.
Type: | String |
Aliases: | RHV |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Type: | SwitchParameter |
Aliases: | wi |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Inputs
Microsoft.Graph.PowerShell.Models.IDeviceManagementActionsIdentity
Microsoft.Graph.PowerShell.Models.IPathsM2Hnp9DevicemanagementVirtualendpointCloudpcsCloudpcIdMicrosoftGraphRestorePostRequestbodyContentApplicationJsonSchema
System.Collections.IDictionary
Outputs
System.Boolean
Notes
COMPLEX PARAMETER PROPERTIES
To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
BODYPARAMETER <IPathsM2Hnp9DevicemanagementVirtualendpointCloudpcsCloudpcIdMicrosoftGraphRestorePostRequestbodyContentApplicationJsonSchema>
: .
[(Any) <Object>]
: This indicates any property can be added to this object.[CloudPcSnapshotId <String>]
:
INPUTOBJECT <IDeviceManagementActionsIdentity>
: Identity Parameter
[AppLogCollectionRequestId <String>]
: The unique identifier of appLogCollectionRequest[CloudPcId <String>]
: The unique identifier of cloudPC[CloudPcOnPremisesConnectionId <String>]
: The unique identifier of cloudPcOnPremisesConnection[CloudPcProvisioningPolicyId <String>]
: The unique identifier of cloudPcProvisioningPolicy[CloudPcUserSettingId <String>]
: The unique identifier of cloudPcUserSetting[DeviceCompliancePolicyId <String>]
: The unique identifier of deviceCompliancePolicy[DeviceConfigurationId <String>]
: The unique identifier of deviceConfiguration[DeviceEnrollmentConfigurationId <String>]
: The unique identifier of deviceEnrollmentConfiguration[DeviceLogCollectionResponseId <String>]
: The unique identifier of deviceLogCollectionResponse[DeviceManagementExchangeConnectorId <String>]
: The unique identifier of deviceManagementExchangeConnector[DeviceManagementPartnerId <String>]
: The unique identifier of deviceManagementPartner[ManagedDeviceId <String>]
: The unique identifier of managedDevice[MobileAppTroubleshootingEventId <String>]
: The unique identifier of mobileAppTroubleshootingEvent[NotificationMessageTemplateId <String>]
: The unique identifier of notificationMessageTemplate[RemoteAssistancePartnerId <String>]
: The unique identifier of remoteAssistancePartner[WindowsAutopilotDeviceIdentityId <String>]
: The unique identifier of windowsAutopilotDeviceIdentity