@trycourier/courier 6.2.1 → 6.2.3
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/Client.d.ts +71 -10
- package/Client.js +72 -11
- package/api/client/requests/SendMessageRequest.d.ts +71 -10
- package/api/resources/audiences/client/Client.js +5 -5
- package/api/resources/auditEvents/client/Client.js +2 -2
- package/api/resources/authTokens/client/Client.js +1 -1
- package/api/resources/automations/client/Client.js +2 -2
- package/api/resources/brands/client/Client.d.ts +38 -4
- package/api/resources/brands/client/Client.js +43 -9
- package/api/resources/brands/client/requests/BrandUpdateParameters.d.ts +13 -2
- package/api/resources/bulk/client/Client.d.ts +91 -3
- package/api/resources/bulk/client/Client.js +96 -8
- package/api/resources/bulk/client/requests/BulkCreateJobParams.d.ts +70 -1
- package/api/resources/inbound/client/Client.js +1 -1
- package/api/resources/lists/client/Client.d.ts +8 -96
- package/api/resources/lists/client/Client.js +18 -106
- package/api/resources/lists/client/requests/AddSubscribersToList.d.ts +2 -24
- package/api/resources/lists/client/requests/SubscribeUserToListRequest.d.ts +2 -24
- package/api/resources/lists/client/requests/SubscribeUsersToListRequest.d.ts +2 -24
- package/api/resources/messages/client/Client.js +6 -6
- package/api/resources/notifications/client/Client.d.ts +2 -1
- package/api/resources/notifications/client/Client.js +12 -8
- package/api/resources/notifications/client/requests/NotificationListParams.d.ts +6 -1
- package/api/resources/notifications/types/Notification.d.ts +1 -0
- package/api/resources/profiles/client/Client.d.ts +7 -1
- package/api/resources/profiles/client/Client.js +14 -8
- package/api/resources/profiles/types/Pagerduty.d.ts +9 -0
- package/api/resources/profiles/types/UserProfile.d.ts +1 -1
- package/api/resources/profiles/types/UserProfileFirebaseToken.d.ts +4 -0
- package/api/resources/profiles/types/WebhookAuthMode.d.ts +9 -0
- package/api/resources/profiles/types/WebhookAuthMode.js +11 -0
- package/api/resources/profiles/types/WebhookAuthentication.d.ts +14 -0
- package/api/resources/profiles/types/WebhookAuthentication.js +5 -0
- package/api/resources/profiles/types/WebhookMethod.d.ts +8 -0
- package/api/resources/profiles/types/WebhookMethod.js +10 -0
- package/api/resources/profiles/types/WebhookProfile.d.ts +16 -0
- package/api/resources/profiles/types/WebhookProfile.js +5 -0
- package/api/resources/profiles/types/WebhookProfileType.d.ts +8 -0
- package/api/resources/profiles/types/WebhookProfileType.js +10 -0
- package/api/resources/profiles/types/index.d.ts +7 -0
- package/api/resources/profiles/types/index.js +7 -0
- package/api/resources/send/types/BaseMessage.d.ts +1 -0
- package/api/resources/send/types/Channel.d.ts +1 -1
- package/api/resources/send/types/MessagePreferences.d.ts +7 -0
- package/api/resources/send/types/MessagePreferences.js +5 -0
- package/api/resources/send/types/PagerdutyRecipient.d.ts +7 -0
- package/api/resources/send/types/PagerdutyRecipient.js +5 -0
- package/api/resources/send/types/Recipient.d.ts +1 -1
- package/api/resources/send/types/WebhookRecipient.d.ts +7 -0
- package/api/resources/send/types/WebhookRecipient.js +5 -0
- package/api/resources/send/types/index.d.ts +3 -2
- package/api/resources/send/types/index.js +3 -2
- package/api/resources/templates/client/Client.js +1 -1
- package/api/resources/tenants/client/Client.d.ts +6 -1
- package/api/resources/tenants/client/Client.js +13 -8
- package/api/resources/tenants/client/requests/TenantCreateOrReplaceParams.d.ts +6 -1
- package/api/resources/translations/client/Client.js +2 -2
- package/api/resources/users/resources/preferences/client/Client.d.ts +10 -4
- package/api/resources/users/resources/preferences/client/Client.js +43 -8
- package/api/resources/users/resources/preferences/client/requests/UserPreferencesParams.d.ts +15 -0
- package/api/resources/users/resources/preferences/client/requests/UserPreferencesParams.js +5 -0
- package/api/resources/users/resources/preferences/client/requests/UserPreferencesTopicParams.d.ts +15 -0
- package/api/resources/users/resources/preferences/client/requests/UserPreferencesTopicParams.js +5 -0
- package/api/resources/users/resources/preferences/client/requests/UserPreferencesUpdateParams.d.ts +4 -0
- package/api/resources/users/resources/preferences/client/requests/index.d.ts +2 -0
- package/api/resources/users/resources/tenants/client/Client.js +5 -5
- package/api/resources/users/resources/tokens/client/Client.d.ts +5 -1
- package/api/resources/users/resources/tokens/client/Client.js +11 -7
- package/dist/Client.d.ts +71 -10
- package/dist/Client.js +72 -11
- package/dist/api/client/requests/SendMessageRequest.d.ts +71 -10
- package/dist/api/resources/audiences/client/Client.js +5 -5
- package/dist/api/resources/auditEvents/client/Client.js +2 -2
- package/dist/api/resources/authTokens/client/Client.js +1 -1
- package/dist/api/resources/automations/client/Client.js +2 -2
- package/dist/api/resources/brands/client/Client.d.ts +38 -4
- package/dist/api/resources/brands/client/Client.js +43 -9
- package/dist/api/resources/brands/client/requests/BrandUpdateParameters.d.ts +13 -2
- package/dist/api/resources/bulk/client/Client.d.ts +91 -3
- package/dist/api/resources/bulk/client/Client.js +96 -8
- package/dist/api/resources/bulk/client/requests/BulkCreateJobParams.d.ts +70 -1
- package/dist/api/resources/inbound/client/Client.js +1 -1
- package/dist/api/resources/lists/client/Client.d.ts +8 -96
- package/dist/api/resources/lists/client/Client.js +18 -106
- package/dist/api/resources/lists/client/requests/AddSubscribersToList.d.ts +2 -24
- package/dist/api/resources/lists/client/requests/SubscribeUserToListRequest.d.ts +2 -24
- package/dist/api/resources/lists/client/requests/SubscribeUsersToListRequest.d.ts +2 -24
- package/dist/api/resources/messages/client/Client.js +6 -6
- package/dist/api/resources/notifications/client/Client.d.ts +2 -1
- package/dist/api/resources/notifications/client/Client.js +12 -8
- package/dist/api/resources/notifications/client/requests/NotificationListParams.d.ts +6 -1
- package/dist/api/resources/notifications/types/Notification.d.ts +1 -0
- package/dist/api/resources/profiles/client/Client.d.ts +7 -1
- package/dist/api/resources/profiles/client/Client.js +14 -8
- package/dist/api/resources/profiles/types/Pagerduty.d.ts +9 -0
- package/dist/api/resources/profiles/types/Pagerduty.js +5 -0
- package/dist/api/resources/profiles/types/UserProfile.d.ts +1 -1
- package/dist/api/resources/profiles/types/UserProfileFirebaseToken.d.ts +4 -0
- package/dist/api/resources/profiles/types/UserProfileFirebaseToken.js +5 -0
- package/dist/api/resources/profiles/types/WebhookAuthMode.d.ts +9 -0
- package/dist/api/resources/profiles/types/WebhookAuthMode.js +11 -0
- package/dist/api/resources/profiles/types/WebhookAuthentication.d.ts +14 -0
- package/dist/api/resources/profiles/types/WebhookAuthentication.js +5 -0
- package/dist/api/resources/profiles/types/WebhookMethod.d.ts +8 -0
- package/dist/api/resources/profiles/types/WebhookMethod.js +10 -0
- package/dist/api/resources/profiles/types/WebhookProfile.d.ts +16 -0
- package/dist/api/resources/profiles/types/WebhookProfile.js +5 -0
- package/dist/api/resources/profiles/types/WebhookProfileType.d.ts +8 -0
- package/dist/api/resources/profiles/types/WebhookProfileType.js +10 -0
- package/dist/api/resources/profiles/types/index.d.ts +7 -0
- package/dist/api/resources/profiles/types/index.js +7 -0
- package/dist/api/resources/send/types/BaseMessage.d.ts +1 -0
- package/dist/api/resources/send/types/Channel.d.ts +1 -1
- package/dist/api/resources/send/types/MessagePreferences.d.ts +7 -0
- package/dist/api/resources/send/types/MessagePreferences.js +5 -0
- package/dist/api/resources/send/types/PagerdutyRecipient.d.ts +7 -0
- package/dist/api/resources/send/types/PagerdutyRecipient.js +5 -0
- package/dist/api/resources/send/types/Recipient.d.ts +1 -1
- package/dist/api/resources/send/types/WebhookRecipient.d.ts +7 -0
- package/dist/api/resources/send/types/WebhookRecipient.js +5 -0
- package/dist/api/resources/send/types/index.d.ts +3 -2
- package/dist/api/resources/send/types/index.js +3 -2
- package/dist/api/resources/templates/client/Client.js +1 -1
- package/dist/api/resources/tenants/client/Client.d.ts +6 -1
- package/dist/api/resources/tenants/client/Client.js +13 -8
- package/dist/api/resources/tenants/client/requests/TenantCreateOrReplaceParams.d.ts +6 -1
- package/dist/api/resources/translations/client/Client.js +2 -2
- package/dist/api/resources/users/resources/preferences/client/Client.d.ts +10 -4
- package/dist/api/resources/users/resources/preferences/client/Client.js +43 -8
- package/dist/api/resources/users/resources/preferences/client/requests/UserPreferencesParams.d.ts +15 -0
- package/dist/api/resources/users/resources/preferences/client/requests/UserPreferencesParams.js +5 -0
- package/dist/api/resources/users/resources/preferences/client/requests/UserPreferencesTopicParams.d.ts +15 -0
- package/dist/api/resources/users/resources/preferences/client/requests/UserPreferencesTopicParams.js +5 -0
- package/dist/api/resources/users/resources/preferences/client/requests/UserPreferencesUpdateParams.d.ts +4 -0
- package/dist/api/resources/users/resources/preferences/client/requests/index.d.ts +2 -0
- package/dist/api/resources/users/resources/tenants/client/Client.js +5 -5
- package/dist/api/resources/users/resources/tokens/client/Client.d.ts +5 -1
- package/dist/api/resources/users/resources/tokens/client/Client.js +11 -7
- package/package.json +1 -1
- package/api/resources/send/types/MessageChannelEmailOverride.d.ts +0 -16
- package/api/resources/send/types/Override.d.ts +0 -8
- package/api/resources/send/types/Override.js +0 -10
- package/dist/api/resources/send/types/MessageChannelEmailOverride.d.ts +0 -16
- package/dist/api/resources/send/types/Override.d.ts +0 -8
- package/dist/api/resources/send/types/Override.js +0 -10
- /package/api/resources/{send/types/MessageChannelEmailOverride.js → profiles/types/Pagerduty.js} +0 -0
- /package/{dist/api/resources/send/types/MessageChannelEmailOverride.js → api/resources/profiles/types/UserProfileFirebaseToken.js} +0 -0
|
@@ -80,7 +80,7 @@ class Lists {
|
|
|
80
80
|
Authorization: yield this._getAuthorizationHeader(),
|
|
81
81
|
"X-Fern-Language": "JavaScript",
|
|
82
82
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
83
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
83
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
84
84
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
85
85
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
86
86
|
},
|
|
@@ -139,7 +139,7 @@ class Lists {
|
|
|
139
139
|
Authorization: yield this._getAuthorizationHeader(),
|
|
140
140
|
"X-Fern-Language": "JavaScript",
|
|
141
141
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
142
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
142
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
143
143
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
144
144
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
145
145
|
},
|
|
@@ -187,30 +187,8 @@ class Lists {
|
|
|
187
187
|
* await courier.lists.update("string", {
|
|
188
188
|
* name: "string",
|
|
189
189
|
* preferences: {
|
|
190
|
-
* categories: {
|
|
191
|
-
*
|
|
192
|
-
* status: Courier.PreferenceStatus.OptedIn,
|
|
193
|
-
* rules: [{
|
|
194
|
-
* start: "string",
|
|
195
|
-
* until: "string"
|
|
196
|
-
* }],
|
|
197
|
-
* channel_preferences: [{
|
|
198
|
-
* channel: Courier.ChannelClassification.DirectMessage
|
|
199
|
-
* }]
|
|
200
|
-
* }
|
|
201
|
-
* },
|
|
202
|
-
* notifications: {
|
|
203
|
-
* "string": {
|
|
204
|
-
* status: Courier.PreferenceStatus.OptedIn,
|
|
205
|
-
* rules: [{
|
|
206
|
-
* start: "string",
|
|
207
|
-
* until: "string"
|
|
208
|
-
* }],
|
|
209
|
-
* channel_preferences: [{
|
|
210
|
-
* channel: Courier.ChannelClassification.DirectMessage
|
|
211
|
-
* }]
|
|
212
|
-
* }
|
|
213
|
-
* }
|
|
190
|
+
* categories: {},
|
|
191
|
+
* notifications: {}
|
|
214
192
|
* }
|
|
215
193
|
* })
|
|
216
194
|
*/
|
|
@@ -224,7 +202,7 @@ class Lists {
|
|
|
224
202
|
Authorization: yield this._getAuthorizationHeader(),
|
|
225
203
|
"X-Fern-Language": "JavaScript",
|
|
226
204
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
227
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
205
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
228
206
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
229
207
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
230
208
|
},
|
|
@@ -276,7 +254,7 @@ class Lists {
|
|
|
276
254
|
Authorization: yield this._getAuthorizationHeader(),
|
|
277
255
|
"X-Fern-Language": "JavaScript",
|
|
278
256
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
279
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
257
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
280
258
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
281
259
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
282
260
|
},
|
|
@@ -327,7 +305,7 @@ class Lists {
|
|
|
327
305
|
Authorization: yield this._getAuthorizationHeader(),
|
|
328
306
|
"X-Fern-Language": "JavaScript",
|
|
329
307
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
330
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
308
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
331
309
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
332
310
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
333
311
|
},
|
|
@@ -388,7 +366,7 @@ class Lists {
|
|
|
388
366
|
Authorization: yield this._getAuthorizationHeader(),
|
|
389
367
|
"X-Fern-Language": "JavaScript",
|
|
390
368
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
391
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
369
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
392
370
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
393
371
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
394
372
|
},
|
|
@@ -440,30 +418,8 @@ class Lists {
|
|
|
440
418
|
* recipients: [{
|
|
441
419
|
* recipientId: "string",
|
|
442
420
|
* preferences: {
|
|
443
|
-
* categories: {
|
|
444
|
-
*
|
|
445
|
-
* status: Courier.PreferenceStatus.OptedIn,
|
|
446
|
-
* rules: [{
|
|
447
|
-
* start: "string",
|
|
448
|
-
* until: "string"
|
|
449
|
-
* }],
|
|
450
|
-
* channel_preferences: [{
|
|
451
|
-
* channel: Courier.ChannelClassification.DirectMessage
|
|
452
|
-
* }]
|
|
453
|
-
* }
|
|
454
|
-
* },
|
|
455
|
-
* notifications: {
|
|
456
|
-
* "string": {
|
|
457
|
-
* status: Courier.PreferenceStatus.OptedIn,
|
|
458
|
-
* rules: [{
|
|
459
|
-
* start: "string",
|
|
460
|
-
* until: "string"
|
|
461
|
-
* }],
|
|
462
|
-
* channel_preferences: [{
|
|
463
|
-
* channel: Courier.ChannelClassification.DirectMessage
|
|
464
|
-
* }]
|
|
465
|
-
* }
|
|
466
|
-
* }
|
|
421
|
+
* categories: {},
|
|
422
|
+
* notifications: {}
|
|
467
423
|
* }
|
|
468
424
|
* }]
|
|
469
425
|
* })
|
|
@@ -478,7 +434,7 @@ class Lists {
|
|
|
478
434
|
Authorization: yield this._getAuthorizationHeader(),
|
|
479
435
|
"X-Fern-Language": "JavaScript",
|
|
480
436
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
481
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
437
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
482
438
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
483
439
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
484
440
|
},
|
|
@@ -530,30 +486,8 @@ class Lists {
|
|
|
530
486
|
* recipients: [{
|
|
531
487
|
* recipientId: "string",
|
|
532
488
|
* preferences: {
|
|
533
|
-
* categories: {
|
|
534
|
-
*
|
|
535
|
-
* status: Courier.PreferenceStatus.OptedIn,
|
|
536
|
-
* rules: [{
|
|
537
|
-
* start: "string",
|
|
538
|
-
* until: "string"
|
|
539
|
-
* }],
|
|
540
|
-
* channel_preferences: [{
|
|
541
|
-
* channel: Courier.ChannelClassification.DirectMessage
|
|
542
|
-
* }]
|
|
543
|
-
* }
|
|
544
|
-
* },
|
|
545
|
-
* notifications: {
|
|
546
|
-
* "string": {
|
|
547
|
-
* status: Courier.PreferenceStatus.OptedIn,
|
|
548
|
-
* rules: [{
|
|
549
|
-
* start: "string",
|
|
550
|
-
* until: "string"
|
|
551
|
-
* }],
|
|
552
|
-
* channel_preferences: [{
|
|
553
|
-
* channel: Courier.ChannelClassification.DirectMessage
|
|
554
|
-
* }]
|
|
555
|
-
* }
|
|
556
|
-
* }
|
|
489
|
+
* categories: {},
|
|
490
|
+
* notifications: {}
|
|
557
491
|
* }
|
|
558
492
|
* }]
|
|
559
493
|
* })
|
|
@@ -568,7 +502,7 @@ class Lists {
|
|
|
568
502
|
Authorization: yield this._getAuthorizationHeader(),
|
|
569
503
|
"X-Fern-Language": "JavaScript",
|
|
570
504
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
571
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
505
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
572
506
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
573
507
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
574
508
|
"Idempotency-Key": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey) != null ? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey : undefined,
|
|
@@ -619,30 +553,8 @@ class Lists {
|
|
|
619
553
|
* @example
|
|
620
554
|
* await courier.lists.subscribe("string", "string", {
|
|
621
555
|
* preferences: {
|
|
622
|
-
* categories: {
|
|
623
|
-
*
|
|
624
|
-
* status: Courier.PreferenceStatus.OptedIn,
|
|
625
|
-
* rules: [{
|
|
626
|
-
* start: "string",
|
|
627
|
-
* until: "string"
|
|
628
|
-
* }],
|
|
629
|
-
* channel_preferences: [{
|
|
630
|
-
* channel: Courier.ChannelClassification.DirectMessage
|
|
631
|
-
* }]
|
|
632
|
-
* }
|
|
633
|
-
* },
|
|
634
|
-
* notifications: {
|
|
635
|
-
* "string": {
|
|
636
|
-
* status: Courier.PreferenceStatus.OptedIn,
|
|
637
|
-
* rules: [{
|
|
638
|
-
* start: "string",
|
|
639
|
-
* until: "string"
|
|
640
|
-
* }],
|
|
641
|
-
* channel_preferences: [{
|
|
642
|
-
* channel: Courier.ChannelClassification.DirectMessage
|
|
643
|
-
* }]
|
|
644
|
-
* }
|
|
645
|
-
* }
|
|
556
|
+
* categories: {},
|
|
557
|
+
* notifications: {}
|
|
646
558
|
* }
|
|
647
559
|
* })
|
|
648
560
|
*/
|
|
@@ -656,7 +568,7 @@ class Lists {
|
|
|
656
568
|
Authorization: yield this._getAuthorizationHeader(),
|
|
657
569
|
"X-Fern-Language": "JavaScript",
|
|
658
570
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
659
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
571
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
660
572
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
661
573
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
662
574
|
},
|
|
@@ -711,7 +623,7 @@ class Lists {
|
|
|
711
623
|
Authorization: yield this._getAuthorizationHeader(),
|
|
712
624
|
"X-Fern-Language": "JavaScript",
|
|
713
625
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
714
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
626
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
715
627
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
716
628
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
717
629
|
},
|
|
@@ -8,30 +8,8 @@ import * as Courier from "../../../../index";
|
|
|
8
8
|
* recipients: [{
|
|
9
9
|
* recipientId: "string",
|
|
10
10
|
* preferences: {
|
|
11
|
-
* categories: {
|
|
12
|
-
*
|
|
13
|
-
* status: Courier.PreferenceStatus.OptedIn,
|
|
14
|
-
* rules: [{
|
|
15
|
-
* start: "string",
|
|
16
|
-
* until: "string"
|
|
17
|
-
* }],
|
|
18
|
-
* channel_preferences: [{
|
|
19
|
-
* channel: Courier.ChannelClassification.DirectMessage
|
|
20
|
-
* }]
|
|
21
|
-
* }
|
|
22
|
-
* },
|
|
23
|
-
* notifications: {
|
|
24
|
-
* "string": {
|
|
25
|
-
* status: Courier.PreferenceStatus.OptedIn,
|
|
26
|
-
* rules: [{
|
|
27
|
-
* start: "string",
|
|
28
|
-
* until: "string"
|
|
29
|
-
* }],
|
|
30
|
-
* channel_preferences: [{
|
|
31
|
-
* channel: Courier.ChannelClassification.DirectMessage
|
|
32
|
-
* }]
|
|
33
|
-
* }
|
|
34
|
-
* }
|
|
11
|
+
* categories: {},
|
|
12
|
+
* notifications: {}
|
|
35
13
|
* }
|
|
36
14
|
* }]
|
|
37
15
|
* }
|
|
@@ -6,30 +6,8 @@ import * as Courier from "../../../../index";
|
|
|
6
6
|
* @example
|
|
7
7
|
* {
|
|
8
8
|
* preferences: {
|
|
9
|
-
* categories: {
|
|
10
|
-
*
|
|
11
|
-
* status: Courier.PreferenceStatus.OptedIn,
|
|
12
|
-
* rules: [{
|
|
13
|
-
* start: "string",
|
|
14
|
-
* until: "string"
|
|
15
|
-
* }],
|
|
16
|
-
* channel_preferences: [{
|
|
17
|
-
* channel: Courier.ChannelClassification.DirectMessage
|
|
18
|
-
* }]
|
|
19
|
-
* }
|
|
20
|
-
* },
|
|
21
|
-
* notifications: {
|
|
22
|
-
* "string": {
|
|
23
|
-
* status: Courier.PreferenceStatus.OptedIn,
|
|
24
|
-
* rules: [{
|
|
25
|
-
* start: "string",
|
|
26
|
-
* until: "string"
|
|
27
|
-
* }],
|
|
28
|
-
* channel_preferences: [{
|
|
29
|
-
* channel: Courier.ChannelClassification.DirectMessage
|
|
30
|
-
* }]
|
|
31
|
-
* }
|
|
32
|
-
* }
|
|
9
|
+
* categories: {},
|
|
10
|
+
* notifications: {}
|
|
33
11
|
* }
|
|
34
12
|
* }
|
|
35
13
|
*/
|
|
@@ -8,30 +8,8 @@ import * as Courier from "../../../../index";
|
|
|
8
8
|
* recipients: [{
|
|
9
9
|
* recipientId: "string",
|
|
10
10
|
* preferences: {
|
|
11
|
-
* categories: {
|
|
12
|
-
*
|
|
13
|
-
* status: Courier.PreferenceStatus.OptedIn,
|
|
14
|
-
* rules: [{
|
|
15
|
-
* start: "string",
|
|
16
|
-
* until: "string"
|
|
17
|
-
* }],
|
|
18
|
-
* channel_preferences: [{
|
|
19
|
-
* channel: Courier.ChannelClassification.DirectMessage
|
|
20
|
-
* }]
|
|
21
|
-
* }
|
|
22
|
-
* },
|
|
23
|
-
* notifications: {
|
|
24
|
-
* "string": {
|
|
25
|
-
* status: Courier.PreferenceStatus.OptedIn,
|
|
26
|
-
* rules: [{
|
|
27
|
-
* start: "string",
|
|
28
|
-
* until: "string"
|
|
29
|
-
* }],
|
|
30
|
-
* channel_preferences: [{
|
|
31
|
-
* channel: Courier.ChannelClassification.DirectMessage
|
|
32
|
-
* }]
|
|
33
|
-
* }
|
|
34
|
-
* }
|
|
11
|
+
* categories: {},
|
|
12
|
+
* notifications: {}
|
|
35
13
|
* }
|
|
36
14
|
* }]
|
|
37
15
|
* }
|
|
@@ -141,7 +141,7 @@ class Messages {
|
|
|
141
141
|
Authorization: yield this._getAuthorizationHeader(),
|
|
142
142
|
"X-Fern-Language": "JavaScript",
|
|
143
143
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
144
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
144
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
145
145
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
146
146
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
147
147
|
},
|
|
@@ -196,7 +196,7 @@ class Messages {
|
|
|
196
196
|
Authorization: yield this._getAuthorizationHeader(),
|
|
197
197
|
"X-Fern-Language": "JavaScript",
|
|
198
198
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
199
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
199
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
200
200
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
201
201
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
202
202
|
},
|
|
@@ -254,7 +254,7 @@ class Messages {
|
|
|
254
254
|
Authorization: yield this._getAuthorizationHeader(),
|
|
255
255
|
"X-Fern-Language": "JavaScript",
|
|
256
256
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
257
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
257
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
258
258
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
259
259
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
260
260
|
"Idempotency-Key": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey) != null ? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey : undefined,
|
|
@@ -318,7 +318,7 @@ class Messages {
|
|
|
318
318
|
Authorization: yield this._getAuthorizationHeader(),
|
|
319
319
|
"X-Fern-Language": "JavaScript",
|
|
320
320
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
321
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
321
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
322
322
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
323
323
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
324
324
|
},
|
|
@@ -378,7 +378,7 @@ class Messages {
|
|
|
378
378
|
Authorization: yield this._getAuthorizationHeader(),
|
|
379
379
|
"X-Fern-Language": "JavaScript",
|
|
380
380
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
381
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
381
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
382
382
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
383
383
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
384
384
|
},
|
|
@@ -434,7 +434,7 @@ class Messages {
|
|
|
434
434
|
Authorization: yield this._getAuthorizationHeader(),
|
|
435
435
|
"X-Fern-Language": "JavaScript",
|
|
436
436
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
437
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
437
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
438
438
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
439
439
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
440
440
|
},
|
|
@@ -24,7 +24,8 @@ export declare class Notifications {
|
|
|
24
24
|
*
|
|
25
25
|
* @example
|
|
26
26
|
* await courier.notifications.list({
|
|
27
|
-
* cursor: "string"
|
|
27
|
+
* cursor: "string",
|
|
28
|
+
* notes: true
|
|
28
29
|
* })
|
|
29
30
|
*/
|
|
30
31
|
list(request?: Courier.NotificationListParams, requestOptions?: Notifications.RequestOptions): Promise<Courier.NotificationListResponse>;
|
|
@@ -53,17 +53,21 @@ class Notifications {
|
|
|
53
53
|
*
|
|
54
54
|
* @example
|
|
55
55
|
* await courier.notifications.list({
|
|
56
|
-
* cursor: "string"
|
|
56
|
+
* cursor: "string",
|
|
57
|
+
* notes: true
|
|
57
58
|
* })
|
|
58
59
|
*/
|
|
59
60
|
list(request = {}, requestOptions) {
|
|
60
61
|
var _a, _b;
|
|
61
62
|
return __awaiter(this, void 0, void 0, function* () {
|
|
62
|
-
const { cursor } = request;
|
|
63
|
+
const { cursor, notes } = request;
|
|
63
64
|
const _queryParams = {};
|
|
64
65
|
if (cursor != null) {
|
|
65
66
|
_queryParams["cursor"] = cursor;
|
|
66
67
|
}
|
|
68
|
+
if (notes != null) {
|
|
69
|
+
_queryParams["notes"] = notes.toString();
|
|
70
|
+
}
|
|
67
71
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
68
72
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.CourierEnvironment.Production, "/notifications"),
|
|
69
73
|
method: "GET",
|
|
@@ -71,7 +75,7 @@ class Notifications {
|
|
|
71
75
|
Authorization: yield this._getAuthorizationHeader(),
|
|
72
76
|
"X-Fern-Language": "JavaScript",
|
|
73
77
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
74
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
78
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
75
79
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
76
80
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
77
81
|
},
|
|
@@ -121,7 +125,7 @@ class Notifications {
|
|
|
121
125
|
Authorization: yield this._getAuthorizationHeader(),
|
|
122
126
|
"X-Fern-Language": "JavaScript",
|
|
123
127
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
124
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
128
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
125
129
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
126
130
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
127
131
|
},
|
|
@@ -170,7 +174,7 @@ class Notifications {
|
|
|
170
174
|
Authorization: yield this._getAuthorizationHeader(),
|
|
171
175
|
"X-Fern-Language": "JavaScript",
|
|
172
176
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
173
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
177
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
174
178
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
175
179
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
176
180
|
},
|
|
@@ -220,7 +224,7 @@ class Notifications {
|
|
|
220
224
|
Authorization: yield this._getAuthorizationHeader(),
|
|
221
225
|
"X-Fern-Language": "JavaScript",
|
|
222
226
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
223
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
227
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
224
228
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
225
229
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
226
230
|
},
|
|
@@ -277,7 +281,7 @@ class Notifications {
|
|
|
277
281
|
Authorization: yield this._getAuthorizationHeader(),
|
|
278
282
|
"X-Fern-Language": "JavaScript",
|
|
279
283
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
280
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
284
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
281
285
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
282
286
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
283
287
|
},
|
|
@@ -328,7 +332,7 @@ class Notifications {
|
|
|
328
332
|
Authorization: yield this._getAuthorizationHeader(),
|
|
329
333
|
"X-Fern-Language": "JavaScript",
|
|
330
334
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
331
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
335
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
332
336
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
333
337
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
334
338
|
},
|
|
@@ -4,9 +4,14 @@
|
|
|
4
4
|
/**
|
|
5
5
|
* @example
|
|
6
6
|
* {
|
|
7
|
-
* cursor: "string"
|
|
7
|
+
* cursor: "string",
|
|
8
|
+
* notes: true
|
|
8
9
|
* }
|
|
9
10
|
*/
|
|
10
11
|
export interface NotificationListParams {
|
|
11
12
|
cursor?: string;
|
|
13
|
+
/**
|
|
14
|
+
* Retrieve the notes from the Notification template settings.
|
|
15
|
+
*/
|
|
16
|
+
notes?: boolean;
|
|
12
17
|
}
|
|
@@ -113,7 +113,13 @@ export declare class Profiles {
|
|
|
113
113
|
*
|
|
114
114
|
* @example
|
|
115
115
|
* await courier.profiles.subscribeToLists("string", {
|
|
116
|
-
* lists: [{
|
|
116
|
+
* lists: [{
|
|
117
|
+
* listId: "string",
|
|
118
|
+
* preferences: {
|
|
119
|
+
* categories: {},
|
|
120
|
+
* notifications: {}
|
|
121
|
+
* }
|
|
122
|
+
* }]
|
|
117
123
|
* })
|
|
118
124
|
*/
|
|
119
125
|
subscribeToLists(userId: string, request: Courier.SubscribeToListsRequest, requestOptions?: Profiles.IdempotentRequestOptions): Promise<Courier.SubscribeToListsResponse>;
|
|
@@ -69,7 +69,7 @@ class Profiles {
|
|
|
69
69
|
Authorization: yield this._getAuthorizationHeader(),
|
|
70
70
|
"X-Fern-Language": "JavaScript",
|
|
71
71
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
72
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
72
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
73
73
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
74
74
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
75
75
|
},
|
|
@@ -134,7 +134,7 @@ class Profiles {
|
|
|
134
134
|
Authorization: yield this._getAuthorizationHeader(),
|
|
135
135
|
"X-Fern-Language": "JavaScript",
|
|
136
136
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
137
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
137
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
138
138
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
139
139
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
140
140
|
"Idempotency-Key": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey) != null ? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey : undefined,
|
|
@@ -205,7 +205,7 @@ class Profiles {
|
|
|
205
205
|
Authorization: yield this._getAuthorizationHeader(),
|
|
206
206
|
"X-Fern-Language": "JavaScript",
|
|
207
207
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
208
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
208
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
209
209
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
210
210
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
211
211
|
},
|
|
@@ -264,7 +264,7 @@ class Profiles {
|
|
|
264
264
|
Authorization: yield this._getAuthorizationHeader(),
|
|
265
265
|
"X-Fern-Language": "JavaScript",
|
|
266
266
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
267
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
267
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
268
268
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
269
269
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
270
270
|
},
|
|
@@ -330,7 +330,7 @@ class Profiles {
|
|
|
330
330
|
Authorization: yield this._getAuthorizationHeader(),
|
|
331
331
|
"X-Fern-Language": "JavaScript",
|
|
332
332
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
333
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
333
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
334
334
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
335
335
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
336
336
|
},
|
|
@@ -379,7 +379,13 @@ class Profiles {
|
|
|
379
379
|
*
|
|
380
380
|
* @example
|
|
381
381
|
* await courier.profiles.subscribeToLists("string", {
|
|
382
|
-
* lists: [{
|
|
382
|
+
* lists: [{
|
|
383
|
+
* listId: "string",
|
|
384
|
+
* preferences: {
|
|
385
|
+
* categories: {},
|
|
386
|
+
* notifications: {}
|
|
387
|
+
* }
|
|
388
|
+
* }]
|
|
383
389
|
* })
|
|
384
390
|
*/
|
|
385
391
|
subscribeToLists(userId, request, requestOptions) {
|
|
@@ -392,7 +398,7 @@ class Profiles {
|
|
|
392
398
|
Authorization: yield this._getAuthorizationHeader(),
|
|
393
399
|
"X-Fern-Language": "JavaScript",
|
|
394
400
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
395
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
401
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
396
402
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
397
403
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
398
404
|
"Idempotency-Key": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey) != null ? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey : undefined,
|
|
@@ -453,7 +459,7 @@ class Profiles {
|
|
|
453
459
|
Authorization: yield this._getAuthorizationHeader(),
|
|
454
460
|
"X-Fern-Language": "JavaScript",
|
|
455
461
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
456
|
-
"X-Fern-SDK-Version": "v6.2.
|
|
462
|
+
"X-Fern-SDK-Version": "v6.2.3",
|
|
457
463
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
458
464
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
459
465
|
},
|
|
@@ -31,7 +31,7 @@ export interface UserProfile {
|
|
|
31
31
|
discord: Courier.Discord;
|
|
32
32
|
expo: Courier.Expo;
|
|
33
33
|
facebookPSID: string;
|
|
34
|
-
firebaseToken:
|
|
34
|
+
firebaseToken: Courier.UserProfileFirebaseToken;
|
|
35
35
|
intercom: Courier.Intercom;
|
|
36
36
|
slack: Courier.Slack;
|
|
37
37
|
ms_teams: Courier.MsTeams;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
export declare type WebhookAuthMode = "none" | "basic" | "bearer";
|
|
5
|
+
export declare const WebhookAuthMode: {
|
|
6
|
+
readonly None: "none";
|
|
7
|
+
readonly Basic: "basic";
|
|
8
|
+
readonly Bearer: "bearer";
|
|
9
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
4
|
+
*/
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.WebhookAuthMode = void 0;
|
|
7
|
+
exports.WebhookAuthMode = {
|
|
8
|
+
None: "none",
|
|
9
|
+
Basic: "basic",
|
|
10
|
+
Bearer: "bearer",
|
|
11
|
+
};
|