• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# NotificationSubscribeInfo (System API)
2<!--Kit: Notification Kit-->
3<!--Subsystem: Notification-->
4<!--Owner: @michael_woo888-->
5<!--Designer: @dongqingran; @wulong158-->
6<!--Tester: @wanghong1997-->
7<!--Adviser: @huipeizi-->
8
9The **NotificationSubscribeInfo** module provides APIs for defining the information about the publisher for notification subscription.
10
11> **NOTE**
12>
13> The initial APIs of this module are supported since API version 7. Newly added APIs will be marked with a superscript to indicate their earliest API version.
14>
15> The APIs provided by this module are system APIs.
16
17## NotificationSubscribeInfo
18
19**System capability**: SystemCapability.Notification.Notification
20
21**System API**: This is a system API.
22
23| Name                | Type                 | Read-Only| Optional| Description                                      |
24| -------------------- | --------------------- | ---- | --- | ------------------------------------------ |
25| bundleNames          | Array<string\>         | No| Yes| Bundle names of the applications whose notifications are to be subscribed to.                             |
26| userId               | number                | No| Yes | User ID.                                     |
27| deviceType<sup>12+</sup>           | string                | No| Yes| Device type. The value is obtained based on [device information](../apis-basic-services-kit/js-apis-device-info.md).                                   |
28| slotTypes<sup>18+</sup>   | Array<[notificationManager.SlotType](js-apis-notificationManager.md#slottype)\>| No| Yes| Types of the notification slot.|
29| filterLimit<sup>18+</sup>   | number| No| Yes| Notification filtering range. The options are as follows:<br>- **0**: All notifications are subscribed.<br>- **1**: Filter out notifications whose slot type is [SOCIAL_COMMUNICATION](js-apis-notificationManager.md#slottype) and [userInput](js-apis-inner-notification-notificationActionButton.md#notificationactionbutton) is empty.<br>- **2**: Filter out notifications whose slot type is [SOCIAL_COMMUNICATION](js-apis-notificationManager.md#slottype) and [userInput](js-apis-inner-notification-notificationActionButton.md#notificationactionbutton) is not empty.|
30