@azure/notification-hubs 1.0.0-beta.1

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 (196) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +749 -0
  3. package/dist/index.js +2235 -0
  4. package/dist/index.js.map +1 -0
  5. package/dist-esm/src/client/cancelScheduledNotification.js +23 -0
  6. package/dist-esm/src/client/cancelScheduledNotification.js.map +1 -0
  7. package/dist-esm/src/client/createOrUpdateInstallation.js +24 -0
  8. package/dist-esm/src/client/createOrUpdateInstallation.js.map +1 -0
  9. package/dist-esm/src/client/createOrUpdateRegistration.js +17 -0
  10. package/dist-esm/src/client/createOrUpdateRegistration.js.map +1 -0
  11. package/dist-esm/src/client/createRegistration.js +24 -0
  12. package/dist-esm/src/client/createRegistration.js.map +1 -0
  13. package/dist-esm/src/client/createRegistrationId.js +26 -0
  14. package/dist-esm/src/client/createRegistrationId.js.map +1 -0
  15. package/dist-esm/src/client/deleteInstallation.js +22 -0
  16. package/dist-esm/src/client/deleteInstallation.js.map +1 -0
  17. package/dist-esm/src/client/deleteRegistration.js +25 -0
  18. package/dist-esm/src/client/deleteRegistration.js.map +1 -0
  19. package/dist-esm/src/client/getFeedbackContainerUrl.js +23 -0
  20. package/dist-esm/src/client/getFeedbackContainerUrl.js.map +1 -0
  21. package/dist-esm/src/client/getInstallation.js +23 -0
  22. package/dist-esm/src/client/getInstallation.js.map +1 -0
  23. package/dist-esm/src/client/getNotificationHubJob.js +24 -0
  24. package/dist-esm/src/client/getNotificationHubJob.js.map +1 -0
  25. package/dist-esm/src/client/getNotificationOutcomeDetails.js +24 -0
  26. package/dist-esm/src/client/getNotificationOutcomeDetails.js.map +1 -0
  27. package/dist-esm/src/client/getRegistration.js +24 -0
  28. package/dist-esm/src/client/getRegistration.js.map +1 -0
  29. package/dist-esm/src/client/index.js +44 -0
  30. package/dist-esm/src/client/index.js.map +1 -0
  31. package/dist-esm/src/client/internal/_client.js +75 -0
  32. package/dist-esm/src/client/internal/_client.js.map +1 -0
  33. package/dist-esm/src/client/internal/_createOrUpdateRegistrationDescription.js +31 -0
  34. package/dist-esm/src/client/internal/_createOrUpdateRegistrationDescription.js.map +1 -0
  35. package/dist-esm/src/client/internal/_scheduleNotificationPayload.js +37 -0
  36. package/dist-esm/src/client/internal/_scheduleNotificationPayload.js.map +1 -0
  37. package/dist-esm/src/client/internal/_sendNotificationPayload.js +51 -0
  38. package/dist-esm/src/client/internal/_sendNotificationPayload.js.map +1 -0
  39. package/dist-esm/src/client/listNotificationHubJobs.js +23 -0
  40. package/dist-esm/src/client/listNotificationHubJobs.js.map +1 -0
  41. package/dist-esm/src/client/listRegistrations.js +89 -0
  42. package/dist-esm/src/client/listRegistrations.js.map +1 -0
  43. package/dist-esm/src/client/listRegistrationsByTag.js +87 -0
  44. package/dist-esm/src/client/listRegistrationsByTag.js.map +1 -0
  45. package/dist-esm/src/client/scheduleBroadcastNotification.js +17 -0
  46. package/dist-esm/src/client/scheduleBroadcastNotification.js.map +1 -0
  47. package/dist-esm/src/client/scheduleNotification.js +18 -0
  48. package/dist-esm/src/client/scheduleNotification.js.map +1 -0
  49. package/dist-esm/src/client/sendBroadcastNotification.js +15 -0
  50. package/dist-esm/src/client/sendBroadcastNotification.js.map +1 -0
  51. package/dist-esm/src/client/sendDirectNotification.js +16 -0
  52. package/dist-esm/src/client/sendDirectNotification.js.map +1 -0
  53. package/dist-esm/src/client/sendNotification.js +16 -0
  54. package/dist-esm/src/client/sendNotification.js.map +1 -0
  55. package/dist-esm/src/client/submitNotificationHubJob.js +26 -0
  56. package/dist-esm/src/client/submitNotificationHubJob.js.map +1 -0
  57. package/dist-esm/src/client/updateInstallation.js +25 -0
  58. package/dist-esm/src/client/updateInstallation.js.map +1 -0
  59. package/dist-esm/src/client/updateRegistration.js +21 -0
  60. package/dist-esm/src/client/updateRegistration.js.map +1 -0
  61. package/dist-esm/src/index.js +12 -0
  62. package/dist-esm/src/index.js.map +1 -0
  63. package/dist-esm/src/models/installation.js +51 -0
  64. package/dist-esm/src/models/installation.js.map +1 -0
  65. package/dist-esm/src/models/notification.js +104 -0
  66. package/dist-esm/src/models/notification.js.map +1 -0
  67. package/dist-esm/src/models/notificationBuilder.js +169 -0
  68. package/dist-esm/src/models/notificationBuilder.js.map +1 -0
  69. package/dist-esm/src/models/notificationDetails.js +4 -0
  70. package/dist-esm/src/models/notificationDetails.js.map +1 -0
  71. package/dist-esm/src/models/notificationHubJob.js +4 -0
  72. package/dist-esm/src/models/notificationHubJob.js.map +1 -0
  73. package/dist-esm/src/models/options.js +4 -0
  74. package/dist-esm/src/models/options.js.map +1 -0
  75. package/dist-esm/src/models/registration.js +135 -0
  76. package/dist-esm/src/models/registration.js.map +1 -0
  77. package/dist-esm/src/models/response.js +4 -0
  78. package/dist-esm/src/models/response.js.map +1 -0
  79. package/dist-esm/src/notificationHubsClient.js +251 -0
  80. package/dist-esm/src/notificationHubsClient.js.map +1 -0
  81. package/dist-esm/src/serializers/notificationDetailsSerializer.js +58 -0
  82. package/dist-esm/src/serializers/notificationDetailsSerializer.js.map +1 -0
  83. package/dist-esm/src/serializers/notificationHubJobSerializer.js +74 -0
  84. package/dist-esm/src/serializers/notificationHubJobSerializer.js.map +1 -0
  85. package/dist-esm/src/serializers/registrationSerializer.js +375 -0
  86. package/dist-esm/src/serializers/registrationSerializer.js.map +1 -0
  87. package/dist-esm/src/utils/connectionStringUtils.js +37 -0
  88. package/dist-esm/src/utils/connectionStringUtils.js.map +1 -0
  89. package/dist-esm/src/utils/constants.js +11 -0
  90. package/dist-esm/src/utils/constants.js.map +1 -0
  91. package/dist-esm/src/utils/retryPolicy.js +144 -0
  92. package/dist-esm/src/utils/retryPolicy.js.map +1 -0
  93. package/dist-esm/src/utils/tracing.js +13 -0
  94. package/dist-esm/src/utils/tracing.js.map +1 -0
  95. package/dist-esm/src/utils/utils.js +130 -0
  96. package/dist-esm/src/utils/utils.js.map +1 -0
  97. package/dist-esm/src/utils/xmlUtils.js +101 -0
  98. package/dist-esm/src/utils/xmlUtils.js.map +1 -0
  99. package/package.json +144 -0
  100. package/types/3.1/notification-hubs.d.ts +1728 -0
  101. package/types/latest/notification-hubs.d.ts +1840 -0
  102. package/types/latest/tsdoc-metadata.json +11 -0
  103. package/types/src/client/cancelScheduledNotification.d.ts +13 -0
  104. package/types/src/client/cancelScheduledNotification.d.ts.map +1 -0
  105. package/types/src/client/createOrUpdateInstallation.d.ts +13 -0
  106. package/types/src/client/createOrUpdateInstallation.d.ts.map +1 -0
  107. package/types/src/client/createOrUpdateRegistration.d.ts +12 -0
  108. package/types/src/client/createOrUpdateRegistration.d.ts.map +1 -0
  109. package/types/src/client/createRegistration.d.ts +13 -0
  110. package/types/src/client/createRegistration.d.ts.map +1 -0
  111. package/types/src/client/createRegistrationId.d.ts +10 -0
  112. package/types/src/client/createRegistrationId.d.ts.map +1 -0
  113. package/types/src/client/deleteInstallation.d.ts +12 -0
  114. package/types/src/client/deleteInstallation.d.ts.map +1 -0
  115. package/types/src/client/deleteRegistration.d.ts +12 -0
  116. package/types/src/client/deleteRegistration.d.ts.map +1 -0
  117. package/types/src/client/getFeedbackContainerUrl.d.ts +11 -0
  118. package/types/src/client/getFeedbackContainerUrl.d.ts.map +1 -0
  119. package/types/src/client/getInstallation.d.ts +12 -0
  120. package/types/src/client/getInstallation.d.ts.map +1 -0
  121. package/types/src/client/getNotificationHubJob.d.ts +12 -0
  122. package/types/src/client/getNotificationHubJob.d.ts.map +1 -0
  123. package/types/src/client/getNotificationOutcomeDetails.d.ts +13 -0
  124. package/types/src/client/getNotificationOutcomeDetails.d.ts.map +1 -0
  125. package/types/src/client/getRegistration.d.ts +12 -0
  126. package/types/src/client/getRegistration.d.ts.map +1 -0
  127. package/types/src/client/index.d.ts +41 -0
  128. package/types/src/client/index.d.ts.map +1 -0
  129. package/types/src/client/internal/_client.d.ts +26 -0
  130. package/types/src/client/internal/_client.d.ts.map +1 -0
  131. package/types/src/client/internal/_createOrUpdateRegistrationDescription.d.ts +8 -0
  132. package/types/src/client/internal/_createOrUpdateRegistrationDescription.d.ts.map +1 -0
  133. package/types/src/client/internal/_scheduleNotificationPayload.d.ts +9 -0
  134. package/types/src/client/internal/_scheduleNotificationPayload.d.ts.map +1 -0
  135. package/types/src/client/internal/_sendNotificationPayload.d.ts +10 -0
  136. package/types/src/client/internal/_sendNotificationPayload.d.ts.map +1 -0
  137. package/types/src/client/listNotificationHubJobs.d.ts +11 -0
  138. package/types/src/client/listNotificationHubJobs.d.ts.map +1 -0
  139. package/types/src/client/listRegistrations.d.ts +12 -0
  140. package/types/src/client/listRegistrations.d.ts.map +1 -0
  141. package/types/src/client/listRegistrationsByTag.d.ts +13 -0
  142. package/types/src/client/listRegistrationsByTag.d.ts.map +1 -0
  143. package/types/src/client/scheduleBroadcastNotification.d.ts +16 -0
  144. package/types/src/client/scheduleBroadcastNotification.d.ts.map +1 -0
  145. package/types/src/client/scheduleNotification.d.ts +17 -0
  146. package/types/src/client/scheduleNotification.d.ts.map +1 -0
  147. package/types/src/client/sendBroadcastNotification.d.ts +14 -0
  148. package/types/src/client/sendBroadcastNotification.d.ts.map +1 -0
  149. package/types/src/client/sendDirectNotification.d.ts +16 -0
  150. package/types/src/client/sendDirectNotification.d.ts.map +1 -0
  151. package/types/src/client/sendNotification.d.ts +15 -0
  152. package/types/src/client/sendNotification.d.ts.map +1 -0
  153. package/types/src/client/submitNotificationHubJob.d.ts +13 -0
  154. package/types/src/client/submitNotificationHubJob.d.ts.map +1 -0
  155. package/types/src/client/updateInstallation.d.ts +14 -0
  156. package/types/src/client/updateInstallation.d.ts.map +1 -0
  157. package/types/src/client/updateRegistration.d.ts +12 -0
  158. package/types/src/client/updateRegistration.d.ts.map +1 -0
  159. package/types/src/index.d.ts +10 -0
  160. package/types/src/index.d.ts.map +1 -0
  161. package/types/src/models/installation.d.ts +200 -0
  162. package/types/src/models/installation.d.ts.map +1 -0
  163. package/types/src/models/notification.d.ts +166 -0
  164. package/types/src/models/notification.d.ts.map +1 -0
  165. package/types/src/models/notificationBuilder.d.ts +546 -0
  166. package/types/src/models/notificationBuilder.d.ts.map +1 -0
  167. package/types/src/models/notificationDetails.d.ts +87 -0
  168. package/types/src/models/notificationDetails.d.ts.map +1 -0
  169. package/types/src/models/notificationHubJob.d.ts +104 -0
  170. package/types/src/models/notificationHubJob.d.ts.map +1 -0
  171. package/types/src/models/options.d.ts +43 -0
  172. package/types/src/models/options.d.ts.map +1 -0
  173. package/types/src/models/registration.d.ts +368 -0
  174. package/types/src/models/registration.d.ts.map +1 -0
  175. package/types/src/models/response.d.ts +41 -0
  176. package/types/src/models/response.d.ts.map +1 -0
  177. package/types/src/notificationHubsClient.d.ts +190 -0
  178. package/types/src/notificationHubsClient.d.ts.map +1 -0
  179. package/types/src/serializers/notificationDetailsSerializer.d.ts +7 -0
  180. package/types/src/serializers/notificationDetailsSerializer.d.ts.map +1 -0
  181. package/types/src/serializers/notificationHubJobSerializer.d.ts +21 -0
  182. package/types/src/serializers/notificationHubJobSerializer.d.ts.map +1 -0
  183. package/types/src/serializers/registrationSerializer.d.ts +193 -0
  184. package/types/src/serializers/registrationSerializer.d.ts.map +1 -0
  185. package/types/src/utils/connectionStringUtils.d.ts +37 -0
  186. package/types/src/utils/connectionStringUtils.d.ts.map +1 -0
  187. package/types/src/utils/constants.d.ts +9 -0
  188. package/types/src/utils/constants.d.ts.map +1 -0
  189. package/types/src/utils/retryPolicy.d.ts +72 -0
  190. package/types/src/utils/retryPolicy.d.ts.map +1 -0
  191. package/types/src/utils/tracing.d.ts +6 -0
  192. package/types/src/utils/tracing.d.ts.map +1 -0
  193. package/types/src/utils/utils.d.ts +65 -0
  194. package/types/src/utils/utils.d.ts.map +1 -0
  195. package/types/src/utils/xmlUtils.d.ts +46 -0
  196. package/types/src/utils/xmlUtils.d.ts.map +1 -0
@@ -0,0 +1,1840 @@
1
+ import { CommonClientOptions } from '@azure/core-client';
2
+ import { OperationOptions } from '@azure/core-client';
3
+ import { PagedAsyncIterableIterator } from '@azure/core-paging';
4
+
5
+ /**
6
+ * Represents an Amazon Device Messaging (ADM) based installation.
7
+ */
8
+ export declare interface AdmInstallation extends DeviceTokenInstallation {
9
+ /**
10
+ * The platform for the installation.
11
+ */
12
+ platform: "adm";
13
+ }
14
+
15
+ /**
16
+ * Represents a native ADM notification message payload.
17
+ */
18
+ export declare interface AdmNativeMessage {
19
+ /**
20
+ * The notification payload to send with the message.
21
+ */
22
+ notification?: AdmNativeNotification;
23
+ /**
24
+ * The payload data to send with the message.
25
+ */
26
+ data?: Record<string, string>;
27
+ /**
28
+ * The priority of the msssage.
29
+ */
30
+ priority?: "normal" | "high";
31
+ /**
32
+ * This is an arbitrary string used to indicate that multiple messages are logically the same
33
+ * and that ADM is allowed to drop previously enqueued messages in favor of this new one.
34
+ */
35
+ consolidationKey?: string;
36
+ /**
37
+ * The number of seconds that ADM should retain the message if the device is offline.
38
+ */
39
+ expiresAfter?: number;
40
+ /**
41
+ * This is a base-64-encoded MD5 checksum of the data parameter.
42
+ */
43
+ md5?: string;
44
+ }
45
+
46
+ /**
47
+ * Describes ADM notification messages.
48
+ */
49
+ export declare interface AdmNativeNotification {
50
+ /**
51
+ * The notification's title.
52
+ */
53
+ title?: string;
54
+ /**
55
+ * The notification's body text.
56
+ */
57
+ body?: string;
58
+ /**
59
+ * The notification's icon.
60
+ */
61
+ icon?: string;
62
+ /**
63
+ * The notification's icon color, expressed in #rrggbb format.
64
+ */
65
+ color?: string;
66
+ /**
67
+ * The sound to play when the device receives the notification. Supports "default" or the filename of a sound resource bundled in the app.
68
+ */
69
+ sound?: string;
70
+ /**
71
+ * Identifier used to replace existing notifications in the notification drawer.
72
+ */
73
+ tag?: string;
74
+ /**
75
+ * The action associated with a user click on the notification.
76
+ */
77
+ clickAction?: string;
78
+ /**
79
+ * 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
+ */
81
+ bodyLocKey?: string;
82
+ /**
83
+ * 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
+ */
85
+ bodyLocArgs?: string[];
86
+ /**
87
+ * 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
+ */
89
+ titleLocKey?: string;
90
+ /**
91
+ * 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
+ */
93
+ titleLocArgs?: string[];
94
+ /**
95
+ * The notification's channel id.
96
+ */
97
+ channelId?: string;
98
+ /**
99
+ * Sets the "ticker" text, which is sent to accessibility services.
100
+ */
101
+ ticker?: string;
102
+ /**
103
+ * When set to false or unset, the notification is automatically dismissed when the user clicks it in the panel.
104
+ */
105
+ sticky?: boolean;
106
+ /**
107
+ * 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
+ */
109
+ eventTime?: string;
110
+ /**
111
+ * Set whether or not this notification is relevant only to the current device.
112
+ */
113
+ localOnly?: boolean;
114
+ /**
115
+ * Set the relative priority for this notification.
116
+ */
117
+ notificationPriority?: number;
118
+ /**
119
+ * If set to true, use the Android framework's default sound for the notification.
120
+ */
121
+ defaultSound?: boolean;
122
+ /**
123
+ * Set the Notification.visibility of the notification.
124
+ */
125
+ visibility?: number;
126
+ /**
127
+ * Sets the number of items this notification represents.
128
+ */
129
+ notificationCount?: number;
130
+ /**
131
+ * Contains the URL of an image that is going to be displayed in a notification.
132
+ */
133
+ image?: string;
134
+ }
135
+
136
+ /**
137
+ * Represents an Amazon Device Messaging (ADM) push notification.
138
+ */
139
+ export declare interface AdmNotification extends JsonNotification {
140
+ /**
141
+ * The platform for the push notification.
142
+ */
143
+ platform: "adm";
144
+ }
145
+
146
+ /**
147
+ * Represents the description of the Amazon Device Messaging (ADM) registration.
148
+ */
149
+ export declare interface AdmRegistrationDescription extends RegistrationDescriptionCommon {
150
+ /**
151
+ * The Amazon Device Messaging registration identifier.
152
+ */
153
+ admRegistrationId: string;
154
+ /**
155
+ * The type of the registration.
156
+ */
157
+ type: "Adm";
158
+ }
159
+
160
+ /**
161
+ * Represents the description of the Amazon Device Messaging (ADM) template registration.
162
+ */
163
+ export declare interface AdmTemplateRegistrationDescription extends Omit<AdmRegistrationDescription, "type">, TemplateRegistrationDescription {
164
+ /**
165
+ * The type of the registration.
166
+ */
167
+ type: "AdmTemplate";
168
+ }
169
+
170
+ /**
171
+ * Represents what is in the APNs alert body.
172
+ */
173
+ export declare interface AppleAlert {
174
+ /**
175
+ * The title of the notification. Apple Watch displays this string in the short look notification
176
+ * interface. Specify a string that’s quickly understood by the user.
177
+ */
178
+ title?: string;
179
+ /**
180
+ * Additional information that explains the purpose of the notification.
181
+ */
182
+ subtitle?: string;
183
+ /**
184
+ * The content of the alert message.
185
+ */
186
+ body?: string;
187
+ /**
188
+ * The name of the launch image file to display. If the user chooses to launch your app,
189
+ * the contents of the specified image or storyboard file are displayed instead of your app’s normal launch image.
190
+ */
191
+ launchImage?: string;
192
+ /**
193
+ * The key for a localized title string. Specify this key instead of the title key to retrieve
194
+ * the title from your app’s Localizable.strings files. The value must contain the name of a key in your strings file.
195
+ */
196
+ titleLocKey?: string;
197
+ /**
198
+ * An array of strings containing replacement values for variables in your title string.
199
+ * Each %\@ character in the string specified by the title-loc-key is replaced by a value
200
+ * from this array. The first item in the array replaces the first instance
201
+ * of the %\@ character in the string, the second item replaces the second instance, and so on.
202
+ */
203
+ titleLocArgs?: string[];
204
+ /**
205
+ * The key for a localized subtitle string. Use this key, instead of the subtitle key, to
206
+ * retrieve the subtitle from your app’s Localizable.strings file.
207
+ * The value must contain the name of a key in your strings file.
208
+ */
209
+ subtitleLocKey?: string;
210
+ /**
211
+ * An array of strings containing replacement values for variables in your title string.
212
+ * Each %\@ character in the string specified by subtitle-loc-key is replaced by a value
213
+ * from this array. The first item in the array replaces the first instance of the
214
+ * %\@ character in the string, the second item replaces the second instance, and so on.
215
+ */
216
+ subtitleLocArgs?: string[];
217
+ /**
218
+ * The key for a localized message string. Use this key, instead of the body key, to
219
+ * retrieve the message text from your app’s Localizable.strings file. The value must contain
220
+ * the name of a key in your strings file.
221
+ */
222
+ locKey?: string;
223
+ /**
224
+ * An array of strings containing replacement values for variables in your message text.
225
+ * Each %\@ character in the string specified by loc-key is replaced by a value from
226
+ * this array. The first item in the array replaces the first instance of the %\@ character
227
+ * in the string, the second item replaces the second instance, and so on.
228
+ */
229
+ locArgs?: string[];
230
+ }
231
+
232
+ /**
233
+ * Represents an APNs critical sound
234
+ */
235
+ export declare interface AppleCriticalSound {
236
+ /**
237
+ * The critical alert flag. Set to 1 to enable the critical alert.
238
+ */
239
+ critical: number;
240
+ /**
241
+ * The name of a sound file in your app’s main bundle or in the Library/Sounds folder
242
+ * of your app’s container directory. Specify the string “default” to play the system sound.
243
+ */
244
+ name: string;
245
+ /**
246
+ * The volume for the critical alert’s sound. Set this to a value between 0 (silent) and 1 (full volume).
247
+ */
248
+ volume: number;
249
+ }
250
+
251
+ /**
252
+ * Represents an Apple APNs based installation.
253
+ */
254
+ export declare interface AppleInstallation extends DeviceTokenInstallation {
255
+ /**
256
+ * The platform for the installation.
257
+ */
258
+ platform: "apns";
259
+ }
260
+
261
+ /**
262
+ * Represents a native APNs message.
263
+ */
264
+ export declare interface AppleNativeMessage extends Record<string, any> {
265
+ /**
266
+ * The information for displaying an alert.
267
+ */
268
+ alert?: string | AppleAlert;
269
+ /**
270
+ * The number to display in a badge on your app’s icon.
271
+ */
272
+ badge?: number;
273
+ /**
274
+ * The name of a sound file in your app’s main bundle or in the Library/Sounds
275
+ * folder of your app’s container directory. Specify the string “default” to
276
+ * play the system sound. Use this key for regular notifications.
277
+ * For critical alerts, use the sound dictionary instead.
278
+ */
279
+ sound?: string | AppleCriticalSound;
280
+ /**
281
+ * An app-specific identifier for grouping related notifications.
282
+ */
283
+ threadId?: string;
284
+ /**
285
+ * The notification’s type.
286
+ */
287
+ category?: string;
288
+ /**
289
+ * The background notification flag. To perform a silent background update,
290
+ * specify the value 1 and don’t include the alert, badge, or sound keys in your payload.
291
+ */
292
+ contentAvailable?: number;
293
+ /**
294
+ * The notification service app extension flag. If the value is 1, the system passes
295
+ * the notification to your notification service app extension before delivery.
296
+ */
297
+ mutableContent?: number;
298
+ /**
299
+ * The identifier of the window brought forward.
300
+ */
301
+ targetContentId?: string;
302
+ /**
303
+ * The importance and delivery timing of a notification.
304
+ */
305
+ interruptionLevel?: "passive" | "active" | "time-sensitive" | "critical";
306
+ /**
307
+ * The relevance score, a number between 0 and 1, that the system uses to sort the
308
+ * notifications from your app. The highest score gets featured in the notification summary.
309
+ */
310
+ relevanceScore?: number;
311
+ /**
312
+ * The criteria the system evaluates to determine if it displays the notification in the current Focus.
313
+ */
314
+ filterCriteria?: string;
315
+ }
316
+
317
+ /**
318
+ * Represents an Apple APNs push notification.
319
+ */
320
+ export declare interface AppleNotification extends JsonNotification {
321
+ /**
322
+ * The platform for the push notification.
323
+ */
324
+ platform: "apple";
325
+ }
326
+
327
+ /**
328
+ * The priority of the Apple push notification.
329
+ */
330
+ export declare type ApplePriority = "10" | "5";
331
+
332
+ /**
333
+ * Represents the description of apple registration.
334
+ */
335
+ export declare interface AppleRegistrationDescription extends RegistrationDescriptionCommon {
336
+ /**
337
+ * The APNs device token.
338
+ */
339
+ deviceToken: string;
340
+ /**
341
+ * The type of the registration.
342
+ */
343
+ type: "Apple";
344
+ }
345
+
346
+ /**
347
+ * Represents the description of the Apple template registration.
348
+ */
349
+ export declare interface AppleTemplateRegistrationDescription extends Omit<AppleRegistrationDescription, "type">, TemplateRegistrationDescription {
350
+ /**
351
+ * The expiry date.
352
+ */
353
+ expiry?: Date;
354
+ /**
355
+ * The notification priority.
356
+ */
357
+ priority?: ApplePriority;
358
+ /**
359
+ * The APNS headers.
360
+ */
361
+ apnsHeaders?: Record<string, string>;
362
+ /**
363
+ * The type of the registration.
364
+ */
365
+ type: "AppleTemplate";
366
+ }
367
+
368
+ /**
369
+ * Represents the Baidu Apple native payload.
370
+ */
371
+ export declare interface BaiduAppleNativePayload {
372
+ /**
373
+ * The alert string.
374
+ */
375
+ alert?: string;
376
+ /**
377
+ * The APNs sound to play.
378
+ */
379
+ sound?: string;
380
+ /**
381
+ * The APNs badge count.
382
+ */
383
+ badge?: number;
384
+ }
385
+
386
+ /**
387
+ * Represents a Baidu based installation.
388
+ */
389
+ export declare interface BaiduInstallation extends DeviceTokenInstallation {
390
+ /**
391
+ * The platform for the installation.
392
+ */
393
+ platform: "baidu";
394
+ }
395
+
396
+ /**
397
+ * Baidu Native Format:
398
+ * https://stackoverflow.com/questions/42591815/customize-baidu-push-json-payload
399
+ * http://www.tuicool.com/articles/ZnmANn
400
+ */
401
+ export declare interface BaiduNativeMessage extends Record<string, any> {
402
+ /**
403
+ * Notification title for Android.
404
+ */
405
+ title?: string;
406
+ /**
407
+ * Baidu Notification description for Android.
408
+ */
409
+ description?: string;
410
+ /**
411
+ * Baidu Notification builder ID.
412
+ */
413
+ notificationBuilderId?: number;
414
+ /**
415
+ * Baidu Notification Android basic style.
416
+ */
417
+ notificationBasicStyle?: number;
418
+ /**
419
+ * Baidu Android open type.
420
+ */
421
+ openType?: number;
422
+ /**
423
+ * Baidu Android net support option.
424
+ */
425
+ netSupport?: number;
426
+ /**
427
+ * Baidu Android user confirm.
428
+ */
429
+ userConfirm?: number;
430
+ /**
431
+ * Baidu Android URL.
432
+ */
433
+ url?: string;
434
+ /**
435
+ * Baidu Android package content.
436
+ */
437
+ pkgContent?: string;
438
+ /**
439
+ * Baidu Android package version.
440
+ */
441
+ pkgVersion?: string;
442
+ /**
443
+ * Baidu Android custom content dictionary.
444
+ */
445
+ customContent?: Record<string, any>;
446
+ /**
447
+ * Baidu APNs support.
448
+ */
449
+ aps?: BaiduAppleNativePayload;
450
+ }
451
+
452
+ /**
453
+ * Represents a Baidu push notification.
454
+ */
455
+ export declare interface BaiduNotification extends JsonNotification {
456
+ /**
457
+ * The platform for the push notification.
458
+ */
459
+ platform: "baidu";
460
+ }
461
+
462
+ /**
463
+ * Represents a Baidu registration description.
464
+ */
465
+ export declare interface BaiduRegistrationDescription extends RegistrationDescriptionCommon {
466
+ /**
467
+ * The Baidu user identifier.
468
+ */
469
+ baiduUserId: string;
470
+ /**
471
+ * The Baidu channel identifier.
472
+ */
473
+ baiduChannelId: string;
474
+ /**
475
+ * The type of the registration.
476
+ */
477
+ type: "Baidu";
478
+ }
479
+
480
+ /**
481
+ * Represents a Baidu template registration description.
482
+ */
483
+ export declare interface BaiduTemplateRegistrationDescription extends Omit<BaiduRegistrationDescription, "type">, TemplateRegistrationDescription {
484
+ /**
485
+ * The type of the registration.
486
+ */
487
+ type: "BaiduTemplate";
488
+ }
489
+
490
+ /**
491
+ * Represents a Browser/Web Push based installation.
492
+ */
493
+ export declare interface BrowserInstallation extends InstallationCommon {
494
+ /**
495
+ * The push channel for the Web Push API.
496
+ */
497
+ pushChannel: BrowserPushChannel;
498
+ /**
499
+ * The platform for the installation.
500
+ */
501
+ platform: "browser";
502
+ }
503
+
504
+ /**
505
+ * Represents a Browser push notification.
506
+ */
507
+ export declare interface BrowserNotification extends JsonNotification {
508
+ /**
509
+ * The platform for the push notification.
510
+ */
511
+ platform: "browser";
512
+ }
513
+
514
+ /**
515
+ * Represents the push channel for a Browser Push installation.
516
+ */
517
+ export declare interface BrowserPushChannel {
518
+ /**
519
+ * The P256DH for the browser push installation.
520
+ */
521
+ p256dh: string;
522
+ /**
523
+ * The auth secret for the browser push installation.
524
+ */
525
+ auth: string;
526
+ /**
527
+ * The endpoint URL for the browser push installation.
528
+ */
529
+ endpoint: string;
530
+ }
531
+
532
+ /**
533
+ * Represents a Browser Push registration description.
534
+ */
535
+ export declare interface BrowserRegistrationDescription extends RegistrationDescriptionCommon {
536
+ /**
537
+ * The Browser push endpoint.
538
+ */
539
+ endpoint: string;
540
+ /**
541
+ * The Browser push P256DH.
542
+ */
543
+ p256dh: string;
544
+ /**
545
+ * The Browser push auth secret.
546
+ */
547
+ auth: string;
548
+ /**
549
+ * The type of the registration.
550
+ */
551
+ type: "Browser";
552
+ }
553
+
554
+ /**
555
+ * Represents a Browser Push remplate registration description.
556
+ */
557
+ export declare interface BrowserTemplateRegistrationDescription extends Omit<BrowserRegistrationDescription, "type">, TemplateRegistrationDescription {
558
+ /**
559
+ * The type of the registration.
560
+ */
561
+ type: "BrowserTemplate";
562
+ }
563
+
564
+ /**
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.
584
+ */
585
+ export declare function buildBaiduNativeMessage(nativeMessage: BaiduNativeMessage, additionalProperties?: Record<string, any>): BaiduNotification;
586
+
587
+ /**
588
+ * Creates a FirebaseLegacyNotification from a native Firebase payload.
589
+ * @param nativeMessage - The native message payload to send to Notification Hubs.
590
+ * @returns The FirebaseLegacyNotification to send to Notification Hubs.
591
+ */
592
+ export declare function buildFirebaseLegacyNativeMessage(nativeMessage: FirebaseLegacyNativeMessage): FirebaseLegacyNotification;
593
+
594
+ /**
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.
598
+ */
599
+ export declare function buildWindowsBadgeNativeMessage(nativeMessage: WindowsBadgeNativeMessage): WindowsNotification;
600
+
601
+ /**
602
+ * Creates an Amazon Device Messaging (ADM) based installation.
603
+ * @param installation - A partial installation used to create the ADM installation.
604
+ * @returns The newly created ADM installation.
605
+ */
606
+ export declare function createAdmInstallation(installation: Omit<AdmInstallation, "platform">): AdmInstallation;
607
+
608
+ /**
609
+ * Creates a notification to send to an Amazon Device Messaging device.
610
+ * @param notification - A partial message used to create a message for Amazon Device Messaging.
611
+ * @returns A newly created Amazon Device Messaging.
612
+ */
613
+ export declare function createAdmNotification(notification: Omit<AdmNotification, "platform" | "contentType">): AdmNotification;
614
+
615
+ /**
616
+ * Creates an ADM registration description.
617
+ * @param description - A partial ADM registration description.
618
+ * @returns A created ADM registration description.
619
+ */
620
+ export declare function createAdmRegistrationDescription(description: Omit<AdmRegistrationDescription, "type">): AdmRegistrationDescription;
621
+
622
+ /**
623
+ * Creates an ADM template registration description.
624
+ * @param description - A partial ADM template registration description.
625
+ * @returns A created ADM template registration description.
626
+ */
627
+ export declare function createAdmTemplateRegistrationDescription(description: Omit<AdmTemplateRegistrationDescription, "type">): AdmTemplateRegistrationDescription;
628
+
629
+ /**
630
+ * Creates an Apple based installation.
631
+ * @param installation - A partial installation used to create the Apple installation.
632
+ * @returns The newly created Apple installation.
633
+ */
634
+ export declare function createAppleInstallation(installation: Omit<AppleInstallation, "platform">): AppleInstallation;
635
+
636
+ /**
637
+ * Creates a notification to send to an Apple device.
638
+ * @param notification - A partial message used to create a message for Apple.
639
+ * @returns A newly created Apple.
640
+ */
641
+ export declare function createAppleNotification(notification: Omit<AppleNotification, "platform" | "contentType">): AppleNotification;
642
+
643
+ /**
644
+ * Creates an Apple registration description.
645
+ * @param description - A partial Apple registration description.
646
+ * @returns A created Apple registration description.
647
+ */
648
+ export declare function createAppleRegistrationDescription(description: Omit<AppleRegistrationDescription, "type">): AppleRegistrationDescription;
649
+
650
+ /**
651
+ * Creates an Apple template registration description.
652
+ * @param description - A partial Apple template registration description.
653
+ * @returns A created Apple template registration description.
654
+ */
655
+ export declare function createAppleTemplateRegistrationDescription(description: Omit<AppleTemplateRegistrationDescription, "type">): AppleTemplateRegistrationDescription;
656
+
657
+ /**
658
+ * Creates a Baidu based installation.
659
+ * @param installation - A partial installation used to create the Baidu installation.
660
+ * @returns The newly created Baidu installation.
661
+ */
662
+ export declare function createBaiduInstallation(installation: Omit<BaiduInstallation, "platform">): BaiduInstallation;
663
+
664
+ /**
665
+ * Creates a notification to send to a Baidu registered device.
666
+ * @param notification - A partial message used to create a message for Baidu.
667
+ * @returns A newly created Baidu.
668
+ */
669
+ export declare function createBaiduNotification(notification: Omit<BaiduNotification, "platform" | "contentType">): BaiduNotification;
670
+
671
+ /**
672
+ * Creates a Baidu registration description.
673
+ * @param description - A partial Baidu registration description.
674
+ * @returns A created Baidu registration description.
675
+ */
676
+ export declare function createBaiduRegistrationDescription(description: Omit<BaiduRegistrationDescription, "type">): BaiduRegistrationDescription;
677
+
678
+ /**
679
+ * Creates a Baidu template registration description.
680
+ * @param description - A partial Baidu template registration description.
681
+ * @returns A created Baidu template registration description.
682
+ */
683
+ export declare function createBaiduTemplateRegistrationDescription(description: Omit<BaiduTemplateRegistrationDescription, "type">): BaiduTemplateRegistrationDescription;
684
+
685
+ /**
686
+ * Creates a Web Push based installation.
687
+ * @param installation - A partial installation used to create the Web Push installation.
688
+ * @returns The newly created Web Push installation.
689
+ */
690
+ export declare function createBrowserInstallation(installation: Omit<BrowserInstallation, "platform">): BrowserInstallation;
691
+
692
+ /**
693
+ * Creates a notification to send to a browser.
694
+ * @param notification - A partial message used to create a message for a browser.
695
+ * @returns A newly created Web Push browser.
696
+ */
697
+ export declare function createBrowserNotification(notification: Omit<BrowserNotification, "platform" | "contentType">): BrowserNotification;
698
+
699
+ /**
700
+ * Creates a Web Push registration description.
701
+ * @param description - A partial Web Push registration description.
702
+ * @returns A created Web Push registration description.
703
+ */
704
+ export declare function createBrowserRegistrationDescription(description: Omit<BrowserRegistrationDescription, "type">): BrowserRegistrationDescription;
705
+
706
+ /**
707
+ * Creates a Web Push registration description.
708
+ * @param description - A partial Web Push template registration description.
709
+ * @returns A created Web Push template registration description.
710
+ */
711
+ export declare function createBrowserTemplateRegistrationDescription(description: Omit<BrowserTemplateRegistrationDescription, "type">): BrowserTemplateRegistrationDescription;
712
+
713
+ /**
714
+ * Creates an FCM registration description.
715
+ * @param description - A partial FCM registration description.
716
+ * @returns A created FCM registration description.
717
+ */
718
+ export declare function createFcmRegistrationDescription(description: Omit<FcmRegistrationDescription, "type">): FcmRegistrationDescription;
719
+
720
+ /**
721
+ * Creates an FCM template registration description.
722
+ * @param description - A partial FCM template registration description.
723
+ * @returns A created FCM template registration description.
724
+ */
725
+ export declare function createFcmTemplateRegistrationDescription(description: Omit<FcmTemplateRegistrationDescription, "type">): FcmTemplateRegistrationDescription;
726
+
727
+ /**
728
+ * Creates a Firebase legacy HTTP based installation.
729
+ * @param installation - A partial installation used to create the Firebase Legacy HTTP installation.
730
+ * @returns The newly created Baidu installation.
731
+ */
732
+ export declare function createFirebaseLegacyInstallation(installation: Omit<FirebaseLegacyInstallation, "platform">): FirebaseLegacyInstallation;
733
+
734
+ /**
735
+ * Creates a notification to send to Firebase.
736
+ * @param notification - A partial message used to create a message for Firebase.
737
+ * @returns A newly created Firebase.
738
+ */
739
+ export declare function createFirebaseLegacyNotification(notification: Omit<FirebaseLegacyNotification, "platform" | "contentType">): FirebaseLegacyNotification;
740
+
741
+ /**
742
+ * @deprecated Use createFcmRegistrationDescription instead.
743
+ * Creates a GCM registration description.
744
+ * @param description - A partial GCM registration description.
745
+ * @returns A created GCM registration description.
746
+ */
747
+ export declare function createGcmRegistrationDescription(description: Omit<GcmRegistrationDescription, "type">): GcmRegistrationDescription;
748
+
749
+ /**
750
+ * @deprecated Use createFcmTemplateRegistrationDescription instead.
751
+ * Creates a GCM template registration description.
752
+ * @param description - A partial GCM template registration description.
753
+ * @returns A created GCM template registration description.
754
+ */
755
+ export declare function createGcmTemplateRegistrationDescription(description: Omit<GcmTemplateRegistrationDescription, "type">): GcmTemplateRegistrationDescription;
756
+
757
+ /**
758
+ * @deprecated Windows Phone is no longer supported.
759
+ * Creates an MPNS registration description.
760
+ * @param description - A partial MPNS registration description.
761
+ * @returns A created MPNS registration description.
762
+ */
763
+ export declare function createMpnsRegistrationDescription(description: Omit<MpnsRegistrationDescription, "type">): MpnsRegistrationDescription;
764
+
765
+ /**
766
+ * @deprecated Windows Phone is no longer supported.
767
+ * Creates an MPNS template registration description.
768
+ * @param description - A partial MPNS template registration description.
769
+ * @returns A created MPNS template registration description.
770
+ */
771
+ export declare function createMpnsTemplateRegistrationDescription(description: Omit<MpnsTemplateRegistrationDescription, "type">): MpnsTemplateRegistrationDescription;
772
+
773
+ /**
774
+ * Creates a notification to send to Firebase.
775
+ * @param notification - A partial message used to create a message for Firebase.
776
+ * @returns A newly created Firebase.
777
+ */
778
+ export declare function createTemplateNotification(notification: Omit<TemplateNotification, "platform" | "contentType">): TemplateNotification;
779
+
780
+ /**
781
+ * Creates a badge message to send to WNS.
782
+ * @param notification - A partial message used to create a badge message for WNS.
783
+ * @returns A newly created WNS badge.
784
+ */
785
+ export declare function createWindowsBadgeNotification(notification: Omit<WindowsNotification, "platform" | "contentType">): WindowsNotification;
786
+
787
+ /**
788
+ * Creates a Windows Notification Services (WNS) based installation.
789
+ * @param installation - A partial installation used to create the WNS installation.
790
+ * @returns The newly created WNS installation.
791
+ */
792
+ export declare function createWindowsInstallation(installation: Omit<WindowsInstallation, "platform">): WindowsInstallation;
793
+
794
+ /**
795
+ * Creates a notification to send to WNS in wns/raw format..
796
+ * @param notification - A partial message used to create a message for WNS in XML format.
797
+ * @returns A newly created WNS message using XML.
798
+ */
799
+ export declare function createWindowsRawNotification(notification: Omit<WindowsNotification, "platform" | "contentType">): WindowsNotification;
800
+
801
+ /**
802
+ * Creates a Windows registration description.
803
+ * @param description - A partial Windows registration description.
804
+ * @returns A created Windows registration description.
805
+ */
806
+ export declare function createWindowsRegistrationDescription(description: Omit<WindowsRegistrationDescription, "type">): WindowsRegistrationDescription;
807
+
808
+ /**
809
+ * Creates a Windows template registration description.
810
+ * @param description - A partial Windows template registration description.
811
+ * @returns A created Windows template registration description.
812
+ */
813
+ export declare function createWindowsTemplateRegistrationDescription(description: Omit<WindowsTemplateRegistrationDescription, "type">): WindowsTemplateRegistrationDescription;
814
+
815
+ /**
816
+ * Creates a tile message to send to WNS.
817
+ * @param notification - A partial message used to create a tile message for WNS.
818
+ * @returns A newly created WNS tile.
819
+ */
820
+ export declare function createWindowsTileNotification(notification: Omit<WindowsNotification, "platform" | "contentType">): WindowsNotification;
821
+
822
+ /**
823
+ * Creates a toast message to send to WNS.
824
+ * @param notification - A partial message used to create a toast message for WNS.
825
+ * @returns A newly created WNS toast.
826
+ */
827
+ export declare function createWindowsToastNotification(notification: Omit<WindowsNotification, "platform" | "contentType">): WindowsNotification;
828
+
829
+ /**
830
+ * Represents an installation with a string based device token.
831
+ */
832
+ export declare interface DeviceTokenInstallation extends InstallationCommon {
833
+ /**
834
+ * The push channel for a device.
835
+ */
836
+ pushChannel: string;
837
+ }
838
+
839
+ /**
840
+ * Represents entity update operation options that can be set.
841
+ */
842
+ export declare interface EntityOperationOptions extends OperationOptions {
843
+ /**
844
+ * ETag as returned by creation, update, and retrieval, or ‘*’ (overwrite).
845
+ */
846
+ etag?: string;
847
+ }
848
+
849
+ /**
850
+ * Represents Notification Hub registration description for Firebase Legacy HTTP API.
851
+ */
852
+ export declare interface FcmRegistrationDescription extends RegistrationDescriptionCommon {
853
+ /**
854
+ * Registration id obtained from the Google Cloud Messaging service.
855
+ */
856
+ fcmRegistrationId: string;
857
+ /**
858
+ * The type of the registration.
859
+ */
860
+ type: "Fcm";
861
+ }
862
+
863
+ /**
864
+ * Represents Notification Hub template registration description for Firebase Legacy HTTP API.
865
+ */
866
+ export declare interface FcmTemplateRegistrationDescription extends Omit<FcmRegistrationDescription, "type">, TemplateRegistrationDescription {
867
+ /**
868
+ * The type of the registration.
869
+ */
870
+ type: "FcmTemplate";
871
+ }
872
+
873
+ /**
874
+ * Represents an Android native payload for the Firebase Legacy HTTP interface.
875
+ */
876
+ export declare interface FirebaseLegacyAndroidNativePayload {
877
+ /**
878
+ * The notification's title.
879
+ */
880
+ title?: string;
881
+ /**
882
+ * The notification's body text.
883
+ */
884
+ body?: string;
885
+ /**
886
+ * The notification's channel ID.
887
+ */
888
+ androidChannelId?: string;
889
+ /**
890
+ * The notification's icon.
891
+ */
892
+ icon?: string;
893
+ /**
894
+ * The sound to play when the device receives the notification.
895
+ */
896
+ sound?: string;
897
+ /**
898
+ * Identifier used to replace existing notifications in the notification drawer.
899
+ */
900
+ tag?: string;
901
+ /**
902
+ * The notification's icon color, expressed in #rrggbb format.
903
+ */
904
+ color?: string;
905
+ /**
906
+ * The action associated with a user click on the notification.
907
+ */
908
+ clickAction?: string;
909
+ /**
910
+ * 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.
911
+ */
912
+ bodyLocKey?: string;
913
+ /**
914
+ * 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.
915
+ */
916
+ bodyLocArgs?: string[];
917
+ /**
918
+ * 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.
919
+ */
920
+ titleLocKey?: string;
921
+ /**
922
+ * 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.
923
+ */
924
+ titleLocArgs?: string[];
925
+ }
926
+
927
+ /**
928
+ * Represents an APNs native payload for the Firebase Legacy HTTP interface.
929
+ */
930
+ export declare interface FirebaseLegacyAppleNativePayload {
931
+ /**
932
+ * The notification's title.
933
+ */
934
+ title?: string;
935
+ /**
936
+ * The notification's body text.
937
+ */
938
+ body?: string;
939
+ /**
940
+ * The sound to play when the device receives the notification.
941
+ */
942
+ sound?: string;
943
+ /**
944
+ * The value of the badge on the home screen app icon.
945
+ */
946
+ badge?: string;
947
+ /**
948
+ * The action associated with a user click on the notification which corresponds to the APNs category.
949
+ */
950
+ clickAction?: string;
951
+ /**
952
+ * The notification's subtitle.
953
+ */
954
+ subtitle?: string;
955
+ /**
956
+ * 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.
957
+ */
958
+ bodyLocKey?: string;
959
+ /**
960
+ * 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.
961
+ */
962
+ bodyLocArgs?: string[];
963
+ /**
964
+ * 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.
965
+ */
966
+ titleLocKey?: string;
967
+ /**
968
+ * 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.
969
+ */
970
+ titleLocArgs?: string[];
971
+ }
972
+
973
+ /**
974
+ * Represents a Firebase Legacy HTTP installation.
975
+ */
976
+ export declare interface FirebaseLegacyInstallation extends DeviceTokenInstallation {
977
+ /**
978
+ * The platform for the installation.
979
+ */
980
+ platform: "gcm";
981
+ }
982
+
983
+ /**
984
+ * Represents the targets, options, and payload for HTTP JSON messages for the Firebase Legacy HTTP interface.
985
+ */
986
+ export declare interface FirebaseLegacyNativeMessage {
987
+ /**
988
+ * The recipient of a message.
989
+ */
990
+ to?: string;
991
+ /**
992
+ * The recipient of a multicast message, a message sent to more than one registration token.
993
+ */
994
+ registrationIds?: string[];
995
+ /**
996
+ * A logical expression of conditions that determine the message target.
997
+ */
998
+ condition?: string;
999
+ /**
1000
+ * Used to identify a group of messages.
1001
+ */
1002
+ collapseKey?: string;
1003
+ /**
1004
+ * The priority of the message.
1005
+ */
1006
+ priority?: "normal" | "high";
1007
+ /**
1008
+ * The background notification flag. To perform a silent background update,
1009
+ * specify the value 1 and don’t include the alert, badge, or sound keys in your payload.
1010
+ */
1011
+ contentAvailable?: boolean;
1012
+ /**
1013
+ * The notification service app extension flag. If the value is 1, the system passes
1014
+ * the notification to your notification service app extension before delivery.
1015
+ */
1016
+ mutableContent?: number;
1017
+ /**
1018
+ * Specifies how long (in seconds) the message should be kept in FCM storage if the device is offline
1019
+ */
1020
+ timeToLive?: number;
1021
+ /**
1022
+ * The package name of the application where the registration tokens must match in order to receive the message.
1023
+ */
1024
+ restrictedPackageName?: string;
1025
+ /**
1026
+ * When set to true, allows developers to test a request without actually sending a message.
1027
+ */
1028
+ dryRun?: boolean;
1029
+ /**
1030
+ * Custom key-value pairs of the message's payload.
1031
+ */
1032
+ data?: Record<string, any>;
1033
+ /**
1034
+ * The predefined, user-visible key-value pairs of the notification payload.
1035
+ */
1036
+ notification?: FirebaseLegacyAppleNativePayload | FirebaseLegacyAndroidNativePayload | FirebaseLegacyWebNativePayload;
1037
+ }
1038
+
1039
+ /**
1040
+ * Represents a Firebase legacy HTTP push notification.
1041
+ */
1042
+ export declare interface FirebaseLegacyNotification extends JsonNotification {
1043
+ /**
1044
+ * The platform for the push notification.
1045
+ */
1046
+ platform: "gcm";
1047
+ }
1048
+
1049
+ /**
1050
+ * Represents an Web Push native payload for the Firebase Legacy HTTP interface.
1051
+ */
1052
+ export declare interface FirebaseLegacyWebNativePayload {
1053
+ /**
1054
+ * The notification's title.
1055
+ */
1056
+ title?: string;
1057
+ /**
1058
+ * The notification's body text.
1059
+ */
1060
+ body?: string;
1061
+ /**
1062
+ * The URL to use for the notification's icon.
1063
+ */
1064
+ icon?: string;
1065
+ /**
1066
+ * The action associated with a user click on the notification.
1067
+ */
1068
+ clickAction?: string;
1069
+ }
1070
+
1071
+ /**
1072
+ * Represents Notification Hub registration description for Google Cloud Messaging.
1073
+ * @deprecated Use FcmRegistrationDescription instead.
1074
+ */
1075
+ export declare interface GcmRegistrationDescription extends RegistrationDescriptionCommon {
1076
+ /**
1077
+ * Registration id obtained from the Google Cloud Messaging service.
1078
+ */
1079
+ gcmRegistrationId: string;
1080
+ /**
1081
+ * The type of the registration.
1082
+ */
1083
+ type: "Gcm";
1084
+ }
1085
+
1086
+ /**
1087
+ * @deprecated Use createFcmTemplateRegistrationDescription instead.
1088
+ * Represents Notification Hub template registration description for Google Cloud Messaging.
1089
+ * @deprecated Use FcmTemplateRegistrationDescription instead
1090
+ */
1091
+ export declare interface GcmTemplateRegistrationDescription extends Omit<GcmRegistrationDescription, "type">, TemplateRegistrationDescription {
1092
+ /**
1093
+ * The type of the registration.
1094
+ */
1095
+ type: "GcmTemplate";
1096
+ }
1097
+
1098
+ /**
1099
+ * Represents the types of installations available in Notification Hubs.
1100
+ */
1101
+ export declare type Installation = AppleInstallation | AdmInstallation | BaiduInstallation | BrowserInstallation | FirebaseLegacyInstallation | WindowsInstallation;
1102
+
1103
+ /**
1104
+ * Represents an installation for a device for Notification Hubs.
1105
+ */
1106
+ export declare interface InstallationCommon {
1107
+ /**
1108
+ * The ID for the installation.
1109
+ */
1110
+ installationId: string;
1111
+ /**
1112
+ * The User ID for the installation used for targeting.
1113
+ */
1114
+ userId?: string;
1115
+ /**
1116
+ * The installation expiration time.
1117
+ */
1118
+ readonly expirationTime?: string;
1119
+ /**
1120
+ * The last update date of the installation.
1121
+ */
1122
+ readonly lastUpdate?: string;
1123
+ /**
1124
+ * The platform for the installation.
1125
+ */
1126
+ platform: "apns" | "adm" | "baidu" | "browser" | "gcm" | "wns";
1127
+ /**
1128
+ * The tags used for targeting this installation.
1129
+ */
1130
+ tags?: string[];
1131
+ /**
1132
+ * The templates for the installation.
1133
+ */
1134
+ templates?: Record<string, InstallationTemplate>;
1135
+ }
1136
+
1137
+ /**
1138
+ * Represents an installation template.
1139
+ */
1140
+ export declare interface InstallationTemplate {
1141
+ /**
1142
+ * The body for the installation template.
1143
+ */
1144
+ body: string;
1145
+ /**
1146
+ * Headers to include for the template send.
1147
+ */
1148
+ headers: Record<string, string>;
1149
+ /**
1150
+ * The tags to include for the template.
1151
+ */
1152
+ tags?: string[];
1153
+ }
1154
+
1155
+ /**
1156
+ * Represents a JSON notification hub.
1157
+ */
1158
+ export declare interface JsonNotification extends NotificationCommon {
1159
+ /**
1160
+ * The content type for the push notification.
1161
+ */
1162
+ contentType: "application/json;charset=utf-8";
1163
+ }
1164
+
1165
+ /**
1166
+ * Represents a patch operation.
1167
+ */
1168
+ export declare interface JsonPatch {
1169
+ /**
1170
+ * The patch operation.
1171
+ */
1172
+ op: JsonPatchOperation;
1173
+ /**
1174
+ * The path for the patch operation.
1175
+ */
1176
+ path: string;
1177
+ /**
1178
+ * The value to add or replace for the operation.
1179
+ */
1180
+ value?: string;
1181
+ }
1182
+
1183
+ /**
1184
+ * Represents the JSON Patch types of add, remove and replace.
1185
+ */
1186
+ export declare type JsonPatchOperation = "add" | "remove" | "replace";
1187
+
1188
+ /**
1189
+ * Represents a Windows Phone Notification Services registration description.
1190
+ * @deprecated Windows Phone is no longer supported.
1191
+ */
1192
+ export declare interface MpnsRegistrationDescription extends RegistrationDescriptionCommon {
1193
+ /**
1194
+ * The channel URI.
1195
+ */
1196
+ channelUri: string;
1197
+ /**
1198
+ * The type of the registration.
1199
+ */
1200
+ type: "Mpns";
1201
+ }
1202
+
1203
+ /**
1204
+ * Represents a Windows Phone Notification Services template registration.
1205
+ * @deprecated Windows Phone is no longer supported.
1206
+ */
1207
+ export declare interface MpnsTemplateRegistrationDescription extends Omit<MpnsRegistrationDescription, "type">, TemplateRegistrationDescription {
1208
+ /**
1209
+ * The WNS headers.
1210
+ */
1211
+ mpnsHeaders?: Record<string, string>;
1212
+ /**
1213
+ * The type of the registration.
1214
+ */
1215
+ type: "MpnsTemplate";
1216
+ }
1217
+
1218
+ /**
1219
+ * Represents the possible push notification messages types.
1220
+ */
1221
+ export declare type Notification = AppleNotification | AdmNotification | BaiduNotification | BrowserNotification | FirebaseLegacyNotification | WindowsNotification | TemplateNotification;
1222
+
1223
+ /**
1224
+ * Represents a notification hub.
1225
+ */
1226
+ export declare interface NotificationCommon {
1227
+ /**
1228
+ * The body for the push notification.
1229
+ */
1230
+ body: string;
1231
+ /**
1232
+ * The headers to include for the push notification.
1233
+ */
1234
+ headers?: Record<string, string>;
1235
+ /**
1236
+ * The platform for the push notification.
1237
+ */
1238
+ platform: string;
1239
+ /**
1240
+ * The content type for the push notification.
1241
+ */
1242
+ contentType: string;
1243
+ }
1244
+
1245
+ /**
1246
+ * Represents Notification details.
1247
+ */
1248
+ export declare interface NotificationDetails {
1249
+ /**
1250
+ * The unique notification identifier.
1251
+ */
1252
+ notificationId?: string;
1253
+ /**
1254
+ * The notification location.
1255
+ */
1256
+ location?: string;
1257
+ /**
1258
+ * The notification state.
1259
+ */
1260
+ state?: NotificationOutcomeState;
1261
+ /**
1262
+ * The enqueue time of the notification.
1263
+ */
1264
+ enqueueTime?: Date;
1265
+ /**
1266
+ * The notification send start time.
1267
+ */
1268
+ startTime?: Date;
1269
+ /**
1270
+ * The notification send end time.
1271
+ */
1272
+ endTime?: Date;
1273
+ /**
1274
+ * The notification body.
1275
+ */
1276
+ notificationBody?: string;
1277
+ /**
1278
+ * The notification tags.
1279
+ */
1280
+ tags?: string;
1281
+ /**
1282
+ * The notification platforms targeted.
1283
+ */
1284
+ targetPlatforms?: string;
1285
+ /**
1286
+ * The URL for the platform notification services errors.
1287
+ */
1288
+ pnsErrorDetailsUrl?: string;
1289
+ /**
1290
+ * APNs outcomes counts per state.
1291
+ */
1292
+ apnsOutcomeCounts?: NotificationOutcomeCollectionItem[];
1293
+ /**
1294
+ * WNS outcomes counts per state.
1295
+ */
1296
+ wnsOutcomeCounts?: NotificationOutcomeCollectionItem[];
1297
+ /**
1298
+ * FCM outcome counts per state.
1299
+ */
1300
+ fcmOutcomeCounts?: NotificationOutcomeCollectionItem[];
1301
+ /**
1302
+ * ADM outcome counts per state.
1303
+ */
1304
+ admOutcomeCounts?: NotificationOutcomeCollectionItem[];
1305
+ /**
1306
+ * Baidu outcome counts per state.
1307
+ */
1308
+ baiduOutcomeCounts?: NotificationOutcomeCollectionItem[];
1309
+ /**
1310
+ * Web Push outcome counts per state.
1311
+ */
1312
+ browserOutcomeCounts?: NotificationOutcomeCollectionItem[];
1313
+ }
1314
+
1315
+ /**
1316
+ * Represents a Notification Hub Job.
1317
+ */
1318
+ export declare interface NotificationHubJob {
1319
+ /**
1320
+ * The unique job identifier.
1321
+ */
1322
+ jobId?: string;
1323
+ /**
1324
+ * The output file name.
1325
+ */
1326
+ outputFileName?: string;
1327
+ /**
1328
+ * The file name for the job failures.
1329
+ */
1330
+ failuresFileName?: string;
1331
+ /**
1332
+ * The progress for the job.
1333
+ */
1334
+ progress?: number;
1335
+ /**
1336
+ * The type of job.
1337
+ */
1338
+ type: NotificationHubJobType;
1339
+ /**
1340
+ * The status of the job.
1341
+ */
1342
+ status?: NotificationHubJobStatus;
1343
+ /**
1344
+ * The output container URL.
1345
+ */
1346
+ outputContainerUrl: string;
1347
+ /**
1348
+ * The import file URL.
1349
+ */
1350
+ importFileUrl?: string;
1351
+ /**
1352
+ * The input properties for the notification hub job.
1353
+ */
1354
+ inputProperties?: Record<string, string>;
1355
+ /**
1356
+ * Gets the notification hub job failure message.
1357
+ */
1358
+ failure?: string;
1359
+ /**
1360
+ * The output properties for the notification hub job.
1361
+ */
1362
+ outputProperties?: Record<string, string>;
1363
+ /**
1364
+ * Notification hub job created date.
1365
+ */
1366
+ createdAt?: Date;
1367
+ /**
1368
+ * Notification hub job last updated date.
1369
+ */
1370
+ updatedAt?: Date;
1371
+ }
1372
+
1373
+ /**
1374
+ * Describes the types of notification hub job statuses.
1375
+ */
1376
+ export declare type NotificationHubJobStatus =
1377
+ /**
1378
+ * Indicates that the NotificationHubJob was accepted.
1379
+ */
1380
+ "Started"
1381
+ /**
1382
+ * Indicates that the NotificationHubJob is currently running. Depending on the amount of data,
1383
+ * a job may stay in this state for several hours.
1384
+ */
1385
+ | "Running"
1386
+ /**
1387
+ * Indicates that the NotificationHubJob was completed successfully. Any output
1388
+ * will be ready where configured via the NotificationHubJob object.
1389
+ */
1390
+ | "Completed"
1391
+ /**
1392
+ * Indicates that the NotificationHubJob has failed.
1393
+ */
1394
+ | "Failed";
1395
+
1396
+ /**
1397
+ * Describes the types of notification hub jobs.
1398
+ */
1399
+ export declare type NotificationHubJobType =
1400
+ /**
1401
+ * Job type to bulk get registrations.
1402
+ */
1403
+ "ExportRegistrations"
1404
+ /**
1405
+ * Job type to bulk create registrations.
1406
+ */
1407
+ | "ImportCreateRegistrations"
1408
+ /**
1409
+ * Job type to bulk update registrations.
1410
+ */
1411
+ | "ImportUpdateRegistrations"
1412
+ /**
1413
+ * Job type to bulk delete registrations.
1414
+ */
1415
+ | "ImportDeleteRegistrations"
1416
+ /**
1417
+ * Job type to bulk upsert registrations.
1418
+ */
1419
+ | "ImportUpsertRegistrations";
1420
+
1421
+ /**
1422
+ * Describes the options that can be provided while creating the NotificationHubsClientContext.
1423
+ */
1424
+ export declare interface NotificationHubsClientOptions extends CommonClientOptions {
1425
+ }
1426
+
1427
+ /**
1428
+ * Describes a response from the Notification Hubs service for send operations.
1429
+ */
1430
+ export declare interface NotificationHubsMessageResponse extends NotificationHubsResponse {
1431
+ /**
1432
+ * The notification ID from the operation. Note this is only available in Standard SKU and above.
1433
+ */
1434
+ notificationId?: string;
1435
+ }
1436
+
1437
+ /**
1438
+ * Describes a response from the Notification Hubs which includes a tracking ID, correlation ID and location.
1439
+ */
1440
+ export declare interface NotificationHubsResponse {
1441
+ /**
1442
+ * The Tracking ID of the operation.
1443
+ */
1444
+ trackingId?: string;
1445
+ /**
1446
+ * The correlation ID of the operation.
1447
+ */
1448
+ correlationId?: string;
1449
+ /**
1450
+ * The location of the operation.
1451
+ */
1452
+ location?: string;
1453
+ }
1454
+
1455
+ /**
1456
+ * This represents a client for Azure Notification Hubs to manage installations and send
1457
+ * messages to devices.
1458
+ */
1459
+ export declare class NotificationHubsServiceClient {
1460
+ private _client;
1461
+ /**
1462
+ * Creates a new instance of the NotificationClient with a connection string, hub name and options.
1463
+ * @param connectionString - The Notification Hub Access Policy connection string.
1464
+ * @param hubName - The name of the Azure Notification Hub.
1465
+ * @param options - Options for configuring the Azure Notification Hubs client.
1466
+ */
1467
+ constructor(connectionString: string, hubName: string, options?: NotificationHubsClientOptions);
1468
+ /**
1469
+ * Creates or overwrites an installation to a Notification Hub.
1470
+ * @param installation - The installation to create or overwrite.
1471
+ * @param options - Configuration options for the create or update installation operation.
1472
+ * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.
1473
+ */
1474
+ createOrUpdateInstallation(installation: Installation, options?: OperationOptions): Promise<NotificationHubsResponse>;
1475
+ /**
1476
+ * Deletes an installation from a Notification Hub.
1477
+ * @param installationId - The installation ID of the installation to delete.
1478
+ * @param options - Configuration options for the installation delete operation.
1479
+ * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.
1480
+ */
1481
+ deleteInstallation(installationId: string, options?: OperationOptions): Promise<NotificationHubsResponse>;
1482
+ /**
1483
+ * Gets an Azure Notification Hub installation by the installation ID.
1484
+ * @param installationId - The ID of the installation to get.
1485
+ * @param options - Configuration options for the get installation operation.
1486
+ * @returns The installation that matches the installation ID.
1487
+ */
1488
+ getInstallation(installationId: string, options?: OperationOptions): Promise<Installation>;
1489
+ /**
1490
+ * Updates an installation using the JSON-Patch standard in RFC6902.
1491
+ * @param installationId - The ID of the installation to update.
1492
+ * @param patches - An array of patches following the JSON-Patch standard.
1493
+ * @param options - Configuration options for the patch installation operation.
1494
+ * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.
1495
+ */
1496
+ updateInstallation(installationId: string, patches: JsonPatch[], options?: OperationOptions): Promise<NotificationHubsResponse>;
1497
+ /**
1498
+ * Creates a new registration ID.
1499
+ * @param options - The options for creating a new registration ID.
1500
+ * @returns The newly created registration ID.
1501
+ */
1502
+ createRegistrationId(options?: OperationOptions): Promise<string>;
1503
+ /**
1504
+ * Creates a new registration. This method generates a registration ID,
1505
+ * which you can subsequently use to retrieve, update, and delete this registration.
1506
+ * @param registration - The registration to create.
1507
+ * @param options - Options for creating a new registration.
1508
+ * @returns The newly created registration description.
1509
+ */
1510
+ createRegistration(registration: RegistrationDescription, options?: OperationOptions): Promise<RegistrationDescription>;
1511
+ /**
1512
+ * Creates or updates a registration.
1513
+ * @param registration - The registration to create or update.
1514
+ * @param options - The operation options.
1515
+ * @returns The created or updated registration description.
1516
+ */
1517
+ createOrUpdateRegistration(registration: RegistrationDescription, options?: OperationOptions): Promise<RegistrationDescription>;
1518
+ /**
1519
+ * Updates an existing registration.
1520
+ * @param registration - The registration to update.
1521
+ * @param options - The operation options.
1522
+ * @returns The updated registration description.
1523
+ */
1524
+ updateRegistration(registration: RegistrationDescription, options?: OperationOptions): Promise<RegistrationDescription>;
1525
+ /**
1526
+ * Gets a registration by the given registration ID.
1527
+ * @param registrationId - The ID of the registration to get.
1528
+ * @param options - The options for getting a registration by ID.
1529
+ * @returns A RegistrationDescription that has the given registration ID.
1530
+ */
1531
+ getRegistration(registrationId: string, options?: OperationOptions): Promise<RegistrationDescription>;
1532
+ /**
1533
+ * Gets all registrations for the notification hub with the given query options.
1534
+ * @param options - The options for querying the registrations such as $top and $filter.
1535
+ * @returns A paged async iterable containing all of the registrations for the notification hub.
1536
+ */
1537
+ listRegistrations(options?: RegistrationQueryOptions): PagedAsyncIterableIterator<RegistrationDescription>;
1538
+ /**
1539
+ * Lists all registrations with the matching tag.
1540
+ * @param tag - The tag to query for matching registrations.
1541
+ * @param options - The query options such as $top.
1542
+ * @returns A paged async iterable containing the matching registrations for the notification hub.
1543
+ */
1544
+ listRegistrationsByTag(tag: string, options?: RegistrationQueryLimitOptions): PagedAsyncIterableIterator<RegistrationDescription>;
1545
+ /**
1546
+ * Sends a direct push notification to a device with the given push handle.
1547
+ * @param pushHandle - The push handle which is the unique identifier for the device.
1548
+ * @param notification - The notification to send to the device.
1549
+ * @param options - Configuration options for the direct send operation which can contain custom headers
1550
+ * which may include APNs specific such as apns-topic or for WNS, X-WNS-TYPE.
1551
+ * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.
1552
+ */
1553
+ sendDirectNotification(pushHandle: PushHandle, notification: Notification, options?: SendOperationOptions): Promise<NotificationHubsMessageResponse>;
1554
+ /**
1555
+ * Sends push notifications to devices that match the given tags or tag expression.
1556
+ * @param tags - The tags used to target the device for push notifications in either an array or tag expression.
1557
+ * @param notification - The notification to send to the matching devices.
1558
+ * @param options - Configuration options for the direct send operation which can contain custom headers
1559
+ * which may include APNs specific such as apns-topic or for WNS, X-WNS-TYPE.
1560
+ * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.
1561
+ */
1562
+ sendNotification(tags: string[] | string, notification: Notification, options?: SendOperationOptions): Promise<NotificationHubsMessageResponse>;
1563
+ /**
1564
+ * Sends push notifications to all devices on the Notification Hub.
1565
+ * @param notification - The notification to send to all devices.
1566
+ * @param options - Configuration options for the direct send operation which can contain custom headers
1567
+ * which may include APNs specific such as apns-topic or for WNS, X-WNS-TYPE.
1568
+ * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.
1569
+ */
1570
+ sendBroadcastNotification(notification: Notification, options?: SendOperationOptions): Promise<NotificationHubsMessageResponse>;
1571
+ /**
1572
+ * Schedules a push notification to devices that match the given tags or tag expression at the specified time.
1573
+ * NOTE: This is only available in Standard SKU Azure Notification Hubs.
1574
+ * @param scheduledTime - The Date to send the push notification.
1575
+ * @param tags - The tags used to target the device for push notifications in either an array or tag expression.
1576
+ * @param notification - The notification to send to the matching devices.
1577
+ * @param options - Configuration options for the direct send operation which can contain custom headers
1578
+ * which may include APNs specific such as apns-topic or for WNS, X-WNS-TYPE.
1579
+ * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.
1580
+ */
1581
+ scheduleNotification(scheduledTime: Date, tags: string[] | string, notification: Notification, options?: OperationOptions): Promise<NotificationHubsMessageResponse>;
1582
+ /**
1583
+ * Schedules a push notification to all devices registered on the Notification Hub.
1584
+ * NOTE: This is only available in Standard SKU Azure Notification Hubs.
1585
+ * @param scheduledTime - The Date to send the push notification.
1586
+ * @param notification - The notification to send to the matching devices.
1587
+ * @param options - Configuration options for the direct send operation which can contain custom headers
1588
+ * which may include APNs specific such as apns-topic or for WNS, X-WNS-TYPE.
1589
+ * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.
1590
+ */
1591
+ scheduleBroadcastNotification(scheduledTime: Date, notification: Notification, options?: OperationOptions): Promise<NotificationHubsMessageResponse>;
1592
+ /**
1593
+ * Cancels the scheduled notification with the given notification ID.
1594
+ * @param notificationId - The notification ID from the scheduled notification.
1595
+ * @param options - The operation options.
1596
+ * @returns A notification hub response with correlation ID and tracking ID.
1597
+ */
1598
+ cancelScheduledNotification(notificationId: string, options?: OperationOptions): Promise<NotificationHubsResponse>;
1599
+ /**
1600
+ * Retrieves an Azure Storage container URL. The container has feedback data for the notification hub.
1601
+ * The caller can then use the Azure Storage Services SDK to retrieve the contents of the container.
1602
+ * @param options - The options for getting the push notification feedback container URL.
1603
+ * @returns The URL of the Azure Storage Container containing the feedback data.
1604
+ */
1605
+ getFeedbackContainerUrl(options?: OperationOptions): Promise<string>;
1606
+ /**
1607
+ * Retrieves the results of a send operation. This can retrieve intermediate results if the send is being processed
1608
+ * or final results if the Send* has completed. This API can only be called for Standard SKU and above.
1609
+ * @param notificationId - The notification ID returned from the send operation.
1610
+ * @param options - The operation options.
1611
+ * @returns The results of the send operation.
1612
+ */
1613
+ getNotificationOutcomeDetails(notificationId: string, options?: OperationOptions): Promise<NotificationDetails>;
1614
+ /**
1615
+ * Gets a Notification Hub Job by the ID.
1616
+ * @param jobId - The Notification Hub Job ID.
1617
+ * @param options - The operation options.
1618
+ * @returns The Notification Hub Job with the matching ID.
1619
+ */
1620
+ getNotificationHubJob(jobId: string, options?: OperationOptions): Promise<NotificationHubJob>;
1621
+ /**
1622
+ * Submits a Notification Hub Job. Note this is available to Standard SKU namespace and above.
1623
+ * @param job - The notification hub job to submit.
1624
+ * @param options - The operation options.
1625
+ * @returns The notification hub job details including job ID and status.
1626
+ */
1627
+ submitNotificationHubJob(job: NotificationHubJob, options?: OperationOptions): Promise<NotificationHubJob>;
1628
+ /**
1629
+ * Gets all Notification Hub Jobs for this Notification Hub.
1630
+ * @param options - The operation options.
1631
+ * @returns An array of all Notification Hub Jobs for this Notification Hub.
1632
+ */
1633
+ listNotificationHubJobs(options?: OperationOptions): Promise<NotificationHubJob[]>;
1634
+ }
1635
+
1636
+ /**
1637
+ * The per platform count per state.
1638
+ */
1639
+ export declare interface NotificationOutcomeCollectionItem {
1640
+ /**
1641
+ * The state of the notification.
1642
+ */
1643
+ state: string;
1644
+ /**
1645
+ * The count of notifications per state.
1646
+ */
1647
+ count: number;
1648
+ }
1649
+
1650
+ /**
1651
+ * Represents the notification outcome states.
1652
+ */
1653
+ export declare type NotificationOutcomeState = "Enqueued" | "DetailedStateAvailable" | "Processing" | "Completed" | "Abandoned" | "Unknown" | "NoTargetFound" | "Cancelled";
1654
+
1655
+ /**
1656
+ * Represents the types of push channels available for Notification Hubs.
1657
+ */
1658
+ export declare type PushHandle = BrowserPushChannel | string;
1659
+
1660
+ /**
1661
+ * Describes the types of registration descriptions.
1662
+ */
1663
+ export declare type RegistrationDescription = AdmRegistrationDescription | AdmTemplateRegistrationDescription | AppleRegistrationDescription | AppleTemplateRegistrationDescription | BaiduRegistrationDescription | BaiduTemplateRegistrationDescription | BrowserRegistrationDescription | BrowserTemplateRegistrationDescription | GcmRegistrationDescription | GcmTemplateRegistrationDescription | FcmRegistrationDescription | FcmTemplateRegistrationDescription | MpnsRegistrationDescription | MpnsTemplateRegistrationDescription | WindowsRegistrationDescription | WindowsTemplateRegistrationDescription;
1664
+
1665
+ /**
1666
+ * Represents a registration description.
1667
+ */
1668
+ export declare interface RegistrationDescriptionCommon {
1669
+ /**
1670
+ * The registration ID.
1671
+ */
1672
+ registrationId?: string;
1673
+ /**
1674
+ * The expiration time of the registration.
1675
+ */
1676
+ expirationTime?: Date;
1677
+ /**
1678
+ * The ETag associated with this description.
1679
+ */
1680
+ etag?: string;
1681
+ /**
1682
+ * The tags associated with the registration.
1683
+ */
1684
+ tags?: string[];
1685
+ /**
1686
+ * A dictionary of push variables associated with property bag.
1687
+ */
1688
+ pushVariables?: Record<string, string>;
1689
+ /**
1690
+ * The type of the registration.
1691
+ */
1692
+ type: RegistrationType;
1693
+ }
1694
+
1695
+ /**
1696
+ * Represents query options to include $top support.
1697
+ */
1698
+ export declare interface RegistrationQueryLimitOptions extends OperationOptions {
1699
+ /**
1700
+ * The $top query member to get a number of records.
1701
+ */
1702
+ top?: number;
1703
+ }
1704
+
1705
+ /**
1706
+ * Represents query options to include both $top and $filter.
1707
+ */
1708
+ export declare interface RegistrationQueryOptions extends RegistrationQueryLimitOptions {
1709
+ /**
1710
+ * The OData $filter operator query string.
1711
+ */
1712
+ filter?: string;
1713
+ }
1714
+
1715
+ /**
1716
+ * Describes a registration query response with registrations and a continuation token.
1717
+ */
1718
+ export declare interface RegistrationQueryResponse {
1719
+ /**
1720
+ * The list of registrations.
1721
+ */
1722
+ registrations: RegistrationDescription[];
1723
+ /**
1724
+ * A continuation token to get more results.
1725
+ */
1726
+ continuationToken?: string;
1727
+ }
1728
+
1729
+ /**
1730
+ * Represents the types of registration descriptions.
1731
+ */
1732
+ export declare type RegistrationType = "Adm" | "AdmTemplate" | "Apple" | "AppleTemplate" | "Baidu" | "BaiduTemplate" | "Browser" | "BrowserTemplate" | "Gcm" | "GcmTemplate" | "Fcm" | "FcmTemplate" | "Mpns" | "MpnsTemplate" | "Windows" | "WindowsTemplate";
1733
+
1734
+ /**
1735
+ * Represents the send operation options that can be set.
1736
+ */
1737
+ export declare interface SendOperationOptions extends OperationOptions {
1738
+ /**
1739
+ * Set to true to enable test send.
1740
+ */
1741
+ enableTestSend?: boolean;
1742
+ }
1743
+
1744
+ /**
1745
+ * Represents a template based push notification.
1746
+ */
1747
+ export declare interface TemplateNotification extends JsonNotification {
1748
+ /**
1749
+ * The platform for the push notification.
1750
+ */
1751
+ platform: "template";
1752
+ }
1753
+
1754
+ /**
1755
+ * Represents the description of a template registration.
1756
+ */
1757
+ export declare interface TemplateRegistrationDescription {
1758
+ /**
1759
+ * The body template.
1760
+ */
1761
+ bodyTemplate: string;
1762
+ /**
1763
+ * The name of the template.
1764
+ */
1765
+ templateName?: string;
1766
+ }
1767
+
1768
+ /**
1769
+ * Represents the types of Windows Badge Glyphs
1770
+ */
1771
+ export declare type WindowsBadgeGlyphType = "none" | "activity" | "alarm" | "alert" | "attention" | "available" | "away" | "busy" | "error" | "newMessage" | "paused" | "playing" | "unavailable";
1772
+
1773
+ /**
1774
+ * Represents the Windows Badge Message
1775
+ */
1776
+ export declare interface WindowsBadgeNativeMessage {
1777
+ /**
1778
+ * Either a numeric value or a string value that specifies a predefined badge glyph.
1779
+ */
1780
+ value: WindowsBadgeGlyphType | number;
1781
+ }
1782
+
1783
+ /**
1784
+ * Represents the possible WNS content-types.
1785
+ */
1786
+ export declare type WindowsContentType = "application/xml" | "application/octet-stream";
1787
+
1788
+ /**
1789
+ * Represents a Windows Notification Services (WNS) based installation.
1790
+ */
1791
+ export declare interface WindowsInstallation extends DeviceTokenInstallation {
1792
+ /**
1793
+ * The platform for the installation.
1794
+ */
1795
+ platform: "wns";
1796
+ }
1797
+
1798
+ /**
1799
+ * Represents a Windows Notification Services (WNS) push notification.
1800
+ */
1801
+ export declare interface WindowsNotification extends NotificationCommon {
1802
+ /**
1803
+ * The platform for the push notification.
1804
+ */
1805
+ platform: "wns";
1806
+ /**
1807
+ * The content type for the push notification.
1808
+ */
1809
+ contentType: WindowsContentType;
1810
+ }
1811
+
1812
+ /**
1813
+ * Represents a Windows Notification Services (WNS) registration description.
1814
+ */
1815
+ export declare interface WindowsRegistrationDescription extends RegistrationDescriptionCommon {
1816
+ /**
1817
+ * The channel URI.
1818
+ */
1819
+ channelUri: string;
1820
+ /**
1821
+ * The type of the registration.
1822
+ */
1823
+ type: "Windows";
1824
+ }
1825
+
1826
+ /**
1827
+ * Represents a Windows Notification Services (WNS) template registration.
1828
+ */
1829
+ export declare interface WindowsTemplateRegistrationDescription extends Omit<WindowsRegistrationDescription, "type">, TemplateRegistrationDescription {
1830
+ /**
1831
+ * The WNS headers.
1832
+ */
1833
+ wnsHeaders?: Record<string, string>;
1834
+ /**
1835
+ * The type of the registration.
1836
+ */
1837
+ type: "WindowsTemplate";
1838
+ }
1839
+
1840
+ export { }