EnterpriseModernAppManagement 云解决方案提供商EnterpriseModernAppManagement CSP

EnterpriseModernAppManagement 配置服务提供程序 (CSP) 用于预配和报告新式企业应用。The EnterpriseModernAppManagement configuration service provider (CSP) is used for the provisioning and reporting of modern enterprise apps. 有关如何使用此 CSP 报告应用清单、用户的应用的安装和删除、将应用预配到设备和管理应用许可证的详细信息,请参阅企业 应用管理For details about how to use this CSP to for reporting apps inventory, installation and removal of apps for users, provisioning apps to devices, and managing app licenses, see Enterprise app management.

备注

Windows 全息版仅支持 EnterpriseModernAppManagement CSP 的按用户配置。Windows Holographic only supports per-user configuration of the EnterpriseModernAppManagement CSP.

下面以树格式显示 EnterpriseModernAppManagement 配置服务提供程序。The following shows the EnterpriseModernAppManagement configuration service provider in tree format.

./Vendor/MSFT
EnterpriseModernAppManagement
----AppManagement
--------EnterpriseID
------------PackageFamilyName
----------------PackageFullName
--------------------Name
--------------------Version
--------------------Publisher
--------------------Architecture
--------------------InstallLocation
--------------------IsFramework
--------------------IsBundle
--------------------InstallDate
--------------------ResourceID
--------------------PackageStatus
--------------------RequiresReinstall
--------------------Users
--------------------IsProvisioned
----------------DoNotUpdate
----------------AppSettingPolicy
--------------------SettingValue
--------UpdateScan
--------LastScanError
--------AppInventoryResults
--------AppInventoryQuery
----AppInstallation
--------PackageFamilyName
------------StoreInstall
------------HostedInstall
------------LastError
------------LastErrorDesc
------------Status
------------ProgressStatus
----AppLicenses
--------StoreLicenses
------------LicenseID
----------------LicenseCategory
----------------LicenseUsage
----------------RequesterID
----------------AddLicense
----------------GetLicenseFromStore

设备或用户上下文Device or User context
对于用户上下文,请使用 ./User/Vendor/MSFT 路径,对于设备上下文,请使用 ./Device/Vendor/MSFT 路径。For user context, use ./User/Vendor/MSFT path and for device context, use ./Device/Vendor/MSFT path.

备注

Windows 全息版和 Windows 10 移动版仅支持 EnterpriseModernAppManagement CSP 的每个用户配置。Windows Holographic and Windows 10 Mobile only support per-user configuration of the EnterpriseModernAppManagement CSP.

AppManagementAppManagement
必需。Required. 用于清单和管理应用 (安装后) 。Used for inventory and app management (post-install).

AppManagement/UpdateScanAppManagement/UpdateScan
必需。Required. 用于启动 Windows 更新扫描。Used to start the Windows Update scan.

支持的操作是 Execute。Supported operation is Execute.

AppManagement/LastScanErrorAppManagement/LastScanError
必需。Required. 报告更新扫描返回的最后一个错误代码。Reports the last error code returned by the update scan.

支持的操作为 Get。Supported operation is Get.

AppManagement/AppInventoryResultsAppManagement/AppInventoryResults
在 Windows 10 版本 1511 中添加。Added in Windows 10, version 1511. 必需。Required. 返回 AppInventoryQuery 操作之后创建的应用清单的结果。Returns the results for app inventory that was created after the AppInventoryQuery operation.

支持的操作为 Get。Supported operation is Get.

下面是 AppInventoryResults 操作的示例。Here's an example of AppInventoryResults operation.

<Get>
   <CmdID>11</CmdID>
   <Item>
      <Target>
         <LocURI>./User/Vendor/MSFT/EnterpriseModernAppManagement/AppManagement/AppInventoryResults</LocURI>
      </Target>
   </Item>
</Get>

AppManagement/AppInventoryQueryAppManagement/AppInventoryQuery
在 Windows 10 版本 1511 中添加。Added in Windows 10, version 1511. 必需。Required. 指定应用清单的查询。Specifies the query for app inventory.

查询参数:Query parameters:

  • Output - 指定 AppInventoryResults 操作中返回的信息的参数。Output - Specifies the parameters for the information returned in AppInventoryResults operation. 多个值必须由多个值|。Multiple value must be separate by |. 有效值包括:Valid values are:

    • PackagesName - 返回应用的 PackageFamilyNamePackageFullName。PackagesName - returns the PackageFamilyName and PackageFullName of the app. 如果未指定任何对象,则默认为默认值。Default if nothing is specified.
    • PackageDetails - 返回包的所有清单属性。PackageDetails - returns all inventory attributes of the package. 这包括 PackageNames 参数中所有的信息,但不验证 RequiresReinstall。This includes all information from PackageNames parameter, but does not validate RequiresReinstall.
    • RequiredReinstall - 验证清单查询中应用的应用状态,以确定是否需要重新安装。RequiredReinstall - Validates the app status of the apps in the inventory query to determine if they require a reinstallation. 此属性可能会影响系统性能,具体取决于安装的应用数量。This attribute may impact system performance depending on the number of apps installed. 当资源包更新或应用位于篡改状态时,需要重新安装。Requiring reinstall occurs when resource package updates or when the app is in a tampered state.
  • Source - 指定与现有清单节点对齐的应用分类。Source - specifies the app classification that aligns to the existing inventory nodes. 您可以使用特定筛选器,或者如果未指定筛选器,则返回所有源。You can use a specific filter or if no filter is specified then all sources will be returned. 如果未指定任何值,则返回所有分类。If no value is specified, all classifications are returned. 有效值包括:Valid values are:

    • AppStore - 此分类适用于从 Microsoft Store 获取的应用。AppStore - This classification is for apps that were acquired from Microsoft Store. 这些是直接从 Microsoft Store 安装的应用或来自适用于企业的 Microsoft Store 的企业应用。These were apps directly installed from Microsoft Store or enterprise apps from Microsoft Store for Business.
    • nonStore - 此分类适用于未从 Microsoft Store 获取的应用。nonStore - This classification is for apps that were not acquired from the Microsoft Store.
    • 系统 - 操作系统中的应用。System - Apps that are part of the OS. 无法卸载这些应用。You cannot uninstall these apps. 此分类是只读的,只能进行清点。This classification is read-only and can only be inventoried.
  • PackageTypeFilter - 指定可用于查询用户或设备的一个或多个类型的包。PackageTypeFilter - Specifies one or multiple types of packages you can use to query the user or device. 多个值必须由多个值|。Multiple values must be separated by |. 有效值包括:Valid values are:

    • Main - 返回已安装的主程序包。Main - returns the main installed package.
    • Bundle - 返回已安装的捆绑包。Bundle - returns installed bundle packages.
    • Framework - 返回已安装的框架包。Framework - returns installed framework packages.
    • Resource - 返回已安装的资源包。Resource - returns installed resources packages. 资源可以是语言、比例或 DirectX 资源。Resources are either language, scale, or DirectX resources. 它们是捆绑包的一部分。They are parts of a bundle.
    • XAP - 返回 XAP 包类型。XAP - returns XAP package types. 除 Windows Mobile 外,此筛选器在设备上不受支持。This filter is not supported on devices other than Windows Mobile.
    • All - 返回所有包类型。All - returns all package types.

    如果未指定任何值,则返回 Main、Bundle 和 Framework 的组合。If no value is specified, the combination of Main, Bundle, and Framework are returned.

  • PackageFamilyName - 指定特定包的名称。PackageFamilyName - specifies the name of a particular package. 如果指定此参数,如果程序包包含此值,它将返回程序包系列名称。If you specify this parameter, it returns the Package Family name if the package contains this value.

    如果不指定此值,则返回所有程序包。If you do not specify this value, then all packages are returned.

  • Publisher - 指定特定程序包的发布者。Publisher - specifies the publisher of a particular package. 如果指定此参数,如果 Publisher 字段中存在值,则返回发布者。If you specify this parameter, it returns the publisher if the value exists in the Publisher field.

    如果不指定此值,则返回所有发布者。If you do not specify this value, then all publishers are returned.

支持的操作是 Get 和 Replace。Supported operation is Get and Replace.

以下示例设置程序包名称的清单查询,并检查非Store应用的所有主程序包的重新安装状态。The following example sets the inventory query for the package names and checks the status for reinstallation for all main packages that are nonStore apps.

<Replace>
   <CmdID>10</CmdID>
   <Item>
      <Target>
         <LocURI>./User/Vendor/MSFT/EnterpriseModernAppManagement/AppManagement/AppInventoryQuery</LocURI>
      </Target>
      <Meta><Format xmlns="syncml:metinf">xml</Format></Meta>
      <Data><Inventory Output="PackageNames|RequiresReinstall" Source="nonStore" PackageTypeFilter="Main" /></Data>
   </Item>
</Replace>

AppManagement/RemovePackageAppManagement/RemovePackage
已添加到 Windows 10 版本 1703。Added in Windows 10, version 1703. 用于删除程序包。Used to remove packages. 不支持 ./User/Vendor/MSFT。Not supported for ./User/Vendor/MSFT.

参数:Parameters:

  • Package
    • 名称:指定要删除的特定包的 PackageFullName。Name: Specifies the PackageFullName of the particular package to remove.
    • RemoveForAllUsers:RemoveForAllUsers:
      • 0 (默认) – 未预配程序包,以便新用户不会收到程序包。0 (default) – Package will be un-provisioned so that new users do not receive the package. 程序包仍将为当前用户安装。The package will remain installed for current users. 当前不支持此功能。This is not currently supported.
      • 1 – 只有当程序包是预配包时,才将删除所有用户的程序包。1 – Package will be removed for all users only if it is a provisioned package.
  • User (可选) :指定要删除程序包的特定用户的 SID;只能删除指定用户的程序包。User (optional): Specifies the SID of the particular user for whom to remove the package; only the package for the specified user can be removed.

支持的操作是 Execute。Supported operation is Execute.

以下示例删除所有用户的程序包:The following example removes a package for all users:

<Exec>
   <CmdID>10</CmdID>
   <Item>
      <Target>
         <LocURI>./Device/Vendor/MSFT/EnterpriseModernAppManagement/AppManagement/RemovePackage</LocURI>
      </Target>
      <Meta><Format xmlns="syncml:metinf">xml</Format></Meta>
      <Data>
          <Package Name="{PackageFullName}" RemoveForAllUsers=1 />
      </Data>
   </Item>
</Exec>

AppManagement/nonStoreAppManagement/nonStore
用于管理未从 Microsoft Store 获取的企业应用或开发人员应用。Used to manage enterprise apps or developer apps that were not acquired from the Microsoft Store.

支持的操作为 Get。Supported operation is Get.

AppManagement/SystemAppManagement/System
报告作为操作系统的一部分安装的应用。Reports apps installed as part of the operating system.

支持的操作为 Get。Supported operation is Get.

AppManagement/AppStoreAppManagement/AppStore
必需。Required. 用于管理 Microsoft Store 中的应用。Used for managing apps from the Microsoft Store.

支持的操作包括 Get 和 Delete。Supported operations are Get and Delete.

AppManagement/AppStore/ReleaseManagementAppManagement/AppStore/ReleaseManagement
在 Windows 10 版本 1809 中添加。Added in Windows 10, version 1809. 用于通过 Microsoft Store 管理更新的内部节点。Interior node for the managing updates through the Microsoft Store. 这些设置允许 IT 管理员为希望用户用于接收更新的应用指定更新通道。These settings allow the IT admin to specify update channels for apps that they want their users to use for receiving updates. 它允许 IT 管理员在大型部署之前将特定版本分配给较小的组进行测试,然后再将其分配给组织的其余部分。It allows the IT admin to assign a specific release to a smaller group for testing before the large deployment to the rest of the organization.

备注

ReleaseManagement 设置仅适用于通过 Microsoft Store 的更新。ReleaseManagement settings only apply to updates through the Microsoft Store.

AppManagement/AppStore/ReleaseManagement/ReleaseManagementKeyAppManagement/AppStore/ReleaseManagement/ReleaseManagementKey
在 Windows 10 版本 1809 中添加。Added in Windows 10, version 1809. 应用或应用集的标识符。Identifier for the app or set of apps. 如果只有一个应用,则它是 PackageFamilyName。If there is only one app, it is the PackageFamilyName. 如果用于一组应用,则它是主应用的 PackageFamilyName。If it is for a set of apps, it is the PackageFamilyName of the main app.

AppManagement/AppStore/ReleaseManagement/ReleaseManagementKey/ChannelIdAppManagement/AppStore/ReleaseManagement/ReleaseManagementKey/ChannelId
在 Windows 10 版本 1809 中添加。Added in Windows 10, version 1809. 指定应用通道 ID。Specifies the app channel ID.

值类型为字符串。Value type is string. 支持的操作包括添加、获取、替换和删除。Supported operations are Add, Get, Replace, and Delete.

AppManagement/AppStore/ReleaseManagement/ReleaseManagementKey/ReleaseManagementIdAppManagement/AppStore/ReleaseManagement/ReleaseManagementKey/ReleaseManagementId
在 Windows 10 版本 1809 中添加。Added in Windows 10, version 1809. IT 管理员可以指定版本 ID,以指示他们希望用户或设备打开的特定版本。The IT admin can specify a release ID to indicate a specific release that they would like the user or device to be on.

值类型为字符串。Value type is string. 支持的操作包括添加、获取、替换和删除。Supported operations are Add, Get, Replace, and Delete.

AppManagement/AppStore/ReleaseManagement/ReleaseManagementKey/EffectiveReleaseAppManagement/AppStore/ReleaseManagement/ReleaseManagementKey/EffectiveRelease
在 Windows 10 版本 1809 中添加。Added in Windows 10, version 1809. 内部节点,用于在设备上设置多个用户策略时指定使用的有效应用版本。Interior node used to specify the effective app release to use when multiple user policies are set on the device. 使用设备策略或最后一个用户策略。The device policy or last user policy is used.

AppManagement/AppStore/ReleaseManagement/ReleaseManagementKey/EffectiveRelease/ChannelIdAppManagement/AppStore/ReleaseManagement/ReleaseManagementKey/EffectiveRelease/ChannelId
在 Windows 10 版本 1809 中添加。Added in Windows 10, version 1809. 返回设备上最后一个用户通道 ID。Returns the last user channel ID on the device.

值类型为字符串。Value type is string. 支持的操作为 Get。Supported operation is Get.

AppManagement/AppStore/ReleaseManagement/ReleaseManagementKey/EffectiveRelease/ReleaseManagementIdAppManagement/AppStore/ReleaseManagement/ReleaseManagementKey/EffectiveRelease/ReleaseManagementId
在 Windows 10 版本 1809 中添加。Added in Windows 10, version 1809. 返回设备上最后一个用户版本 ID。Returns the last user release ID on the device.

值类型为字符串。Value type is string. 支持的操作为 Get。Supported operation is Get.

.../PackageFamilyName.../PackageFamilyName
可选。Optional. 程序包系列 (PFN) 应用的一部分。Package family name (PFN) of the app. 报告清单时,设备上每个 PFN 都有一个。There is one for each PFN on the device when reporting inventory. 这些项目的签名来源下有根。These items are rooted under their signing origin.

支持的操作包括 Get 和 Delete。Supported operations are Get and Delete.

备注

XAP 文件使用产品 ID 来表示 PackageFamilyName。XAP files use a product ID in place of PackageFamilyName. 下面是 XAP 产品 ID 示例, (大括号 {12345678-9012-3456-7890-123456789012}) 。Here's an example of XAP product ID (including the braces), {12345678-9012-3456-7890-123456789012}.

下面是卸载应用的示例:Here's an example for uninstalling an app:

<SyncML xmlns="SYNCML:SYNCML1.2">
  <SyncBody>
        <!-- Uninstall app -->
        <delete>
           <CmdID>2</CmdID>
              <Item>
                 <Target>
                    <LocURI>./User/Vendor/MSFT/EnterpriseModernAppManagement/AppManagement/AppStore/%7b12345678-9012-3456-7890-123456789012%7D</LocURI>
                 </Target>
              </Item>
        </delete>
     <Final/>
  </SyncBody>
</SyncML>

.../*PackageFamilyName* / ** *PackageFullName*.../PackageFamilyName/**PackageFullName
可选。Optional. 安装的程序包的全名。Full name of the package installed.

支持的操作包括 Get 和 Delete。Supported operations are Get and Delete.

备注

XAP 文件使用产品 ID 来表示 PackageFullName。XAP files use a product ID in place of PackageFullName. 下面是 XAP 产品 ID 示例, (大括号 {12345678-9012-3456-7890-123456789012}) 。Here's an example of XAP product ID (including the braces), {12345678-9012-3456-7890-123456789012}.

.../PackageFamilyName / PackageFullName/Name.../PackageFamilyName/PackageFullName/Name
必需。Required. 应用的名称。Name of the app. 值类型为字符串。Value type is string.

支持的操作为 Get。Supported operation is Get.

.../PackageFamilyName / PackageFullName/Version.../PackageFamilyName/PackageFullName/Version
必需。Required. 应用的版本。Version of the app. 值类型为字符串。Value type is string.

支持的操作为 Get。Supported operation is Get.

.../PackageFamilyName / PackageFullName/Publisher.../PackageFamilyName/PackageFullName/Publisher
必需。Required. 应用的发布者名称。Publisher name of the app. 值类型为字符串。Value type is string.

支持的操作为 Get。Supported operation is Get.

.../PackageFamilyName / PackageFullName/Architecture.../PackageFamilyName/PackageFullName/Architecture
必需。Required. 已安装程序包的体系结构。Architecture of installed package. 值类型为字符串。Value type is string.

备注

不适用于 XAP 文件。Not applicable to XAP files.

支持的操作为 Get。Supported operation is Get.

.../PackageFamilyName / PackageFullName/InstallLocation.../PackageFamilyName/PackageFullName/InstallLocation
必需。Required. 在设备上安装应用的位置。Install location of the app on the device. 值类型为字符串。Value type is string.

备注

不适用于 XAP 文件。Not applicable to XAP files.

支持的操作为 Get。Supported operation is Get.

.../PackageFamilyName / PackageFullName/IsFramework.../PackageFamilyName/PackageFullName/IsFramework
必需。Required. 应用是否是框架包。Whether or not the app is a framework package. 值类型为 int。如果应用是框架包,则值为 1,对于所有其他情况, (0) 为零。Value type is int. The value is 1 if the app is a framework package and 0 (zero) for all other cases.

备注

不适用于 XAP 文件。Not applicable to XAP files.

支持的操作为 Get。Supported operation is Get.

.../PackageFamilyName / PackageFullName/IsBundle.../PackageFamilyName/PackageFullName/IsBundle
必需。Required. 如果程序包是应用程序包,则值为 1,对于所有其他情况 (0) 为零。The value is 1 if the package is an app bundle and 0 (zero) for all other cases. 值类型为 int。Value type is int.

支持的操作为 Get。Supported operation is Get.

.../PackageFamilyName / PackageFullName/InstallDate.../PackageFamilyName/PackageFullName/InstallDate
必需。Required. 应用安装日期。Date the app was installed. 值类型为字符串。Value type is string.

支持的操作为 Get。Supported operation is Get.

.../PackageFamilyName / PackageFullName/ResourceID.../PackageFamilyName/PackageFullName/ResourceID
必需。Required. 应用的资源 ID。Resource ID of the app. 对于主应用为 null,~ 表示捆绑包,并且包含资源包的资源信息。This is null for the main app, ~ for a bundle, and contains resource information for resources packages. 值类型为字符串。Value type is string.

备注

不适用于 XAP 文件。Not applicable to XAP files.

支持的操作为 Get。Supported operation is Get.

.../PackageFamilyName / PackageFullName/PackageStatus.../PackageFamilyName/PackageFullName/PackageStatus
必需。Required. 提供有关程序包状态的信息。Provides information about the status of the package. 值类型为 int。有效值为:Value type is int. Valid values are:

  • 确定 (0) - 程序包可用。OK (0) - The package is usable.
  • LicenseIssue (1) - 程序包的许可证无效。LicenseIssue (1) - The license of the package is not valid.
  • 修改 (2) - 包有效负载由未知源修改。Modified (2) - The package payload was modified by an unknown source.
  • 篡改 (4) - 程序包有效负载被有意篡改。Tampered (4) - The package payload was tampered intentionally.
  • 禁用 (8) - 程序包不可用。Disabled (8) - The package is not available for use. 它仍可提供服务。It can still be serviced.

备注

不适用于 XAP 文件。Not applicable to XAP files.

支持的操作为 Get。Supported operation is Get.

.../PackageFamilyName / PackageFullName/RequiresReinstall.../PackageFamilyName/PackageFullName/RequiresReinstall
必需。Required. 指定程序包状态是否已更改,并要求重新安装应用。Specifies whether the package state has changed and requires a reinstallation of the app. 当需要新的应用资源时(例如设备的语言首选项或新 DPI 发生变化时)可能会发生这种情况。This can occur when new app resources are required, such as when a device has a change in language preference or a new DPI. 它还可能发生程序包已损坏的情况。It can also occur of the package was corrupted. 如果值为 1,则重新安装应用。If the value is 1, reinstallation of the app is performed. 值类型为 int。Value type is int.

备注

不适用于 XAP 文件。Not applicable to XAP files.

支持的操作为 Get。Supported operation is Get.

.../PackageFamilyName / PackageFullName/Users.../PackageFamilyName/PackageFullName/Users
必需。Required. 应用的注册用户和程序包安装状态。Registered users of the app and the package install state. 如果查询在设备级别,它将返回设备的所有注册用户。If the query is at the device level, it returns all the registered users of the device. 如果查询用户上下文,它将仅返回当前用户。If you query the user context, it will only return the current user. 值类型为字符串。Value type is string.

  • 未安装 = 0Not Installed = 0
  • Staged = 1Staged = 1
  • Installed = 2Installed = 2
  • Paused = 6Paused = 6

支持的操作为 Get。Supported operation is Get.

.../PackageFamilyName / PackageFullName/IsProvisioned.../PackageFamilyName/PackageFullName/IsProvisioned
必需。Required. 值为 0 或 1,指示是否在设备上预配应用。The value is 0 or 1 that indicates if the app is provisioned on the device. 值类型为 int。The value type is int.

支持的操作为 Get。Supported operation is Get.

.../PackageFamilyName / PackageFullName/IsStub.../PackageFamilyName/PackageFullName/IsStub
在 Windows 10 版本 2004 中添加。Added in Windows 10, version 2004. 必需。Required. 此节点用于标识程序包是否是存根包。This node is used to identify whether the package is a stub package. 存根包是具有最少功能的程序包版本,可以减少应用的大小。A stub package is a version of the package with minimal functionality that will reduce the size of the app.

如果包是存根包,则值为 1,对于所有其他情况, (0) 为零。The value is 1 if the package is a stub package and 0 (zero) for all other cases. 值类型为 int。Value type is int.

支持的操作为 Get。Supported operation is Get.

.../PackageFamilyName/DoNotUpdate.../PackageFamilyName/DoNotUpdate
必需。Required. 指定是否要阻止通过自动更新更新特定应用。Specifies whether you want to block a specific app from being updated via auto-updates.

支持的操作包括添加、获取、删除和替换。Supported operations are Add, Get, Delete, and Replace.

.../PackageFamilyName/AppSettingPolicy (仅适用于 ./User/Vendor/MSFT) .../PackageFamilyName/AppSettingPolicy (only for ./User/Vendor/MSFT)
在 Windows 10 版本 1511 中添加。Added in Windows 10, version 1511. 所有托管应用设置值的内部节点。Interior node for all managed app setting values. 此节点仅在用户上下文中受支持。This node is only supported in the user context.

.../PackageFamilyName/AppSettingPolicy/ SettingValue ( 仅适用于 ./User/Vendor/MSFT) .../PackageFamilyName/AppSettingPolicy/SettingValue (only for ./User/Vendor/MSFT)
在 Windows 10 版本 1511 中添加。Added in Windows 10, version 1511. SettingValue和数据表示要为应用配置的键值对。The SettingValue and data represent a key value pair to be configured for the app. 节点表示键的名称,数据表示值。The node represents the name of the key and the data represents the value. 可以在 Managed.App.Settings 容器的 LocalSettings 中查找此值。You can find this value in LocalSettings in the Managed.App.Settings container.

此设置仅适用于支持该功能的应用,并且仅在用户上下文中受支持。This setting only works for apps that support the feature and it is only supported in the user context.

值类型为字符串。Value type is string. 支持的操作包括添加、获取、替换和删除。Supported operations are Add, Get, Replace, and Delete.

以下示例设置"Server"的值The following example sets the value for the 'Server'

<!— Configure app settings -->
<Add>
   <CmdID>0</CmdID>
   <Item>
      <Target>
         <LocURI>./User/Vendor/MSFT/EnterpriseModernAppManagement/AppManagement/AppStore/PackageFamilyName/AppSettingPolicy/Server</LocURI>
      </Target>
      <Meta>
         <Format xmlns="syncml:metinf">chr</Format>
      </Meta>
      <Data>server1.contoso.com</Data>
   </Item>
</Add>

以下示例获取特定应用的所有托管应用设置。The following example gets all managed app settings for a specific app.

<!—Get app settings -->
<Get>
   <CmdID>0</CmdID>
   <Item>
      <Target>
         <LocURI>./User/Vendor/MSFT/EnterpriseModernAppManagement/AppManagement/AppStore/PackageFamilyName/AppSettingPolicy?list=StructData</LocURI>
      </Target>
   </Item>
</Get>

.../PackageFamilyName/MaintainProcessorArchitectureOnUpdate.../PackageFamilyName/MaintainProcessorArchitectureOnUpdate
已添加到 Windows 10 版本 1803。Added in Windows 10, version 1803. 指定在 AMD64 设备上,在应用更新中是否不得更改已安装应用的体系结构。Specify whether on a AMD64 device, across an app update, the architecture of the installed app must not change. 例如,如果你安装了 x86 风格 Windows 应用,并且在整个更新中启用了此设置,则即使 x64 风格可用,也会安装 x86 风格。For example if you have the x86 flavor of a Windows app installed, with this setting enabled, across an update, the x86 flavor will be installed even when x64 flavor is available.

支持的操作包括添加、获取、删除和替换。Supported operations are Add, Get, Delete, and Replace. 值类型为整数。Value type is integer.

在安装了 x86 风格应用的 AMD64 计算机上,预期行为 (限制性) 。Expected Behavior on an AMD64 machine that has x86 flavor of an app installed (Most restrictive wins).

适用性设置Applicability Setting 云解决方案提供商状态CSP state 结果Result
TrueTrue 未配置Not configured 已选取 X86 风格X86 flavor is picked
TrueTrue 启用Enabled 已选取 X86 风格X86 flavor is picked
TrueTrue 禁用Disabled 已选取 X86 风格X86 flavor is picked
如果 (False,) False (not set) 未配置Not configured 已选取 X64 风格X64 flavor is picked

.../PackageFamilyName/NonRemovable.../PackageFamilyName/NonRemovable
在 Windows 10 版本 1809 中添加。Added in Windows 10, version 1809. 指定用户是否不可移动应用。Specifies if an app is nonremovable by the user.

此设置允许 IT 管理员将应用设置为不可移动或无法被用户卸载。This setting allows the IT admin to set an app to be nonremovable, or unable to be uninstalled by a user. 这适用于企业和教育方案,其中 IT 管理员可能希望确保每个人都始终具有某些应用,并且不会意外删除它们。This is useful in enterprise and education scenarios, where the IT admin might want to ensure that everyone always has certain apps and they won't be removed accidentally. 当每个设备有多个用户,并且你想要确保一个用户不会为所有用户删除它时,这一点也很有用。This is also useful when there are multiple users per device, and you want to ensure that one user doesn’t remove it for all users.

NonRemovable 需要管理员权限。NonRemovable requires admin permission. 这只能按设备进行设置,不能按用户进行设置。This can only be set per device, not per user. 可以使用 AppInventoryQuery 或 AppInventoryResults 查询设置。You can query the setting using AppInventoryQuery or AppInventoryResults.

值类型为整数。Value type is integer. 支持的操作包括添加、获取和替换。Supported operations are Add, Get, and Replace.

有效值:Valid values:

  • 0 – 应用不在不可移动的应用策略列表中0 – app is not in the nonremovable app policy list
  • 1 – 应用包含在不可移动的应用策略列表中1 – app is included in the nonremovable app policy list

示例:Examples:

将应用添加到不可移动的应用策略列表Add an app to the nonremovable app policy list

<SyncML xmlns="SYNCML:SYNCML1.2">  
    <SyncBody> 
        <Add> 
            <CmdID>1</CmdID> 
            <Item> 
                <Target> 
                    <LocURI>./Device/Vendor/MSFT/EnterpriseModernAppManagement/AppManagement/AppStore/PackageFamilyName/NonRemovable</LocURI> 
                </Target> 
                <Meta> 
                    <Format xmlns="syncml:metinf">int</Format> 
                </Meta> 
                <Data>1</Data> 
            </Item> 
        </Add> 
        <Final/> 
      </SyncBody> 
</SyncML> 

获取特定应用的状态Get the status for a particular app

<SyncML xmlns="SYNCML:SYNCML1.2"> 
    <SyncBody> 
        <Get> 
            <CmdID>1</CmdID> 
            <Item> 
                <Target> 
                    <LocURI>./Device/Vendor/MSFT/EnterpriseModernAppManagement/AppManagement/AppStore/PackageFamilyName/NonRemovable</LocURI> 
                </Target> 
            </Item> 
        </Get> 
        <Final/> 
    </SyncBody> 
</SyncML> 

替换不可删除的应用策略列表中的应用Replace an app in the nonremovable app policy list
数据 0 = 应用不在应用策略列表中Data 0 = app is not in the app policy list
数据 1 = 应用在应用策略列表中Data 1 = app is in the app policy list

<SyncML xmlns="SYNCML:SYNCML1.2"> 
    <SyncBody> 
        <Replace> 
            <CmdID>1</CmdID> 
            <Item> 
                <Target> 
                    <LocURI>./Device/Vendor/MSFT/EnterpriseModernAppManagement/AppManagement/AppStore/PackageFamilyName/NonRemovable</LocURI> 
                </Target> 
                <Meta> 
                    <Format xmlns="syncml:metinf">int</Format> 
                </Meta> 
                <Data>0</Data> 
            </Item> 
        </Replace> 
        <Final/> 
    </SyncBody> 
</SyncML> 

AppInstallationAppInstallation
必需的节点。Required node. 用于执行应用安装。Used to perform app installation.

AppInstallation/ PackageFamilyNameAppInstallation/PackageFamilyName
可选节点。Optional node. 程序包系列 (PFN) 应用的一部分。Package family name (PFN) of the app. 报告清单时,设备上每个 PFN 都有一个。There is one for each PFN on the device when reporting inventory. 这些项目的签名来源下有根。These items are rooted under their signing origin.

支持的操作包括 Get 和 Add。Supported operations are Get and Add.

备注

XAP 文件使用产品 ID 来表示 PackageFamilyName。XAP files use a product ID in place of PackageFamilyName. 下面是 XAP 产品 ID 示例, (大括号 {12345678-9012-3456-7890-123456789012}) 。Here's an example of XAP product ID (including the braces), {12345678-9012-3456-7890-123456789012}.

AppInstallation/PackageFamilyName/StoreInstallAppInstallation/PackageFamilyName/StoreInstall
必需。Required. 用于从 Microsoft Store 安装应用和许可证的命令。Command to perform an install of an app and a license from the Microsoft Store.

支持的操作为 Execute、Add、Delete 和 Get。Supported operation is Execute, Add, Delete, and Get.

AppInstallation/PackageFamilyName/HostedInstallAppInstallation/PackageFamilyName/HostedInstall
必需。Required. 从托管位置执行应用包安装 (可以是本地驱动器、UNC 或 https 数据源) 。Command to perform an install of an app package from a hosted location (this can be a local drive, a UNC, or https data source).

以下列表显示了受支持的部署选项:The following list shows the supported deployment options:

  • ForceApplicationShutdownForceApplicationShutdown
  • DevelopmentModeDevelopmentMode
  • InstallAllResourcesInstallAllResources
  • ForceTargetApplicationShutdownForceTargetApplicationShutdown
  • ForceUpdateToAnyVersionForceUpdateToAnyVersion
  • DeferRegistration="1"。DeferRegistration="1". 如果在安装时应用处于使用中。If the app is in use at the time of installation. 这将为应用更新分步文件,在应用关闭后完成应用更新的注册。This stages the files for an app update and completes the registration of the app update after the app closes. 在 20H1 的最新预览体验成员版中可用。Available in the latest insider flight of 20H1.
  • StageOnly="1"。StageOnly="1". 在不安装应用的情况下,为应用安装或更新阶段文件。Stages the files for an app installation or update without installing the app. 在 1803 中可用。Available in 1803.
  • LicenseUri="\server\license.lic"。LicenseUri="\server\license.lic". 从适用于 Business 的 Microsoft Store 部署脱机许可证。Deploys an offline license from the Microsoft Store for Business. 在 1607 中可用。Available in 1607.
  • ValidateDependencies="1"。ValidateDependencies="1". 这用于预配/暂存时间。This is used at provisioning/staging time. 如果设置为 1,则部署将在暂存期间执行与通常在注册时相同的依赖验证,如果不存在依赖关系,则失败并拒绝预配请求。If it is set to 1, deployment will perform the same dependency validation during staging that we would normally do at registration time, failing and rejecting the provision request if the dependencies are not present. 在 20H1 的最新预览体验成员版中可用。Available in the latest insider flight of 20H1.
  • ExcludeAppFromLayoutModification="1"。ExcludeAppFromLayoutModification="1". 设置将在所有设备上预配应用,并且能够保留预配的应用,而无需将它们固定到"开始"屏幕布局。Sets that the app will be provisioned on all devices and will be able to retain the apps provisioned without pinning them to start layout. 1809 年可用。Available in 1809.

支持的操作为 Execute、Add、Delete 和 Get。Supported operation is Execute, Add, Delete, and Get.

AppInstallation/PackageFamilyName/LastErrorAppInstallation/PackageFamilyName/LastError
必需。Required. 上次与应用安装相关的错误。Last error relating to the app installation.

支持的操作为 Get。Supported operation is Get.

备注

安装应用后,此元素不存在。This element is not present after the app is installed.

AppInstallation/PackageFamilyName/LastErrorDescAppInstallation/PackageFamilyName/LastErrorDesc
必需。Required. 与应用安装相关的最后一个错误的说明。Description of last error relating to the app installation.

支持的操作为 Get。Supported operation is Get.

备注

安装应用后,此元素不存在。This element is not present after the app is installed.

AppInstallation/PackageFamilyName/StatusAppInstallation/PackageFamilyName/Status
必需。Required. 应用安装的状态。Status of app installation. 将返回以下值:The following values are returned:

  • NOT_INSTALLED (0) - 已添加节点,但尚未完成执行。NOT_INSTALLED (0) - The node was added, but the execution has not completed.
  • INSTALLING (1) - 已启动执行,但部署尚未完成。INSTALLING (1) - Execution has started, but the deployment has not completed. 如果部署完成,而不考虑是否成功,则更新此值。If the deployment completes regardless of success, this value is updated.
  • 失败 (2) - 安装失败。FAILED (2) - Installation failed. 可以在 LastError 和 LastErrorDescription 下找到错误的详细信息。The details of the error can be found under LastError and LastErrorDescription.
  • INSTALLED (3) - 安装成功后,将清除此节点,但是,如果未完成清理操作,此状态可能会短暂出现。INSTALLED (3) - Once an install is successful this node is cleaned up, however in the event the clean up action has not completed, this state may briefly appear.

支持的操作为 Get。Supported operation is Get.

备注

安装应用后,此元素不存在。This element is not present after the app is installed.

AppInstallation/PackageFamilyName/ProgessStatusAppInstallation/PackageFamilyName/ProgessStatus
必需。Required. 指示应用安装进度的整数。An integer the indicates the progress of the app installation. 对于 https 位置,这表示下载进度。For https locations, this indicates the download progress. ProgressStatus 不可用于预配,并且仅适用于基于用户的安装。ProgressStatus is not available for provisioning and it is only for user-based installations. 在预配中,该值始终为 0 (零) 。In provisioning, the value is always 0 (zero).

支持的操作为 Get。Supported operation is Get.

备注

安装应用后,此元素不存在。This element is not present after the app is installed.

AppLicensesAppLicenses
必需的节点。Required node. 用于管理应用场景的许可证。Used to manage licenses for app scenarios.

AppLicenses/StoreLicensesAppLicenses/StoreLicenses
必需的节点。Required node. 用于管理应用商店应用的许可证。Used to manage licenses for store apps.

AppLicenses/StoreLicenses/ LicenseIDAppLicenses/StoreLicenses/LicenseID
可选节点。Optional node. 应用商店安装的应用的许可证 ID。License ID for a store installed app. 许可证 ID 通常是应用的 PFN。The license ID is generally the PFN of the app.

支持的操作包括添加、获取和删除。Supported operations are Add, Get, and Delete.

AppLicenses/StoreLicenses/LicenseID/LicenseCategoryAppLicenses/StoreLicenses/LicenseID/LicenseCategory
在 Windows 10 版本 1511 中添加。Added in Windows 10, version 1511. 必需。Required. 用于对各种许可证源进行分类的许可证类别。Category of license that is used to classify various license sources. 有效值:Valid value:

  • 未知 - 未知许可证类别Unknown - unknown license category
  • 零售 - 通过零售渠道(通常从 Microsoft Store)销售的许可证Retail - license sold through retail channels, typically from the Microsoft Store
  • 企业 - 通过企业销售渠道(通常从适用于企业的应用商店)销售的许可证Enterprise - license sold through the enterprise sales channel, typically from the Store for Business
  • OEM - 颁发给 OEM 的许可证OEM - license issued to an OEM
  • 开发人员 - 开发人员许可证,通常在应用开发或旁加载方案中安装。Developer - developer license, typically installed during the app development or side-loading scenarios.

支持的操作为 Get。Supported operation is Get.

AppLicenses/StoreLicenses/LicenseID/LicenseUsageAppLicenses/StoreLicenses/LicenseID/LicenseUsage
在 Windows 10 版本 1511 中添加。Added in Windows 10, version 1511. 必需。Required. 指示许可证的允许用法。Indicates the allowed usage for the license. 有效值:Valid values:

  • 未知 - 用法未知Unknown - usage is unknown
  • 联机 - 许可证仅对联机使用有效。Online - the license is only valid for online usage. 这适用于具有并发要求的应用程序,如在多台计算机上使用的应用,但在任何给定时间只能在一台计算机上使用。This is for applications with concurrence requirements, such as an app used on several computers, but can only be used on one at any given time.
  • 脱机 - 许可证对脱机使用有效。Offline - license is valid for use offline. 使用此许可证不需要连接到 Internet。You don't need a connection to the internet to use this license.
  • 企业根 -Enterprise Root -

支持的操作为 Get。Supported operation is Get.

AppLicenses/StoreLicenses/LicenseID/RequesterIDAppLicenses/StoreLicenses/LicenseID/RequesterID
在 Windows 10 版本 1511 中添加。Added in Windows 10, version 1511. 必需。Required. 请求许可证的实体的标识符,例如获取许可证的客户端。Identifier for the entity that requested the license, such as the client who acquired the license. 例如,适用于企业的应用商店为特定企业客户端颁发的所有许可证具有相同的 RequesterID。For example, all licenses issued by the Store for Business for a particular enterprise client has the same RequesterID.

支持的操作为 Get。Supported operation is Get.

AppLicenses/StoreLicenses/LicenseID/AddLicenseAppLicenses/StoreLicenses/LicenseID/AddLicense
必需。Required. 用于添加许可证的命令。Command to add license.

支持的操作是 Execute。Supported operation is Execute.

AppLicenses/StoreLicenses/LicenseID/GetLicenseFromStoreAppLicenses/StoreLicenses/LicenseID/GetLicenseFromStore
在 Windows 10 版本 1511 中添加。Added in Windows 10, version 1511. 必需。Required. 从应用商店获取许可证的命令。Command to get license from the store.

支持的操作是 Execute。Supported operation is Execute.

示例Examples

有关如何使用此 CSP 报告应用清单、为用户安装和删除应用、将应用预配到设备和管理应用许可证的示例,请参阅企业 应用管理For examples of how to use this CSP to for reporting apps inventory, installation and removal of apps for users, provisioning apps to devices, and managing app licenses, see Enterprise app management.

在设备中查询特定应用程序子类别,如 nonStore 应用。Query the device for a specific app subcategory, such as nonStore apps.

<Get>
  <CmdID>1</CmdID>
  <Item>
    <Target>
      <LocURI>./Device/Vendor/MSFT/EnterpriseModernAppManagement/AppManagement/nonStore</LocURI>
    </Target>
  </Item>
</Get>

结果包含应用列表,如 <Data> App1/App2/App </Data> 。The result contains a list of apps, such as <Data>App1/App2/App</Data>.

对特定应用的属性的后续查询。Subsequent query for a specific app for its properties.

<Get>
   <CmdID>1</CmdID>
   <Item>
     <Target>
       <LocURI>./Device/Vendor/MSFT/EnterpriseModernAppManagement/AppManagement/nonStore/App1?list=StructData</LocURI>
     </Target>
   </Item>
</Get>
<Get>
  <CmdID>2</CmdID>
  <Item>
    <Target>
      <LocURI>./Device/Vendor/MSFT/EnterpriseModernAppManagement/AppManagement/nonStore/App2?list=StructData</LocURI>
    </Target>
  </Item>
</Get>

配置服务提供程序参考Configuration service provider reference