1e41f4b71Sopenharmony_ci# AbilityInfo
2e41f4b71Sopenharmony_ci
3e41f4b71Sopenharmony_ciThe **AbilityInfo** module defines the ability information. A third-party application can obtain its own ability information through [bundleManager.getBundleInfoForSelf](js-apis-bundleManager.md#bundlemanagergetbundleinfoforself), with **GET_BUNDLE_INFO_WITH_HAP_MODULE** and **GET_BUNDLE_INFO_WITH_ABILITY** passed in to [bundleFlags](js-apis-bundleManager.md#bundleflag).
4e41f4b71Sopenharmony_ci
5e41f4b71Sopenharmony_ci> **NOTE**
6e41f4b71Sopenharmony_ci>
7e41f4b71Sopenharmony_ci> The initial APIs of this module are supported since API version 9. Newly added APIs will be marked with a superscript to indicate their earliest API version.
8e41f4b71Sopenharmony_ci
9e41f4b71Sopenharmony_ci## AbilityInfo
10e41f4b71Sopenharmony_ci
11e41f4b71Sopenharmony_ci**System capability**: SystemCapability.BundleManager.BundleFramework.Core
12e41f4b71Sopenharmony_ci
13e41f4b71Sopenharmony_ci| Name                 | Type                                                    | Read-Only| Optional| Description                                     |
14e41f4b71Sopenharmony_ci| --------------------- | -------------------------------------------------------- | ---- | ---- | ------------------------------------------ |
15e41f4b71Sopenharmony_ci| bundleName            | string                                                   | Yes  | No  | Bundle name.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
16e41f4b71Sopenharmony_ci| moduleName            | string                                                   | Yes  | No  | Name of the HAP file to which the ability belongs.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
17e41f4b71Sopenharmony_ci| name                  | string                                                   | Yes  | No  | Ability name.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
18e41f4b71Sopenharmony_ci| label                 | string                                                   | Yes  | No  | Resource descriptor of the ability name visible to users. Example: **"label": "$string: mainability_description"**.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
19e41f4b71Sopenharmony_ci| labelId               | number                                                   | Yes  | No  | ID of the ability label.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
20e41f4b71Sopenharmony_ci| description           | string                                                   | Yes  | No  | Ability description.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
21e41f4b71Sopenharmony_ci| descriptionId         | number                                                   | Yes  | No  | ID of the ability description.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
22e41f4b71Sopenharmony_ci| icon                  | string                                                   | Yes  | No  | Resource descriptor of the ability icon. Example: **"icon": "$media:icon"**.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
23e41f4b71Sopenharmony_ci| iconId                | number                                                   | Yes  | No  | ID of the ability icon.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
24e41f4b71Sopenharmony_ci| process               | string                                                   | Yes  | No  | Process in which the ability runs. If this parameter is not set, the bundle name is used.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
25e41f4b71Sopenharmony_ci| exported             | boolean                                                  | Yes  | No  | Whether the ability can be called by other bundles.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
26e41f4b71Sopenharmony_ci| type                  | [bundleManager.AbilityType](js-apis-bundleManager.md#abilitytype)      | Yes  | No  | Ability type.<br>**Model restriction**: This API can be used only in the FA model.|
27e41f4b71Sopenharmony_ci| orientation           | [bundleManager.DisplayOrientation](js-apis-bundleManager.md#displayorientation)  | Yes  | No  | Ability display orientation.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
28e41f4b71Sopenharmony_ci| launchType            | [bundleManager.LaunchType](js-apis-bundleManager.md#launchtype)        | Yes  | No  | Ability launch mode.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
29e41f4b71Sopenharmony_ci| permissions           | Array\<string>                                           | Yes  | No  | Permissions required for other applications to call the ability.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
30e41f4b71Sopenharmony_ci| readPermission        | string                                                   | Yes  | No  | Permission required for reading the ability data.<br>**Model restriction**: This API can be used only in the FA model.|
31e41f4b71Sopenharmony_ci| writePermission       | string                                                   | Yes  | No  | Permission required for writing data to the ability.<br>**Model restriction**: This API can be used only in the FA model.|
32e41f4b71Sopenharmony_ci| uri                   | string                                                   | Yes  | No  | URI of the ability.<br>**Model restriction**: This API can be used only in the FA model.|
33e41f4b71Sopenharmony_ci| deviceTypes           | Array\<string>                                           | Yes  | No  | Device types supported by the ability.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
34e41f4b71Sopenharmony_ci| applicationInfo       | [ApplicationInfo](js-apis-bundleManager-applicationInfo.md)     | Yes  | No  | Application information. The information can be obtained by passing in **GET_BUNDLE_INFO_WITH_HAP_MODULE**, **GET_BUNDLE_INFO_WITH_ABILITY**, and **GET_BUNDLE_INFO_WITH_APPLICATION** to the **bundleFlags** parameter of [getBundleInfoForSelf](js-apis-bundleManager.md#bundlemanagergetbundleinfoforself).<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
35e41f4b71Sopenharmony_ci| metadata              | Array\<[Metadata](js-apis-bundleManager-metadata.md)>           | Yes  | No  | Metadata of the ability. The information can be obtained by passing in **GET_BUNDLE_INFO_WITH_HAP_MODULE**, **GET_BUNDLE_INFO_WITH_ABILITY**, and **GET_BUNDLE_INFO_WITH_METADATA** to the **bundleFlags** parameter of [getBundleInfoForSelf](js-apis-bundleManager.md#bundlemanagergetbundleinfoforself).<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
36e41f4b71Sopenharmony_ci| enabled               | boolean                                                  | Yes  | No  | Whether the ability is enabled.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
37e41f4b71Sopenharmony_ci| supportWindowModes    | Array\<[bundleManager.SupportWindowMode](js-apis-bundleManager.md#supportwindowmode)> | Yes  | No  | Window modes supported by the ability.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
38e41f4b71Sopenharmony_ci| windowSize|[WindowSize](#windowsize)                                            |    Yes  | No  | Window size.<br>**Atomic service API**: This API can be used in atomic services since API version 11.|
39e41f4b71Sopenharmony_ci| excludeFromDock<sup>12+</sup>             | boolean                                                  | Yes  | No  | Whether the ability can hide icons in the dock area.<br>**Atomic service API**: This API can be used in atomic services since API version 12.|
40e41f4b71Sopenharmony_ci| skills<sup>12+</sup>             | Array\<[Skill](js-apis-bundleManager-skill.md)>                                                 | Yes  | No  | Skills of the ability.<br>**Atomic service API**: This API can be used in atomic services since API version 12.  |
41e41f4b71Sopenharmony_ci| appIndex<sup>12+</sup>    | number    | Yes  | No  | Index of an application clone. It takes effect only for cloned applications.|
42e41f4b71Sopenharmony_ci
43e41f4b71Sopenharmony_ci## WindowSize
44e41f4b71Sopenharmony_ci
45e41f4b71Sopenharmony_ciDescribes the window size.
46e41f4b71Sopenharmony_ci
47e41f4b71Sopenharmony_ci<br>**Atomic service API**: This API can be used in atomic services since API version 11.
48e41f4b71Sopenharmony_ci
49e41f4b71Sopenharmony_ci**System capability**: SystemCapability.BundleManager.BundleFramework.Core
50e41f4b71Sopenharmony_ci
51e41f4b71Sopenharmony_ci| Name              | Type   | Read-Only| Optional| Description                              |
52e41f4b71Sopenharmony_ci| -------------------| ------- | ---- | ---- | ---------------------------------- |
53e41f4b71Sopenharmony_ci| maxWindowRatio     | number  | Yes  | No  | Maximum aspect ratio of the window in free window mode. The value ranges from 0 to 1.|
54e41f4b71Sopenharmony_ci| minWindowRatio     | number  | Yes  | No  | Minimum aspect ratio of the window in free window mode. The value ranges from 0 to 1.|
55e41f4b71Sopenharmony_ci| maxWindowWidth     | number  | Yes  | No  | Maximum width of the window in free window mode. The unit is vp.|
56e41f4b71Sopenharmony_ci| minWindowWidth     | number  | Yes  | No  | Minimum width of the window in free window mode. The unit is vp.|
57e41f4b71Sopenharmony_ci| maxWindowHeight    | number  | Yes  | No  | Maximum height of the window in free window mode. The unit is vp.|
58e41f4b71Sopenharmony_ci| minWindowHeight    | number  | Yes  | No  | Minimum height of the window in free window mode. The unit is vp.|
59