更新 azureADWindowsAutopilotDeploymentProfile
命名空间:microsoft.graph
重要提示: Microsoft Graph /beta 版本下的 API 可能会更改;不支持生产使用。
注意: 适用于 Intune 的 Microsoft Graph API 需要适用于租户的 活动 Intune 许可证。
更新 azureADWindowsAutopilotDeploymentProfile 对象 的属性。
先决条件
要调用此 API,需要以下权限之一。要了解详细信息,包括如何选择权限的信息,请参阅权限。
| 权限类型 | 权限(从最低特权到最高特权) |
|---|---|
| 委派(工作或学校帐户) | DeviceManagementServiceConfig.ReadWrite.All |
| 委派(个人 Microsoft 帐户) | 不支持。 |
| 应用程序 | DeviceManagementServiceConfig.ReadWrite.All |
HTTP 请求
PATCH /deviceManagement/windowsAutopilotDeploymentProfiles/{windowsAutopilotDeploymentProfileId}
PATCH /deviceManagement/windowsAutopilotDeviceIdentities/{windowsAutopilotDeviceIdentityId}/deploymentProfile
PATCH /deviceManagement/windowsAutopilotDeviceIdentities/{windowsAutopilotDeviceIdentityId}/intendedDeploymentProfile
请求标头
| 标头 | 值 |
|---|---|
| Authorization | Bearer <token>。必需。 |
| 接受 | application/json |
请求正文
在请求正文中,提供 azureADWindowsAutopilotDeploymentProfile 对象的 JSON 表示形式。
下表显示创建 azureADWindowsAutopilotDeploymentProfile 时所需的属性。
| 属性 | 类型 | 说明 |
|---|---|---|
| id | String | 配置文件密钥 继承自 windowsAutopilotDeploymentProfile |
| displayName | String | 配置文件的名称 继承自 windowsAutopilotDeploymentProfile |
| 说明 | String | 配置文件的说明 继承自 windowsAutopilotDeploymentProfile |
| language | String | 在设备上配置的语言 继承自 windowsAutopilotDeploymentProfile |
| createdDateTime | DateTimeOffset | 配置文件创建时间 继承自 windowsAutopilotDeploymentProfile |
| lastModifiedDateTime | DateTimeOffset | 配置文件上次修改时间 继承自 windowsAutopilotDeploymentProfile |
| outOfBoxExperienceSettings | outOfBoxExperienceSettings | 开箱体验设置 继承自 windowsAutopilotDeploymentProfile |
| enrollmentStatusScreenSettings | windowsEnrollmentStatusScreenSettings | 注册状态屏幕设置 继承自 windowsAutopilotDeploymentProfile |
| extractHardwareHash | 布尔值 | 配置文件的 HardwareHash 提取 继承自 windowsAutopilotDeploymentProfile |
| deviceNameTemplate | String | 用于命名 AutoPilot 设备的模板。 这可以是自定义文本,还可以包含设备的序列号或随机生成的数字。 模板生成的文本的总长度不能超过 15 个字符。 继承自 windowsAutopilotDeploymentProfile |
| deviceType | windowsAutopilotDeviceType | 此配置文件适用的 AutoPilot 设备类型。 继承自 windowsAutopilotDeploymentProfile。 可取值为:windowsPc、surfaceHub2、holoLens、surfaceHub2S、virtualMachine、unknownFutureValue。 |
| enableWhiteGlove | 布尔值 | 为配置文件启用 Autopilot White Glove。 继承自 windowsAutopilotDeploymentProfile |
| roleScopeTagIds | 字符串集合 | 配置文件的范围标记。 继承自 windowsAutopilotDeploymentProfile |
| managementServiceAppId | String | 基于客户端设备的注册发现期间使用的 AzureAD 管理应用 ID 继承自 windowsAutopilotDeploymentProfile |
响应
如果成功,此方法在响应正文中返回 响应代码和更新的 200 OK azureADWindowsAutopilotDeploymentProfile 对象。
示例
请求
下面是一个请求示例。
PATCH https://graph.microsoft.com/beta/deviceManagement/windowsAutopilotDeploymentProfiles/{windowsAutopilotDeploymentProfileId}
Content-type: application/json
Content-length: 1223
{
"@odata.type": "#microsoft.graph.azureADWindowsAutopilotDeploymentProfile",
"displayName": "Display Name value",
"description": "Description value",
"language": "Language value",
"outOfBoxExperienceSettings": {
"@odata.type": "microsoft.graph.outOfBoxExperienceSettings",
"hidePrivacySettings": true,
"hideEULA": true,
"userType": "standard",
"deviceUsageType": "shared",
"skipKeyboardSelectionPage": true,
"hideEscapeLink": true
},
"enrollmentStatusScreenSettings": {
"@odata.type": "microsoft.graph.windowsEnrollmentStatusScreenSettings",
"hideInstallationProgress": true,
"allowDeviceUseBeforeProfileAndAppInstallComplete": true,
"blockDeviceSetupRetryByUser": true,
"allowLogCollectionOnInstallFailure": true,
"customErrorMessage": "Custom Error Message value",
"installProgressTimeoutInMinutes": 15,
"allowDeviceUseOnInstallFailure": true
},
"extractHardwareHash": true,
"deviceNameTemplate": "Device Name Template value",
"deviceType": "surfaceHub2",
"enableWhiteGlove": true,
"roleScopeTagIds": [
"Role Scope Tag Ids value"
],
"managementServiceAppId": "Management Service App Id value"
}
响应
下面是一个响应示例。注意:为了简单起见,可能会将此处所示的响应对象截断。将从实际调用中返回所有属性。
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 1395
{
"@odata.type": "#microsoft.graph.azureADWindowsAutopilotDeploymentProfile",
"id": "e2ec4e69-4e69-e2ec-694e-ece2694eece2",
"displayName": "Display Name value",
"description": "Description value",
"language": "Language value",
"createdDateTime": "2017-01-01T00:02:43.5775965-08:00",
"lastModifiedDateTime": "2017-01-01T00:00:35.1329464-08:00",
"outOfBoxExperienceSettings": {
"@odata.type": "microsoft.graph.outOfBoxExperienceSettings",
"hidePrivacySettings": true,
"hideEULA": true,
"userType": "standard",
"deviceUsageType": "shared",
"skipKeyboardSelectionPage": true,
"hideEscapeLink": true
},
"enrollmentStatusScreenSettings": {
"@odata.type": "microsoft.graph.windowsEnrollmentStatusScreenSettings",
"hideInstallationProgress": true,
"allowDeviceUseBeforeProfileAndAppInstallComplete": true,
"blockDeviceSetupRetryByUser": true,
"allowLogCollectionOnInstallFailure": true,
"customErrorMessage": "Custom Error Message value",
"installProgressTimeoutInMinutes": 15,
"allowDeviceUseOnInstallFailure": true
},
"extractHardwareHash": true,
"deviceNameTemplate": "Device Name Template value",
"deviceType": "surfaceHub2",
"enableWhiteGlove": true,
"roleScopeTagIds": [
"Role Scope Tag Ids value"
],
"managementServiceAppId": "Management Service App Id value"
}
反馈
提交和查看相关反馈