1e41f4b71Sopenharmony_ci# @ohos.ability.wantConstant (wantConstant) 2e41f4b71Sopenharmony_ci 3e41f4b71Sopenharmony_ciThe **wantConstant** module provides the actions, entities, and flags used in **Want** objects. 4e41f4b71Sopenharmony_ci 5e41f4b71Sopenharmony_ci> **NOTE** 6e41f4b71Sopenharmony_ci> 7e41f4b71Sopenharmony_ci> The APIs of this module are supported since API version 6 and deprecated since API version 9. You are advised to use [@ohos.app.ability.wantConstant](js-apis-app-ability-wantConstant.md) instead. Newly added APIs will be marked with a superscript to indicate their earliest API version. 8e41f4b71Sopenharmony_ci 9e41f4b71Sopenharmony_ci## Modules to Import 10e41f4b71Sopenharmony_ci 11e41f4b71Sopenharmony_ci```ts 12e41f4b71Sopenharmony_ciimport wantConstant from '@ohos.ability.wantConstant'; 13e41f4b71Sopenharmony_ci``` 14e41f4b71Sopenharmony_ci 15e41f4b71Sopenharmony_ci## Action 16e41f4b71Sopenharmony_ci 17e41f4b71Sopenharmony_ciEnumerates the action constants of the **Want** object. **action** specifies the operation to execute. 18e41f4b71Sopenharmony_ci 19e41f4b71Sopenharmony_ci**System capability**: SystemCapability.Ability.AbilityBase 20e41f4b71Sopenharmony_ci 21e41f4b71Sopenharmony_ci| Name | Value | Description | 22e41f4b71Sopenharmony_ci| ------------ | ------------------ | ---------------------- | 23e41f4b71Sopenharmony_ci| ACTION_HOME | ohos.want.action.home | Action of returning to the home page. | 24e41f4b71Sopenharmony_ci| ACTION_DIAL | ohos.want.action.dial | Action of launching the numeric keypad. | 25e41f4b71Sopenharmony_ci| ACTION_SEARCH | ohos.want.action.search | Action of launching the search function. | 26e41f4b71Sopenharmony_ci| ACTION_WIRELESS_SETTINGS | ohos.settings.wireless | Action of launching the UI that provides wireless network settings, for example, Wi-Fi options. | 27e41f4b71Sopenharmony_ci| ACTION_MANAGE_APPLICATIONS_SETTINGS | ohos.settings.manage.applications | Action of launching the UI for managing installed applications. | 28e41f4b71Sopenharmony_ci| ACTION_APPLICATION_DETAILS_SETTINGS | ohos.settings.application.details | Action of launching the UI that displays the details of an application. | 29e41f4b71Sopenharmony_ci| ACTION_SET_ALARM | ohos.want.action.setAlarm | Action of launching the UI for setting the alarm clock. | 30e41f4b71Sopenharmony_ci| ACTION_SHOW_ALARMS | ohos.want.action.showAlarms | Action of launching the UI that displays all alarms. | 31e41f4b71Sopenharmony_ci| ACTION_SNOOZE_ALARM | ohos.want.action.snoozeAlarm | Action of launching the UI for snoozing an alarm. | 32e41f4b71Sopenharmony_ci| ACTION_DISMISS_ALARM | ohos.want.action.dismissAlarm | Action of launching the UI for deleting an alarm. | 33e41f4b71Sopenharmony_ci| ACTION_DISMISS_TIMER | ohos.want.action.dismissTimer | Action of launching the UI for dismissing a timer. | 34e41f4b71Sopenharmony_ci| ACTION_SEND_SMS | ohos.want.action.sendSms | Action of launching the UI for sending an SMS message. | 35e41f4b71Sopenharmony_ci| ACTION_CHOOSE | ohos.want.action.choose | Action of launching the UI for opening a contact or picture. | 36e41f4b71Sopenharmony_ci| ACTION_IMAGE_CAPTURE<sup>8+</sup> | ohos.want.action.imageCapture | Action of launching the UI for photographing. | 37e41f4b71Sopenharmony_ci| ACTION_VIDEO_CAPTURE<sup>8+</sup> | ohos.want.action.videoCapture | Action of launching the UI for shooting a video. | 38e41f4b71Sopenharmony_ci| ACTION_SELECT | ohos.want.action.select | Action of launching the UI for application selection. | 39e41f4b71Sopenharmony_ci| ACTION_SEND_DATA | ohos.want.action.sendData | Action of launching the UI for sending a single data record. | 40e41f4b71Sopenharmony_ci| ACTION_SEND_MULTIPLE_DATA | ohos.want.action.sendMultipleData | Action of launching the UI for sending multiple data records. | 41e41f4b71Sopenharmony_ci| ACTION_SCAN_MEDIA_FILE | ohos.want.action.scanMediaFile | Action of requesting a media scanner to scan a file and add the file to the media library. | 42e41f4b71Sopenharmony_ci| ACTION_VIEW_DATA | ohos.want.action.viewData | Action of viewing data. | 43e41f4b71Sopenharmony_ci| ACTION_EDIT_DATA | ohos.want.action.editData | Action of editing data. | 44e41f4b71Sopenharmony_ci| INTENT_PARAMS_INTENT | ability.want.params.INTENT | Action of displaying selection options with an action selector. | 45e41f4b71Sopenharmony_ci| INTENT_PARAMS_TITLE | ability.want.params.TITLE | Title of the character sequence dialog box used with the action selector. | 46e41f4b71Sopenharmony_ci| ACTION_FILE_SELECT<sup>7+</sup> | ohos.action.fileSelect | Action of selecting a file. | 47e41f4b71Sopenharmony_ci| PARAMS_STREAM<sup>7+</sup> | ability.params.stream | URI of the data stream associated with the target when the data is sent. The value must be an array of the string type. | 48e41f4b71Sopenharmony_ci| ACTION_APP_ACCOUNT_OAUTH <sup>8+</sup> | ohos.account.appAccount.action.oauth | Action of providing the OAuth service. | 49e41f4b71Sopenharmony_ci 50e41f4b71Sopenharmony_ci 51e41f4b71Sopenharmony_ci## Entity 52e41f4b71Sopenharmony_ci 53e41f4b71Sopenharmony_ciEnumerates the entity constants of the **Want** object. **entity** specifies additional information of the target ability. 54e41f4b71Sopenharmony_ci 55e41f4b71Sopenharmony_ci**System capability**: SystemCapability.Ability.AbilityBase 56e41f4b71Sopenharmony_ci 57e41f4b71Sopenharmony_ci| Name | Value | Description | 58e41f4b71Sopenharmony_ci| ------------ | ------------------ | ---------------------- | 59e41f4b71Sopenharmony_ci| ENTITY_DEFAULT | entity.system.default | Default entity. The default entity is used if no entity is specified. | 60e41f4b71Sopenharmony_ci| ENTITY_HOME | entity.system.home | Home screen entity. | 61e41f4b71Sopenharmony_ci| ENTITY_VOICE | entity.system.voice | Voice interaction entity. | 62e41f4b71Sopenharmony_ci| ENTITY_BROWSABLE | entity.system.browsable | Browser type entity. | 63e41f4b71Sopenharmony_ci| ENTITY_VIDEO | entity.system.video | Video type entity. | 64e41f4b71Sopenharmony_ci 65e41f4b71Sopenharmony_ci 66e41f4b71Sopenharmony_ci## Flags 67e41f4b71Sopenharmony_ci 68e41f4b71Sopenharmony_ci Enumerates the flags that specify how the Want will be handled. 69e41f4b71Sopenharmony_ci 70e41f4b71Sopenharmony_ci**System capability**: SystemCapability.Ability.AbilityBase 71e41f4b71Sopenharmony_ci 72e41f4b71Sopenharmony_ci| Name | Value | Description | 73e41f4b71Sopenharmony_ci| ------------------------------------ | ---------- | ------------------------------------------------------------ | 74e41f4b71Sopenharmony_ci| FLAG_AUTH_READ_URI_PERMISSION | 0x00000001 | Grants the permission to read the URI. | 75e41f4b71Sopenharmony_ci| FLAG_AUTH_WRITE_URI_PERMISSION | 0x00000002 | Grants the permission to write data to the URI. | 76e41f4b71Sopenharmony_ci| FLAG_ABILITY_FORWARD_RESULT | 0x00000004 | Returns the result to the ability. | 77e41f4b71Sopenharmony_ci| FLAG_ABILITY_CONTINUATION | 0x00000008 | Indicates whether the ability on the local device can be continued on a remote device. | 78e41f4b71Sopenharmony_ci| FLAG_NOT_OHOS_COMPONENT | 0x00000010 | Indicates that a component does not belong to OHOS. | 79e41f4b71Sopenharmony_ci| FLAG_ABILITY_FORM_ENABLED | 0x00000020 | Indicates that an ability is enabled. | 80e41f4b71Sopenharmony_ci| FLAG_ABILITYSLICE_MULTI_DEVICE | 0x00000100 | Indicates the support for cross-device startup in the distributed scheduler. | 81e41f4b71Sopenharmony_ci| FLAG_START_FOREGROUND_ABILITY | 0x00000200 | Indicates that the ServiceAbility is started regardless of whether the host application has been started. | 82e41f4b71Sopenharmony_ci| FLAG_INSTALL_ON_DEMAND | 0x00000800 | Indicates that the specific ability will be installed if it has not been installed. | 83e41f4b71Sopenharmony_ci| FLAG_INSTALL_WITH_BACKGROUND_MODE | 0x80000000 | Indicates that the specific ability will be installed in the background if it has not been installed. | 84e41f4b71Sopenharmony_ci| FLAG_ABILITY_CLEAR_MISSION | 0x00008000 | Clears other operation missions. This flag can be set for **Want** passed in [startAbility](js-apis-ability-featureAbility.md#startability). It must be used together with **FLAG_ABILITY_NEW_MISSION**.| 85e41f4b71Sopenharmony_ci| FLAG_ABILITY_NEW_MISSION | 0x10000000 | Creates a mission on the history mission stack. | 86e41f4b71Sopenharmony_ci| FLAG_ABILITY_MISSION_TOP | 0x20000000 | Reuses an ability instance if it is on the top of an existing mission stack; creates an ability instance otherwise.| 87