@azure/notification-hubs 1.0.0-beta.5 → 1.0.0-beta.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (245) hide show
  1. package/README.md +104 -113
  2. package/dist/index.cjs +625 -602
  3. package/dist/index.cjs.map +1 -1
  4. package/dist-esm/src/api/beginSubmitNotificationHubJob.js +131 -0
  5. package/dist-esm/src/api/beginSubmitNotificationHubJob.js.map +1 -0
  6. package/dist-esm/src/{client → api}/cancelScheduledNotification.js +1 -1
  7. package/dist-esm/src/api/cancelScheduledNotification.js.map +1 -0
  8. package/dist-esm/src/{client → api}/createOrUpdateInstallation.js +1 -1
  9. package/dist-esm/src/api/createOrUpdateInstallation.js.map +1 -0
  10. package/dist-esm/src/{client → api}/createOrUpdateRegistration.js +1 -1
  11. package/dist-esm/src/api/createOrUpdateRegistration.js.map +1 -0
  12. package/dist-esm/src/{client → api}/createRegistration.js +1 -1
  13. package/dist-esm/src/api/createRegistration.js.map +1 -0
  14. package/dist-esm/src/{client → api}/createRegistrationId.js +1 -1
  15. package/dist-esm/src/api/createRegistrationId.js.map +1 -0
  16. package/dist-esm/src/{client → api}/deleteInstallation.js +1 -1
  17. package/dist-esm/src/api/deleteInstallation.js.map +1 -0
  18. package/dist-esm/src/{client → api}/deleteRegistration.js +1 -1
  19. package/dist-esm/src/api/deleteRegistration.js.map +1 -0
  20. package/dist-esm/src/{client → api}/getFeedbackContainerUrl.js +1 -1
  21. package/dist-esm/src/api/getFeedbackContainerUrl.js.map +1 -0
  22. package/dist-esm/src/{client → api}/getInstallation.js +1 -1
  23. package/dist-esm/src/api/getInstallation.js.map +1 -0
  24. package/dist-esm/src/{client → api}/getNotificationHubJob.js +1 -1
  25. package/dist-esm/src/api/getNotificationHubJob.js.map +1 -0
  26. package/dist-esm/src/{client → api}/getNotificationOutcomeDetails.js +1 -1
  27. package/dist-esm/src/api/getNotificationOutcomeDetails.js.map +1 -0
  28. package/dist-esm/src/{client → api}/getRegistration.js +1 -1
  29. package/dist-esm/src/api/getRegistration.js.map +1 -0
  30. package/dist-esm/src/{client → api}/index.js +24 -2
  31. package/dist-esm/src/api/index.js.map +1 -0
  32. package/dist-esm/src/{client → api}/internal/_client.js +1 -1
  33. package/dist-esm/src/api/internal/_client.js.map +1 -0
  34. package/dist-esm/src/{client → api}/internal/_createOrUpdateRegistrationDescription.js +0 -0
  35. package/dist-esm/src/api/internal/_createOrUpdateRegistrationDescription.js.map +1 -0
  36. package/dist-esm/src/{client/listRegistrations.js → api/internal/_listRegistrations.js} +6 -38
  37. package/dist-esm/src/api/internal/_listRegistrations.js.map +1 -0
  38. package/dist-esm/src/{client → api}/listNotificationHubJobs.js +1 -1
  39. package/dist-esm/src/api/listNotificationHubJobs.js.map +1 -0
  40. package/dist-esm/src/api/listRegistrations.js +35 -0
  41. package/dist-esm/src/api/listRegistrations.js.map +1 -0
  42. package/dist-esm/src/api/listRegistrationsByChannel.js +58 -0
  43. package/dist-esm/src/api/listRegistrationsByChannel.js.map +1 -0
  44. package/dist-esm/src/{client → api}/listRegistrationsByTag.js +1 -1
  45. package/dist-esm/src/api/listRegistrationsByTag.js.map +1 -0
  46. package/dist-esm/src/api/scheduleNotification.js +31 -0
  47. package/dist-esm/src/api/scheduleNotification.js.map +1 -0
  48. package/dist-esm/src/api/sendNotification.js +63 -0
  49. package/dist-esm/src/api/sendNotification.js.map +1 -0
  50. package/dist-esm/src/{client → api}/submitNotificationHubJob.js +1 -1
  51. package/dist-esm/src/api/submitNotificationHubJob.js.map +1 -0
  52. package/dist-esm/src/{client → api}/updateInstallation.js +1 -1
  53. package/dist-esm/src/api/updateInstallation.js.map +1 -0
  54. package/dist-esm/src/{client → api}/updateRegistration.js +1 -1
  55. package/dist-esm/src/api/updateRegistration.js.map +1 -0
  56. package/dist-esm/src/index.js +3 -2
  57. package/dist-esm/src/index.js.map +1 -1
  58. package/dist-esm/src/models/index.js +12 -0
  59. package/dist-esm/src/models/index.js.map +1 -0
  60. package/dist-esm/src/models/installation.js.map +1 -1
  61. package/dist-esm/src/models/notification.js.map +1 -1
  62. package/dist-esm/src/models/notificationBodyBuilder.js +48 -0
  63. package/dist-esm/src/models/notificationBodyBuilder.js.map +1 -0
  64. package/dist-esm/src/models/notificationDetails.js.map +1 -1
  65. package/dist-esm/src/models/notificationHubJob.js.map +1 -1
  66. package/dist-esm/src/models/options.js.map +1 -1
  67. package/dist-esm/src/models/registration.js +12 -12
  68. package/dist-esm/src/models/registration.js.map +1 -1
  69. package/dist-esm/src/models/tagExpressionBuilder.js +11 -0
  70. package/dist-esm/src/models/tagExpressionBuilder.js.map +1 -0
  71. package/dist-esm/src/notificationHubsClient.js +49 -68
  72. package/dist-esm/src/notificationHubsClient.js.map +1 -1
  73. package/dist-esm/src/serializers/notificationDetailsSerializer.js +2 -1
  74. package/dist-esm/src/serializers/notificationDetailsSerializer.js.map +1 -1
  75. package/dist-esm/src/serializers/notificationHubJobSerializer.js +3 -1
  76. package/dist-esm/src/serializers/notificationHubJobSerializer.js.map +1 -1
  77. package/dist-esm/src/serializers/notificationOutcomeSerializer.js +2 -2
  78. package/dist-esm/src/serializers/notificationOutcomeSerializer.js.map +1 -1
  79. package/dist-esm/src/serializers/registrationSerializer.js +16 -16
  80. package/dist-esm/src/serializers/registrationSerializer.js.map +1 -1
  81. package/dist-esm/src/utils/constants.js +1 -1
  82. package/dist-esm/src/utils/constants.js.map +1 -1
  83. package/dist-esm/src/utils/notificationUtils.js +19 -0
  84. package/dist-esm/src/utils/notificationUtils.js.map +1 -0
  85. package/dist-esm/src/utils/optionUtils.js +20 -0
  86. package/dist-esm/src/utils/optionUtils.js.map +1 -0
  87. package/package.json +14 -17
  88. package/types/3.1/notification-hubs.d.ts +468 -281
  89. package/types/latest/notification-hubs.d.ts +500 -286
  90. package/types/latest/tsdoc-metadata.json +1 -1
  91. package/types/src/api/beginSubmitNotificationHubJob.d.ts +12 -0
  92. package/types/src/api/beginSubmitNotificationHubJob.d.ts.map +1 -0
  93. package/types/src/{client → api}/cancelScheduledNotification.d.ts +0 -0
  94. package/types/src/api/cancelScheduledNotification.d.ts.map +1 -0
  95. package/types/src/{client → api}/createOrUpdateInstallation.d.ts +0 -0
  96. package/types/src/api/createOrUpdateInstallation.d.ts.map +1 -0
  97. package/types/src/{client → api}/createOrUpdateRegistration.d.ts +0 -0
  98. package/types/src/api/createOrUpdateRegistration.d.ts.map +1 -0
  99. package/types/src/{client → api}/createRegistration.d.ts +0 -0
  100. package/types/src/api/createRegistration.d.ts.map +1 -0
  101. package/types/src/{client → api}/createRegistrationId.d.ts +0 -0
  102. package/types/src/api/createRegistrationId.d.ts.map +1 -0
  103. package/types/src/{client → api}/deleteInstallation.d.ts +0 -0
  104. package/types/src/api/deleteInstallation.d.ts.map +1 -0
  105. package/types/src/{client → api}/deleteRegistration.d.ts +0 -0
  106. package/types/src/api/deleteRegistration.d.ts.map +1 -0
  107. package/types/src/{client → api}/getFeedbackContainerUrl.d.ts +0 -0
  108. package/types/src/api/getFeedbackContainerUrl.d.ts.map +1 -0
  109. package/types/src/{client → api}/getInstallation.d.ts +0 -0
  110. package/types/src/api/getInstallation.d.ts.map +1 -0
  111. package/types/src/{client → api}/getNotificationHubJob.d.ts +0 -0
  112. package/types/src/api/getNotificationHubJob.d.ts.map +1 -0
  113. package/types/src/{client → api}/getNotificationOutcomeDetails.d.ts +0 -0
  114. package/types/src/api/getNotificationOutcomeDetails.d.ts.map +1 -0
  115. package/types/src/{client → api}/getRegistration.d.ts +0 -0
  116. package/types/src/api/getRegistration.d.ts.map +1 -0
  117. package/types/src/{client → api}/index.d.ts +23 -1
  118. package/types/src/api/index.d.ts.map +1 -0
  119. package/types/src/{client → api}/internal/_client.d.ts +0 -0
  120. package/types/src/api/internal/_client.d.ts.map +1 -0
  121. package/types/src/{client → api}/internal/_createOrUpdateRegistrationDescription.d.ts +0 -0
  122. package/types/src/api/internal/_createOrUpdateRegistrationDescription.d.ts.map +1 -0
  123. package/types/src/api/internal/_listRegistrations.d.ts +6 -0
  124. package/types/src/api/internal/_listRegistrations.d.ts.map +1 -0
  125. package/types/src/{client → api}/listNotificationHubJobs.d.ts +0 -0
  126. package/types/src/api/listNotificationHubJobs.d.ts.map +1 -0
  127. package/types/src/{client → api}/listRegistrations.d.ts +3 -3
  128. package/types/src/api/listRegistrations.d.ts.map +1 -0
  129. package/types/src/api/listRegistrationsByChannel.d.ts +13 -0
  130. package/types/src/api/listRegistrationsByChannel.d.ts.map +1 -0
  131. package/types/src/{client → api}/listRegistrationsByTag.d.ts +0 -0
  132. package/types/src/api/listRegistrationsByTag.d.ts.map +1 -0
  133. package/types/src/{client → api}/scheduleNotification.d.ts +3 -5
  134. package/types/src/api/scheduleNotification.d.ts.map +1 -0
  135. package/types/src/{client → api}/sendNotification.d.ts +3 -5
  136. package/types/src/api/sendNotification.d.ts.map +1 -0
  137. package/types/src/{client → api}/submitNotificationHubJob.d.ts +0 -0
  138. package/types/src/api/submitNotificationHubJob.d.ts.map +1 -0
  139. package/types/src/{client → api}/updateInstallation.d.ts +0 -0
  140. package/types/src/api/updateInstallation.d.ts.map +1 -0
  141. package/types/src/{client → api}/updateRegistration.d.ts +0 -0
  142. package/types/src/api/updateRegistration.d.ts.map +1 -0
  143. package/types/src/index.d.ts +3 -2
  144. package/types/src/index.d.ts.map +1 -1
  145. package/types/src/models/index.d.ts +10 -0
  146. package/types/src/models/index.d.ts.map +1 -0
  147. package/types/src/models/installation.d.ts +12 -11
  148. package/types/src/models/installation.d.ts.map +1 -1
  149. package/types/src/models/notification.d.ts +10 -18
  150. package/types/src/models/notification.d.ts.map +1 -1
  151. package/types/src/models/{notificationBuilder.d.ts → notificationBodyBuilder.d.ts} +62 -64
  152. package/types/src/models/notificationBodyBuilder.d.ts.map +1 -0
  153. package/types/src/models/notificationDetails.d.ts +9 -9
  154. package/types/src/models/notificationDetails.d.ts.map +1 -1
  155. package/types/src/models/notificationHubJob.d.ts +5 -0
  156. package/types/src/models/notificationHubJob.d.ts.map +1 -1
  157. package/types/src/models/options.d.ts +36 -2
  158. package/types/src/models/options.d.ts.map +1 -1
  159. package/types/src/models/registration.d.ts +235 -69
  160. package/types/src/models/registration.d.ts.map +1 -1
  161. package/types/src/models/tagExpressionBuilder.d.ts +7 -0
  162. package/types/src/models/tagExpressionBuilder.d.ts.map +1 -0
  163. package/types/src/notificationHubsClient.d.ts +25 -41
  164. package/types/src/notificationHubsClient.d.ts.map +1 -1
  165. package/types/src/serializers/registrationSerializer.d.ts +14 -14
  166. package/types/src/serializers/registrationSerializer.d.ts.map +1 -1
  167. package/types/src/utils/notificationUtils.d.ts +6 -0
  168. package/types/src/utils/notificationUtils.d.ts.map +1 -0
  169. package/types/src/utils/optionUtils.d.ts +14 -0
  170. package/types/src/utils/optionUtils.d.ts.map +1 -0
  171. package/dist-esm/src/client/cancelScheduledNotification.js.map +0 -1
  172. package/dist-esm/src/client/createOrUpdateInstallation.js.map +0 -1
  173. package/dist-esm/src/client/createOrUpdateRegistration.js.map +0 -1
  174. package/dist-esm/src/client/createRegistration.js.map +0 -1
  175. package/dist-esm/src/client/createRegistrationId.js.map +0 -1
  176. package/dist-esm/src/client/deleteInstallation.js.map +0 -1
  177. package/dist-esm/src/client/deleteRegistration.js.map +0 -1
  178. package/dist-esm/src/client/getFeedbackContainerUrl.js.map +0 -1
  179. package/dist-esm/src/client/getInstallation.js.map +0 -1
  180. package/dist-esm/src/client/getNotificationHubJob.js.map +0 -1
  181. package/dist-esm/src/client/getNotificationOutcomeDetails.js.map +0 -1
  182. package/dist-esm/src/client/getRegistration.js.map +0 -1
  183. package/dist-esm/src/client/index.js.map +0 -1
  184. package/dist-esm/src/client/internal/_client.js.map +0 -1
  185. package/dist-esm/src/client/internal/_createOrUpdateRegistrationDescription.js.map +0 -1
  186. package/dist-esm/src/client/internal/_scheduleNotificationPayload.js +0 -38
  187. package/dist-esm/src/client/internal/_scheduleNotificationPayload.js.map +0 -1
  188. package/dist-esm/src/client/internal/_sendNotificationPayload.js +0 -51
  189. package/dist-esm/src/client/internal/_sendNotificationPayload.js.map +0 -1
  190. package/dist-esm/src/client/listNotificationHubJobs.js.map +0 -1
  191. package/dist-esm/src/client/listRegistrations.js.map +0 -1
  192. package/dist-esm/src/client/listRegistrationsByTag.js.map +0 -1
  193. package/dist-esm/src/client/scheduleBroadcastNotification.js +0 -17
  194. package/dist-esm/src/client/scheduleBroadcastNotification.js.map +0 -1
  195. package/dist-esm/src/client/scheduleNotification.js +0 -18
  196. package/dist-esm/src/client/scheduleNotification.js.map +0 -1
  197. package/dist-esm/src/client/sendBroadcastNotification.js +0 -15
  198. package/dist-esm/src/client/sendBroadcastNotification.js.map +0 -1
  199. package/dist-esm/src/client/sendDirectNotification.js +0 -15
  200. package/dist-esm/src/client/sendDirectNotification.js.map +0 -1
  201. package/dist-esm/src/client/sendNotification.js +0 -16
  202. package/dist-esm/src/client/sendNotification.js.map +0 -1
  203. package/dist-esm/src/client/submitNotificationHubJob.js.map +0 -1
  204. package/dist-esm/src/client/updateInstallation.js.map +0 -1
  205. package/dist-esm/src/client/updateRegistration.js.map +0 -1
  206. package/dist-esm/src/models/notificationBuilder.js +0 -169
  207. package/dist-esm/src/models/notificationBuilder.js.map +0 -1
  208. package/dist-esm/src/utils/retryPolicy.js +0 -144
  209. package/dist-esm/src/utils/retryPolicy.js.map +0 -1
  210. package/types/src/client/cancelScheduledNotification.d.ts.map +0 -1
  211. package/types/src/client/createOrUpdateInstallation.d.ts.map +0 -1
  212. package/types/src/client/createOrUpdateRegistration.d.ts.map +0 -1
  213. package/types/src/client/createRegistration.d.ts.map +0 -1
  214. package/types/src/client/createRegistrationId.d.ts.map +0 -1
  215. package/types/src/client/deleteInstallation.d.ts.map +0 -1
  216. package/types/src/client/deleteRegistration.d.ts.map +0 -1
  217. package/types/src/client/getFeedbackContainerUrl.d.ts.map +0 -1
  218. package/types/src/client/getInstallation.d.ts.map +0 -1
  219. package/types/src/client/getNotificationHubJob.d.ts.map +0 -1
  220. package/types/src/client/getNotificationOutcomeDetails.d.ts.map +0 -1
  221. package/types/src/client/getRegistration.d.ts.map +0 -1
  222. package/types/src/client/index.d.ts.map +0 -1
  223. package/types/src/client/internal/_client.d.ts.map +0 -1
  224. package/types/src/client/internal/_createOrUpdateRegistrationDescription.d.ts.map +0 -1
  225. package/types/src/client/internal/_scheduleNotificationPayload.d.ts +0 -9
  226. package/types/src/client/internal/_scheduleNotificationPayload.d.ts.map +0 -1
  227. package/types/src/client/internal/_sendNotificationPayload.d.ts +0 -10
  228. package/types/src/client/internal/_sendNotificationPayload.d.ts.map +0 -1
  229. package/types/src/client/listNotificationHubJobs.d.ts.map +0 -1
  230. package/types/src/client/listRegistrations.d.ts.map +0 -1
  231. package/types/src/client/listRegistrationsByTag.d.ts.map +0 -1
  232. package/types/src/client/scheduleBroadcastNotification.d.ts +0 -16
  233. package/types/src/client/scheduleBroadcastNotification.d.ts.map +0 -1
  234. package/types/src/client/scheduleNotification.d.ts.map +0 -1
  235. package/types/src/client/sendBroadcastNotification.d.ts +0 -14
  236. package/types/src/client/sendBroadcastNotification.d.ts.map +0 -1
  237. package/types/src/client/sendDirectNotification.d.ts +0 -15
  238. package/types/src/client/sendDirectNotification.d.ts.map +0 -1
  239. package/types/src/client/sendNotification.d.ts.map +0 -1
  240. package/types/src/client/submitNotificationHubJob.d.ts.map +0 -1
  241. package/types/src/client/updateInstallation.d.ts.map +0 -1
  242. package/types/src/client/updateRegistration.d.ts.map +0 -1
  243. package/types/src/models/notificationBuilder.d.ts.map +0 -1
  244. package/types/src/utils/retryPolicy.d.ts +0 -72
  245. package/types/src/utils/retryPolicy.d.ts.map +0 -1
@@ -1,6 +1,8 @@
1
1
  import { CommonClientOptions } from '@azure/core-client';
2
2
  import { OperationOptions } from '@azure/core-client';
3
+ import { OperationState } from '@azure/core-lro';
3
4
  import { PagedAsyncIterableIterator } from '@azure/core-paging';
5
+ import { SimplePollerLike } from '@azure/core-lro';
4
6
 
5
7
  /**
6
8
  * Represents an Amazon Device Messaging (ADM) based installation.
@@ -74,27 +76,27 @@ export declare interface AdmNativeNotification {
74
76
  /**
75
77
  * The action associated with a user click on the notification.
76
78
  */
77
- clickAction?: string;
79
+ click_action?: string;
78
80
  /**
79
81
  * The key to the body string in the app's string resources to use to localize the body text to the user's current localization.
80
82
  */
81
- bodyLocKey?: string;
83
+ body_loc_key?: string;
82
84
  /**
83
85
  * Variable string values to be used in place of the format specifiers in body_loc_key to use to localize the body text to the user's current localization.
84
86
  */
85
- bodyLocArgs?: string[];
87
+ body_loc_args?: string[];
86
88
  /**
87
89
  * The key to the title string in the app's string resources to use to localize the title text to the user's current localization.
88
90
  */
89
- titleLocKey?: string;
91
+ title_loc_key?: string;
90
92
  /**
91
93
  * Variable string values to be used in place of the format specifiers in title_loc_key to use to localize the title text to the user's current localization.
92
94
  */
93
- titleLocArgs?: string[];
95
+ title_loc_args?: string[];
94
96
  /**
95
97
  * The notification's channel id.
96
98
  */
97
- channelId?: string;
99
+ channel_id?: string;
98
100
  /**
99
101
  * Sets the "ticker" text, which is sent to accessibility services.
100
102
  */
@@ -106,27 +108,27 @@ export declare interface AdmNativeNotification {
106
108
  /**
107
109
  * Set the time that the event in the notification occurred. Must be a timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".
108
110
  */
109
- eventTime?: string;
111
+ event_time?: string;
110
112
  /**
111
113
  * Set whether or not this notification is relevant only to the current device.
112
114
  */
113
- localOnly?: boolean;
115
+ local_only?: boolean;
114
116
  /**
115
117
  * Set the relative priority for this notification.
116
118
  */
117
- notificationPriority?: number;
119
+ notification_priority?: "PRIORITY_UNSPECIFIED" | "PRIORITY_MIN" | "PRIORITY_LOW" | "PRIORITY_DEFAULT" | "PRIORITY_HIGH" | "PRIORITY_MAX";
118
120
  /**
119
121
  * If set to true, use the Android framework's default sound for the notification.
120
122
  */
121
- defaultSound?: boolean;
123
+ default_sound?: boolean;
122
124
  /**
123
125
  * Set the Notification.visibility of the notification.
124
126
  */
125
- visibility?: number;
127
+ visibility?: "VISIBILITY_UNSPECIFIED" | "PRIVATE" | "PUBLIC" | "SECRET";
126
128
  /**
127
129
  * Sets the number of items this notification represents.
128
130
  */
129
- notificationCount?: number;
131
+ notification_count?: number;
130
132
  /**
131
133
  * Contains the URL of an image that is going to be displayed in a notification.
132
134
  */
@@ -144,27 +146,50 @@ export declare interface AdmNotification extends JsonNotification {
144
146
  }
145
147
 
146
148
  /**
147
- * Represents the description of the Amazon Device Messaging (ADM) registration.
149
+ * Describes an ADM Registration channel query.
148
150
  */
149
- export declare interface AdmRegistrationDescription extends RegistrationDescriptionCommon {
151
+ export declare interface AdmRegistrationChannel {
150
152
  /**
151
- * The Amazon Device Messaging registration identifier.
153
+ * The ADM Registration ID.
152
154
  */
153
155
  admRegistrationId: string;
154
156
  /**
155
- * The type of the registration.
157
+ * The kind of the registration channel.
158
+ */
159
+ kind: "adm";
160
+ }
161
+
162
+ /**
163
+ * Represents the description of the Amazon Device Messaging (ADM) registration.
164
+ */
165
+ export declare interface AdmRegistrationDescription extends AdmRegistrationDescriptionCommon {
166
+ /**
167
+ * The kind of the registration.
168
+ */
169
+ kind: "Adm";
170
+ }
171
+
172
+ export declare interface AdmRegistrationDescriptionCommon extends RegistrationDescriptionCommon {
173
+ /**
174
+ * The Amazon Device Messaging registration identifier.
156
175
  */
157
- type: "Adm";
176
+ admRegistrationId: string;
158
177
  }
159
178
 
160
179
  /**
161
180
  * Represents the description of the Amazon Device Messaging (ADM) template registration.
162
181
  */
163
- export declare interface AdmTemplateRegistrationDescription extends Omit<AdmRegistrationDescription, "type">, TemplateRegistrationDescription {
182
+ export declare interface AdmTemplateRegistrationDescription extends AdmTemplateRegistrationDescriptionCommon {
164
183
  /**
165
- * The type of the registration.
184
+ * The kind of the registration.
166
185
  */
167
- type: "AdmTemplate";
186
+ kind: "AdmTemplate";
187
+ }
188
+
189
+ /**
190
+ * Represents the description of the Amazon Device Messaging (ADM) template registration.
191
+ */
192
+ export declare interface AdmTemplateRegistrationDescriptionCommon extends AdmRegistrationDescriptionCommon, TemplateRegistrationDescription {
168
193
  }
169
194
 
170
195
  /**
@@ -188,45 +213,45 @@ export declare interface AppleAlert {
188
213
  * The name of the launch image file to display. If the user chooses to launch your app,
189
214
  * the contents of the specified image or storyboard file are displayed instead of your app’s normal launch image.
190
215
  */
191
- launchImage?: string;
216
+ "launch-image"?: string;
192
217
  /**
193
218
  * The key for a localized title string. Specify this key instead of the title key to retrieve
194
219
  * the title from your app’s Localizable.strings files. The value must contain the name of a key in your strings file.
195
220
  */
196
- titleLocKey?: string;
221
+ "title-loc-key"?: string;
197
222
  /**
198
223
  * An array of strings containing replacement values for variables in your title string.
199
224
  * Each %\@ character in the string specified by the title-loc-key is replaced by a value
200
225
  * from this array. The first item in the array replaces the first instance
201
226
  * of the %\@ character in the string, the second item replaces the second instance, and so on.
202
227
  */
203
- titleLocArgs?: string[];
228
+ "title-loc-args"?: string[];
204
229
  /**
205
230
  * The key for a localized subtitle string. Use this key, instead of the subtitle key, to
206
231
  * retrieve the subtitle from your app’s Localizable.strings file.
207
232
  * The value must contain the name of a key in your strings file.
208
233
  */
209
- subtitleLocKey?: string;
234
+ "subtitle-loc-key"?: string;
210
235
  /**
211
236
  * An array of strings containing replacement values for variables in your title string.
212
237
  * Each %\@ character in the string specified by subtitle-loc-key is replaced by a value
213
238
  * from this array. The first item in the array replaces the first instance of the
214
239
  * %\@ character in the string, the second item replaces the second instance, and so on.
215
240
  */
216
- subtitleLocArgs?: string[];
241
+ "subtitle-loc-args"?: string[];
217
242
  /**
218
243
  * The key for a localized message string. Use this key, instead of the body key, to
219
244
  * retrieve the message text from your app’s Localizable.strings file. The value must contain
220
245
  * the name of a key in your strings file.
221
246
  */
222
- locKey?: string;
247
+ "loc-key"?: string;
223
248
  /**
224
249
  * An array of strings containing replacement values for variables in your message text.
225
250
  * Each %\@ character in the string specified by loc-key is replaced by a value from
226
251
  * this array. The first item in the array replaces the first instance of the %\@ character
227
252
  * in the string, the second item replaces the second instance, and so on.
228
253
  */
229
- locArgs?: string[];
254
+ "loc-args"?: string[];
230
255
  }
231
256
 
232
257
  /**
@@ -280,7 +305,7 @@ export declare interface AppleNativeMessage extends Record<string, any> {
280
305
  /**
281
306
  * An app-specific identifier for grouping related notifications.
282
307
  */
283
- threadId?: string;
308
+ "thread-id"?: string;
284
309
  /**
285
310
  * The notification’s type.
286
311
  */
@@ -289,29 +314,29 @@ export declare interface AppleNativeMessage extends Record<string, any> {
289
314
  * The background notification flag. To perform a silent background update,
290
315
  * specify the value 1 and don’t include the alert, badge, or sound keys in your payload.
291
316
  */
292
- contentAvailable?: number;
317
+ "content-available"?: number;
293
318
  /**
294
319
  * The notification service app extension flag. If the value is 1, the system passes
295
320
  * the notification to your notification service app extension before delivery.
296
321
  */
297
- mutableContent?: number;
322
+ "mutable-content"?: number;
298
323
  /**
299
324
  * The identifier of the window brought forward.
300
325
  */
301
- targetContentId?: string;
326
+ "target-content-id"?: string;
302
327
  /**
303
328
  * The importance and delivery timing of a notification.
304
329
  */
305
- interruptionLevel?: "passive" | "active" | "time-sensitive" | "critical";
330
+ "interruption-level"?: "passive" | "active" | "time-sensitive" | "critical";
306
331
  /**
307
332
  * The relevance score, a number between 0 and 1, that the system uses to sort the
308
333
  * notifications from your app. The highest score gets featured in the notification summary.
309
334
  */
310
- relevanceScore?: number;
335
+ "relevance-score"?: number;
311
336
  /**
312
337
  * The criteria the system evaluates to determine if it displays the notification in the current Focus.
313
338
  */
314
- filterCriteria?: string;
339
+ "filter-criteria"?: string;
315
340
  }
316
341
 
317
342
  /**
@@ -325,28 +350,53 @@ export declare interface AppleNotification extends JsonNotification {
325
350
  }
326
351
 
327
352
  /**
328
- * The priority of the Apple push notification.
353
+ * Describes an Apple Registration channel query.
329
354
  */
330
- export declare type ApplePriority = "10" | "5";
355
+ export declare interface AppleRegistrationChannel {
356
+ /**
357
+ * The APNs device token.
358
+ */
359
+ deviceToken: string;
360
+ /**
361
+ * The kind of the registration channel.
362
+ */
363
+ kind: "apple";
364
+ }
365
+
366
+ /**
367
+ * Represents the description of apple registration.
368
+ */
369
+ export declare interface AppleRegistrationDescription extends AppleRegistrationDescriptionCommon {
370
+ /**
371
+ * The kind of the registration.
372
+ */
373
+ kind: "Apple";
374
+ }
331
375
 
332
376
  /**
333
377
  * Represents the description of apple registration.
334
378
  */
335
- export declare interface AppleRegistrationDescription extends RegistrationDescriptionCommon {
379
+ export declare interface AppleRegistrationDescriptionCommon extends RegistrationDescriptionCommon {
336
380
  /**
337
381
  * The APNs device token.
338
382
  */
339
383
  deviceToken: string;
384
+ }
385
+
386
+ /**
387
+ * Represents the description of the Apple template registration.
388
+ */
389
+ export declare interface AppleTemplateRegistrationDescription extends AppleTemplateRegistrationDescriptionCommon {
340
390
  /**
341
- * The type of the registration.
391
+ * The kind of the registration.
342
392
  */
343
- type: "Apple";
393
+ kind: "AppleTemplate";
344
394
  }
345
395
 
346
396
  /**
347
397
  * Represents the description of the Apple template registration.
348
398
  */
349
- export declare interface AppleTemplateRegistrationDescription extends Omit<AppleRegistrationDescription, "type">, TemplateRegistrationDescription {
399
+ export declare interface AppleTemplateRegistrationDescriptionCommon extends AppleRegistrationDescriptionCommon, TemplateRegistrationDescription {
350
400
  /**
351
401
  * The expiry date.
352
402
  */
@@ -354,15 +404,11 @@ export declare interface AppleTemplateRegistrationDescription extends Omit<Apple
354
404
  /**
355
405
  * The notification priority.
356
406
  */
357
- priority?: ApplePriority;
407
+ priority?: "10" | "5";
358
408
  /**
359
409
  * The APNS headers.
360
410
  */
361
411
  apnsHeaders?: Record<string, string>;
362
- /**
363
- * The type of the registration.
364
- */
365
- type: "AppleTemplate";
366
412
  }
367
413
 
368
414
  /**
@@ -410,23 +456,23 @@ export declare interface BaiduNativeMessage extends Record<string, any> {
410
456
  /**
411
457
  * Baidu Notification builder ID.
412
458
  */
413
- notificationBuilderId?: number;
459
+ notification_builder_id?: number;
414
460
  /**
415
461
  * Baidu Notification Android basic style.
416
462
  */
417
- notificationBasicStyle?: number;
463
+ notification_basic_style?: number;
418
464
  /**
419
465
  * Baidu Android open type.
420
466
  */
421
- openType?: number;
467
+ open_type?: number;
422
468
  /**
423
469
  * Baidu Android net support option.
424
470
  */
425
- netSupport?: number;
471
+ net_support?: number;
426
472
  /**
427
473
  * Baidu Android user confirm.
428
474
  */
429
- userConfirm?: number;
475
+ user_confirm?: number;
430
476
  /**
431
477
  * Baidu Android URL.
432
478
  */
@@ -434,15 +480,15 @@ export declare interface BaiduNativeMessage extends Record<string, any> {
434
480
  /**
435
481
  * Baidu Android package content.
436
482
  */
437
- pkgContent?: string;
483
+ pkg_content?: string;
438
484
  /**
439
485
  * Baidu Android package version.
440
486
  */
441
- pkgVersion?: string;
487
+ pkg_version?: string;
442
488
  /**
443
489
  * Baidu Android custom content dictionary.
444
490
  */
445
- customContent?: Record<string, any>;
491
+ custom_content?: Record<string, any>;
446
492
  /**
447
493
  * Baidu APNs support.
448
494
  */
@@ -459,10 +505,35 @@ export declare interface BaiduNotification extends JsonNotification {
459
505
  platform: "baidu";
460
506
  }
461
507
 
508
+ /**
509
+ * Describes an Baidu Registration channel query.
510
+ */
511
+ export declare interface BaiduRegistrationChannel {
512
+ /**
513
+ * The Baidu Channel ID.
514
+ */
515
+ baiduChannelId: string;
516
+ /**
517
+ * The Baidu User ID.
518
+ */
519
+ baiduUserId: string;
520
+ /**
521
+ * The kind of the registration channel.
522
+ */
523
+ kind: "baidu";
524
+ }
525
+
462
526
  /**
463
527
  * Represents a Baidu registration description.
464
528
  */
465
- export declare interface BaiduRegistrationDescription extends RegistrationDescriptionCommon {
529
+ export declare interface BaiduRegistrationDescription extends BaiduRegistrationDescriptionCommon {
530
+ /**
531
+ * The kind of the registration.
532
+ */
533
+ kind: "Baidu";
534
+ }
535
+
536
+ export declare interface BaiduRegistrationDescriptionCommon extends RegistrationDescriptionCommon {
466
537
  /**
467
538
  * The Baidu user identifier.
468
539
  */
@@ -471,34 +542,42 @@ export declare interface BaiduRegistrationDescription extends RegistrationDescri
471
542
  * The Baidu channel identifier.
472
543
  */
473
544
  baiduChannelId: string;
545
+ }
546
+
547
+ /**
548
+ * Represents a Baidu template registration description.
549
+ */
550
+ export declare interface BaiduTemplateRegistrationDescription extends BaiduTemplateRegistrationDescriptionCommon {
474
551
  /**
475
- * The type of the registration.
552
+ * The kind of the registration.
476
553
  */
477
- type: "Baidu";
554
+ kind: "BaiduTemplate";
478
555
  }
479
556
 
480
557
  /**
481
558
  * Represents a Baidu template registration description.
482
559
  */
483
- export declare interface BaiduTemplateRegistrationDescription extends Omit<BaiduRegistrationDescription, "type">, TemplateRegistrationDescription {
560
+ export declare interface BaiduTemplateRegistrationDescriptionCommon extends BaiduRegistrationDescriptionCommon, TemplateRegistrationDescription {
561
+ }
562
+
563
+ /**
564
+ * Represents a Browser/Web Push based installation.
565
+ */
566
+ export declare interface BrowserInstallation extends BrowserInstallationCommon {
484
567
  /**
485
- * The type of the registration.
568
+ * The platform for the installation.
486
569
  */
487
- type: "BaiduTemplate";
570
+ platform: "browser";
488
571
  }
489
572
 
490
573
  /**
491
574
  * Represents a Browser/Web Push based installation.
492
575
  */
493
- export declare interface BrowserInstallation extends InstallationCommon {
576
+ export declare interface BrowserInstallationCommon extends InstallationCommon {
494
577
  /**
495
578
  * The push channel for the Web Push API.
496
579
  */
497
580
  pushChannel: BrowserPushChannel;
498
- /**
499
- * The platform for the installation.
500
- */
501
- platform: "browser";
502
581
  }
503
582
 
504
583
  /**
@@ -530,269 +609,309 @@ export declare interface BrowserPushChannel {
530
609
  }
531
610
 
532
611
  /**
533
- * Represents a Browser Push registration description.
612
+ * Describes an Browser Registration channel query.
534
613
  */
535
- export declare interface BrowserRegistrationDescription extends RegistrationDescriptionCommon {
614
+ export declare interface BrowserRegistrationChannel {
536
615
  /**
537
- * The Browser push endpoint.
616
+ * The Web Push endpoint URL.
538
617
  */
539
618
  endpoint: string;
540
619
  /**
541
- * The Browser push P256DH.
620
+ * The Web Push subscription P256DH.
542
621
  */
543
622
  p256dh: string;
544
623
  /**
545
- * The Browser push auth secret.
624
+ * The Web Push subscription auth secret.
546
625
  */
547
626
  auth: string;
548
627
  /**
549
- * The type of the registration.
628
+ * The kind of the registration channel.
550
629
  */
551
- type: "Browser";
630
+ kind: "browser";
552
631
  }
553
632
 
554
633
  /**
555
- * Represents a Browser Push remplate registration description.
634
+ * Represents a Browser Push registration description.
556
635
  */
557
- export declare interface BrowserTemplateRegistrationDescription extends Omit<BrowserRegistrationDescription, "type">, TemplateRegistrationDescription {
636
+ export declare interface BrowserRegistrationDescription extends BrowserRegistrationDescriptionCommon {
558
637
  /**
559
- * The type of the registration.
638
+ * The kind of the registration.
560
639
  */
561
- type: "BrowserTemplate";
640
+ kind: "Browser";
562
641
  }
563
642
 
564
643
  /**
565
- * Creates a AdmNotification from a native ADM payload.
566
- * @param nativeMessage - The native message payload to send to Notification Hubs.
567
- * @returns The AdmNotification to send to Notification Hubs.
568
- */
569
- export declare function buildAdmNativeMessage(nativeMessage: AdmNativeMessage): AdmNotification;
570
-
571
- /**
572
- * Creates an APNs native message to send to Notification Hubs.
573
- * @param nativeMessage - The Apple native message properties to set.
574
- * @param additionalProperties - Additional properties for Apple messages.
575
- * @returns An AppleNotification to send to Notification Hubs.
576
- */
577
- export declare function buildAppleNativeMessage(nativeMessage: AppleNativeMessage, additionalProperties?: Record<string, any>): AppleNotification;
578
-
579
- /**
580
- * Creates a BaiduNotification from a native Baidu payload.
581
- * @param nativeMessage - The native message payload to send to Notification Hubs.
582
- * @param additionalProperties - Additional properties for Apple Baidu messages.
583
- * @returns The BaiduNotification to send to Notification Hubs.
644
+ * Represents a Browser Push registration description.
584
645
  */
585
- export declare function buildBaiduNativeMessage(nativeMessage: BaiduNativeMessage, additionalProperties?: Record<string, any>): BaiduNotification;
646
+ export declare interface BrowserRegistrationDescriptionCommon extends RegistrationDescriptionCommon {
647
+ /**
648
+ * The Browser push endpoint.
649
+ */
650
+ endpoint: string;
651
+ /**
652
+ * The Browser push P256DH.
653
+ */
654
+ p256dh: string;
655
+ /**
656
+ * The Browser push auth secret.
657
+ */
658
+ auth: string;
659
+ }
586
660
 
587
661
  /**
588
- * Creates a FcmLegacyNotification from a native Firebase payload.
589
- * @param nativeMessage - The native message payload to send to Notification Hubs.
590
- * @returns The FcmLegacyNotification to send to Notification Hubs.
662
+ * Represents a Browser Push remplate registration description.
591
663
  */
592
- export declare function buildFirebaseLegacyNativeMessage(nativeMessage: FirebaseLegacyNativeMessage): FcmLegacyNotification;
664
+ export declare interface BrowserTemplateRegistrationDescription extends BrowserTemplateRegistrationDescriptionCommon {
665
+ /**
666
+ * The kind of the registration.
667
+ */
668
+ kind: "BrowserTemplate";
669
+ }
593
670
 
594
671
  /**
595
- * Builds a WindowsNotification from a Windows Badge.
596
- * @param nativeMessage - The Windows Badge Message to build.
597
- * @returns A WindowsNotification created with the badge information.
672
+ * Represents a Browser Push remplate registration description.
598
673
  */
599
- export declare function buildWindowsBadgeNativeMessage(nativeMessage: WindowsBadgeNativeMessage): WindowsNotification;
674
+ export declare interface BrowserTemplateRegistrationDescriptionCommon extends BrowserRegistrationDescriptionCommon, TemplateRegistrationDescription {
675
+ }
600
676
 
601
677
  /**
602
678
  * Creates an Amazon Device Messaging (ADM) based installation.
603
679
  * @param installation - A partial installation used to create the ADM installation.
604
680
  * @returns The newly created ADM installation.
605
681
  */
606
- export declare function createAdmInstallation(installation: Omit<AdmInstallation, "platform">): AdmInstallation;
682
+ export declare function createAdmInstallation(installation: DeviceTokenInstallation): AdmInstallation;
607
683
 
608
684
  /**
609
685
  * Creates a notification to send to an Amazon Device Messaging device.
610
686
  * @param notification - A partial message used to create a message for Amazon Device Messaging.
611
687
  * @returns A newly created Amazon Device Messaging.
612
688
  */
613
- export declare function createAdmNotification(notification: Omit<AdmNotification, "platform" | "contentType">): AdmNotification;
689
+ export declare function createAdmNotification(notification: NotificationCommon): AdmNotification;
690
+
691
+ /**
692
+ * Creates a AdmNotification from a native ADM payload.
693
+ * @param nativeMessage - The native message payload to send to Notification Hubs.
694
+ * @returns The AdmNotification to send to Notification Hubs.
695
+ */
696
+ export declare function createAdmNotificationBody(nativeMessage: AdmNativeMessage): string;
614
697
 
615
698
  /**
616
699
  * Creates an ADM registration description.
617
700
  * @param description - A partial ADM registration description.
618
701
  * @returns A created ADM registration description.
619
702
  */
620
- export declare function createAdmRegistrationDescription(description: Omit<AdmRegistrationDescription, "type">): AdmRegistrationDescription;
703
+ export declare function createAdmRegistrationDescription(description: AdmRegistrationDescriptionCommon): AdmRegistrationDescription;
621
704
 
622
705
  /**
623
706
  * Creates an ADM template registration description.
624
707
  * @param description - A partial ADM template registration description.
625
708
  * @returns A created ADM template registration description.
626
709
  */
627
- export declare function createAdmTemplateRegistrationDescription(description: Omit<AdmTemplateRegistrationDescription, "type">): AdmTemplateRegistrationDescription;
710
+ export declare function createAdmTemplateRegistrationDescription(description: AdmTemplateRegistrationDescriptionCommon): AdmTemplateRegistrationDescription;
628
711
 
629
712
  /**
630
713
  * Creates an Apple based installation.
631
714
  * @param installation - A partial installation used to create the Apple installation.
632
715
  * @returns The newly created Apple installation.
633
716
  */
634
- export declare function createAppleInstallation(installation: Omit<AppleInstallation, "platform">): AppleInstallation;
717
+ export declare function createAppleInstallation(installation: DeviceTokenInstallation): AppleInstallation;
635
718
 
636
719
  /**
637
720
  * Creates a notification to send to an Apple device.
638
721
  * @param notification - A partial message used to create a message for Apple.
639
722
  * @returns A newly created Apple.
640
723
  */
641
- export declare function createAppleNotification(notification: Omit<AppleNotification, "platform" | "contentType">): AppleNotification;
724
+ export declare function createAppleNotification(notification: NotificationCommon): AppleNotification;
725
+
726
+ /**
727
+ * Creates an APNs native message to send to Notification Hubs.
728
+ * @param nativeMessage - The Apple native message properties to set.
729
+ * @param additionalProperties - Additional properties for Apple messages.
730
+ * @returns An AppleNotification to send to Notification Hubs.
731
+ */
732
+ export declare function createAppleNotificationBody(nativeMessage: AppleNativeMessage): string;
642
733
 
643
734
  /**
644
735
  * Creates an Apple registration description.
645
736
  * @param description - A partial Apple registration description.
646
737
  * @returns A created Apple registration description.
647
738
  */
648
- export declare function createAppleRegistrationDescription(description: Omit<AppleRegistrationDescription, "type">): AppleRegistrationDescription;
739
+ export declare function createAppleRegistrationDescription(description: AppleRegistrationDescriptionCommon): AppleRegistrationDescription;
649
740
 
650
741
  /**
651
742
  * Creates an Apple template registration description.
652
743
  * @param description - A partial Apple template registration description.
653
744
  * @returns A created Apple template registration description.
654
745
  */
655
- export declare function createAppleTemplateRegistrationDescription(description: Omit<AppleTemplateRegistrationDescription, "type">): AppleTemplateRegistrationDescription;
746
+ export declare function createAppleTemplateRegistrationDescription(description: AppleTemplateRegistrationDescriptionCommon): AppleTemplateRegistrationDescription;
656
747
 
657
748
  /**
658
749
  * Creates a Baidu based installation.
659
750
  * @param installation - A partial installation used to create the Baidu installation.
660
751
  * @returns The newly created Baidu installation.
661
752
  */
662
- export declare function createBaiduInstallation(installation: Omit<BaiduInstallation, "platform">): BaiduInstallation;
753
+ export declare function createBaiduInstallation(installation: DeviceTokenInstallation): BaiduInstallation;
663
754
 
664
755
  /**
665
756
  * Creates a notification to send to a Baidu registered device.
666
757
  * @param notification - A partial message used to create a message for Baidu.
667
758
  * @returns A newly created Baidu.
668
759
  */
669
- export declare function createBaiduNotification(notification: Omit<BaiduNotification, "platform" | "contentType">): BaiduNotification;
760
+ export declare function createBaiduNotification(notification: NotificationCommon): BaiduNotification;
761
+
762
+ /**
763
+ * Creates a BaiduNotification from a native Baidu payload.
764
+ * @param nativeMessage - The native message payload to send to Notification Hubs.
765
+ * @returns The JSON body to send to Notification Hubs.
766
+ */
767
+ export declare function createBaiduNotificationBody(nativeMessage: BaiduNativeMessage): string;
670
768
 
671
769
  /**
672
770
  * Creates a Baidu registration description.
673
771
  * @param description - A partial Baidu registration description.
674
772
  * @returns A created Baidu registration description.
675
773
  */
676
- export declare function createBaiduRegistrationDescription(description: Omit<BaiduRegistrationDescription, "type">): BaiduRegistrationDescription;
774
+ export declare function createBaiduRegistrationDescription(description: BaiduRegistrationDescriptionCommon): BaiduRegistrationDescription;
677
775
 
678
776
  /**
679
777
  * Creates a Baidu template registration description.
680
778
  * @param description - A partial Baidu template registration description.
681
779
  * @returns A created Baidu template registration description.
682
780
  */
683
- export declare function createBaiduTemplateRegistrationDescription(description: Omit<BaiduTemplateRegistrationDescription, "type">): BaiduTemplateRegistrationDescription;
781
+ export declare function createBaiduTemplateRegistrationDescription(description: BaiduTemplateRegistrationDescriptionCommon): BaiduTemplateRegistrationDescription;
684
782
 
685
783
  /**
686
784
  * Creates a Web Push based installation.
687
785
  * @param installation - A partial installation used to create the Web Push installation.
688
786
  * @returns The newly created Web Push installation.
689
787
  */
690
- export declare function createBrowserInstallation(installation: Omit<BrowserInstallation, "platform">): BrowserInstallation;
788
+ export declare function createBrowserInstallation(installation: BrowserInstallationCommon): BrowserInstallation;
691
789
 
692
790
  /**
693
791
  * Creates a notification to send to a browser.
694
792
  * @param notification - A partial message used to create a message for a browser.
695
793
  * @returns A newly created Web Push browser.
696
794
  */
697
- export declare function createBrowserNotification(notification: Omit<BrowserNotification, "platform" | "contentType">): BrowserNotification;
795
+ export declare function createBrowserNotification(notification: NotificationCommon): BrowserNotification;
698
796
 
699
797
  /**
700
798
  * Creates a Web Push registration description.
701
799
  * @param description - A partial Web Push registration description.
702
800
  * @returns A created Web Push registration description.
703
801
  */
704
- export declare function createBrowserRegistrationDescription(description: Omit<BrowserRegistrationDescription, "type">): BrowserRegistrationDescription;
802
+ export declare function createBrowserRegistrationDescription(description: BrowserRegistrationDescriptionCommon): BrowserRegistrationDescription;
705
803
 
706
804
  /**
707
805
  * Creates a Web Push registration description.
708
806
  * @param description - A partial Web Push template registration description.
709
807
  * @returns A created Web Push template registration description.
710
808
  */
711
- export declare function createBrowserTemplateRegistrationDescription(description: Omit<BrowserTemplateRegistrationDescription, "type">): BrowserTemplateRegistrationDescription;
809
+ export declare function createBrowserTemplateRegistrationDescription(description: BrowserTemplateRegistrationDescriptionCommon): BrowserTemplateRegistrationDescription;
712
810
 
713
811
  /**
714
812
  * Creates a Firebase legacy HTTP based installation.
715
813
  * @param installation - A partial installation used to create the Firebase Legacy HTTP installation.
716
814
  * @returns The newly created Baidu installation.
717
815
  */
718
- export declare function createFcmLegacyInstallation(installation: Omit<FcmLegacyInstallation, "platform">): FcmLegacyInstallation;
816
+ export declare function createFcmLegacyInstallation(installation: DeviceTokenInstallation): FcmLegacyInstallation;
719
817
 
720
818
  /**
721
819
  * Creates a notification to send to Firebase.
722
820
  * @param notification - A partial message used to create a message for Firebase.
723
821
  * @returns A newly created Firebase.
724
822
  */
725
- export declare function createFcmLegacyNotification(notification: Omit<FcmLegacyNotification, "platform" | "contentType">): FcmLegacyNotification;
823
+ export declare function createFcmLegacyNotification(notification: NotificationCommon): FcmLegacyNotification;
726
824
 
727
825
  /**
728
826
  * Creates a Firebase Legacy registration description.
729
827
  * @param description - A partial GCM registration description.
730
828
  * @returns A created GCM registration description.
731
829
  */
732
- export declare function createFcmLegacyRegistrationDescription(description: Omit<GcmRegistrationDescription, "type">): GcmRegistrationDescription;
830
+ export declare function createFcmLegacyRegistrationDescription(description: GcmRegistrationDescriptionCommon): GcmRegistrationDescription;
733
831
 
734
832
  /**
735
833
  * Creates a GCM template registration description.
736
834
  * @param description - A partial GCM template registration description.
737
835
  * @returns A created GCM template registration description.
738
836
  */
739
- export declare function createFcmLegacyTemplateRegistrationDescription(description: Omit<GcmTemplateRegistrationDescription, "type">): GcmTemplateRegistrationDescription;
837
+ export declare function createFcmLegacyTemplateRegistrationDescription(description: GcmTemplateRegistrationDescriptionCommon): GcmTemplateRegistrationDescription;
838
+
839
+ /**
840
+ * Creates a FcmLegacyNotification from a native Firebase payload.
841
+ * @param nativeMessage - The native message payload to send to Notification Hubs.
842
+ * @returns The JSON body to send to Notification Hubs.
843
+ */
844
+ export declare function createFirebaseLegacyNotificationBody(nativeMessage: FirebaseLegacyNativeMessage): string;
845
+
846
+ /**
847
+ * Creates a tag expression from a list of tags as a || expression.
848
+ * @param tags - The tags to create the || expression
849
+ * @returns The tag expression made from the array of strings into an || expression.
850
+ */
851
+ export declare function createTagExpression(tags: string[]): string;
740
852
 
741
853
  /**
742
854
  * Creates a notification to send to Firebase.
743
855
  * @param notification - A partial message used to create a message for Firebase.
744
856
  * @returns A newly created Firebase.
745
857
  */
746
- export declare function createTemplateNotification(notification: Omit<TemplateNotification, "platform" | "contentType">): TemplateNotification;
858
+ export declare function createTemplateNotification(notification: NotificationCommon): TemplateNotification;
747
859
 
748
860
  /**
749
861
  * Creates a badge message to send to WNS.
750
862
  * @param notification - A partial message used to create a badge message for WNS.
751
863
  * @returns A newly created WNS badge.
752
864
  */
753
- export declare function createWindowsBadgeNotification(notification: Omit<WindowsNotification, "platform" | "contentType">): WindowsNotification;
865
+ export declare function createWindowsBadgeNotification(notification: NotificationCommon): WindowsNotification;
866
+
867
+ /**
868
+ * Builds a WindowsNotification from a Windows Badge.
869
+ * @param nativeMessage - The Windows Badge Message to build.
870
+ * @returns The WNS XML created with the badge information.
871
+ */
872
+ export declare function createWindowsBadgeNotificationBody(nativeMessage: WindowsBadgeNativeMessage): string;
754
873
 
755
874
  /**
756
875
  * Creates a Windows Notification Services (WNS) based installation.
757
876
  * @param installation - A partial installation used to create the WNS installation.
758
877
  * @returns The newly created WNS installation.
759
878
  */
760
- export declare function createWindowsInstallation(installation: Omit<WindowsInstallation, "platform">): WindowsInstallation;
879
+ export declare function createWindowsInstallation(installation: DeviceTokenInstallation): WindowsInstallation;
761
880
 
762
881
  /**
763
882
  * Creates a notification to send to WNS in wns/raw format..
764
883
  * @param notification - A partial message used to create a message for WNS in XML format.
765
884
  * @returns A newly created WNS message using XML.
766
885
  */
767
- export declare function createWindowsRawNotification(notification: Omit<WindowsNotification, "platform" | "contentType">): WindowsNotification;
886
+ export declare function createWindowsRawNotification(notification: NotificationCommon): WindowsNotification;
768
887
 
769
888
  /**
770
889
  * Creates a Windows registration description.
771
890
  * @param description - A partial Windows registration description.
772
891
  * @returns A created Windows registration description.
773
892
  */
774
- export declare function createWindowsRegistrationDescription(description: Omit<WindowsRegistrationDescription, "type">): WindowsRegistrationDescription;
893
+ export declare function createWindowsRegistrationDescription(description: WindowsRegistrationDescriptionCommon): WindowsRegistrationDescription;
775
894
 
776
895
  /**
777
896
  * Creates a Windows template registration description.
778
897
  * @param description - A partial Windows template registration description.
779
898
  * @returns A created Windows template registration description.
780
899
  */
781
- export declare function createWindowsTemplateRegistrationDescription(description: Omit<WindowsTemplateRegistrationDescription, "type">): WindowsTemplateRegistrationDescription;
900
+ export declare function createWindowsTemplateRegistrationDescription(description: WindowsTemplateRegistrationDescriptionCommon): WindowsTemplateRegistrationDescription;
782
901
 
783
902
  /**
784
903
  * Creates a tile message to send to WNS.
785
904
  * @param notification - A partial message used to create a tile message for WNS.
786
905
  * @returns A newly created WNS tile.
787
906
  */
788
- export declare function createWindowsTileNotification(notification: Omit<WindowsNotification, "platform" | "contentType">): WindowsNotification;
907
+ export declare function createWindowsTileNotification(notification: NotificationCommon): WindowsNotification;
789
908
 
790
909
  /**
791
910
  * Creates a toast message to send to WNS.
792
911
  * @param notification - A partial message used to create a toast message for WNS.
793
912
  * @returns A newly created WNS toast.
794
913
  */
795
- export declare function createWindowsToastNotification(notification: Omit<WindowsNotification, "platform" | "contentType">): WindowsNotification;
914
+ export declare function createWindowsToastNotification(notification: NotificationCommon): WindowsNotification;
796
915
 
797
916
  /**
798
917
  * Represents an installation with a string based device token.
@@ -804,6 +923,16 @@ export declare interface DeviceTokenInstallation extends InstallationCommon {
804
923
  pushChannel: string;
805
924
  }
806
925
 
926
+ /**
927
+ * Options for sending notifications to individual devices.
928
+ */
929
+ export declare interface DirectSendNotificationOptions extends OperationOptions {
930
+ /**
931
+ * The device handle to send the notification. If an array is provided, this uses batch direct send which is only available in Standard SKU and above.
932
+ */
933
+ deviceHandle: string | BrowserPushChannel | string[];
934
+ }
935
+
807
936
  /**
808
937
  * Represents entity update operation options that can be set.
809
938
  */
@@ -849,7 +978,7 @@ export declare interface FirebaseLegacyAndroidNativePayload {
849
978
  /**
850
979
  * The notification's channel ID.
851
980
  */
852
- androidChannelId?: string;
981
+ android_channel_id?: string;
853
982
  /**
854
983
  * The notification's icon.
855
984
  */
@@ -869,23 +998,23 @@ export declare interface FirebaseLegacyAndroidNativePayload {
869
998
  /**
870
999
  * The action associated with a user click on the notification.
871
1000
  */
872
- clickAction?: string;
1001
+ click_action?: string;
873
1002
  /**
874
1003
  * The key to the body string in the app's string resources to use to localize the body text to the user's current localization.
875
1004
  */
876
- bodyLocKey?: string;
1005
+ body_loc_key?: string;
877
1006
  /**
878
1007
  * Variable string values to be used in place of the format specifiers in body_loc_key to use to localize the body text to the user's current localization.
879
1008
  */
880
- bodyLocArgs?: string[];
1009
+ body_loc_args?: string[];
881
1010
  /**
882
1011
  * The key to the title string in the app's string resources to use to localize the title text to the user's current localization.
883
1012
  */
884
- titleLocKey?: string;
1013
+ title_loc_key?: string;
885
1014
  /**
886
1015
  * Variable string values to be used in place of the format specifiers in title_loc_key to use to localize the title text to the user's current localization.
887
1016
  */
888
- titleLocArgs?: string[];
1017
+ title_loc_args?: string[];
889
1018
  }
890
1019
 
891
1020
  /**
@@ -911,7 +1040,7 @@ export declare interface FirebaseLegacyAppleNativePayload {
911
1040
  /**
912
1041
  * The action associated with a user click on the notification which corresponds to the APNs category.
913
1042
  */
914
- clickAction?: string;
1043
+ click_action?: string;
915
1044
  /**
916
1045
  * The notification's subtitle.
917
1046
  */
@@ -919,19 +1048,19 @@ export declare interface FirebaseLegacyAppleNativePayload {
919
1048
  /**
920
1049
  * The key to the body string in the app's string resources to use to localize the body text to the user's current localization.
921
1050
  */
922
- bodyLocKey?: string;
1051
+ body_loc_key?: string;
923
1052
  /**
924
1053
  * Variable string values to be used in place of the format specifiers in body_loc_key to use to localize the body text to the user's current localization.
925
1054
  */
926
- bodyLocArgs?: string[];
1055
+ body_loc_args?: string[];
927
1056
  /**
928
1057
  * The key to the title string in the app's string resources to use to localize the title text to the user's current localization.
929
1058
  */
930
- titleLocKey?: string;
1059
+ title_loc_key?: string;
931
1060
  /**
932
1061
  * Variable string values to be used in place of the format specifiers in title_loc_key to use to localize the title text to the user's current localization.
933
1062
  */
934
- titleLocArgs?: string[];
1063
+ title_loc_args?: string[];
935
1064
  }
936
1065
 
937
1066
  /**
@@ -945,7 +1074,7 @@ export declare interface FirebaseLegacyNativeMessage {
945
1074
  /**
946
1075
  * The recipient of a multicast message, a message sent to more than one registration token.
947
1076
  */
948
- registrationIds?: string[];
1077
+ registration_ids?: string[];
949
1078
  /**
950
1079
  * A logical expression of conditions that determine the message target.
951
1080
  */
@@ -953,7 +1082,7 @@ export declare interface FirebaseLegacyNativeMessage {
953
1082
  /**
954
1083
  * Used to identify a group of messages.
955
1084
  */
956
- collapseKey?: string;
1085
+ collapse_key?: string;
957
1086
  /**
958
1087
  * The priority of the message.
959
1088
  */
@@ -962,24 +1091,24 @@ export declare interface FirebaseLegacyNativeMessage {
962
1091
  * The background notification flag. To perform a silent background update,
963
1092
  * specify the value 1 and don’t include the alert, badge, or sound keys in your payload.
964
1093
  */
965
- contentAvailable?: boolean;
1094
+ content_available?: boolean;
966
1095
  /**
967
1096
  * The notification service app extension flag. If the value is 1, the system passes
968
1097
  * the notification to your notification service app extension before delivery.
969
1098
  */
970
- mutableContent?: number;
1099
+ mutable_content?: number;
971
1100
  /**
972
1101
  * Specifies how long (in seconds) the message should be kept in FCM storage if the device is offline
973
1102
  */
974
- timeToLive?: number;
1103
+ time_to_live?: number;
975
1104
  /**
976
1105
  * The package name of the application where the registration tokens must match in order to receive the message.
977
1106
  */
978
- restrictedPackageName?: string;
1107
+ restricted_package_name?: string;
979
1108
  /**
980
1109
  * When set to true, allows developers to test a request without actually sending a message.
981
1110
  */
982
- dryRun?: boolean;
1111
+ dry_run?: boolean;
983
1112
  /**
984
1113
  * Custom key-value pairs of the message's payload.
985
1114
  */
@@ -990,6 +1119,20 @@ export declare interface FirebaseLegacyNativeMessage {
990
1119
  notification?: FirebaseLegacyAppleNativePayload | FirebaseLegacyAndroidNativePayload | FirebaseLegacyWebNativePayload;
991
1120
  }
992
1121
 
1122
+ /**
1123
+ * Describes an Firebase Legacy Registration channel query.
1124
+ */
1125
+ export declare interface FirebaseLegacyRegistrationChannel {
1126
+ /**
1127
+ * The FCM Legacy registration ID.
1128
+ */
1129
+ gcmRegistrationId: string;
1130
+ /**
1131
+ * The kind of the registration channel.
1132
+ */
1133
+ kind: "gcm";
1134
+ }
1135
+
993
1136
  /**
994
1137
  * Represents an Web Push native payload for the Firebase Legacy HTTP interface.
995
1138
  */
@@ -1009,31 +1152,43 @@ export declare interface FirebaseLegacyWebNativePayload {
1009
1152
  /**
1010
1153
  * The action associated with a user click on the notification.
1011
1154
  */
1012
- clickAction?: string;
1155
+ click_action?: string;
1013
1156
  }
1014
1157
 
1015
1158
  /**
1016
1159
  * Represents Notification Hub registration description for Google Cloud Messaging.
1017
1160
  */
1018
- export declare interface GcmRegistrationDescription extends RegistrationDescriptionCommon {
1161
+ export declare interface GcmRegistrationDescription extends GcmRegistrationDescriptionCommon {
1019
1162
  /**
1020
- * Registration id obtained from the Google Cloud Messaging service.
1163
+ * The kind of the registration.
1021
1164
  */
1022
- gcmRegistrationId: string;
1165
+ kind: "Gcm";
1166
+ }
1167
+
1168
+ /**
1169
+ * Represents Notification Hub registration description for Google Cloud Messaging.
1170
+ */
1171
+ export declare interface GcmRegistrationDescriptionCommon extends RegistrationDescriptionCommon {
1023
1172
  /**
1024
- * The type of the registration.
1173
+ * Registration id obtained from the Google Cloud Messaging service.
1025
1174
  */
1026
- type: "Gcm";
1175
+ gcmRegistrationId: string;
1027
1176
  }
1028
1177
 
1029
1178
  /**
1030
1179
  * Represents Notification Hub template registration description for Firebase Legacy Cloud Messaging.
1031
1180
  */
1032
- export declare interface GcmTemplateRegistrationDescription extends Omit<GcmRegistrationDescription, "type">, TemplateRegistrationDescription {
1181
+ export declare interface GcmTemplateRegistrationDescription extends GcmTemplateRegistrationDescriptionCommon {
1033
1182
  /**
1034
- * The type of the registration.
1183
+ * The kind of the registration.
1035
1184
  */
1036
- type: "GcmTemplate";
1185
+ kind: "GcmTemplate";
1186
+ }
1187
+
1188
+ /**
1189
+ * Represents Notification Hub template registration description for Firebase Legacy Cloud Messaging.
1190
+ */
1191
+ export declare interface GcmTemplateRegistrationDescriptionCommon extends GcmRegistrationDescriptionCommon, TemplateRegistrationDescription {
1037
1192
  }
1038
1193
 
1039
1194
  /**
@@ -1061,10 +1216,6 @@ export declare interface InstallationCommon {
1061
1216
  * The last update date of the installation.
1062
1217
  */
1063
1218
  readonly lastUpdate?: string;
1064
- /**
1065
- * The platform for the installation.
1066
- */
1067
- platform: "apns" | "adm" | "baidu" | "browser" | "gcm" | "wns";
1068
1219
  /**
1069
1220
  * The tags used for targeting this installation.
1070
1221
  */
@@ -1130,30 +1281,59 @@ export declare type JsonPatchOperation = "add" | "remove" | "replace";
1130
1281
  * Represents a Windows Phone Notification Services registration description.
1131
1282
  * @deprecated Windows Phone is no longer supported.
1132
1283
  */
1133
- export declare interface MpnsRegistrationDescription extends RegistrationDescriptionCommon {
1284
+ export declare interface MpnsRegistrationDescription extends MpnsRegistrationDescriptionCommon {
1134
1285
  /**
1135
- * The channel URI.
1286
+ * The kind of the registration.
1136
1287
  */
1137
- channelUri: string;
1288
+ kind: "Mpns";
1289
+ }
1290
+
1291
+ /**
1292
+ * Represents a Windows Phone Notification Services registration description.
1293
+ * @deprecated Windows Phone is no longer supported.
1294
+ */
1295
+ export declare interface MpnsRegistrationDescriptionCommon extends RegistrationDescriptionCommon {
1138
1296
  /**
1139
- * The type of the registration.
1297
+ * The channel URI.
1140
1298
  */
1141
- type: "Mpns";
1299
+ channelUri: string;
1142
1300
  }
1143
1301
 
1144
1302
  /**
1145
1303
  * Represents a Windows Phone Notification Services template registration.
1146
1304
  * @deprecated Windows Phone is no longer supported.
1147
1305
  */
1148
- export declare interface MpnsTemplateRegistrationDescription extends Omit<MpnsRegistrationDescription, "type">, TemplateRegistrationDescription {
1306
+ export declare interface MpnsTemplateRegistrationDescription extends MpnsRegistrationDescriptionCommon, TemplateRegistrationDescription {
1149
1307
  /**
1150
1308
  * The WNS headers.
1151
1309
  */
1152
1310
  mpnsHeaders?: Record<string, string>;
1153
1311
  /**
1154
- * The type of the registration.
1312
+ * The kind of the registration.
1313
+ */
1314
+ kind: "MpnsTemplate";
1315
+ }
1316
+
1317
+ /**
1318
+ * Represents a Windows Phone Notification Services template registration.
1319
+ * @deprecated Windows Phone is no longer supported.
1320
+ */
1321
+ export declare interface MpnsTemplateRegistrationDescription extends MpnsTemplateRegistrationDescriptionCommon {
1322
+ /**
1323
+ * The kind of the registration.
1155
1324
  */
1156
- type: "MpnsTemplate";
1325
+ kind: "MpnsTemplate";
1326
+ }
1327
+
1328
+ /**
1329
+ * Represents a Windows Phone Notification Services template registration.
1330
+ * @deprecated Windows Phone is no longer supported.
1331
+ */
1332
+ export declare interface MpnsTemplateRegistrationDescriptionCommon extends MpnsRegistrationDescriptionCommon, TemplateRegistrationDescription {
1333
+ /**
1334
+ * The WNS headers.
1335
+ */
1336
+ mpnsHeaders?: Record<string, string>;
1157
1337
  }
1158
1338
 
1159
1339
  /**
@@ -1173,14 +1353,6 @@ export declare interface NotificationCommon {
1173
1353
  * The headers to include for the push notification.
1174
1354
  */
1175
1355
  headers?: Record<string, string>;
1176
- /**
1177
- * The platform for the push notification.
1178
- */
1179
- platform: string;
1180
- /**
1181
- * The content type for the push notification.
1182
- */
1183
- contentType: string;
1184
1356
  }
1185
1357
 
1186
1358
  /**
@@ -1230,27 +1402,27 @@ export declare interface NotificationDetails {
1230
1402
  /**
1231
1403
  * APNs outcomes counts per state.
1232
1404
  */
1233
- apnsOutcomeCounts?: NotificationOutcomeCollectionItem[];
1405
+ apnsOutcomeCounts?: NotificationOutcome[];
1234
1406
  /**
1235
1407
  * WNS outcomes counts per state.
1236
1408
  */
1237
- wnsOutcomeCounts?: NotificationOutcomeCollectionItem[];
1409
+ wnsOutcomeCounts?: NotificationOutcome[];
1238
1410
  /**
1239
1411
  * FCM outcome counts per state.
1240
1412
  */
1241
- fcmOutcomeCounts?: NotificationOutcomeCollectionItem[];
1413
+ fcmOutcomeCounts?: NotificationOutcome[];
1242
1414
  /**
1243
1415
  * ADM outcome counts per state.
1244
1416
  */
1245
- admOutcomeCounts?: NotificationOutcomeCollectionItem[];
1417
+ admOutcomeCounts?: NotificationOutcome[];
1246
1418
  /**
1247
1419
  * Baidu outcome counts per state.
1248
1420
  */
1249
- baiduOutcomeCounts?: NotificationOutcomeCollectionItem[];
1421
+ baiduOutcomeCounts?: NotificationOutcome[];
1250
1422
  /**
1251
1423
  * Web Push outcome counts per state.
1252
1424
  */
1253
- browserOutcomeCounts?: NotificationOutcomeCollectionItem[];
1425
+ browserOutcomeCounts?: NotificationOutcome[];
1254
1426
  }
1255
1427
 
1256
1428
  /**
@@ -1311,6 +1483,11 @@ export declare interface NotificationHubJob {
1311
1483
  updatedAt?: Date;
1312
1484
  }
1313
1485
 
1486
+ /**
1487
+ * Describes a poller for NotificationHubJob types.
1488
+ */
1489
+ export declare type NotificationHubJobPoller = SimplePollerLike<OperationState<NotificationHubJob>, NotificationHubJob>;
1490
+
1314
1491
  /**
1315
1492
  * Describes the types of notification hub job statuses.
1316
1493
  */
@@ -1359,61 +1536,11 @@ export declare type NotificationHubJobType =
1359
1536
  */
1360
1537
  | "ImportUpsertRegistrations";
1361
1538
 
1362
- /**
1363
- * Describes the options that can be provided while creating the NotificationHubsClientContext.
1364
- */
1365
- export declare interface NotificationHubsClientOptions extends CommonClientOptions {
1366
- }
1367
-
1368
- /**
1369
- * Describes a response from the Notification Hubs service for send operations.
1370
- */
1371
- export declare interface NotificationHubsMessageResponse extends NotificationHubsResponse {
1372
- /**
1373
- * The notification ID from the operation. Note this is only available in Standard SKU and above.
1374
- */
1375
- notificationId?: string;
1376
- /**
1377
- * The number of devices that successfully received the notification.
1378
- */
1379
- success: number;
1380
- /**
1381
- * The number of devices that failed to receive a notification.
1382
- */
1383
- failure: number;
1384
- /**
1385
- * The list of notification outcome results for each device registered with the hub, to which this notification was sent.
1386
- */
1387
- results: RegistrationResult[];
1388
- /**
1389
- * The state of this notification outcome.
1390
- */
1391
- state: NotificationOutcomeState;
1392
- }
1393
-
1394
- /**
1395
- * Describes a response from the Notification Hubs which includes a tracking ID, correlation ID and location.
1396
- */
1397
- export declare interface NotificationHubsResponse {
1398
- /**
1399
- * The Tracking ID of the operation.
1400
- */
1401
- trackingId?: string;
1402
- /**
1403
- * The correlation ID of the operation.
1404
- */
1405
- correlationId?: string;
1406
- /**
1407
- * The location of the operation.
1408
- */
1409
- location?: string;
1410
- }
1411
-
1412
1539
  /**
1413
1540
  * This represents a client for Azure Notification Hubs to manage installations and send
1414
1541
  * messages to devices.
1415
1542
  */
1416
- export declare class NotificationHubsServiceClient {
1543
+ export declare class NotificationHubsClient {
1417
1544
  private _client;
1418
1545
  /**
1419
1546
  * Creates a new instance of the NotificationClient with a connection string, hub name and options.
@@ -1496,10 +1623,17 @@ export declare class NotificationHubsServiceClient {
1496
1623
  getRegistration(registrationId: string, options?: OperationOptions): Promise<RegistrationDescription>;
1497
1624
  /**
1498
1625
  * Gets all registrations for the notification hub with the given query options.
1499
- * @param options - The options for querying the registrations such as $top and $filter.
1626
+ * @param options - The options for querying the registrations such as $top.
1627
+ * @returns A paged async iterable containing all of the registrations for the notification hub.
1628
+ */
1629
+ listRegistrations(options?: RegistrationQueryLimitOptions): PagedAsyncIterableIterator<RegistrationDescription>;
1630
+ /**
1631
+ * Gets all registrations for the notification hub with the given device information and options.
1632
+ * @param channel - The registration channel information to query per PNS type.
1633
+ * @param options - The options for querying the registrations such as $top.
1500
1634
  * @returns A paged async iterable containing all of the registrations for the notification hub.
1501
1635
  */
1502
- listRegistrations(options?: RegistrationQueryOptions): PagedAsyncIterableIterator<RegistrationDescription>;
1636
+ listRegistrationsByChannel(channel: RegistrationChannel, options?: RegistrationQueryLimitOptions): PagedAsyncIterableIterator<RegistrationDescription>;
1503
1637
  /**
1504
1638
  * Lists all registrations with the matching tag.
1505
1639
  * @param tag - The tag to query for matching registrations.
@@ -1507,52 +1641,22 @@ export declare class NotificationHubsServiceClient {
1507
1641
  * @returns A paged async iterable containing the matching registrations for the notification hub.
1508
1642
  */
1509
1643
  listRegistrationsByTag(tag: string, options?: RegistrationQueryLimitOptions): PagedAsyncIterableIterator<RegistrationDescription>;
1510
- /**
1511
- * Sends a direct push notification to a device with the given push handle.
1512
- * @param pushHandle - The push handle which is the unique identifier for the device.
1513
- * @param notification - The notification to send to the device.
1514
- * @param options - The options for sending a direct notification.
1515
- * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.
1516
- */
1517
- sendDirectNotification(pushHandle: PushHandle, notification: Notification, options?: OperationOptions): Promise<NotificationHubsMessageResponse>;
1518
1644
  /**
1519
1645
  * Sends push notifications to devices that match the given tags or tag expression.
1520
- * @param tags - The tags used to target the device for push notifications in either an array or tag expression.
1521
1646
  * @param notification - The notification to send to the matching devices.
1522
- * @param options - Configuration options for the direct send operation which can contain custom headers
1523
- * which may include APNs specific such as apns-topic or for WNS, X-WNS-TYPE.
1524
- * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.
1525
- */
1526
- sendNotification(tags: string[] | string, notification: Notification, options?: SendOperationOptions): Promise<NotificationHubsMessageResponse>;
1527
- /**
1528
- * Sends push notifications to all devices on the Notification Hub.
1529
- * @param notification - The notification to send to all devices.
1530
- * @param options - Configuration options for the direct send operation which can contain custom headers
1531
- * which may include APNs specific such as apns-topic or for WNS, X-WNS-TYPE.
1647
+ * @param options - Options for the notification including tags, device handles and whether to enable test send.
1532
1648
  * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.
1533
1649
  */
1534
- sendBroadcastNotification(notification: Notification, options?: SendOperationOptions): Promise<NotificationHubsMessageResponse>;
1650
+ sendNotification(notification: Notification, options?: DirectSendNotificationOptions | SendNotificationOptions): Promise<NotificationHubsMessageResponse>;
1535
1651
  /**
1536
1652
  * Schedules a push notification to devices that match the given tags or tag expression at the specified time.
1537
1653
  * NOTE: This is only available in Standard SKU Azure Notification Hubs.
1538
1654
  * @param scheduledTime - The Date to send the push notification.
1539
- * @param tags - The tags used to target the device for push notifications in either an array or tag expression.
1540
- * @param notification - The notification to send to the matching devices.
1541
- * @param options - Configuration options for the direct send operation which can contain custom headers
1542
- * which may include APNs specific such as apns-topic or for WNS, X-WNS-TYPE.
1543
- * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.
1544
- */
1545
- scheduleNotification(scheduledTime: Date, tags: string[] | string, notification: Notification, options?: OperationOptions): Promise<NotificationHubsMessageResponse>;
1546
- /**
1547
- * Schedules a push notification to all devices registered on the Notification Hub.
1548
- * NOTE: This is only available in Standard SKU Azure Notification Hubs.
1549
- * @param scheduledTime - The Date to send the push notification.
1550
1655
  * @param notification - The notification to send to the matching devices.
1551
- * @param options - Configuration options for the direct send operation which can contain custom headers
1552
- * which may include APNs specific such as apns-topic or for WNS, X-WNS-TYPE.
1656
+ * @param options - Options which include tags used to target the device for push notifications in either an array or tag expression.
1553
1657
  * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.
1554
1658
  */
1555
- scheduleBroadcastNotification(scheduledTime: Date, notification: Notification, options?: OperationOptions): Promise<NotificationHubsMessageResponse>;
1659
+ scheduleNotification(scheduledTime: Date, notification: Notification, options?: ScheduleNotificationOptions): Promise<NotificationHubsMessageResponse>;
1556
1660
  /**
1557
1661
  * Cancels the scheduled notification with the given notification ID.
1558
1662
  * @param notificationId - The notification ID from the scheduled notification.
@@ -1582,6 +1686,13 @@ export declare class NotificationHubsServiceClient {
1582
1686
  * @returns The Notification Hub Job with the matching ID.
1583
1687
  */
1584
1688
  getNotificationHubJob(jobId: string, options?: OperationOptions): Promise<NotificationHubJob>;
1689
+ /**
1690
+ * Submits a Notification Hub job and creates a poller to poll for results.
1691
+ * @param notificationHubJob - The Notification Hub import/export job to start.
1692
+ * @param options - The operation options.
1693
+ * @returns A poller which can be called to poll until completion of the job.
1694
+ */
1695
+ beginSubmitNotificationHubJob(notificationHubJob: NotificationHubJob, options?: PolledOperationOptions): Promise<NotificationHubJobPoller>;
1585
1696
  /**
1586
1697
  * Submits a Notification Hub Job. Note this is available to Standard SKU namespace and above.
1587
1698
  * @param job - The notification hub job to submit.
@@ -1597,10 +1708,60 @@ export declare class NotificationHubsServiceClient {
1597
1708
  listNotificationHubJobs(options?: OperationOptions): Promise<NotificationHubJob[]>;
1598
1709
  }
1599
1710
 
1711
+ /**
1712
+ * Describes the options that can be provided while creating the NotificationHubsClientContext.
1713
+ */
1714
+ export declare interface NotificationHubsClientOptions extends CommonClientOptions {
1715
+ }
1716
+
1717
+ /**
1718
+ * Describes a response from the Notification Hubs service for send operations.
1719
+ */
1720
+ export declare interface NotificationHubsMessageResponse extends NotificationHubsResponse {
1721
+ /**
1722
+ * The notification ID from the operation. Note this is only available in Standard SKU and above.
1723
+ */
1724
+ notificationId?: string;
1725
+ /**
1726
+ * The number of devices that successfully received the notification.
1727
+ */
1728
+ successCount: number;
1729
+ /**
1730
+ * The number of devices that failed to receive a notification.
1731
+ */
1732
+ failureCount: number;
1733
+ /**
1734
+ * The list of notification outcome results for each device registered with the hub, to which this notification was sent.
1735
+ */
1736
+ results: RegistrationResult[];
1737
+ /**
1738
+ * The state of this notification outcome.
1739
+ */
1740
+ state: NotificationOutcomeState;
1741
+ }
1742
+
1743
+ /**
1744
+ * Describes a response from the Notification Hubs which includes a tracking ID, correlation ID and location.
1745
+ */
1746
+ export declare interface NotificationHubsResponse {
1747
+ /**
1748
+ * The Tracking ID of the operation.
1749
+ */
1750
+ trackingId?: string;
1751
+ /**
1752
+ * The correlation ID of the operation.
1753
+ */
1754
+ correlationId?: string;
1755
+ /**
1756
+ * The location of the operation.
1757
+ */
1758
+ location?: string;
1759
+ }
1760
+
1600
1761
  /**
1601
1762
  * The per platform count per state.
1602
1763
  */
1603
- export declare interface NotificationOutcomeCollectionItem {
1764
+ export declare interface NotificationOutcome {
1604
1765
  /**
1605
1766
  * The state of the notification.
1606
1767
  */
@@ -1616,11 +1777,26 @@ export declare interface NotificationOutcomeCollectionItem {
1616
1777
  */
1617
1778
  export declare type NotificationOutcomeState = "Enqueued" | "DetailedStateAvailable" | "Processing" | "Completed" | "Abandoned" | "Unknown" | "NoTargetFound" | "Cancelled";
1618
1779
 
1780
+ /**
1781
+ * Options for polled operations including the polling interval cycle.
1782
+ */
1783
+ export declare interface PolledOperationOptions extends OperationOptions {
1784
+ /**
1785
+ * Time delay between poll requests, in milliseconds.
1786
+ */
1787
+ updateIntervalInMs?: number;
1788
+ }
1789
+
1619
1790
  /**
1620
1791
  * Represents the types of push channels available for Notification Hubs.
1621
1792
  */
1622
1793
  export declare type PushHandle = BrowserPushChannel | string;
1623
1794
 
1795
+ /**
1796
+ * Describes a Registration query.
1797
+ */
1798
+ export declare type RegistrationChannel = AdmRegistrationChannel | AppleRegistrationChannel | BaiduRegistrationChannel | BrowserRegistrationChannel | FirebaseLegacyRegistrationChannel | WindowsRegistrationChannel;
1799
+
1624
1800
  /**
1625
1801
  * Describes the types of registration descriptions.
1626
1802
  */
@@ -1650,10 +1826,6 @@ export declare interface RegistrationDescriptionCommon {
1650
1826
  * A dictionary of push variables associated with property bag.
1651
1827
  */
1652
1828
  pushVariables?: Record<string, string>;
1653
- /**
1654
- * The type of the registration.
1655
- */
1656
- type: RegistrationType;
1657
1829
  }
1658
1830
 
1659
1831
  /**
@@ -1718,9 +1890,25 @@ export declare interface RegistrationResult {
1718
1890
  export declare type RegistrationType = "Adm" | "AdmTemplate" | "Apple" | "AppleTemplate" | "Baidu" | "BaiduTemplate" | "Browser" | "BrowserTemplate" | "Gcm" | "GcmTemplate" | "Mpns" | "MpnsTemplate" | "Windows" | "WindowsTemplate";
1719
1891
 
1720
1892
  /**
1721
- * Represents the send operation options that can be set.
1893
+ * Options for sending notifications for both tag based send and broadcast scheduled send.
1722
1894
  */
1723
- export declare interface SendOperationOptions extends OperationOptions {
1895
+ export declare interface ScheduleNotificationOptions extends OperationOptions {
1896
+ /**
1897
+ * A tag expression used to target devices. Use the `createTagExpression` function to create a tag expression from an array of tags.
1898
+ * If not set, this results in a broadcast notification to be scheduled.
1899
+ */
1900
+ tagExpression?: string;
1901
+ }
1902
+
1903
+ /**
1904
+ * Options for sending notifications for both tag based send and broadcast send.
1905
+ */
1906
+ export declare interface SendNotificationOptions extends OperationOptions {
1907
+ /**
1908
+ * A tag expression used to target devices. Use the `createTagExpression` function to create a tag expression from an array of tags.
1909
+ * If not set, this results in a broadcast notification to be sent.
1910
+ */
1911
+ tagExpression?: string;
1724
1912
  /**
1725
1913
  * Set to true to enable test send.
1726
1914
  */
@@ -1795,32 +1983,58 @@ export declare interface WindowsNotification extends NotificationCommon {
1795
1983
  contentType: WindowsContentType;
1796
1984
  }
1797
1985
 
1986
+ /**
1987
+ * Describes an Windows Notification Services Registration channel query.
1988
+ */
1989
+ export declare interface WindowsRegistrationChannel {
1990
+ /**
1991
+ * The WNS Channel URI.
1992
+ */
1993
+ channelUri: string;
1994
+ /**
1995
+ * The kind of the registration channel.
1996
+ */
1997
+ kind: "windows";
1998
+ }
1999
+
1798
2000
  /**
1799
2001
  * Represents a Windows Notification Services (WNS) registration description.
1800
2002
  */
1801
- export declare interface WindowsRegistrationDescription extends RegistrationDescriptionCommon {
2003
+ export declare interface WindowsRegistrationDescription extends WindowsRegistrationDescriptionCommon {
2004
+ /**
2005
+ * The kind of the registration.
2006
+ */
2007
+ kind: "Windows";
2008
+ }
2009
+
2010
+ /**
2011
+ * Represents a Windows Notification Services (WNS) registration description.
2012
+ */
2013
+ export declare interface WindowsRegistrationDescriptionCommon extends RegistrationDescriptionCommon {
1802
2014
  /**
1803
2015
  * The channel URI.
1804
2016
  */
1805
2017
  channelUri: string;
2018
+ }
2019
+
2020
+ /**
2021
+ * Represents a Windows Notification Services (WNS) template registration.
2022
+ */
2023
+ export declare interface WindowsTemplateRegistrationDescription extends WindowsTemplateRegistrationDescriptionCommon {
1806
2024
  /**
1807
- * The type of the registration.
2025
+ * The kind of the registration.
1808
2026
  */
1809
- type: "Windows";
2027
+ kind: "WindowsTemplate";
1810
2028
  }
1811
2029
 
1812
2030
  /**
1813
2031
  * Represents a Windows Notification Services (WNS) template registration.
1814
2032
  */
1815
- export declare interface WindowsTemplateRegistrationDescription extends Omit<WindowsRegistrationDescription, "type">, TemplateRegistrationDescription {
2033
+ export declare interface WindowsTemplateRegistrationDescriptionCommon extends WindowsRegistrationDescriptionCommon, TemplateRegistrationDescription {
1816
2034
  /**
1817
2035
  * The WNS headers.
1818
2036
  */
1819
2037
  wnsHeaders?: Record<string, string>;
1820
- /**
1821
- * The type of the registration.
1822
- */
1823
- type: "WindowsTemplate";
1824
2038
  }
1825
2039
 
1826
2040
  export { }