创建 depMacOSEnrollmentProfile
命名空间:microsoft.graph
重要: /beta 版本下的 Microsoft Graph API 可能会更改;不支持生产使用。
注意:适用于 Intune 的 Microsoft Graph API 需要适用于租户的活动 Intune 许可证。
创建新的 depMacOSEnrollmentProfile 对象。
权限
调用此 API 需要以下权限之一。 若要了解详细信息,包括如何选择权限的信息,请参阅权限。
权限类型 | 权限(从最低特权到最高特权) |
---|---|
委派(工作或学校帐户) | DeviceManagementServiceConfig.ReadWrite.All |
委派(个人 Microsoft 帐户) | 不支持。 |
应用程序 | DeviceManagementServiceConfig.ReadWrite.All |
HTTP 请求
POST /deviceManagement/depOnboardingSettings/{depOnboardingSettingId}/enrollmentProfiles
请求标头
标头 | 值 |
---|---|
授权 | Bearer <token>。必需。 |
接受 | application/json |
请求正文
在请求正文中,提供 depMacOSEnrollmentProfile 对象的 JSON 表示形式。
下表显示了创建 depMacOSEnrollmentProfile 时所需的属性。
属性 | 类型 | 说明 |
---|---|---|
id | String | 对象的 GUID 继承自 enrollmentProfile |
displayName | String | 从 enrollmentProfile 继承的配置文件的名称 |
说明 | String | 配置文件的说明继承自 enrollmentProfile |
requiresUserAuthentication | Boolean | 指示配置文件是否需要从 enrollmentProfile 继承的用户身份验证 |
configurationEndpointUrl | String | 用于注册继承自 enrollmentProfile 的配置终结点 URL |
enableAuthenticationViaCompanyPortal | Boolean | 指示使用 Apple 设置助理而不是公司门户进行身份验证。 继承自 enrollmentProfile |
requireCompanyPortalOnSetupAssistantEnrolledDevices | Boolean | 指示在从 enrollmentProfile 继承的设置助理注册设备上需要公司门户 |
isDefault | Boolean | 指示此配置文件是否是继承自 depEnrollmentBaseProfile 的默认配置文件 |
supervisedModeEnabled | Boolean | 监督模式,如果为 True,则为启用,否则为 false。 有关详细信息,请参阅 https://learn.microsoft.com/intune/deploy-use/enroll-devices-in-microsoft-intune 。 继承自 depEnrollmentBaseProfile |
supportDepartment | String | 从 depEnrollmentBaseProfile 继承的支持部门信息 |
isMandatory | Boolean | 指示配置文件是否是必需的 继承自 depEnrollmentBaseProfile |
locationDisabled | Boolean | 指示是否禁用“位置服务设置”窗格,“继承自 depEnrollmentBaseProfile” |
supportPhoneNumber | String | 支持电话号码继承自 depEnrollmentBaseProfile |
profileRemovalDisabled | Boolean | 指示配置文件删除选项是否禁用“继承自 depEnrollmentBaseProfile” |
restoreBlocked | Boolean | 指示是否阻止“还原设置”窗格继承自 depEnrollmentBaseProfile |
appleIdDisabled | Boolean | 指示是否禁用 Apple ID 设置窗格继承自 depEnrollmentBaseProfile |
termsAndConditionsDisabled | Boolean | 指示是否禁用“条款和条件”设置窗格继承自 depEnrollmentBaseProfile |
touchIdDisabled | Boolean | 指示触摸 ID 设置窗格是否已禁用,继承自 depEnrollmentBaseProfile |
applePayDisabled | Boolean | 指示是否禁用 Apple 付费设置窗格继承自 depEnrollmentBaseProfile |
siriDisabled | Boolean | 指示是否禁用 siri 设置窗格继承自 depEnrollmentBaseProfile |
diagnosticsDisabled | Boolean | 指示是否禁用诊断安装窗格继承自 depEnrollmentBaseProfile |
displayToneSetupDisabled | Boolean | 指示是否禁用了“显示色调设置”屏幕,“继承自 depEnrollmentBaseProfile” |
privacyPaneDisabled | Boolean | 指示是否禁用隐私屏幕 继承自 depEnrollmentBaseProfile |
screenTimeScreenDisabled | Boolean | 指示是否禁用屏幕超时设置继承自 depEnrollmentBaseProfile |
deviceNameTemplate | String | 设置文本或名称模式。 继承自 depEnrollmentBaseProfile |
configurationWebUrl | Boolean | 安装程序助理登录名的 URL 继承自 depEnrollmentBaseProfile |
enabledSkipKeys | 字符串集合 | enabledSkipKeys 包含所有启用的跳过键作为字符串继承自 depEnrollmentBaseProfile |
registrationDisabled | Boolean | 指示是否禁用注册 |
fileVaultDisabled | Boolean | 指示是否禁用文件保管库 |
iCloudDiagnosticsDisabled | Boolean | 指示 iCloud Analytics 屏幕是否已禁用 |
passCodeDisabled | Boolean | 指示是否禁用密码设置窗格 |
zoomDisabled | Boolean | 指示缩放设置窗格是否已禁用 |
iCloudStorageDisabled | Boolean | 指示是否禁用 iCloud 文档和桌面屏幕 |
chooseYourLockScreenDisabled | Boolean | 指示是否禁用 iCloud 文档和桌面屏幕 |
accessibilityScreenDisabled | Boolean | 指示是否禁用辅助功能屏幕 |
autoUnlockWithWatchDisabled | Boolean | 指示是否禁用 UnlockWithWatch 屏幕 |
skipPrimarySetupAccountCreation | Boolean | 指示设置助理是否会跳过主帐户设置的用户界面 |
setPrimarySetupAccountAsRegularUser | Boolean | 指示设置助理是否将帐户设置为普通用户 |
dontAutoPopulatePrimaryAccountInfo | Boolean | 指示设置助理是否会自动填充主帐户信息 |
primaryAccountFullName | String | 指示主帐户的全名 |
primaryAccountUserName | String | 指示主帐户的帐户名称 |
enableRestrictEditing | Boolean | 指示用户是否将启用阻止编辑 |
adminAccountUserName | String | 指示管理员帐户的用户名 |
adminAccountFullName | String | 指示管理员帐户的全名 |
adminAccountPassword | String | 指示管理员帐户的密码 |
hideAdminAccount | Boolean | 指示是否应隐藏管理员帐户 |
响应
如果成功,此方法在 201 Created
响应正文中返回响应代码和 depMacOSEnrollmentProfile 对象。
示例
请求
下面是一个请求示例。
POST https://graph.microsoft.com/beta/deviceManagement/depOnboardingSettings/{depOnboardingSettingId}/enrollmentProfiles
Content-type: application/json
Content-length: 1910
{
"@odata.type": "#microsoft.graph.depMacOSEnrollmentProfile",
"displayName": "Display Name value",
"description": "Description value",
"requiresUserAuthentication": true,
"configurationEndpointUrl": "https://example.com/configurationEndpointUrl/",
"enableAuthenticationViaCompanyPortal": true,
"requireCompanyPortalOnSetupAssistantEnrolledDevices": true,
"isDefault": true,
"supervisedModeEnabled": true,
"supportDepartment": "Support Department value",
"isMandatory": true,
"locationDisabled": true,
"supportPhoneNumber": "Support Phone Number value",
"profileRemovalDisabled": true,
"restoreBlocked": true,
"appleIdDisabled": true,
"termsAndConditionsDisabled": true,
"touchIdDisabled": true,
"applePayDisabled": true,
"siriDisabled": true,
"diagnosticsDisabled": true,
"displayToneSetupDisabled": true,
"privacyPaneDisabled": true,
"screenTimeScreenDisabled": true,
"deviceNameTemplate": "Device Name Template value",
"configurationWebUrl": true,
"enabledSkipKeys": [
"Enabled Skip Keys value"
],
"registrationDisabled": true,
"fileVaultDisabled": true,
"iCloudDiagnosticsDisabled": true,
"passCodeDisabled": true,
"zoomDisabled": true,
"iCloudStorageDisabled": true,
"chooseYourLockScreenDisabled": true,
"accessibilityScreenDisabled": true,
"autoUnlockWithWatchDisabled": true,
"skipPrimarySetupAccountCreation": true,
"setPrimarySetupAccountAsRegularUser": true,
"dontAutoPopulatePrimaryAccountInfo": true,
"primaryAccountFullName": "Primary Account Full Name value",
"primaryAccountUserName": "Primary Account User Name value",
"enableRestrictEditing": true,
"adminAccountUserName": "Admin Account User Name value",
"adminAccountFullName": "Admin Account Full Name value",
"adminAccountPassword": "Admin Account Password value",
"hideAdminAccount": true
}
响应
下面是一个响应示例。 注意:为简洁起见,可能会截断此处显示的响应对象。 将从实际调用中返回所有属性。
HTTP/1.1 201 Created
Content-Type: application/json
Content-Length: 1959
{
"@odata.type": "#microsoft.graph.depMacOSEnrollmentProfile",
"id": "e433c95c-c95c-e433-5cc9-33e45cc933e4",
"displayName": "Display Name value",
"description": "Description value",
"requiresUserAuthentication": true,
"configurationEndpointUrl": "https://example.com/configurationEndpointUrl/",
"enableAuthenticationViaCompanyPortal": true,
"requireCompanyPortalOnSetupAssistantEnrolledDevices": true,
"isDefault": true,
"supervisedModeEnabled": true,
"supportDepartment": "Support Department value",
"isMandatory": true,
"locationDisabled": true,
"supportPhoneNumber": "Support Phone Number value",
"profileRemovalDisabled": true,
"restoreBlocked": true,
"appleIdDisabled": true,
"termsAndConditionsDisabled": true,
"touchIdDisabled": true,
"applePayDisabled": true,
"siriDisabled": true,
"diagnosticsDisabled": true,
"displayToneSetupDisabled": true,
"privacyPaneDisabled": true,
"screenTimeScreenDisabled": true,
"deviceNameTemplate": "Device Name Template value",
"configurationWebUrl": true,
"enabledSkipKeys": [
"Enabled Skip Keys value"
],
"registrationDisabled": true,
"fileVaultDisabled": true,
"iCloudDiagnosticsDisabled": true,
"passCodeDisabled": true,
"zoomDisabled": true,
"iCloudStorageDisabled": true,
"chooseYourLockScreenDisabled": true,
"accessibilityScreenDisabled": true,
"autoUnlockWithWatchDisabled": true,
"skipPrimarySetupAccountCreation": true,
"setPrimarySetupAccountAsRegularUser": true,
"dontAutoPopulatePrimaryAccountInfo": true,
"primaryAccountFullName": "Primary Account Full Name value",
"primaryAccountUserName": "Primary Account User Name value",
"enableRestrictEditing": true,
"adminAccountUserName": "Admin Account User Name value",
"adminAccountFullName": "Admin Account Full Name value",
"adminAccountPassword": "Admin Account Password value",
"hideAdminAccount": true
}