1e41f4b71Sopenharmony_ci# Bundle Manager Subsystem ChangeLog
2e41f4b71Sopenharmony_ci
3e41f4b71Sopenharmony_ci## cl.bundlemanager.1 Bundle Manager API Changes
4e41f4b71Sopenharmony_ciThe bundle manager APIs use service logic return values to indicate the error information, which does not comply with the API error code specifications of OpenHarmony. APIs in API version 8 and earlier are deprecated. Replace them with APIs in API version 9 instead.
5e41f4b71Sopenharmony_ci
6e41f4b71Sopenharmony_ci**Change Impacts**
7e41f4b71Sopenharmony_ci
8e41f4b71Sopenharmony_ciThe application developed based on the SDK versions of OpenHarmony 3.2.8.2 and later needs to adapt the modules and APIs (version 9) and their method for returning API error information. Otherwise, the original service logic will be affected.
9e41f4b71Sopenharmony_ci
10e41f4b71Sopenharmony_ci**Key API/Component Changes**
11e41f4b71Sopenharmony_ci
12e41f4b71Sopenharmony_ciThe new APIs are classified by module. The original **d.ts** file is divided into multiple ones. You can import the **d.ts** files as required. The newly added APIs support unified error code handling specifications and function the same as the original APIs. APIs whose functions are changed or added are listed separately.
13e41f4b71Sopenharmony_ci
14e41f4b71Sopenharmony_ciFor adaptation to the unified API exception handling mode, bundle manager APIs (version 8 and earlier) are deprecated (original APIs in the following table) and corresponding new APIs (version 9) in the following table are added.
15e41f4b71Sopenharmony_ci
16e41f4b71Sopenharmony_ci| Original API (Deprecated)                      | New API (Added)                                              |
17e41f4b71Sopenharmony_ci| ------------------------------------ | ------------------------------------------------------------ |
18e41f4b71Sopenharmony_ci| @ohos.bundle.d.ts                    | [@ohos.bundle.bundleManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.bundleManager.d.ts) |
19e41f4b71Sopenharmony_ci| @ohos.bundle.d.ts                    | [@ohos.bundle.freeInstall.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.freeInstall.d.ts) |
20e41f4b71Sopenharmony_ci| @ohos.bundle.d.ts                    | [@ohos.bundle.installer.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.installer.d.ts) |
21e41f4b71Sopenharmony_ci| @ohos.bundle.innerBundleManager.d.ts | [@ohos.bundle.launcherBundleManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.launcherBundleManager.d.ts) |
22e41f4b71Sopenharmony_ci| @ohos.bundle.innerBundleManager.d.ts | [@ohos.bundle.bundleMonitor.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.bundleMonitor.d.ts) |
23e41f4b71Sopenharmony_ci| @ohos.bundle.defaultAppManager.d.ts  | [@ohos.bundle.defaultAppManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.defaultAppManager.d.ts) |
24e41f4b71Sopenharmony_ci| @ohos.distributedBundle.d.ts         | [@ohos.bundle.distributedBundleManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.distributedBundleManager.d.ts) |
25e41f4b71Sopenharmony_ci| N/A                                  | [@ohos.bundle.appControl.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.appControl.d.ts) |
26e41f4b71Sopenharmony_ci| @system.package.d.ts                 | N/A                                                          |
27e41f4b71Sopenharmony_ci
28e41f4b71Sopenharmony_ci**Adaptation Guide**
29e41f4b71Sopenharmony_ci1. Call the bundle manager query API.
30e41f4b71Sopenharmony_ci```
31e41f4b71Sopenharmony_ciimport bundle form '@ohos.bundle.bundleManager'
32e41f4b71Sopenharmony_ci```
33e41f4b71Sopenharmony_ci2. Call the bundle manager installation and uninstallation API.
34e41f4b71Sopenharmony_ci```
35e41f4b71Sopenharmony_ciimport installer form '@ohos.bundle.installer'
36e41f4b71Sopenharmony_ci```
37e41f4b71Sopenharmony_ci3. Call the bundle manager installation-free API.
38e41f4b71Sopenharmony_ci```
39e41f4b71Sopenharmony_ciimport freeInstall form '@ohos.bundle.freeInstall'
40e41f4b71Sopenharmony_ci```
41e41f4b71Sopenharmony_ci4. Call the bundle manager launcher APIs.
42e41f4b71Sopenharmony_ci```
43e41f4b71Sopenharmony_ciimport launcherBundleManager form '@ohos.bundle.launcherBundleManager'
44e41f4b71Sopenharmony_ciimport bundleMonitor form '@ohos.bundle.bundleMonitor'
45e41f4b71Sopenharmony_ci```
46e41f4b71Sopenharmony_ci6. Call the bundle manager API for the default application.
47e41f4b71Sopenharmony_ci```
48e41f4b71Sopenharmony_ciimport defaultAppManager form '@ohos.bundle.defaultAppManager'
49e41f4b71Sopenharmony_ci```
50e41f4b71Sopenharmony_ci7. Call the distributed bundle manager API.
51e41f4b71Sopenharmony_ci```
52e41f4b71Sopenharmony_ciimport distributedBundle form '@ohos.bundle.distributedBundle'
53e41f4b71Sopenharmony_ci```
54e41f4b71Sopenharmony_ciIn addition, exception handling is needed. For details, see the API reference for the new APIs.
55e41f4b71Sopenharmony_ci
56e41f4b71Sopenharmony_ci## cl.bundlemanager.1 Bundle Manager API Structure Changes
57e41f4b71Sopenharmony_ciThe bundle manager APIs use service logic return values to indicate the error information, which does not comply with the API error code specifications of OpenHarmony. The structures of APIs in API version 8 and earlier are deprecated. Use the structures of APIs in API version 9 instead.
58e41f4b71Sopenharmony_ci
59e41f4b71Sopenharmony_ci**Change Impacts**
60e41f4b71Sopenharmony_ci
61e41f4b71Sopenharmony_ciThe application developed based on the SDK versions of OpenHarmony 3.2.8.2 and later needs to adapt new structures. Otherwise, the original service logic will be affected. The export function of original level-2 modules will also be deprecated. Instead, the level-2 modules' export function of new APIs will be used, and new level-1 d.ts modules are imported.
62e41f4b71Sopenharmony_ci
63e41f4b71Sopenharmony_ci**Key API/Component Changes**
64e41f4b71Sopenharmony_ci
65e41f4b71Sopenharmony_ciThe structures of APIs in API version 8 and earlier are sorted out and deprecated, and those of new APIs in API version 9 are added. The following table lists the comparison before and after the change. Some structures are combined. For example, replace **moduleInfo.d.ts** with **hapModuleInfo.d.ts** and **customizeData.d.ts** with **metadata.d.ts**. The structures' functions are the same as those of the original ones. Structures whose attributes are changed or added are listed separately.
66e41f4b71Sopenharmony_ci| Original Structure (Deprecated)                | New Structure (Added)                                            |
67e41f4b71Sopenharmony_ci| -------------------------------- | ------------------------------------------------------------ |
68e41f4b71Sopenharmony_ci| bundle/abilityInfo.d.ts          | [bundleManager/AbilityInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/AbilityInfo.d.ts) |
69e41f4b71Sopenharmony_ci| bundle/applicationInfo.d.ts      | [bundleManager/ApplicationInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ApplicationInfo.d.ts) |
70e41f4b71Sopenharmony_ci| bundle/bundleInfo.d.ts           | [bundleManager/BundleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/BundleInfo.d.ts) |
71e41f4b71Sopenharmony_ci| bundle/bundleInstaller.d.ts      | [@ohos.bundle.installer.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.installer.d.ts) |
72e41f4b71Sopenharmony_ci| bundle/bundleStatusCallback.d.ts | [@ohos.bundle.bundleMonitor.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.bundleMonitor.d.ts) |
73e41f4b71Sopenharmony_ci| bundle/customizeData.d.ts        | [bundleManager/Metadata.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/Metadata.d.ts) |
74e41f4b71Sopenharmony_ci| bundle/dispatchInfo.d.ts         | [bundleManager/DispatchInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/DispatchInfo.d.ts) |
75e41f4b71Sopenharmony_ci| bundle/elementName.d.ts          | [bundleManager/ElementName.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ElementName.d.ts) |
76e41f4b71Sopenharmony_ci| bundle/extensionAbilityInfo.d.ts | [bundleManager/ExtensionAbilityInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ExtensionAbilityInfo.d.ts) |
77e41f4b71Sopenharmony_ci| bundle/hapModuleInfo.d.ts        | [bundleManager/HapModuleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts) |
78e41f4b71Sopenharmony_ci| bundle/launcherAbilityInfo.d.ts  | [bundleManager/LauncherAbilityInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/LauncherAbilityInfo.d.ts) |
79e41f4b71Sopenharmony_ci| bundle/metadata.d.ts             | [bundleManager/Metadata.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/Metadata.d.ts) |
80e41f4b71Sopenharmony_ci| bundle/moduleInfo.d.ts           | [bundleManager/HapModuleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts) |
81e41f4b71Sopenharmony_ci| bundle/PermissionDef.d.ts        | [bundleManager/PermissionDef.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/PermissionDef.d.ts) |
82e41f4b71Sopenharmony_ci| bundle/remoteAbilityInfo.d.ts    | [bundleManager/RemoteAbilityInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/RemoteAbilityInfo.d.ts) |
83e41f4b71Sopenharmony_ci| bundle/shortcutInfo.d.ts         | [bundleManager/ShortcutInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ShortcutInfo.d.ts) |
84e41f4b71Sopenharmony_ci
85e41f4b71Sopenharmony_ci**Adaptation Guide**
86e41f4b71Sopenharmony_ci1. Replace the code of original structures with the code of new ones.
87e41f4b71Sopenharmony_ci2. Deprecate the export function of original level-2 modules. Instead, use the level-2 modules' export function of new APIs, and import new level-1 d.ts modules.
88e41f4b71Sopenharmony_ci
89e41f4b71Sopenharmony_ci## cl.bundlemanager.3 Bundle Manager Query API Changes
90e41f4b71Sopenharmony_ci
91e41f4b71Sopenharmony_ciBundle manager query APIs are changed as follows: APIs of version 8 and earlier in **@ohos.bundle** are deprecated, and APIs of version 9 in **@ohos.bundle** are changed to **@ohos.bundle.bundleManager**, **@ohos.bundle.freeInstall**, and **@ohos.bundle.installer**. Most deprecated APIs are added to **@ohos.bundle.bundleManager** and changed to system APIs, and the exception handling capability is added.
92e41f4b71Sopenharmony_ci
93e41f4b71Sopenharmony_ciAPI call mode: APIs are now used by the **@ohos.bundle.bundleManager**, **@ohos.bundle.freeInstall**, and **@ohos.bundle.installer** modules, instead of the **@ohos.bundle** module.
94e41f4b71Sopenharmony_ci
95e41f4b71Sopenharmony_ciThe system capability of the **@ohos.bundle.bundleManager** and **@ohos.bundle.installer** modules is **SystemCapability.BundleManager.BundleFramework.Core**, and that of **@ohos.bundle.freeInstall** is **SystemCapability.BundleManager.BundleFramework.FreeInstall**.
96e41f4b71Sopenharmony_ci
97e41f4b71Sopenharmony_ci**Change Impacts**
98e41f4b71Sopenharmony_ci
99e41f4b71Sopenharmony_ciThere is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new modules and APIs. APIs of version 9 in **@ohos.bundle** are moved to the new **@ohos.bundle.bundleManager.d.ts**, **@ohos.bundle.freeInstall**, and **@ohos.bundle.installer** files.
100e41f4b71Sopenharmony_ci
101e41f4b71Sopenharmony_ci**Key API/Component Changes**
102e41f4b71Sopenharmony_ci
103e41f4b71Sopenharmony_ciThe following table lists the deprecated and changed APIs involved in **@ohos.bundle.d.ts**. The APIs not listed in the table have no change in API names and input parameters, and they have new exception handling and import modules. The APIs can be directly used after being imported to **@ohos.bundle.bundleManager.d.ts**, **@ohos.bundle.freeInstall**, and **@ohos.bundle.installer**. The APIs listed in the table are changed in API version 9, and those marked with "N/A" are deprecated in API version 9.
104e41f4b71Sopenharmony_ci
105e41f4b71Sopenharmony_ci| Original API (Deprecated)              | New API (Changed or Added)        | System API| New File Name                       |
106e41f4b71Sopenharmony_ci| ---------------------------- | ---------------------------- | --------- | ------------------------------- |
107e41f4b71Sopenharmony_ci| BundleFlag                   | BundleFlag                   | No       | @ohos.bundle.bundleManager.d.ts |
108e41f4b71Sopenharmony_ci| N/A                          | ApplicationFlag              | Yes       | @ohos.bundle.bundleManager.d.ts |
109e41f4b71Sopenharmony_ci| N/A                          | AbilityFlag                  | Yes       | @ohos.bundle.bundleManager.d.ts |
110e41f4b71Sopenharmony_ci| ExtensionFlag                | ExtensionAbilityFlag         | Yes       | @ohos.bundle.bundleManager.d.ts |
111e41f4b71Sopenharmony_ci| ColorMode                    | N/A                          | No       | N/A                             |
112e41f4b71Sopenharmony_ci| GrantStatus                  | PermissionGrantState         | No       | @ohos.bundle.bundleManager.d.ts |
113e41f4b71Sopenharmony_ci| AbilityType                  | AbilityType                  | No       | @ohos.bundle.bundleManager.d.ts |
114e41f4b71Sopenharmony_ci| AbilitySubType               | N/A                          | No       | N/A                             |
115e41f4b71Sopenharmony_ci| DisplayOrientation           | DisplayOrientation           | No       | @ohos.bundle.bundleManager.d.ts |
116e41f4b71Sopenharmony_ci| LaunchMode                   | LaunchType                   | No       | @ohos.bundle.bundleManager.d.ts |
117e41f4b71Sopenharmony_ci| ExtensionAbilityType         | ExtensionAbilityType         | Yes       | @ohos.bundle.bundleManager.d.ts |
118e41f4b71Sopenharmony_ci| BundleOptions                | N/A                          | No       | N/A                             |
119e41f4b71Sopenharmony_ci| InstallErrorCode             | N/A                          | No       | N/A                             |
120e41f4b71Sopenharmony_ci| UpgradeFlag                  | UpgradeFlag                  | Yes       | @ohos.bundle.freeInstall.d.ts   |
121e41f4b71Sopenharmony_ci| SupportWindowMode            | SupportWindowMode            | No       | @ohos.bundle.bundleManager.d.ts |
122e41f4b71Sopenharmony_ci| getBundleInfo                | getBundleInfo                | Yes       | @ohos.bundle.bundleManager.d.ts |
123e41f4b71Sopenharmony_ci| getBundleInstaller           | getBundleInstaller           | Yes       | @ohos.bundle.installer.d.ts     |
124e41f4b71Sopenharmony_ci| getAbilityInfo               | queryAbilityInfo             | Yes       | @ohos.bundle.bundleManager.d.ts |
125e41f4b71Sopenharmony_ci| getApplicationInfo           | getApplicationInfo           | Yes       | @ohos.bundle.bundleManager.d.ts |
126e41f4b71Sopenharmony_ci| queryAbilityByWant           | queryAbilityInfo             | Yes       | @ohos.bundle.bundleManager.d.ts |
127e41f4b71Sopenharmony_ci| getAllBundleInfo             | getAllBundleInfo             | Yes       | @ohos.bundle.bundleManager.d.ts |
128e41f4b71Sopenharmony_ci| getAllApplicationInfo        | getAllApplicationInfo        | Yes       | @ohos.bundle.bundleManager.d.ts |
129e41f4b71Sopenharmony_ci| getNameForUid                | getBundleNameByUid           | Yes       | @ohos.bundle.bundleManager.d.ts |
130e41f4b71Sopenharmony_ci| getBundleArchiveInfo         | getBundleArchiveInfo         | Yes       | @ohos.bundle.bundleManager.d.ts |
131e41f4b71Sopenharmony_ci| getLaunchWantForBundle       | getLaunchWantForBundle       | Yes       | @ohos.bundle.bundleManager.d.ts |
132e41f4b71Sopenharmony_ci| cleanBundleCacheFiles        | cleanBundleCacheFiles        | Yes       | @ohos.bundle.bundleManager.d.ts |
133e41f4b71Sopenharmony_ci| setApplicationEnabled        | setApplicationEnabled        | Yes       | @ohos.bundle.bundleManager.d.ts |
134e41f4b71Sopenharmony_ci| setAbilityEnabled            | setAbilityEnabled            | Yes       | @ohos.bundle.bundleManager.d.ts |
135e41f4b71Sopenharmony_ci| queryExtensionAbilityInfos   | queryExtensionAbilityInfo    | Yes       | @ohos.bundle.bundleManager.d.ts |
136e41f4b71Sopenharmony_ci| getPermissionDef             | getPermissionDef             | Yes       | @ohos.bundle.bundleManager.d.ts |
137e41f4b71Sopenharmony_ci| getAbilityLabel              | getAbilityLabel              | Yes       | @ohos.bundle.bundleManager.d.ts |
138e41f4b71Sopenharmony_ci| getAbilityIcon               | getAbilityIcon               | Yes       | @ohos.bundle.bundleManager.d.ts |
139e41f4b71Sopenharmony_ci| isAbilityEnabled             | isAbilityEnabled             | Yes       | @ohos.bundle.bundleManager.d.ts |
140e41f4b71Sopenharmony_ci| isApplicationEnabled         | isApplicationEnabled         | Yes       | @ohos.bundle.bundleManager.d.ts |
141e41f4b71Sopenharmony_ci| setModuleUpgradeFlag         | setHapModuleUpgradeFlag      | Yes       | @ohos.bundle.freeInstall.d.ts   |
142e41f4b71Sopenharmony_ci| isModuleRemovable            | isHapModuleRemovable         | Yes       | @ohos.bundle.freeInstall.d.ts   |
143e41f4b71Sopenharmony_ci| getBundlePackInfo            | getBundlePackInfo            | Yes       | @ohos.bundle.freeInstall.d.ts   |
144e41f4b71Sopenharmony_ci| getDispatcherVersion         | getDispatchInfo              | Yes       | @ohos.bundle.freeInstall.d.ts   |
145e41f4b71Sopenharmony_ci| getProfileByAbility          | getProfileByAbility          | No       | @ohos.bundle.bundleManager.d.ts |
146e41f4b71Sopenharmony_ci| getProfileByExtensionAbility | getProfileByExtensionAbility | No       | @ohos.bundle.bundleManager.d.ts |
147e41f4b71Sopenharmony_ci| setDisposedStatus            | setDisposedStatus            | Yes       | @ohos.bundle.appControl.d.ts    |
148e41f4b71Sopenharmony_ci| getDisposedStatus            | getDisposedStatus            | Yes       | @ohos.bundle.appControl.d.ts    |
149e41f4b71Sopenharmony_ci| N/A                          | deleteDisposedStatus         | Yes       | @ohos.bundle.appControl.d.ts    |
150e41f4b71Sopenharmony_ci| getBundleInfoSync            | getBundleInfoSync            | Yes       | @ohos.bundle.bundleManager.d.ts |
151e41f4b71Sopenharmony_ci| getApplicationInfoSync       | getApplicationInfoSync       | Yes       | @ohos.bundle.bundleManager.d.ts |
152e41f4b71Sopenharmony_ci| N/A                          | getBundleInfoForSelf         | No       | @ohos.bundle.bundleManager.d.ts |
153e41f4b71Sopenharmony_ci
154e41f4b71Sopenharmony_ci**Adaptation Guide**
155e41f4b71Sopenharmony_ci
156e41f4b71Sopenharmony_ciReplace the original APIs with new ones of version 9 and import related modules.
157e41f4b71Sopenharmony_ci
158e41f4b71Sopenharmony_ciOld import module:
159e41f4b71Sopenharmony_ci```
160e41f4b71Sopenharmony_ciimport bundle form '@ohos.bundle'
161e41f4b71Sopenharmony_ci```
162e41f4b71Sopenharmony_ciNew import module:
163e41f4b71Sopenharmony_ci```
164e41f4b71Sopenharmony_ciimport bundle form '@ohos.bundle.bundleManager'
165e41f4b71Sopenharmony_ciimport freeInstall form '@ohos.bundle.freeInstall'
166e41f4b71Sopenharmony_ciimport installer form '@ohos.bundle.installer'
167e41f4b71Sopenharmony_ciimport appControl form '@ohos.bundle.appControl'
168e41f4b71Sopenharmony_ci```
169e41f4b71Sopenharmony_ci
170e41f4b71Sopenharmony_ci## cl.bundlemanager.4 BundleInfo Structure Changes
171e41f4b71Sopenharmony_ci
172e41f4b71Sopenharmony_ciAll **bundle/bundleInfo.d.ts** fields in the bundle manager are deprecated. [bundle/bundleInfo.d.ts]((https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundle/bundleInfo.d.ts)) is changed to [bundleManager/BundleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/BundleInfo.d.ts), involving field type changes.
173e41f4b71Sopenharmony_ci
174e41f4b71Sopenharmony_ci**Change Impacts**
175e41f4b71Sopenharmony_ci
176e41f4b71Sopenharmony_ciThere is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new modules and APIs. When a level-2 module is used to export **BundleInfo**, the **@ohos.bundle.bundleManager** module needs to be imported.
177e41f4b71Sopenharmony_ci
178e41f4b71Sopenharmony_ci**Key API/Component Changes**
179e41f4b71Sopenharmony_ci
180e41f4b71Sopenharmony_ciThe following table describes the changed fields in the **BundleInfo** structure. After other fields are deprecated in **bundle/bundleInfo.d.ts**, they have corresponding values in the new **[bundleManager/BundleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/BundleInfo.d.ts)**. If corresponding fields do not exist, the fields have been deprecated in API version 9.
181e41f4b71Sopenharmony_ci
182e41f4b71Sopenharmony_ci| Deprecated               | Added or Changed in API Version 9       | Type                                      |
183e41f4b71Sopenharmony_ci| --------------------- | --------------------- | ------------------------------------------ |
184e41f4b71Sopenharmony_ci| type                  | N/A                   | string                                     |
185e41f4b71Sopenharmony_ci| appId                 | N/A                   | string                                     |
186e41f4b71Sopenharmony_ci| N/A                   | signatureInfo         | SignatureInfo                              |
187e41f4b71Sopenharmony_ci| uid                   | N/A                   | number                                     |
188e41f4b71Sopenharmony_ci| abilityInfos          | N/A                   | Array\<AbilityInfo>                        |
189e41f4b71Sopenharmony_ci| reqPermissions        | N/A                   | Array<string>                              |
190e41f4b71Sopenharmony_ci| compatibleVersion     | N/A                   | number                                     |
191e41f4b71Sopenharmony_ci| isCompressNativeLibs  | N/A                   | boolean                                    |
192e41f4b71Sopenharmony_ci| entryModuleName       | N/A                   | string                                     |
193e41f4b71Sopenharmony_ci| cpuAbi                | N/A                   | string                                     |
194e41f4b71Sopenharmony_ci| isSilentInstallation  | N/A                   | string                                     |
195e41f4b71Sopenharmony_ci| entryInstallationFree | N/A                   | boolean                                    |
196e41f4b71Sopenharmony_ci| reqPermissionStates   | permissionGrantStates | Array\<bundleManager.PermissionGrantState> |
197e41f4b71Sopenharmony_ci| extensionAbilityInfo  | N/A                   | Array\<ExtensionAbilityInfo>               |
198e41f4b71Sopenharmony_ci| hapModuleInfos        | hapModulesInfo        | Array\<HapModuleInfo>                      |
199e41f4b71Sopenharmony_ci
200e41f4b71Sopenharmony_ciThe **SignatureInfo** structure is added to API version 9 as follows.
201e41f4b71Sopenharmony_ci
202e41f4b71Sopenharmony_ci| Field     | Type  |
203e41f4b71Sopenharmony_ci| ----------- | ------ |
204e41f4b71Sopenharmony_ci| appId       | string |
205e41f4b71Sopenharmony_ci| fingerprint | string |
206e41f4b71Sopenharmony_ci
207e41f4b71Sopenharmony_ci**Adaptation Guide**
208e41f4b71Sopenharmony_ci
209e41f4b71Sopenharmony_ciUse the **BundleInfo** structure of API version 9 for modules imported for bundle manager query. The following module needs to be imported when a level-2 module is used for export.
210e41f4b71Sopenharmony_ci
211e41f4b71Sopenharmony_ci```
212e41f4b71Sopenharmony_ciimport bundle form '@ohos.bundle.bundleManager'
213e41f4b71Sopenharmony_ci```
214e41f4b71Sopenharmony_ci
215e41f4b71Sopenharmony_ci## cl.bundlemanager.5 ApplicationInfo Structure Changes
216e41f4b71Sopenharmony_ciThe **ApplicationInfo** structure is changed. The original **bundle/applicationInfo.d.ts** fields in the bundle manager are deprecated, and the file is changed from **bundle/applicationInfo.d.ts** to **bundleManager/ApplicationInfo.d.ts**, involving field type changes.
217e41f4b71Sopenharmony_ci
218e41f4b71Sopenharmony_ci**Change Impacts**
219e41f4b71Sopenharmony_ci
220e41f4b71Sopenharmony_ciThere is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new modules and APIs. When a level-2 module is used to export **ApplicationInfo**, the **@ohos.bundle.bundleManager** module needs to be imported.
221e41f4b71Sopenharmony_ci
222e41f4b71Sopenharmony_ci**Key API/Component Changes**
223e41f4b71Sopenharmony_ci
224e41f4b71Sopenharmony_ciThe following table describes the changed fields in the **ApplicationInfo** structure. After other fields are deprecated in **bundle/applicationInfo.d.ts**, they have corresponding values in the new [bundleManager/ApplicationInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ApplicationInfo.d.ts). If corresponding fields do not exist, the fields have been deprecated in API version 9.
225e41f4b71Sopenharmony_ci
226e41f4b71Sopenharmony_ci| Deprecated            | Added or Changed in API Version 9| Type                              |
227e41f4b71Sopenharmony_ci| ---------------- | -------------- | ---------------------------------- |
228e41f4b71Sopenharmony_ci| systemApp        | N/A            | boolean                            |
229e41f4b71Sopenharmony_ci| labelId          | N/A            | string                             |
230e41f4b71Sopenharmony_ci| labelIndex       | labelId        | number                             |
231e41f4b71Sopenharmony_ci| iconId           | N/A            | string                             |
232e41f4b71Sopenharmony_ci| iconIndex        | iconId         | number                             |
233e41f4b71Sopenharmony_ci| supportedModes   | N/A            | number                             |
234e41f4b71Sopenharmony_ci| moduleSourceDirs | N/A            | Array\<string>                     |
235e41f4b71Sopenharmony_ci| moduleInfos      | N/A            | Array\<ModuleInfo>                 |
236e41f4b71Sopenharmony_ci| metaData         | N/A            | Map\<string,Array\<CustomizeData>> |
237e41f4b71Sopenharmony_ci| entityType       | N/A            | string                             |
238e41f4b71Sopenharmony_ci| fingerprint      | N/A            | string                             |
239e41f4b71Sopenharmony_ci
240e41f4b71Sopenharmony_ci**Adaptation Guide**
241e41f4b71Sopenharmony_ci
242e41f4b71Sopenharmony_ciUse the **ApplicationInfo** structure of API version 9 for modules imported for bundle manager query.
243e41f4b71Sopenharmony_ci
244e41f4b71Sopenharmony_ci
245e41f4b71Sopenharmony_ci## cl.bundlemanager.6 HapModuleInfo Structure Changes
246e41f4b71Sopenharmony_ci
247e41f4b71Sopenharmony_ciThe **HapModuleInfo** structure is changed. The original **bundle/hapModuleInfo.d.ts** and **moduleInfo.d.ts** fields in the bundle manager are deprecated, and the files are changed to [bundleManager/HapModuleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts), involving field type changes.
248e41f4b71Sopenharmony_ci
249e41f4b71Sopenharmony_ci**Change Impacts**
250e41f4b71Sopenharmony_ci
251e41f4b71Sopenharmony_ciThere is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new modules and APIs. When a level-2 module is used to export **HapModuleInfo**, the **@ohos.bundle.bundleManager** module needs to be imported.
252e41f4b71Sopenharmony_ci
253e41f4b71Sopenharmony_ci**Key API/Component Changes**
254e41f4b71Sopenharmony_ci
255e41f4b71Sopenharmony_ciThe following table describes the changed fields in the **HapModuleInfo** structure. After other fields are deprecated in **bundle/hapModuleInfo.d.ts**, they have corresponding values in the new **bundleManager/HapModuleInfo.d.ts** file.
256e41f4b71Sopenharmony_ci
257e41f4b71Sopenharmony_ci| Deprecated                | Added or Changed in API Version 9        | Type                        |
258e41f4b71Sopenharmony_ci| -------------------- | ---------------------- | ---------------------------- |
259e41f4b71Sopenharmony_ci| abilityInfo          | abilitiesInfo          | Array<AbilityInfo>           |
260e41f4b71Sopenharmony_ci| N/A                  | moduleSourceDir        | string                       |
261e41f4b71Sopenharmony_ci| backgroundImg        | N/A                    | string                       |
262e41f4b71Sopenharmony_ci| supportedModes       | N/A                    | string                       |
263e41f4b71Sopenharmony_ci| reqCapabilities      | N/A                    | Array\<string>               |
264e41f4b71Sopenharmony_ci| moduleName           | N/A                    | string                       |
265e41f4b71Sopenharmony_ci| mainAbilityName      | N/A                    | string                       |
266e41f4b71Sopenharmony_ci| extensionAbilityInfo | extensionAbilitiesInfo | Array\<ExtensionAbilityInfo> |
267e41f4b71Sopenharmony_ci
268e41f4b71Sopenharmony_ci**Adaptation Guide**
269e41f4b71Sopenharmony_ci
270e41f4b71Sopenharmony_ciUse the **HapModuleInfo** structure of API version 9 for modules imported for bundle manager query.
271e41f4b71Sopenharmony_ci
272e41f4b71Sopenharmony_ci## cl.bundlemanager.7 ModuleInfo Structure Changes
273e41f4b71Sopenharmony_ci
274e41f4b71Sopenharmony_ciThe original **bundle/hapModuleInfo.d.ts** and **moduleInfo.d.ts** fields in the bundle manager are deprecated, and the files are changed to [bundleManager/HapModuleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts), involving field changes.
275e41f4b71Sopenharmony_ci
276e41f4b71Sopenharmony_ciThe **ModuleInfo** structure is deprecated and replaced by **HapModuleInfo** in [bundleManager/HapModuleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts).
277e41f4b71Sopenharmony_ci
278e41f4b71Sopenharmony_ci**Change Impacts**
279e41f4b71Sopenharmony_ci
280e41f4b71Sopenharmony_ciThere is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new modules and APIs. The **ModuleInfo** structure is deprecated and replaced by **HapModuleInfo**.
281e41f4b71Sopenharmony_ci
282e41f4b71Sopenharmony_ci**Key API/Component Changes**
283e41f4b71Sopenharmony_ci
284e41f4b71Sopenharmony_ciThe **ModuleInfo** structure is deprecated and replaced by **HapModuleInfo**.
285e41f4b71Sopenharmony_ci
286e41f4b71Sopenharmony_ci**Adaptation Guide**
287e41f4b71Sopenharmony_ci
288e41f4b71Sopenharmony_ciUse the **HapModuleInfo** structure of API version 9.
289e41f4b71Sopenharmony_ci
290e41f4b71Sopenharmony_ci## cl.bundlemanager.8 AbilityInfo Structure Changes
291e41f4b71Sopenharmony_ci
292e41f4b71Sopenharmony_ciThe **AbilityInfo** structure is changed. The original **bundle/abilityInfo.d.ts** file is deprecated and changed to **bundleManager/AbilityInfo.d.ts**, involving field type changes.
293e41f4b71Sopenharmony_ci
294e41f4b71Sopenharmony_ci**Change Impacts**
295e41f4b71Sopenharmony_ci
296e41f4b71Sopenharmony_ciThere is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new modules and APIs.
297e41f4b71Sopenharmony_ci
298e41f4b71Sopenharmony_ci**Key API/Component Changes**
299e41f4b71Sopenharmony_ci
300e41f4b71Sopenharmony_ciThe following table lists the field changes in the **AbilityInfo** structure for the bundle manager. Fields that are not listed in the table exist in the new **AbilityInfo** structure after being deprecated. Fields marked with "N/A" have been deprecated in API version 9 and do not exist in the new **AbilityInfo** structure.
301e41f4b71Sopenharmony_ci
302e41f4b71Sopenharmony_ci| Deprecated              | Added or Changed in API Version 9    | Type                 |
303e41f4b71Sopenharmony_ci| ------------------ | ------------------ | --------------------- |
304e41f4b71Sopenharmony_ci| launchMode         | launchType         | number                |
305e41f4b71Sopenharmony_ci| supportWindowMode  | supportWindowModes | Array\<number>        |
306e41f4b71Sopenharmony_ci| targetAbility      | N/A                | string                |
307e41f4b71Sopenharmony_ci| backgroundModes    | N/A                | number                |
308e41f4b71Sopenharmony_ci| formEnabled        | N/A                | boolean               |
309e41f4b71Sopenharmony_ci| subType            | N/A                | AbilitySubType        |
310e41f4b71Sopenharmony_ci| deviceCapabilities | N/A                | Array\<string>        |
311e41f4b71Sopenharmony_ci| metaData           | N/A                | Array\<CustomizeData> |
312e41f4b71Sopenharmony_ci| maxWindowRatio     | N/A                | number                |
313e41f4b71Sopenharmony_ci| minWindowRatio     | N/A                | number                |
314e41f4b71Sopenharmony_ci| maxWindowWidth     | N/A                | number                |
315e41f4b71Sopenharmony_ci| minWindowWidth     | N/A                | number                |
316e41f4b71Sopenharmony_ci| maxWindowHeight    | N/A                | number                |
317e41f4b71Sopenharmony_ci| minWindowHeight    | N/A                | number                |
318e41f4b71Sopenharmony_ci| N/A                | windowSize         | WindowSize            |
319e41f4b71Sopenharmony_ci
320e41f4b71Sopenharmony_ciThe fields of the new structure **WindowSize** of API version 9 are as follows.
321e41f4b71Sopenharmony_ci
322e41f4b71Sopenharmony_ci|     Field     |  Type |
323e41f4b71Sopenharmony_ci| :-------------: | :----: |
324e41f4b71Sopenharmony_ci| maxWindowRatio  | number |
325e41f4b71Sopenharmony_ci| minWindowRatio  | number |
326e41f4b71Sopenharmony_ci| maxWindowWidth  | number |
327e41f4b71Sopenharmony_ci| minWindowWidth  | number |
328e41f4b71Sopenharmony_ci| maxWindowHeight | number |
329e41f4b71Sopenharmony_ci| minWindowHeight | number |
330e41f4b71Sopenharmony_ci
331e41f4b71Sopenharmony_ci**Adaptation Guide**
332e41f4b71Sopenharmony_ci
333e41f4b71Sopenharmony_ciUse the **AbilityInfo** structure of API version 9.
334e41f4b71Sopenharmony_ci
335e41f4b71Sopenharmony_ci## cl.bundlemanager.9 BundleFlag Changes
336e41f4b71Sopenharmony_ci
337e41f4b71Sopenharmony_ci**BundleFlag** is changed to **BundleFlag**, **ApplicationFlag**, and **AbilityFlag** in **@ohos.bundle.bundleManager**. Different types of flags are passed based on the input parameters of new APIs.
338e41f4b71Sopenharmony_ci
339e41f4b71Sopenharmony_ci**Change Impacts**
340e41f4b71Sopenharmony_ci
341e41f4b71Sopenharmony_ci**BundleFlag** is changed to **BundleFlag**, **ApplicationFlag**, and **AbilityFlag** in **@ohos.bundle.bundleManager**. Different types of flags are passed based on the input parameters of new APIs. If **BundleFlag** of a version earlier than API version 9 is directly used, the query may fail.
342e41f4b71Sopenharmony_ci
343e41f4b71Sopenharmony_ci**Key API/Component Changes**
344e41f4b71Sopenharmony_ci
345e41f4b71Sopenharmony_ci**BundleFlag** in the original **@ohos.bundle** is deprecated and replaced by **BundleFlag**, **ApplicationFlag**, and **AbilityFlag** in the new **@ohos.bundle.bundleManager**.
346e41f4b71Sopenharmony_ci
347e41f4b71Sopenharmony_ciThe following table describes **BundleFlag** of API version 9.
348e41f4b71Sopenharmony_ci
349e41f4b71Sopenharmony_ci| BundleFlag                               | Value        | Description                                                        |
350e41f4b71Sopenharmony_ci| ----------------------------------------- | ---------- | ------------------------------------------------------------ |
351e41f4b71Sopenharmony_ci| GET_BUNDLE_INFO_DEFAULT                   | 0x00000000 | Obtains the default **BundleInfo**. The obtained **BundleInfo** does not contain **signatureInfo**, **hapModuleInfo**, **appInfo**, **reqPermissionDetails**, or **permissionGrantStates**.|
352e41f4b71Sopenharmony_ci| GET_BUNDLE_INFO_WITH_APPLICATION          | 0x00000001 | Obtains **appInfos** with the default **BundleInfo**.                                            |
353e41f4b71Sopenharmony_ci| GET_BUNDLE_INFO_WITH_HAP_MODULE           | 0x00000002 | Obtains **hapModulesInfo** with the default **BundleInfo**.                                      |
354e41f4b71Sopenharmony_ci| GET_BUNDLE_INFO_WITH_ABILITY              | 0x00000004 | Indicates whether **abilitiesInfo** is obtained with **hapModulesInfo**. This flag must be used together with **GET_BUNDLE_INFO_WITH_HAP_MODULE** and cannot be used independently.|
355e41f4b71Sopenharmony_ci| GET_BUNDLE_INFO_WITH_EXTENSION_ABILITY    | 0x00000008 | Indicates whether **extensionAbilitiesInfo** is obtained with **hapModulesInfo**. This flag must be used together with **GET_BUNDLE_INFO_WITH_HAP_MODULE** and cannot be used independently.|
356e41f4b71Sopenharmony_ci| GET_BUNDLE_INFO_WITH_REQUESTED_PERMISSION | 0x00000010 | Obtains **reqPermissionDetails** and **permissionGrantStates** with the default **BundleInfo**.         |
357e41f4b71Sopenharmony_ci| GET_BUNDLE_INFO_WITH_METADATA             | 0x00000020 | Indicates whether the returned **ApplicationInfo**, **AbilityInfo**, and **ExtensionAbilityInfo** contain metadata. This flag cannot be used independently.|
358e41f4b71Sopenharmony_ci| GET_BUNDLE_INFO_WITH_DISABLE              | 0x00000040 | Obtains **BundleInfo** of a disabled application and disabled ability information in **abilitiesInfo**.|
359e41f4b71Sopenharmony_ci| GET_BUNDLE_INFO_WITH_SIGNATURE_INFO       | 0x00000080 | Obtains **signatureInfo** with the default **BundleInfo**.                                       |
360e41f4b71Sopenharmony_ci
361e41f4b71Sopenharmony_ciThe following table describes **ApplicationFlag** of API version 9.
362e41f4b71Sopenharmony_ci
363e41f4b71Sopenharmony_ci| ApplicationFlag                     | Value        | Description                                                        |
364e41f4b71Sopenharmony_ci| ------------------------------------ | ---------- | ------------------------------------------------------------ |
365e41f4b71Sopenharmony_ci| GET_APPLICATION_INFO_DEFAULT         | 0x00000000 | Obtains the default **ApplicationInfo**. The obtained **ApplicationInfo** does not contain permission or metadata information.|
366e41f4b71Sopenharmony_ci| GET_APPLICATION_INFO_WITH_PERMISSION | 0x00000001 | Obtains **permissions** with the default **ApplicationInfo**.                                         |
367e41f4b71Sopenharmony_ci| GET_APPLICATION_INFO_WITH_METADATA   | 0x00000002 | Obtains **metadata** with the default **ApplicationInfo**.                                            |
368e41f4b71Sopenharmony_ci| GET_APPLICATION_INFO_WITH_DISABLE    | 0x00000004 | Obtains disabled application information.                               |
369e41f4b71Sopenharmony_ci
370e41f4b71Sopenharmony_ci
371e41f4b71Sopenharmony_ciThe following table describes **AbilityFlag** of API version 9.
372e41f4b71Sopenharmony_ci| AbilityFlag                      | Value        | Description                                                        |
373e41f4b71Sopenharmony_ci| --------------------------------- | ---------- | ------------------------------------------------------------ |
374e41f4b71Sopenharmony_ci| GET_ABILITY_INFO_DEFAULT          | 0x00000000 | Obtains the default **AbilityInfo**. The obtained **AbilityInfo** does not contain permission, metadata, or disabled ability information.|
375e41f4b71Sopenharmony_ci| GET_ABILITY_INFO_WITH_PERMISSION  | 0x00000001 | Obtains **AbilityInfo** with permission information.                     |
376e41f4b71Sopenharmony_ci| GET_ABILITY_INFO_WITH_APPLICATION | 0x00000002 | Obtains **AbilityInfo** with the **ApplicationInfo** structure.          |
377e41f4b71Sopenharmony_ci| GET_ABILITY_INFO_WITH_METADATA    | 0x00000004 | Obtains **AbilityInfo** with metadata information.                       |
378e41f4b71Sopenharmony_ci| GET_ABILITY_INFO_WITH_DISABLE     | 0x00000008 | Obtains all **AbilityInfo**, including disabled abilities.              |
379e41f4b71Sopenharmony_ci| GET_ABILITY_INFO_ONLY_SYSTEM_APP  | 0x00000010 | Obtains **AbilityInfo** for system applications.                                 |
380e41f4b71Sopenharmony_ci
381e41f4b71Sopenharmony_ci**Adaptation Guide**
382e41f4b71Sopenharmony_ci
383e41f4b71Sopenharmony_ciUse various flags according to the called API in **@ohos.bundle.bundleManager.d.ts**.
384e41f4b71Sopenharmony_ci
385e41f4b71Sopenharmony_ci## cl.bundlemanager.10 ApplicationType Enumerated Value Changes in the Default Application Module
386e41f4b71Sopenharmony_ciFor the **@ohos.bundle.defaultApp** module, both API functions and usage remain unchanged, but only the enumerated values of **ApplicationType** are changed.
387e41f4b71Sopenharmony_ci
388e41f4b71Sopenharmony_ci**Change Impacts**
389e41f4b71Sopenharmony_ci
390e41f4b71Sopenharmony_ciThere is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new enumerated values.
391e41f4b71Sopenharmony_ci
392e41f4b71Sopenharmony_ci**Key API/Component Changes**
393e41f4b71Sopenharmony_ci
394e41f4b71Sopenharmony_ciThe enumerated values of **ApplicationType** are changed as follows.
395e41f4b71Sopenharmony_ci
396e41f4b71Sopenharmony_ci| ApplicationType| Added or Changed in API Version 9 | API Version 8 and Earlier|
397e41f4b71Sopenharmony_ci| :-------------: | :-------------: | :--------: |
398e41f4b71Sopenharmony_ci|     BROWSER     |  "Web Browser"  | "BROWSER"  |
399e41f4b71Sopenharmony_ci|      IMAGE      | "Image Gallery" |  "IMAGE"   |
400e41f4b71Sopenharmony_ci|      AUDIO      | "Audio Player"  |  "AUDIO"   |
401e41f4b71Sopenharmony_ci|      VIDEO      | "Video Player"  |  "VIDEO"   |
402e41f4b71Sopenharmony_ci|       PDF       |  "PDF Viewer"   |   "PDF"    |
403e41f4b71Sopenharmony_ci|      WORD       |  "Word Viewer"  |   "WORD"   |
404e41f4b71Sopenharmony_ci|      EXCEL      | "Excel Viewer"  |  "EXCEL"   |
405e41f4b71Sopenharmony_ci|       PPT       |  "PPT Viewer"   |   "PPT"    |
406e41f4b71Sopenharmony_ci
407e41f4b71Sopenharmony_ci**Adaptation Guide**
408e41f4b71Sopenharmony_ci
409e41f4b71Sopenharmony_ciImport the default application module and call related APIs.
410e41f4b71Sopenharmony_ci
411e41f4b71Sopenharmony_ci```
412e41f4b71Sopenharmony_ciimport defaultApp form '@ohos.bundle.defaultAppManager'
413e41f4b71Sopenharmony_ci```
414e41f4b71Sopenharmony_ci
415e41f4b71Sopenharmony_ci## cl.bundlemanager.11 Distributed Bundle Manager Changes
416e41f4b71Sopenharmony_ciAPI exception handling is rectified. The distributed bundle manager module is changed. The original **@ohos.distributedBundle.d.ts** APIs are deprecated, and the **@ohos.distributedBundle.d.ts** file is changed to [@ohos.bundle.distributedBundleManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.distributedBundleManager.d.ts). The **getRemoteAbilityInfos** API is changed to **getRemoteAbilityInfo**. The export function of a level-2 module in the **RemoteAbilityInfo** structure can be used only after a new module is imported.
417e41f4b71Sopenharmony_ci
418e41f4b71Sopenharmony_ci**Change Impacts**
419e41f4b71Sopenharmony_ci
420e41f4b71Sopenharmony_ciApplications using APIs earlier than version 9 are not affected. The names of the distributed module and the **getRemoteAbilityInfos** API are changed. As a result, applications using APIs of version 9 may fail to be compiled using the new SDK.
421e41f4b71Sopenharmony_ci
422e41f4b71Sopenharmony_ci**Key API/Component Changes**
423e41f4b71Sopenharmony_ci
424e41f4b71Sopenharmony_ciAll APIs in **@ohos.distributedBundle.d.ts** are deprecated. The **@ohos.bundle.distributedBundleManager.d.ts** file is added. The functions of some APIs are the same as those of the original ones. New APIs support exception handling. The API changes are as follows.
425e41f4b71Sopenharmony_ci
426e41f4b71Sopenharmony_ci| Deprecated                 | Added or Changed in API Version 9      | System API|
427e41f4b71Sopenharmony_ci| --------------------- | -------------------- | --------- |
428e41f4b71Sopenharmony_ci| getRemoteAbilityInfos | getRemoteAbilityInfo | Yes       |
429e41f4b71Sopenharmony_ci
430e41f4b71Sopenharmony_ci**Adaptation Guide**
431e41f4b71Sopenharmony_ci
432e41f4b71Sopenharmony_ciImport a new distributed module.
433e41f4b71Sopenharmony_ci
434e41f4b71Sopenharmony_ci```
435e41f4b71Sopenharmony_ciimport distributedBundle form '@ohos.bundle.distributedBundle'
436e41f4b71Sopenharmony_ci```
437e41f4b71Sopenharmony_ci
438e41f4b71Sopenharmony_ci## cl.bundlemanager.12 Installation-Free Module and API Changes
439e41f4b71Sopenharmony_ciAPIs support exception handling rectification. The installation-free module is moved from **@ohos.bundle.d.ts** to **@ohos.bundle.freeInstall.d.ts**, involving module and API changes. The system capability is **SystemCapability.BundleManager.BundleFramework.FreeInstall**.
440e41f4b71Sopenharmony_ci1. The imported **@ohos.bundle** module needs to be changed to **@ohos.bundle.freeInstall**.
441e41f4b71Sopenharmony_ci2. The **setModuleUpgradeFlag** API is changed to **setHapModuleUpgradeFlag**.
442e41f4b71Sopenharmony_ci3. The **isModuleRemovable** API is changed to **isHapModuleRemovable**.
443e41f4b71Sopenharmony_ci4. The **getDispatcher** API is changed to **getDispatchInfo**.
444e41f4b71Sopenharmony_ci
445e41f4b71Sopenharmony_ci**Change Impacts**
446e41f4b71Sopenharmony_ci
447e41f4b71Sopenharmony_ciApplications using APIs earlier than version 9 are not affected. Applications using APIs of version 9 will fail to be compiled.
448e41f4b71Sopenharmony_ci
449e41f4b71Sopenharmony_ci**Key API/Component Changes**
450e41f4b71Sopenharmony_ci
451e41f4b71Sopenharmony_ciThe following table lists the installation-free API changes. For APIs not listed in the table, their names and usage are unchanged, but the module name is changed.
452e41f4b71Sopenharmony_ci
453e41f4b71Sopenharmony_ci| Deprecated                | Added or Changed in API Version 9         | System API|
454e41f4b71Sopenharmony_ci| -------------------- | ----------------------- | --------- |
455e41f4b71Sopenharmony_ci| setModuleUpgradeFlag | setHapModuleUpgradeFlag | Yes       |
456e41f4b71Sopenharmony_ci| isModuleRemovable    | isHapModuleRemovable    | Yes       |
457e41f4b71Sopenharmony_ci| getDispatcher        | getDispatchInfo         | Yes       |
458e41f4b71Sopenharmony_ci
459e41f4b71Sopenharmony_ci**Adaptation Guide**
460e41f4b71Sopenharmony_ci
461e41f4b71Sopenharmony_ciTo use installation-free APIs, import a new module and modify the APIs according to their mappings.
462e41f4b71Sopenharmony_ci
463e41f4b71Sopenharmony_ci```
464e41f4b71Sopenharmony_ciimport freeInstall from '@ohos.bundle.freeInstall'
465e41f4b71Sopenharmony_ci```
466e41f4b71Sopenharmony_ci
467e41f4b71Sopenharmony_ci## cl.bundlemanager.13 Installation-Free Structure Field Changes
468e41f4b71Sopenharmony_ciThe fields of the **DisPatchInfo**, **AbilityFormInfo**, **ModuleDistroInfo**, and **ModuleConfigInfo** structures are changed as follows:
469e41f4b71Sopenharmony_ci1. The name of the **dispatchAPI** field in **DispatchInfo** is changed to [dispatchAPIVersion](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/DispatchInfo.d.ts), and the type is string, which is unchanged. The field indicates the version of the installation-free API. The meaning remains unchanged.
470e41f4b71Sopenharmony_ci2. The type of the **supportDimensions** field in the **AbilityFormInfo** structure is changed from **Array\<number>** to **Array\<string>**.
471e41f4b71Sopenharmony_ci3. The type of the **defaultDimension** field in the **AbilityFormInfo** structure is changed from **number** to **string**.
472e41f4b71Sopenharmony_ci4. The **mainAbility** field is deprecated in the **ModuleDistroInfo** structure and moved to the **ModuleConfigInfo** structure.
473e41f4b71Sopenharmony_ci5. The **mainAbility** field is added to the **ModuleConfigInfo** structure.
474e41f4b71Sopenharmony_ci
475e41f4b71Sopenharmony_ci**Change Impacts**
476e41f4b71Sopenharmony_ci
477e41f4b71Sopenharmony_ciApplications using APIs earlier than version 9 are not affected. The value type of certain fields in the structures is changed. As a result, applications using APIs of version 9 may fail to be compiled using the new SDK.
478e41f4b71Sopenharmony_ci
479e41f4b71Sopenharmony_ci**Key API/Component Changes**
480e41f4b71Sopenharmony_ci
481e41f4b71Sopenharmony_ci1. DispatchInfo
482e41f4b71Sopenharmony_ci
483e41f4b71Sopenharmony_ci| Deprecated       | Added or Changed in API Version 9    | Type  |
484e41f4b71Sopenharmony_ci| ----------- | ------------------ | ------ |
485e41f4b71Sopenharmony_ci| dispatchAPI | dispatchAPIVersion | string |
486e41f4b71Sopenharmony_ci
487e41f4b71Sopenharmony_ci2. AbilityFormInfo
488e41f4b71Sopenharmony_ci
489e41f4b71Sopenharmony_ci| Field             | Type in API Version 9      | Original Type        |
490e41f4b71Sopenharmony_ci| ----------------- | -------------- | -------------- |
491e41f4b71Sopenharmony_ci| supportDimensions | Array\<string> | Array\<number> |
492e41f4b71Sopenharmony_ci| defaultDimension  | string         | number         |
493e41f4b71Sopenharmony_ci
494e41f4b71Sopenharmony_ci3. ModuleDistroInfo
495e41f4b71Sopenharmony_ci
496e41f4b71Sopenharmony_ci| Field       | Added or Changed in API Version 9| Type  |
497e41f4b71Sopenharmony_ci| ----------- | -------------- | ------ |
498e41f4b71Sopenharmony_ci| mainAbility | N/A            | string |
499e41f4b71Sopenharmony_ci
500e41f4b71Sopenharmony_ci4. MooduleConfigInfo
501e41f4b71Sopenharmony_ci
502e41f4b71Sopenharmony_ci| Field| Added or Changed in API Version 9| Type  |
503e41f4b71Sopenharmony_ci| ---- | -------------- | ------ |
504e41f4b71Sopenharmony_ci| N/A  | mainAbility    | string |
505e41f4b71Sopenharmony_ci
506e41f4b71Sopenharmony_ci**Adaptation Guide**
507e41f4b71Sopenharmony_ci
508e41f4b71Sopenharmony_ciTo use installation-free APIs, import a new module and modify the structures according to their mappings.
509e41f4b71Sopenharmony_ci
510e41f4b71Sopenharmony_ci```
511e41f4b71Sopenharmony_ciimport freeInstall from '@ohos.bundle.freeInstall'
512e41f4b71Sopenharmony_ci```
513e41f4b71Sopenharmony_ci
514e41f4b71Sopenharmony_ci## cl.bundlemanager.14 Structure Changes
515e41f4b71Sopenharmony_ciThe structure **GrantStatus** is changed to **PermissionGrantState**. The enumeration type and values remain unchanged.
516e41f4b71Sopenharmony_ci
517e41f4b71Sopenharmony_ci**Change Impacts**
518e41f4b71Sopenharmony_ci
519e41f4b71Sopenharmony_ciApplications using APIs earlier than version 9 are not affected. The structure name is changed. As a result, applications using APIs of version 9 may fail to be compiled using the new SDK.
520e41f4b71Sopenharmony_ci
521e41f4b71Sopenharmony_ci**Key API/Component Changes**
522e41f4b71Sopenharmony_ci
523e41f4b71Sopenharmony_ciThe **GrantStatus** structure indicating the authorization status is changed to **PermissionGrantState** in **@ohos.bundle.bundleManager.d.ts**.
524e41f4b71Sopenharmony_ci
525e41f4b71Sopenharmony_ci| Name            | Value|
526e41f4b71Sopenharmony_ci| ------------------ | ------ |
527e41f4b71Sopenharmony_ci| PERMISSION_DENIED  | -1     |
528e41f4b71Sopenharmony_ci| PERMISSION_GRANTED | 0      |
529e41f4b71Sopenharmony_ci
530e41f4b71Sopenharmony_ci**Adaptation Guide**
531e41f4b71Sopenharmony_ci
532e41f4b71Sopenharmony_ciImport a new module and change the structure name to **PermissionGrantState**.
533e41f4b71Sopenharmony_ci
534e41f4b71Sopenharmony_ci```
535e41f4b71Sopenharmony_ciimport bundle form '@ohos.bundle.bundleManager'
536e41f4b71Sopenharmony_ci```
537e41f4b71Sopenharmony_ci## cl.bundlemanager.15 Bundle Manager ShortcutInfo Structure Field Changes
538e41f4b71Sopenharmony_ciFields in the **ShortcutInfo** structure of the bundle manager are changed. The **bundle/shortcutInfo.d.ts** fields are deprecated, and the file is changed to [bundleManager/ShortcutInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ShortcutInfo.d.ts). The **ShortcutInfo** and **ShortWant** structures are changed to system APIs.
539e41f4b71Sopenharmony_ci
540e41f4b71Sopenharmony_ci**Change Impacts**
541e41f4b71Sopenharmony_ci
542e41f4b71Sopenharmony_ciApplications using APIs earlier than version 9 are not affected. The value type of certain fields in the structures is changed. As a result, applications using APIs of version 9 may fail to be compiled using the new SDK.
543e41f4b71Sopenharmony_ci
544e41f4b71Sopenharmony_ci**Key API/Component Changes**
545e41f4b71Sopenharmony_ci
546e41f4b71Sopenharmony_ciThe **ShortcutInfo** and **ShortcutWant** structures are involved. To use the level-2 module export function, import the new module **@ohos.bundle.launcherBundleManager**.
547e41f4b71Sopenharmony_ciThe following table lists the field changes of the **ShortcutInfo** structure. Fields that are not listed in the table still exist in API version 9.
548e41f4b71Sopenharmony_ci
549e41f4b71Sopenharmony_ci| Deprecated          | Added or Changed in API Version 9| Type   |
550e41f4b71Sopenharmony_ci| -------------- | -------------- | ------- |
551e41f4b71Sopenharmony_ci| disableMessage | N/A            | string  |
552e41f4b71Sopenharmony_ci| isStatic       | N/A            | boolean |
553e41f4b71Sopenharmony_ci| isHomeShortcut | N/A            | boolean |
554e41f4b71Sopenharmony_ci| isEnabled      | N/A            | boolean |
555e41f4b71Sopenharmony_ci| disableMessage | N/A            | boolean |
556e41f4b71Sopenharmony_ci
557e41f4b71Sopenharmony_ciThe following table lists the field changes of the **ShortcutWant** structure. Fields that are not listed in the table still exist in API version 9.
558e41f4b71Sopenharmony_ci| Deprecated       | Added or Changed in API Version 9| Type  |
559e41f4b71Sopenharmony_ci| ----------- | -------------- | ------ |
560e41f4b71Sopenharmony_ci| targetClass | targetAbility  | string |
561e41f4b71Sopenharmony_ci
562e41f4b71Sopenharmony_ci**Adaptation Guide**
563e41f4b71Sopenharmony_ci
564e41f4b71Sopenharmony_ciTo use installation-free APIs, import a new module and modify the structures according to their mappings.
565e41f4b71Sopenharmony_ci
566e41f4b71Sopenharmony_ci```
567e41f4b71Sopenharmony_ciimport launcherBundleManager form '@ohos.bundle.launcherBundleManager'
568e41f4b71Sopenharmony_ci```
569e41f4b71Sopenharmony_ci
570e41f4b71Sopenharmony_ci## cl.bundlemanager.16 getBundleInstaller API Changes
571e41f4b71Sopenharmony_ciThe **getBundleInstaller** API of the bundle manager is moved from **@ohos.bundle.d.ts** to [@ohos.bundle.installer.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.installer.d.ts).
572e41f4b71Sopenharmony_ciThe system capability is **SystemCapability.BundleManager.BundleFramework.Core**.
573e41f4b71Sopenharmony_ci
574e41f4b71Sopenharmony_ci**Change Impacts**
575e41f4b71Sopenharmony_ci
576e41f4b71Sopenharmony_ciApplications using APIs earlier than version 9 are not affected. Applications that use APIs of version 9 need to adapt the new module and APIs.
577e41f4b71Sopenharmony_ci
578e41f4b71Sopenharmony_ci**Key API/Component Changes**
579e41f4b71Sopenharmony_ci1. For **getBundleInstaller**, the import module is changed from **@ohos.bundle** to **@ohos.bundle.installer**.
580e41f4b71Sopenharmony_ci
581e41f4b71Sopenharmony_ci**Adaptation Guide**
582e41f4b71Sopenharmony_ci
583e41f4b71Sopenharmony_ciImport the new bundle manager installation module and call **getBundleInstaller**.
584e41f4b71Sopenharmony_ci
585e41f4b71Sopenharmony_ci```
586e41f4b71Sopenharmony_ciimport installer form '@ohos.bundle.installer'
587e41f4b71Sopenharmony_ci```
588e41f4b71Sopenharmony_ci
589e41f4b71Sopenharmony_ci## cl.bundlemanager.17 Bundle Manager Installation API Changes
590e41f4b71Sopenharmony_ciThe bundle manager installation API is moved from **bundle/bundleInstaller.d.ts** to [@ohos.bundle.installer.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.installer.d.ts). The system capability is **SystemCapability.BundleManager.BundleFramework.Core**.
591e41f4b71Sopenharmony_ci
592e41f4b71Sopenharmony_ci**Change Impacts**
593e41f4b71Sopenharmony_ci
594e41f4b71Sopenharmony_ciApplications using APIs earlier than version 9 are not affected. Applications that use APIs of version 9 need to adapt the new module and APIs.
595e41f4b71Sopenharmony_ci
596e41f4b71Sopenharmony_ci**Key API/Component Changes**
597e41f4b71Sopenharmony_ci
598e41f4b71Sopenharmony_ci1. The exception handling capability is added to the **install**, **uninstall**, and **recover** APIs. The API names and input parameters remain unchanged, and only the module name is changed.
599e41f4b71Sopenharmony_ci2. Fields are added to the **HashParam** structure as follows.
600e41f4b71Sopenharmony_ci
601e41f4b71Sopenharmony_ci| Added in API Version 9  | Type  |
602e41f4b71Sopenharmony_ci| ---------- | ------ |
603e41f4b71Sopenharmony_ci| moduleName | string |
604e41f4b71Sopenharmony_ci| hashValue  | string |
605e41f4b71Sopenharmony_ci
606e41f4b71Sopenharmony_ci3. Fields are added to the **InstallParam** structure as follows.
607e41f4b71Sopenharmony_ci
608e41f4b71Sopenharmony_ci| Added in API Version 9         | Type             |
609e41f4b71Sopenharmony_ci| ----------------- | ----------------- |
610e41f4b71Sopenharmony_ci| userId            | number            |
611e41f4b71Sopenharmony_ci| installFlag       | number            |
612e41f4b71Sopenharmony_ci| isKeepData        | boolean           |
613e41f4b71Sopenharmony_ci| hashParams        | Array\<HashParam> |
614e41f4b71Sopenharmony_ci| crowdtestDeadline | number            |
615e41f4b71Sopenharmony_ci
616e41f4b71Sopenharmony_ci4. The **InstallStatus** structure is deprecated.
617e41f4b71Sopenharmony_ci
618e41f4b71Sopenharmony_ci**Adaptation Guide**
619e41f4b71Sopenharmony_ci
620e41f4b71Sopenharmony_ciImport the new bundle manager installation module and call **getBundleInstaller**.
621e41f4b71Sopenharmony_ci
622e41f4b71Sopenharmony_ci```
623e41f4b71Sopenharmony_ciimport installer form '@ohos.bundle.installer'
624e41f4b71Sopenharmony_ci```
625e41f4b71Sopenharmony_ci
626e41f4b71Sopenharmony_ci## cl.bundlemanager.18 Bundle Manager Installation Function Changes
627e41f4b71Sopenharmony_ciThe installation specifications of the bundle manager module are changed, in which whether the application **deviceType** setting matches the device type is verified. If they do not match, the installation fails.
628e41f4b71Sopenharmony_ci
629e41f4b71Sopenharmony_ci**Change Impacts**
630e41f4b71Sopenharmony_ci
631e41f4b71Sopenharmony_ciApplications developed in earlier versions are affected. Applications can be successfully installed in the image of the new version only after adaptation.
632e41f4b71Sopenharmony_ci
633e41f4b71Sopenharmony_ci**Key API/Component Changes**
634e41f4b71Sopenharmony_ci
635e41f4b71Sopenharmony_ciN/A
636e41f4b71Sopenharmony_ci
637e41f4b71Sopenharmony_ci**Adaptation Guide**
638e41f4b71Sopenharmony_ci
639e41f4b71Sopenharmony_ciConfigure device types in the application configuration file **config.json** or **module.json**.
640e41f4b71Sopenharmony_ci
641e41f4b71Sopenharmony_ci```
642e41f4b71Sopenharmony_ci{
643e41f4b71Sopenharmony_ci    "module": {
644e41f4b71Sopenharmony_ci        "name": "entry",
645e41f4b71Sopenharmony_ci        "type": "entry",
646e41f4b71Sopenharmony_ci        // ...
647e41f4b71Sopenharmony_ci        "deviceTypes":[
648e41f4b71Sopenharmony_ci            // In this example, default and tablet are configured. In this case, the application can be installed on default and tablet.
649e41f4b71Sopenharmony_ci            "default",
650e41f4b71Sopenharmony_ci            "tablet"
651e41f4b71Sopenharmony_ci        ],
652e41f4b71Sopenharmony_ci        // ...
653e41f4b71Sopenharmony_ci    }
654e41f4b71Sopenharmony_ci```
655e41f4b71Sopenharmony_ci## cl.bundlemanager.19 innerBundleManger Module API Changes
656e41f4b71Sopenharmony_ci**innerBundleManager** API functions are unchanged, but API usage is changed. The [@ohos.bundle.launcherBundleManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.launcherBundleManager.d.ts) module needs to be imported to use **innerBundleManager** APIs. The system capability is **SystemCapability.BundleManager.BundleFramework.Core**.
657e41f4b71Sopenharmony_ci
658e41f4b71Sopenharmony_ci**Change Impacts**
659e41f4b71Sopenharmony_ci
660e41f4b71Sopenharmony_ciThere is no impact on applications that use the APIs of versions earlier than 9. Applications that use the **innerBundleManager** API capabilities need to adapt the new module and APIs.
661e41f4b71Sopenharmony_ci
662e41f4b71Sopenharmony_ci**Key API/Component Changes**
663e41f4b71Sopenharmony_ci
664e41f4b71Sopenharmony_ciThe functions and input parameters of the following APIs remain unchanged, and API exception handling is added. When a level-2 module is used to export **ShortcutInfo** and **ShortcutWant**, the **@ohos.bundle.launcherBundleManager** module needs to be imported. The **on** and **off** APIs are deprecated from **@ohos.bundle.innerBundleManger.d.ts** and moved to **@ohos.bundle.bundleMonitor.d.ts**.
665e41f4b71Sopenharmony_ci
666e41f4b71Sopenharmony_ci1. getLauncherAbilityInfos<br>
667e41f4b71Sopenharmony_ci2. getAllLauncherAbilityInfos<br>
668e41f4b71Sopenharmony_ci3. getShortcutInfos
669e41f4b71Sopenharmony_ci
670e41f4b71Sopenharmony_ci**Adaptation Guide**
671e41f4b71Sopenharmony_ci
672e41f4b71Sopenharmony_ciImport the new module **@ohos.bundle.launcherBundleManage**.
673e41f4b71Sopenharmony_ci
674e41f4b71Sopenharmony_ci```
675e41f4b71Sopenharmony_ciimport launcherBundleManager form '@ohos.bundle.launcherBundleManage'
676e41f4b71Sopenharmony_ci```
677e41f4b71Sopenharmony_ci
678e41f4b71Sopenharmony_ci## cl.bundlemanager.20 innerBundleManagr Module Changes
679e41f4b71Sopenharmony_ci**innerBundleManager** API functions are unchanged, but API usage is changed. The [@ohos.bundle.bundleMonitor.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.bundleMonitor.d.ts) module needs to be imported to use **innerBundleManager** APIs, which are system APIs. The system capability is **SystemCapability.BundleManager.BundleFramework.Core**.
680e41f4b71Sopenharmony_ci
681e41f4b71Sopenharmony_ci**Change Impacts**
682e41f4b71Sopenharmony_ci
683e41f4b71Sopenharmony_ciThere is no impact on applications that use the APIs of versions earlier than 9. Applications that use the **innerBundleManager** API capabilities need to adapt the new module and APIs.
684e41f4b71Sopenharmony_ci
685e41f4b71Sopenharmony_ci**Key API/Component Changes**
686e41f4b71Sopenharmony_ci
687e41f4b71Sopenharmony_ciThe **on** and **off** APIs are changed to **@ohos.bundle.bundleMonitor.d.ts**. The input parameters are different from those of the original APIs. The function prototype of the APIs of version 9 is as follows:
688e41f4b71Sopenharmony_ci
689e41f4b71Sopenharmony_ci```
690e41f4b71Sopenharmony_cifunction on(type: BundleChangedEvent, callback: Callback<BundleChangedInfo>): void;
691e41f4b71Sopenharmony_cifunction off(type: BundleChangedEvent, callback?: Callback<BundleChangedInfo>): void;
692e41f4b71Sopenharmony_ci```
693e41f4b71Sopenharmony_ci**BundleChangedEvent**:
694e41f4b71Sopenharmony_ci
695e41f4b71Sopenharmony_ci```
696e41f4b71Sopenharmony_citype BundleChangedEvent = 'add' | 'update' | 'remove';
697e41f4b71Sopenharmony_ci```
698e41f4b71Sopenharmony_ciCallback function of **BundleChangedInfo**:
699e41f4b71Sopenharmony_ci```
700e41f4b71Sopenharmony_ci  interface BundleChangedInfo {
701e41f4b71Sopenharmony_ci    readonly bundleName: string;
702e41f4b71Sopenharmony_ci    readonly userId: number;
703e41f4b71Sopenharmony_ci  }
704e41f4b71Sopenharmony_ci```
705e41f4b71Sopenharmony_ciAfter obtaining **BundleChangedInfo**, perform related operations (that is, the **add**, **update**, and **remove** functions in **BundleStatusCallback** of the original API).
706e41f4b71Sopenharmony_ci
707e41f4b71Sopenharmony_ci**Adaptation Guide**
708e41f4b71Sopenharmony_ci
709e41f4b71Sopenharmony_ciImport the **bundleMonitor** module and call related APIs.
710e41f4b71Sopenharmony_ci
711e41f4b71Sopenharmony_ci```
712e41f4b71Sopenharmony_ciimport bundleMonitor form '@ohos.bundle.bundleMonitor'
713e41f4b71Sopenharmony_ci```
714e41f4b71Sopenharmony_ci
715e41f4b71Sopenharmony_ci## cl.bundlemanager.21 bundleStatusCallback.d.ts API Changes
716e41f4b71Sopenharmony_ciThe **bundleStatusCallback.d.ts** APIs of the bundle manager are deprecated and moved to [@ohos.bundle.bundleMonitor.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.bundleMonitor.d.ts). The **add**, **update**, and **remove** functions in **BundleStatusCallback** are deprecated and changed to **BundleChangedEvent**, which is a system API. The system capability is **SystemCapability.BundleManager.BundleFramework.Core**.
717e41f4b71Sopenharmony_ci
718e41f4b71Sopenharmony_ci**Change Impacts**
719e41f4b71Sopenharmony_ci
720e41f4b71Sopenharmony_ciThere is no impact on applications that use the APIs of versions earlier than 9. Applications that use the **BundleStatusCallback** API capabilities need to adapt the new module and APIs.
721e41f4b71Sopenharmony_ci
722e41f4b71Sopenharmony_ci**Key API/Component Changes**
723e41f4b71Sopenharmony_ci
724e41f4b71Sopenharmony_ciAll the following functions are deprecated. The **BundleChangedEvent** API is added to **@ohos.bundle.bundleMonitor.d.ts**.
725e41f4b71Sopenharmony_ci
726e41f4b71Sopenharmony_ci1. add
727e41f4b71Sopenharmony_ci2. update
728e41f4b71Sopenharmony_ci3. remove
729e41f4b71Sopenharmony_ci
730e41f4b71Sopenharmony_ci**Adaptation Guide**
731e41f4b71Sopenharmony_ci
732e41f4b71Sopenharmony_ciImport the **bundleMonitor** module and call related APIs. Different from the previous **BundleStatusCallback**, **BundleStatusCallback** passes the **add**, **update**, and **remove** functions to the **on** and **off** APIs. The **BundleMonitor** uses the **on** or **off** API of version 9 to return **BundleChangedInfo** to the caller through the callback.
733e41f4b71Sopenharmony_ci
734e41f4b71Sopenharmony_ci```
735e41f4b71Sopenharmony_ciimport bundleMonitor form '@ohos.bundle.bundleMonitor'
736e41f4b71Sopenharmony_ci```
737e41f4b71Sopenharmony_ci
738e41f4b71Sopenharmony_ci## cl.bundlemanager.22 Zlib Module API Changes
739e41f4b71Sopenharmony_ciThe **Zlib** module APIs of the bundle manager are changed. Certain APIs in [@ohos.zlib.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.zlib.d.ts) are deprecated and changed. The system capability is **SystemCapability.BundleManager.Zlib**.
740e41f4b71Sopenharmony_ci
741e41f4b71Sopenharmony_ci**Change Impacts**
742e41f4b71Sopenharmony_ci
743e41f4b71Sopenharmony_ciThere is no impact on applications that use the APIs of versions earlier than 9. Applications that use APIs of version 9 need to adapt the new module and APIs.
744e41f4b71Sopenharmony_ci
745e41f4b71Sopenharmony_ci**Key API/Component Changes**
746e41f4b71Sopenharmony_ci
747e41f4b71Sopenharmony_ciThe following table lists the changed APIs in **@ohos.zlib.d.ts**. The usage of the new APIs of version 9 is the same, and API exception handling is supported.
748e41f4b71Sopenharmony_ci
749e41f4b71Sopenharmony_ci| Deprecated     | Added or Changed in API Version 9| System API|
750e41f4b71Sopenharmony_ci| --------- | -------------- | --------- |
751e41f4b71Sopenharmony_ci| zipFile   | compressFile   | Yes       |
752e41f4b71Sopenharmony_ci| unzipFile | decompressFile | Yes       |
753e41f4b71Sopenharmony_ci| ErrorCode | N/A            | Yes       |
754e41f4b71Sopenharmony_ci
755e41f4b71Sopenharmony_ci**Adaptation Guide**
756e41f4b71Sopenharmony_ci
757e41f4b71Sopenharmony_ciThe import module does not change. The new API is directly used to adapt exception handling.
758e41f4b71Sopenharmony_ci
759e41f4b71Sopenharmony_ci```
760e41f4b71Sopenharmony_ciimport zlib form '@ohos.zlib'
761e41f4b71Sopenharmony_ci```