@pushwoosh/rpc-gateway-messaging 0.6.99 → 0.6.101
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.
- package/data.js +6 -0
- package/package.json +1 -1
- package/pushwoosh_channels_messagingApi_v2.d.ts +218 -0
package/data.js
CHANGED
|
@@ -310,6 +310,9 @@ export const data = {
|
|
|
310
310
|
},
|
|
311
311
|
"useLatestUserDevice": {
|
|
312
312
|
"type": "boolean"
|
|
313
|
+
},
|
|
314
|
+
"controlGroup": {
|
|
315
|
+
"type": "string"
|
|
313
316
|
}
|
|
314
317
|
},
|
|
315
318
|
"oneofs": {
|
|
@@ -420,6 +423,9 @@ export const data = {
|
|
|
420
423
|
},
|
|
421
424
|
"registrationType": {
|
|
422
425
|
"type": "pushwoosh.channels.messagingApi.v2.RegistrationType"
|
|
426
|
+
},
|
|
427
|
+
"controlGroup": {
|
|
428
|
+
"type": "string"
|
|
423
429
|
}
|
|
424
430
|
},
|
|
425
431
|
"oneofs": {
|
package/package.json
CHANGED
|
@@ -87,10 +87,13 @@ export type NotifyRequest = {
|
|
|
87
87
|
kind: NotifyRequest_kind;
|
|
88
88
|
};
|
|
89
89
|
export type NotifyResponse = {
|
|
90
|
+
/** Result of the send. */
|
|
90
91
|
result: NotifyResult;
|
|
91
92
|
};
|
|
92
93
|
export type NotifyResult = {
|
|
94
|
+
/** Code of the created message; use it with cancel, update and delete. */
|
|
93
95
|
messageCode: string;
|
|
96
|
+
/** Requested identifiers no device or user was found for. */
|
|
94
97
|
unknownIdentifiers: string[];
|
|
95
98
|
};
|
|
96
99
|
export type CancelRequest = {
|
|
@@ -174,8 +177,11 @@ export type NotifySegment = {
|
|
|
174
177
|
frequencyCapping: FrequencyCapping;
|
|
175
178
|
/** Campaign code */
|
|
176
179
|
campaign: string;
|
|
180
|
+
/** Throttling for this message. */
|
|
177
181
|
sendRate: SendRate;
|
|
182
|
+
/** Free-form JSON stored with the message and echoed in tracking-log events. */
|
|
178
183
|
metaData: object;
|
|
184
|
+
/** Placeholder name to the value substituted into the message content. */
|
|
179
185
|
dynamicContentPlaceholders: Record<string, string>;
|
|
180
186
|
/**
|
|
181
187
|
* Message type: marketing or transactional.
|
|
@@ -184,6 +190,11 @@ export type NotifySegment = {
|
|
|
184
190
|
messageType: MessageType;
|
|
185
191
|
/** When true, sends only to the device with the most recent Last Application Open timestamp per user. */
|
|
186
192
|
useLatestUserDevice: boolean;
|
|
193
|
+
/**
|
|
194
|
+
* Control group to measure this message against, by group code or by group
|
|
195
|
+
* name. Empty uses the application's default control group.
|
|
196
|
+
*/
|
|
197
|
+
controlGroup: string;
|
|
187
198
|
target: NotifySegment_target;
|
|
188
199
|
messagePayload: NotifySegment_messagePayload;
|
|
189
200
|
};
|
|
@@ -242,8 +253,11 @@ export type NotifyTransactional = {
|
|
|
242
253
|
frequencyCapping: FrequencyCapping;
|
|
243
254
|
/** Campaign code */
|
|
244
255
|
campaign: string;
|
|
256
|
+
/** Throttling for this message. */
|
|
245
257
|
sendRate: SendRate;
|
|
258
|
+
/** Free-form JSON stored with the message and echoed in tracking-log events. */
|
|
246
259
|
metaData: object;
|
|
260
|
+
/** Placeholder name to the value substituted into the message content. */
|
|
247
261
|
dynamicContentPlaceholders: Record<string, string>;
|
|
248
262
|
/**
|
|
249
263
|
* Message type: marketing or transactional.
|
|
@@ -263,6 +277,12 @@ export type NotifyTransactional = {
|
|
|
263
277
|
* See RegistrationType for semantics. Applies across channels (email, SMS, …).
|
|
264
278
|
*/
|
|
265
279
|
registrationType: RegistrationType;
|
|
280
|
+
/**
|
|
281
|
+
* Control group to measure this message against, by group code or by group
|
|
282
|
+
* name. Empty uses the application's default control group. Only has an
|
|
283
|
+
* effect on a marketing message: a transactional one is never held back.
|
|
284
|
+
*/
|
|
285
|
+
controlGroup: string;
|
|
266
286
|
target: NotifyTransactional_target;
|
|
267
287
|
messagePayload: NotifyTransactional_messagePayload;
|
|
268
288
|
};
|
|
@@ -298,9 +318,13 @@ export type FrequencyCappingMode =
|
|
|
298
318
|
| 'FREQUENCY_CAPPING_MODE_CALENDAR_DAY';
|
|
299
319
|
/** Message frequency capping. */
|
|
300
320
|
export type FrequencyCapping = {
|
|
321
|
+
/** Length of the capping window in days; counted together with count. */
|
|
301
322
|
days: number;
|
|
323
|
+
/** How many messages a user may receive within the window. */
|
|
302
324
|
count: number;
|
|
325
|
+
/** Do not count this message towards the user's capping quota. */
|
|
303
326
|
exclude: boolean;
|
|
327
|
+
/** Ignore capping for this message and send it anyway. */
|
|
304
328
|
avoid: boolean;
|
|
305
329
|
/** How the counting window is anchored. Applies only together with explicit days and count. */
|
|
306
330
|
mode: FrequencyCappingMode;
|
|
@@ -308,25 +332,38 @@ export type FrequencyCapping = {
|
|
|
308
332
|
timezone: string;
|
|
309
333
|
};
|
|
310
334
|
export type SendRate = {
|
|
335
|
+
/** Messages per bucket; bounded by the account's send-rate restrictions. */
|
|
311
336
|
value: number;
|
|
337
|
+
/** Time window the value applies to, e.g. "1s". */
|
|
312
338
|
bucket: string;
|
|
339
|
+
/** Send at full speed, ignoring any configured send rate. */
|
|
313
340
|
avoid: boolean;
|
|
314
341
|
};
|
|
315
342
|
export type DeliveryPriority = 'NORMAL' | 'HIGH';
|
|
316
343
|
export type NotificationPriority = 'PRIORITY_UNSPECIFIED' | 'PRIORITY_MIN' | 'PRIORITY_LOW' | 'PRIORITY_DEFAULT' | 'PRIORITY_HIGH' | 'PRIORITY_MAX';
|
|
317
344
|
export type LiveActivity = {
|
|
345
|
+
/** Live Activity event: "start", "update" or "end". */
|
|
318
346
|
event: string;
|
|
347
|
+
/** Unix time after which an ended activity is dismissed. */
|
|
319
348
|
dismissalDate: number;
|
|
349
|
+
/** Dynamic ContentState of the activity. */
|
|
320
350
|
contentState: object;
|
|
351
|
+
/** Unix time after which the shown content counts as stale. */
|
|
321
352
|
staleDate: number;
|
|
353
|
+
/** Ordering hint when several activities compete for the same slot. */
|
|
322
354
|
relevanceScore: number;
|
|
355
|
+
/** Name of the ActivityAttributes type; required to start an activity. */
|
|
323
356
|
attributesType: string;
|
|
357
|
+
/** Static attributes passed when the activity starts. */
|
|
324
358
|
attributes: object;
|
|
359
|
+
/** Unix time the activity starts. */
|
|
325
360
|
start: number;
|
|
326
361
|
};
|
|
327
362
|
export type LiveUpdate_Operation = 'OPERATION_UNSPECIFIED' | 'OPERATION_START' | 'OPERATION_UPDATE' | 'OPERATION_END';
|
|
328
363
|
export type LiveUpdate_Segment = {
|
|
364
|
+
/** Segment color, hex. */
|
|
329
365
|
color: string;
|
|
366
|
+
/** Segment length in progress units. */
|
|
330
367
|
length: number;
|
|
331
368
|
};
|
|
332
369
|
/**
|
|
@@ -342,19 +379,30 @@ export type LiveUpdate = {
|
|
|
342
379
|
operation: LiveUpdate_Operation;
|
|
343
380
|
/** required */
|
|
344
381
|
id: string;
|
|
382
|
+
/** Current progress value. */
|
|
345
383
|
progress: number;
|
|
384
|
+
/** Show the progress bar without a known end. */
|
|
346
385
|
progressIndeterminate: boolean;
|
|
386
|
+
/** Whether a progress bar is shown at all. */
|
|
347
387
|
progressBar: boolean;
|
|
388
|
+
/** Colored segments the progress bar is split into. */
|
|
348
389
|
segments: LiveUpdate_Segment[];
|
|
390
|
+
/** Free-form data passed to the app with the update. */
|
|
349
391
|
extras: object;
|
|
392
|
+
/** Unix time the update refers to. */
|
|
350
393
|
when: number;
|
|
394
|
+
/** Render `when` as a running timer. */
|
|
351
395
|
chronometer: boolean;
|
|
396
|
+
/** Make the chronometer count down instead of up. */
|
|
352
397
|
chronometerCountDown: boolean;
|
|
398
|
+
/** Show the `when` timestamp on the notification. */
|
|
353
399
|
showWhen: boolean;
|
|
354
400
|
};
|
|
355
401
|
export type Link_Shortener = 'NONE' | 'BITLY';
|
|
356
402
|
export type Link = {
|
|
403
|
+
/** URL opened when the user taps the notification. */
|
|
357
404
|
url: string;
|
|
405
|
+
/** Link shortener applied to the URL: NONE or BITLY. */
|
|
358
406
|
shortener: Link_Shortener;
|
|
359
407
|
};
|
|
360
408
|
export type RichMedia_kind_code = {
|
|
@@ -370,7 +418,9 @@ export type RichMedia = {
|
|
|
370
418
|
kind: RichMedia_kind;
|
|
371
419
|
};
|
|
372
420
|
export type DeepLink = {
|
|
421
|
+
/** Deep link code configured in the Control Panel. */
|
|
373
422
|
code: string;
|
|
423
|
+
/** Parameters substituted into the deep link; values support Liquid. */
|
|
374
424
|
params: Record<string, string>;
|
|
375
425
|
};
|
|
376
426
|
export type OpenAction_kind_richMedia = {
|
|
@@ -390,161 +440,291 @@ export type OpenAction = {
|
|
|
390
440
|
kind: OpenAction_kind;
|
|
391
441
|
};
|
|
392
442
|
export type Inbox = {
|
|
443
|
+
/** Image shown in the Message Inbox entry. */
|
|
393
444
|
imageUrl: string;
|
|
445
|
+
/** When the entry is removed from the Message Inbox. */
|
|
394
446
|
expirationDate: Date;
|
|
395
447
|
};
|
|
396
448
|
export type Content_GlobalProperties = {
|
|
449
|
+
/** TTL applied to every platform block that has none of its own. */
|
|
397
450
|
timeToLive: Duration;
|
|
398
451
|
};
|
|
399
452
|
export type Content_PlatformPropertiesIos = {
|
|
453
|
+
/** Notification title. */
|
|
400
454
|
title: string;
|
|
455
|
+
/** Notification subtitle. */
|
|
401
456
|
subtitle: string;
|
|
457
|
+
/** Notification body text. */
|
|
402
458
|
body: string;
|
|
459
|
+
/** How long the push service keeps the notification for a device that is offline. */
|
|
403
460
|
timeToLive: Duration;
|
|
461
|
+
/** Critical alert; requires the Apple critical-alerts entitlement. */
|
|
404
462
|
isCritical: boolean;
|
|
463
|
+
/** URL of a media attachment; needs the Notification Service Extension in the app. */
|
|
405
464
|
attachment: string;
|
|
465
|
+
/** Sound file name played on arrival. */
|
|
406
466
|
sound: string;
|
|
467
|
+
/** Thread identifier iOS groups notifications by. */
|
|
407
468
|
threadId: string;
|
|
469
|
+
/** Badge value: absolute ("5") or relative ("+1"). */
|
|
408
470
|
badges: string;
|
|
471
|
+
/** Trim the content to fit the notification. */
|
|
409
472
|
trimContent: boolean;
|
|
473
|
+
/** UNNotificationCategory identifier holding the interactive actions. */
|
|
410
474
|
categoryId: string;
|
|
475
|
+
/** Enables or suppresses the notification sound. */
|
|
411
476
|
soundEnabled: boolean;
|
|
477
|
+
/** iOS interruption level: passive, active, time-sensitive or critical. */
|
|
412
478
|
interruptionLevel: string;
|
|
479
|
+
/** Raw platform payload overrides merged into the outgoing push. */
|
|
413
480
|
rootParams: object;
|
|
481
|
+
/** Live Activity payload. */
|
|
414
482
|
liveActivity: LiveActivity;
|
|
483
|
+
/** APNs collapse identifier: a newer notification replaces one with the same id. */
|
|
415
484
|
collapseId: string;
|
|
485
|
+
/** Message Inbox entry created for this notification. */
|
|
416
486
|
inbox: Inbox;
|
|
487
|
+
/** Id of the Live Activity this push starts or updates. */
|
|
417
488
|
liveActivityId: string;
|
|
418
489
|
};
|
|
419
490
|
export type Content_PlatformPropertiesAndroid = {
|
|
491
|
+
/** Notification title. */
|
|
420
492
|
title: string;
|
|
493
|
+
/** Notification body text. */
|
|
421
494
|
body: string;
|
|
495
|
+
/** How long the push service keeps the notification for a device that is offline. */
|
|
422
496
|
timeToLive: Duration;
|
|
497
|
+
/** Notification small icon. */
|
|
423
498
|
icon: string;
|
|
499
|
+
/** Big-picture image URL shown in the expanded notification. */
|
|
424
500
|
banner: string;
|
|
501
|
+
/** FCM delivery priority: NORMAL or HIGH. */
|
|
425
502
|
deliveryPriority: DeliveryPriority;
|
|
503
|
+
/** Vibrate when the notification arrives. */
|
|
426
504
|
vibration: boolean;
|
|
505
|
+
/** Badge value: absolute ("5") or relative ("+1"). */
|
|
427
506
|
badges: string;
|
|
507
|
+
/** Sound file name played on arrival. */
|
|
428
508
|
sound: string;
|
|
509
|
+
/** Notification LED color, hex. */
|
|
429
510
|
ledColor: string;
|
|
511
|
+
/** Enables or suppresses the notification sound. */
|
|
430
512
|
soundEnabled: boolean;
|
|
513
|
+
/** Icon background color, hex. */
|
|
431
514
|
iconBackgroundColor: string;
|
|
515
|
+
/** Show the notification on the lock screen. */
|
|
432
516
|
showOnLockscreen: boolean;
|
|
517
|
+
/** Raw platform payload overrides merged into the outgoing push. */
|
|
433
518
|
rootParams: object;
|
|
519
|
+
/** URL of a large custom icon. */
|
|
434
520
|
customIcon: string;
|
|
521
|
+
/** In-tray notification priority. */
|
|
435
522
|
priority: NotificationPriority;
|
|
523
|
+
/** Notification group key the device stacks notifications by. */
|
|
436
524
|
groupId: string;
|
|
525
|
+
/** FCM collapse key: a newer notification replaces an undelivered one with the same key. */
|
|
437
526
|
collapseKey: string;
|
|
527
|
+
/** Message Inbox entry created for this notification. */
|
|
438
528
|
inbox: Inbox;
|
|
529
|
+
/** Android Live Updates payload (Android 16+, FCM only). */
|
|
439
530
|
liveUpdate: LiveUpdate;
|
|
440
531
|
};
|
|
441
532
|
export type Content_PlatformPropertiesChrome = {
|
|
533
|
+
/** Notification title. */
|
|
442
534
|
title: string;
|
|
535
|
+
/** Notification body text. */
|
|
443
536
|
body: string;
|
|
537
|
+
/** How long the push service keeps the notification for a device that is offline. */
|
|
444
538
|
timeToLive: Duration;
|
|
539
|
+
/** Notification small icon. */
|
|
445
540
|
icon: string;
|
|
541
|
+
/** Large image URL. */
|
|
446
542
|
image: string;
|
|
543
|
+
/** Raw platform payload overrides merged into the outgoing push. */
|
|
447
544
|
rootParams: object;
|
|
545
|
+
/** Auto-close timer for the notification. */
|
|
448
546
|
duration: Duration;
|
|
547
|
+
/** Label of the first action button. */
|
|
449
548
|
buttonText1: string;
|
|
549
|
+
/** URL opened by the first action button. */
|
|
450
550
|
buttonUrl1: string;
|
|
551
|
+
/** Label of the second action button. */
|
|
451
552
|
buttonText2: string;
|
|
553
|
+
/** URL opened by the second action button. */
|
|
452
554
|
buttonUrl2: string;
|
|
555
|
+
/** Message Inbox entry created for this notification. */
|
|
453
556
|
inbox: Inbox;
|
|
454
557
|
};
|
|
455
558
|
export type Content_PlatformPropertiesFirefox = {
|
|
559
|
+
/** Notification title. */
|
|
456
560
|
title: string;
|
|
561
|
+
/** Notification body text. */
|
|
457
562
|
body: string;
|
|
563
|
+
/** Notification small icon. */
|
|
458
564
|
icon: string;
|
|
565
|
+
/** Raw platform payload overrides merged into the outgoing push. */
|
|
459
566
|
rootParams: object;
|
|
567
|
+
/** Message Inbox entry created for this notification. */
|
|
460
568
|
inbox: Inbox;
|
|
461
569
|
};
|
|
462
570
|
export type Content_PlatformPropertiesSafari = {
|
|
571
|
+
/** Notification title. */
|
|
463
572
|
title: string;
|
|
573
|
+
/** Notification body text. */
|
|
464
574
|
body: string;
|
|
575
|
+
/** How long the push service keeps the notification for a device that is offline. */
|
|
465
576
|
timeToLive: Duration;
|
|
577
|
+
/** URL opened when the user clicks the notification. */
|
|
466
578
|
action: string;
|
|
579
|
+
/** Arguments substituted into the site's Web Push URL template. */
|
|
467
580
|
urlArguments: string[];
|
|
581
|
+
/** Message Inbox entry created for this notification. */
|
|
468
582
|
inbox: Inbox;
|
|
469
583
|
};
|
|
470
584
|
export type Content_PlatformPropertiesMacOS = {
|
|
585
|
+
/** Notification title. */
|
|
471
586
|
title: string;
|
|
587
|
+
/** Notification body text. */
|
|
472
588
|
body: string;
|
|
589
|
+
/** How long the push service keeps the notification for a device that is offline. */
|
|
473
590
|
timeToLive: Duration;
|
|
591
|
+
/** URL opened when the user clicks the notification. */
|
|
474
592
|
action: string;
|
|
593
|
+
/** Sound file name played on arrival. */
|
|
475
594
|
sound: string;
|
|
595
|
+
/** Enables or suppresses the notification sound. */
|
|
476
596
|
soundEnabled: boolean;
|
|
597
|
+
/** Badge value: absolute ("5") or relative ("+1"). */
|
|
477
598
|
badges: string;
|
|
599
|
+
/** Raw platform payload overrides merged into the outgoing push. */
|
|
478
600
|
rootParams: object;
|
|
601
|
+
/** Message Inbox entry created for this notification. */
|
|
479
602
|
inbox: Inbox;
|
|
603
|
+
/** Notification subtitle. */
|
|
480
604
|
subtitle: string;
|
|
481
605
|
};
|
|
482
606
|
export type Content_PlatformPropertiesAmazon = {
|
|
607
|
+
/** Notification title. */
|
|
483
608
|
title: string;
|
|
609
|
+
/** Notification body text. */
|
|
484
610
|
body: string;
|
|
611
|
+
/** How long the push service keeps the notification for a device that is offline. */
|
|
485
612
|
timeToLive: Duration;
|
|
613
|
+
/** Big-picture image URL shown in the expanded notification. */
|
|
486
614
|
banner: string;
|
|
615
|
+
/** Sound file name played on arrival. */
|
|
487
616
|
sound: string;
|
|
617
|
+
/** Enables or suppresses the notification sound. */
|
|
488
618
|
soundEnabled: boolean;
|
|
619
|
+
/** Raw platform payload overrides merged into the outgoing push. */
|
|
489
620
|
rootParams: object;
|
|
621
|
+
/** Notification small icon. */
|
|
490
622
|
icon: string;
|
|
623
|
+
/** URL of a large custom icon. */
|
|
491
624
|
customIcon: string;
|
|
625
|
+
/** In-tray notification priority. */
|
|
492
626
|
priority: NotificationPriority;
|
|
627
|
+
/** Message Inbox entry created for this notification. */
|
|
493
628
|
inbox: Inbox;
|
|
494
629
|
};
|
|
495
630
|
export type Content_PlatformPropertiesBaiduAndroid = {
|
|
631
|
+
/** Notification title. */
|
|
496
632
|
title: string;
|
|
633
|
+
/** Notification body text. */
|
|
497
634
|
body: string;
|
|
635
|
+
/** How long the push service keeps the notification for a device that is offline. */
|
|
498
636
|
timeToLive: Duration;
|
|
637
|
+
/** Notification small icon. */
|
|
499
638
|
icon: string;
|
|
639
|
+
/** Big-picture image URL shown in the expanded notification. */
|
|
500
640
|
banner: string;
|
|
641
|
+
/** FCM delivery priority: NORMAL or HIGH. */
|
|
501
642
|
deliveryPriority: DeliveryPriority;
|
|
643
|
+
/** Vibrate when the notification arrives. */
|
|
502
644
|
vibration: boolean;
|
|
645
|
+
/** Badge value: absolute ("5") or relative ("+1"). */
|
|
503
646
|
badges: string;
|
|
647
|
+
/** Sound file name played on arrival. */
|
|
504
648
|
sound: string;
|
|
649
|
+
/** Notification LED color, hex. */
|
|
505
650
|
ledColor: string;
|
|
651
|
+
/** Enables or suppresses the notification sound. */
|
|
506
652
|
soundEnabled: boolean;
|
|
653
|
+
/** Icon background color, hex. */
|
|
507
654
|
iconBackgroundColor: string;
|
|
655
|
+
/** Show the notification on the lock screen. */
|
|
508
656
|
showOnLockscreen: boolean;
|
|
657
|
+
/** Raw platform payload overrides merged into the outgoing push. */
|
|
509
658
|
rootParams: object;
|
|
659
|
+
/** URL of a large custom icon. */
|
|
510
660
|
customIcon: string;
|
|
661
|
+
/** In-tray notification priority. */
|
|
511
662
|
priority: NotificationPriority;
|
|
663
|
+
/** Notification group key the device stacks notifications by. */
|
|
512
664
|
groupId: string;
|
|
665
|
+
/** Message Inbox entry created for this notification. */
|
|
513
666
|
inbox: Inbox;
|
|
514
667
|
};
|
|
515
668
|
export type Content_PlatformPropertiesHuaweiAndroid = {
|
|
669
|
+
/** Notification title. */
|
|
516
670
|
title: string;
|
|
671
|
+
/** Notification body text. */
|
|
517
672
|
body: string;
|
|
673
|
+
/** How long the push service keeps the notification for a device that is offline. */
|
|
518
674
|
timeToLive: Duration;
|
|
675
|
+
/** Notification small icon. */
|
|
519
676
|
icon: string;
|
|
677
|
+
/** Big-picture image URL shown in the expanded notification. */
|
|
520
678
|
banner: string;
|
|
679
|
+
/** FCM delivery priority: NORMAL or HIGH. */
|
|
521
680
|
deliveryPriority: DeliveryPriority;
|
|
681
|
+
/** Vibrate when the notification arrives. */
|
|
522
682
|
vibration: boolean;
|
|
683
|
+
/** Badge value: absolute ("5") or relative ("+1"). */
|
|
523
684
|
badges: string;
|
|
685
|
+
/** Sound file name played on arrival. */
|
|
524
686
|
sound: string;
|
|
687
|
+
/** Notification LED color, hex. */
|
|
525
688
|
ledColor: string;
|
|
689
|
+
/** Enables or suppresses the notification sound. */
|
|
526
690
|
soundEnabled: boolean;
|
|
691
|
+
/** Icon background color, hex. */
|
|
527
692
|
iconBackgroundColor: string;
|
|
693
|
+
/** Show the notification on the lock screen. */
|
|
528
694
|
showOnLockscreen: boolean;
|
|
695
|
+
/** Raw platform payload overrides merged into the outgoing push. */
|
|
529
696
|
rootParams: object;
|
|
697
|
+
/** URL of a large custom icon. */
|
|
530
698
|
customIcon: string;
|
|
699
|
+
/** In-tray notification priority. */
|
|
531
700
|
priority: NotificationPriority;
|
|
701
|
+
/** Notification group key the device stacks notifications by. */
|
|
532
702
|
groupId: string;
|
|
703
|
+
/** Message Inbox entry created for this notification. */
|
|
533
704
|
inbox: Inbox;
|
|
534
705
|
};
|
|
535
706
|
export type Content_PlatformPropertiesIE = {
|
|
707
|
+
/** Notification title. */
|
|
536
708
|
title: string;
|
|
709
|
+
/** Badge icon URL. */
|
|
537
710
|
iconBadge: string;
|
|
711
|
+
/** Notification body text. */
|
|
538
712
|
body: string;
|
|
713
|
+
/** Message Inbox entry created for this notification. */
|
|
539
714
|
inbox: Inbox;
|
|
540
715
|
};
|
|
541
716
|
export type Content_PlatformPropertiesWindows_Raw = {
|
|
717
|
+
/** Raw toast/tile XML sent to WNS as is. */
|
|
542
718
|
content: string;
|
|
543
719
|
};
|
|
544
720
|
export type Content_PlatformPropertiesWindows_Template = {
|
|
721
|
+
/** Notification title. */
|
|
545
722
|
title: string;
|
|
723
|
+
/** Notification subtitle. */
|
|
546
724
|
subtitle: string;
|
|
725
|
+
/** Notification body text. */
|
|
547
726
|
body: string;
|
|
727
|
+
/** Image shown in the notification. */
|
|
548
728
|
imageUrl: string;
|
|
549
729
|
};
|
|
550
730
|
export type Content_PlatformPropertiesWindows_Type = 'TILE' | 'TOAST' | 'BADGE';
|
|
@@ -558,13 +738,18 @@ export type Content_PlatformPropertiesWindows_content_template = {
|
|
|
558
738
|
};
|
|
559
739
|
export type Content_PlatformPropertiesWindows_content = Content_PlatformPropertiesWindows_content_raw | Content_PlatformPropertiesWindows_content_template;
|
|
560
740
|
export type Content_PlatformPropertiesWindows = {
|
|
741
|
+
/** Notification kind: TILE, TOAST or BADGE. */
|
|
561
742
|
type: Content_PlatformPropertiesWindows_Type;
|
|
743
|
+
/** WNS tag; a newer notification with the same tag replaces the previous one. */
|
|
562
744
|
tag: string;
|
|
745
|
+
/** Let WNS cache the notification for an offline device. */
|
|
563
746
|
cache: boolean;
|
|
747
|
+
/** How long the push service keeps the notification for a device that is offline. */
|
|
564
748
|
timeToLive: Duration;
|
|
565
749
|
content: Content_PlatformPropertiesWindows_content;
|
|
566
750
|
};
|
|
567
751
|
export type Content_PlatformPropertiesSMS = {
|
|
752
|
+
/** Notification body text. */
|
|
568
753
|
body: string;
|
|
569
754
|
/**
|
|
570
755
|
* MMS: a subject and attachment URLs turn the message into an MMS. Only providers with
|
|
@@ -576,10 +761,13 @@ export type Content_PlatformPropertiesSMS = {
|
|
|
576
761
|
messageAt: number;
|
|
577
762
|
};
|
|
578
763
|
export type Content_PlatformPropertiesTelegram = {
|
|
764
|
+
/** Message text. */
|
|
579
765
|
body: string;
|
|
766
|
+
/** JSON string with variables for the bot-side template. */
|
|
580
767
|
contentVariables: string;
|
|
581
768
|
};
|
|
582
769
|
export type Content_PlatformPropertiesViber = {
|
|
770
|
+
/** Notification body text. */
|
|
583
771
|
body: string;
|
|
584
772
|
/**
|
|
585
773
|
* Transactional template (Omni Messaging / MStat): reference a pre-approved template by
|
|
@@ -596,12 +784,17 @@ export type Content_PlatformPropertiesViber = {
|
|
|
596
784
|
allDevices: boolean;
|
|
597
785
|
};
|
|
598
786
|
export type Content_PlatformPropertiesKakao = {
|
|
787
|
+
/** Message text. */
|
|
599
788
|
content: string;
|
|
789
|
+
/** Code of the approved Kakao template. */
|
|
600
790
|
template: string;
|
|
791
|
+
/** JSON string with the template variable bindings. */
|
|
601
792
|
contentVariables: string;
|
|
602
793
|
};
|
|
603
794
|
export type Content_PlatformPropertiesLine = {
|
|
795
|
+
/** Plain text body. */
|
|
604
796
|
content: string;
|
|
797
|
+
/** Code of a LINE template configured in the Control Panel (image, carousel or flex message). */
|
|
605
798
|
template: string;
|
|
606
799
|
};
|
|
607
800
|
export type Content_PlatformPropertiesWhatsApp = {
|
|
@@ -643,26 +836,45 @@ export type Content_PlatformPropertiesWhatsApp = {
|
|
|
643
836
|
headerVariables: string;
|
|
644
837
|
};
|
|
645
838
|
export type Content = {
|
|
839
|
+
/** iOS push content. */
|
|
646
840
|
ios: Content_PlatformPropertiesIos;
|
|
841
|
+
/** Android (FCM) push content. */
|
|
647
842
|
android: Content_PlatformPropertiesAndroid;
|
|
843
|
+
/** macOS push content. */
|
|
648
844
|
macOs: Content_PlatformPropertiesMacOS;
|
|
845
|
+
/** Amazon (ADM) push content. */
|
|
649
846
|
amazon: Content_PlatformPropertiesAmazon;
|
|
847
|
+
/** Safari web push content. */
|
|
650
848
|
safari: Content_PlatformPropertiesSafari;
|
|
849
|
+
/** Chrome web push content. */
|
|
651
850
|
chrome: Content_PlatformPropertiesChrome;
|
|
851
|
+
/** Firefox web push content. */
|
|
652
852
|
firefox: Content_PlatformPropertiesFirefox;
|
|
853
|
+
/** Baidu Android push content. */
|
|
653
854
|
baiduAndroid: Content_PlatformPropertiesBaiduAndroid;
|
|
855
|
+
/** Huawei Android push content. */
|
|
654
856
|
huaweiAndroid: Content_PlatformPropertiesHuaweiAndroid;
|
|
857
|
+
/** Internet Explorer web push content. */
|
|
655
858
|
ie: Content_PlatformPropertiesIE;
|
|
859
|
+
/** Windows tile/toast/badge content. */
|
|
656
860
|
windows: Content_PlatformPropertiesWindows;
|
|
861
|
+
/** Telegram message content. */
|
|
657
862
|
telegram: Content_PlatformPropertiesTelegram;
|
|
863
|
+
/** Kakao message content. */
|
|
658
864
|
kakao: Content_PlatformPropertiesKakao;
|
|
865
|
+
/** LINE message content. */
|
|
659
866
|
line: Content_PlatformPropertiesLine;
|
|
867
|
+
/** WhatsApp message content. */
|
|
660
868
|
whatsapp: Content_PlatformPropertiesWhatsApp;
|
|
869
|
+
/** Settings applied to every platform block of this locale. */
|
|
661
870
|
globalProperties: Content_GlobalProperties;
|
|
871
|
+
/** SMS (and MMS) message content. */
|
|
662
872
|
sms: Content_PlatformPropertiesSMS;
|
|
873
|
+
/** Viber message content. */
|
|
663
874
|
viber: Content_PlatformPropertiesViber;
|
|
664
875
|
};
|
|
665
876
|
export type LocalizedContent = {
|
|
877
|
+
/** Locale code (ISO 639-1, "zh-Hant"/"zh-Hans", or "default") to the content sent to devices in that language. */
|
|
666
878
|
localizedContent: Record<string, Content>;
|
|
667
879
|
};
|
|
668
880
|
export type Payload_kind_content = {
|
|
@@ -675,11 +887,17 @@ export type Payload_kind_silent = {
|
|
|
675
887
|
};
|
|
676
888
|
export type Payload_kind = Payload_kind_content | Payload_kind_silent;
|
|
677
889
|
export type Payload = {
|
|
890
|
+
/** Push preset code (XXXXX-XXXXX) whose content this message starts from. */
|
|
678
891
|
preset: string;
|
|
892
|
+
/** Free-form JSON delivered to the SDK as the `u` parameter. */
|
|
679
893
|
customData: object;
|
|
894
|
+
/** Action performed when the user opens the notification. */
|
|
680
895
|
openAction: OpenAction;
|
|
896
|
+
/** Per-platform override of open_action, keyed by the numeric platform code. */
|
|
681
897
|
openActions: Record<number, OpenAction>;
|
|
898
|
+
/** Send as an iOS VoIP notification. */
|
|
682
899
|
voipPush: boolean;
|
|
900
|
+
/** Serial of the Apple Wallet pass to update; requires the APPLE_WALLET platform. */
|
|
683
901
|
appleWalletPassSerial: string;
|
|
684
902
|
kind: Payload_kind;
|
|
685
903
|
};
|