@trycourier/courier 6.6.1-alpha0 → 6.7.0-alpha10
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/CHANGELOG.md +124 -0
- package/README.md +11 -11
- package/client.d.mts +48 -20
- package/client.d.mts.map +1 -1
- package/client.d.ts +48 -20
- package/client.d.ts.map +1 -1
- package/client.js.map +1 -1
- package/client.mjs +3 -3
- package/client.mjs.map +1 -1
- package/internal/to-file.d.mts +1 -1
- package/internal/to-file.d.ts +1 -1
- package/internal/to-file.js +1 -1
- package/internal/to-file.mjs +1 -1
- package/internal/tslib.js +6 -6
- package/package.json +1 -1
- package/resources/audiences.d.mts +30 -52
- package/resources/audiences.d.mts.map +1 -1
- package/resources/audiences.d.ts +30 -52
- package/resources/audiences.d.ts.map +1 -1
- package/resources/audiences.js.map +1 -1
- package/resources/audiences.mjs.map +1 -1
- package/resources/audit-events.d.mts +5 -9
- package/resources/audit-events.d.mts.map +1 -1
- package/resources/audit-events.d.ts +5 -9
- package/resources/audit-events.d.ts.map +1 -1
- package/resources/auth.d.mts +2 -2
- package/resources/auth.d.mts.map +1 -1
- package/resources/auth.d.ts +2 -2
- package/resources/auth.d.ts.map +1 -1
- package/resources/automations/automations.d.mts +5 -252
- package/resources/automations/automations.d.mts.map +1 -1
- package/resources/automations/automations.d.ts +5 -252
- package/resources/automations/automations.d.ts.map +1 -1
- package/resources/automations/automations.js +0 -42
- package/resources/automations/automations.js.map +1 -1
- package/resources/automations/automations.mjs +1 -43
- package/resources/automations/automations.mjs.map +1 -1
- package/resources/automations/index.d.mts +2 -2
- package/resources/automations/index.d.mts.map +1 -1
- package/resources/automations/index.d.ts +2 -2
- package/resources/automations/index.d.ts.map +1 -1
- package/resources/automations/index.js.map +1 -1
- package/resources/automations/index.mjs +2 -2
- package/resources/automations/index.mjs.map +1 -1
- package/resources/automations/invoke.d.mts +122 -9
- package/resources/automations/invoke.d.mts.map +1 -1
- package/resources/automations/invoke.d.ts +122 -9
- package/resources/automations/invoke.d.ts.map +1 -1
- package/resources/automations/invoke.js +45 -0
- package/resources/automations/invoke.js.map +1 -1
- package/resources/automations/invoke.mjs +45 -0
- package/resources/automations/invoke.mjs.map +1 -1
- package/resources/brands.d.mts +76 -52
- package/resources/brands.d.mts.map +1 -1
- package/resources/brands.d.ts +76 -52
- package/resources/brands.d.ts.map +1 -1
- package/resources/brands.js.map +1 -1
- package/resources/brands.mjs.map +1 -1
- package/resources/bulk.d.mts +36 -127
- package/resources/bulk.d.mts.map +1 -1
- package/resources/bulk.d.ts +36 -127
- package/resources/bulk.d.ts.map +1 -1
- package/resources/bulk.js.map +1 -1
- package/resources/bulk.mjs.map +1 -1
- package/resources/inbound.d.mts +1 -1
- package/resources/inbound.d.ts +1 -1
- package/resources/index.d.mts +11 -10
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +11 -10
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +2 -0
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +3 -2
- package/resources/index.mjs.map +1 -1
- package/resources/lists/index.d.mts +2 -2
- package/resources/lists/index.d.mts.map +1 -1
- package/resources/lists/index.d.ts +2 -2
- package/resources/lists/index.d.ts.map +1 -1
- package/resources/lists/index.js.map +1 -1
- package/resources/lists/index.mjs +1 -1
- package/resources/lists/index.mjs.map +1 -1
- package/resources/lists/lists.d.mts +19 -13
- package/resources/lists/lists.d.mts.map +1 -1
- package/resources/lists/lists.d.ts +19 -13
- package/resources/lists/lists.d.ts.map +1 -1
- package/resources/lists/lists.js +7 -2
- package/resources/lists/lists.js.map +1 -1
- package/resources/lists/lists.mjs +7 -2
- package/resources/lists/lists.mjs.map +1 -1
- package/resources/lists/subscriptions.d.mts +8 -52
- package/resources/lists/subscriptions.d.mts.map +1 -1
- package/resources/lists/subscriptions.d.ts +8 -52
- package/resources/lists/subscriptions.d.ts.map +1 -1
- package/resources/lists/subscriptions.js.map +1 -1
- package/resources/lists/subscriptions.mjs.map +1 -1
- package/resources/messages.d.mts +8 -8
- package/resources/messages.d.mts.map +1 -1
- package/resources/messages.d.ts +8 -8
- package/resources/messages.d.ts.map +1 -1
- package/resources/messages.js +1 -1
- package/resources/messages.js.map +1 -1
- package/resources/messages.mjs +1 -1
- package/resources/messages.mjs.map +1 -1
- package/resources/notifications/checks.d.mts +5 -12
- package/resources/notifications/checks.d.mts.map +1 -1
- package/resources/notifications/checks.d.ts +5 -12
- package/resources/notifications/checks.d.ts.map +1 -1
- package/resources/notifications/checks.js.map +1 -1
- package/resources/notifications/checks.mjs.map +1 -1
- package/resources/notifications/index.d.mts +2 -2
- package/resources/notifications/index.d.mts.map +1 -1
- package/resources/notifications/index.d.ts +2 -2
- package/resources/notifications/index.d.ts.map +1 -1
- package/resources/notifications/index.js.map +1 -1
- package/resources/notifications/index.mjs.map +1 -1
- package/resources/notifications/notifications.d.mts +13 -11
- package/resources/notifications/notifications.d.mts.map +1 -1
- package/resources/notifications/notifications.d.ts +13 -11
- package/resources/notifications/notifications.d.ts.map +1 -1
- package/resources/notifications/notifications.js.map +1 -1
- package/resources/notifications/notifications.mjs.map +1 -1
- package/resources/profiles/index.d.mts +1 -1
- package/resources/profiles/index.d.mts.map +1 -1
- package/resources/profiles/index.d.ts +1 -1
- package/resources/profiles/index.d.ts.map +1 -1
- package/resources/profiles/index.js.map +1 -1
- package/resources/profiles/index.mjs.map +1 -1
- package/resources/profiles/lists.d.mts +5 -11
- package/resources/profiles/lists.d.mts.map +1 -1
- package/resources/profiles/lists.d.ts +5 -11
- package/resources/profiles/lists.d.ts.map +1 -1
- package/resources/profiles/profiles.d.mts +7 -3
- package/resources/profiles/profiles.d.mts.map +1 -1
- package/resources/profiles/profiles.d.ts +7 -3
- package/resources/profiles/profiles.d.ts.map +1 -1
- package/resources/profiles/profiles.js.map +1 -1
- package/resources/profiles/profiles.mjs.map +1 -1
- package/resources/send.d.mts +127 -745
- package/resources/send.d.mts.map +1 -1
- package/resources/send.d.ts +127 -745
- package/resources/send.d.ts.map +1 -1
- package/resources/send.js +12 -1
- package/resources/send.js.map +1 -1
- package/resources/send.mjs +12 -1
- package/resources/send.mjs.map +1 -1
- package/resources/shared.d.mts +245 -0
- package/resources/shared.d.mts.map +1 -0
- package/resources/shared.d.ts +245 -0
- package/resources/shared.d.ts.map +1 -0
- package/resources/shared.js +4 -0
- package/resources/shared.js.map +1 -0
- package/{src/resources/tenants/default-preferences.ts → resources/shared.mjs} +2 -2
- package/resources/shared.mjs.map +1 -0
- package/resources/tenants/index.d.mts +3 -1
- package/resources/tenants/index.d.mts.map +1 -1
- package/resources/tenants/index.d.ts +3 -1
- package/resources/tenants/index.d.ts.map +1 -1
- package/resources/tenants/index.js +5 -1
- package/resources/tenants/index.js.map +1 -1
- package/resources/tenants/index.mjs +2 -0
- package/resources/tenants/index.mjs.map +1 -1
- package/resources/tenants/templates.d.mts +91 -0
- package/resources/tenants/templates.d.mts.map +1 -0
- package/resources/tenants/templates.d.ts +91 -0
- package/resources/tenants/templates.d.ts.map +1 -0
- package/resources/tenants/templates.js +38 -0
- package/resources/tenants/templates.js.map +1 -0
- package/resources/tenants/templates.mjs +34 -0
- package/resources/tenants/templates.mjs.map +1 -0
- package/resources/tenants/tenant-default-preferences/index.d.mts +3 -0
- package/resources/tenants/tenant-default-preferences/index.d.mts.map +1 -0
- package/resources/tenants/tenant-default-preferences/index.d.ts +3 -0
- package/resources/tenants/tenant-default-preferences/index.d.ts.map +1 -0
- package/resources/tenants/tenant-default-preferences/index.js +9 -0
- package/resources/tenants/tenant-default-preferences/index.js.map +1 -0
- package/resources/tenants/tenant-default-preferences/index.mjs +4 -0
- package/resources/tenants/tenant-default-preferences/index.mjs.map +1 -0
- package/resources/tenants/{default-preferences → tenant-default-preferences}/items.d.mts +5 -18
- package/resources/tenants/tenant-default-preferences/items.d.mts.map +1 -0
- package/resources/tenants/{default-preferences → tenant-default-preferences}/items.d.ts +5 -18
- package/resources/tenants/tenant-default-preferences/items.d.ts.map +1 -0
- package/resources/tenants/{default-preferences → tenant-default-preferences}/items.js +2 -2
- package/resources/tenants/tenant-default-preferences/items.js.map +1 -0
- package/resources/tenants/{default-preferences → tenant-default-preferences}/items.mjs +2 -2
- package/resources/tenants/tenant-default-preferences/items.mjs.map +1 -0
- package/resources/tenants/tenant-default-preferences/tenant-default-preferences.d.mts +10 -0
- package/resources/tenants/tenant-default-preferences/tenant-default-preferences.d.mts.map +1 -0
- package/resources/tenants/tenant-default-preferences/tenant-default-preferences.d.ts +10 -0
- package/resources/tenants/tenant-default-preferences/tenant-default-preferences.d.ts.map +1 -0
- package/resources/tenants/{default-preferences/default-preferences.js → tenant-default-preferences/tenant-default-preferences.js} +5 -5
- package/resources/tenants/tenant-default-preferences/tenant-default-preferences.js.map +1 -0
- package/resources/tenants/{default-preferences/default-preferences.mjs → tenant-default-preferences/tenant-default-preferences.mjs} +4 -4
- package/resources/tenants/tenant-default-preferences/tenant-default-preferences.mjs.map +1 -0
- package/resources/tenants/tenant-default-preferences.d.mts +2 -0
- package/resources/tenants/tenant-default-preferences.d.mts.map +1 -0
- package/resources/tenants/tenant-default-preferences.d.ts +2 -0
- package/resources/tenants/tenant-default-preferences.d.ts.map +1 -0
- package/resources/tenants/{default-preferences.js → tenant-default-preferences.js} +2 -2
- package/resources/tenants/tenant-default-preferences.js.map +1 -0
- package/resources/tenants/tenant-default-preferences.mjs +3 -0
- package/resources/tenants/tenant-default-preferences.mjs.map +1 -0
- package/resources/tenants/tenants.d.mts +66 -7
- package/resources/tenants/tenants.d.mts.map +1 -1
- package/resources/tenants/tenants.d.ts +66 -7
- package/resources/tenants/tenants.d.ts.map +1 -1
- package/resources/tenants/tenants.js +8 -2
- package/resources/tenants/tenants.js.map +1 -1
- package/resources/tenants/tenants.mjs +8 -2
- package/resources/tenants/tenants.mjs.map +1 -1
- package/resources/users/index.d.mts +3 -3
- package/resources/users/index.d.mts.map +1 -1
- package/resources/users/index.d.ts +3 -3
- package/resources/users/index.d.ts.map +1 -1
- package/resources/users/index.js.map +1 -1
- package/resources/users/index.mjs.map +1 -1
- package/resources/users/preferences.d.mts +8 -11
- package/resources/users/preferences.d.mts.map +1 -1
- package/resources/users/preferences.d.ts +8 -11
- package/resources/users/preferences.d.ts.map +1 -1
- package/resources/users/preferences.js.map +1 -1
- package/resources/users/preferences.mjs.map +1 -1
- package/resources/users/tenants.d.mts +4 -21
- package/resources/users/tenants.d.mts.map +1 -1
- package/resources/users/tenants.d.ts +4 -21
- package/resources/users/tenants.d.ts.map +1 -1
- package/resources/users/tenants.js.map +1 -1
- package/resources/users/tenants.mjs.map +1 -1
- package/resources/users/tokens.d.mts +22 -23
- package/resources/users/tokens.d.mts.map +1 -1
- package/resources/users/tokens.d.ts +22 -23
- package/resources/users/tokens.d.ts.map +1 -1
- package/resources/users/tokens.js +14 -15
- package/resources/users/tokens.js.map +1 -1
- package/resources/users/tokens.mjs +14 -15
- package/resources/users/tokens.mjs.map +1 -1
- package/resources/users/users.d.mts +6 -6
- package/resources/users/users.d.mts.map +1 -1
- package/resources/users/users.d.ts +6 -6
- package/resources/users/users.d.ts.map +1 -1
- package/resources/users/users.js.map +1 -1
- package/resources/users/users.mjs.map +1 -1
- package/src/client.ts +81 -56
- package/src/internal/to-file.ts +1 -1
- package/src/resources/audiences.ts +45 -90
- package/src/resources/audit-events.ts +7 -13
- package/src/resources/auth.ts +2 -16
- package/src/resources/automations/automations.ts +6 -342
- package/src/resources/automations/index.ts +2 -12
- package/src/resources/automations/invoke.ts +163 -14
- package/src/resources/brands.ts +119 -53
- package/src/resources/bulk.ts +28 -148
- package/src/resources/inbound.ts +1 -1
- package/src/resources/index.ts +24 -30
- package/src/resources/lists/index.ts +9 -3
- package/src/resources/lists/lists.ts +27 -16
- package/src/resources/lists/subscriptions.ts +7 -65
- package/src/resources/messages.ts +10 -7
- package/src/resources/notifications/checks.ts +4 -17
- package/src/resources/notifications/index.ts +2 -4
- package/src/resources/notifications/notifications.ts +13 -14
- package/src/resources/profiles/index.ts +1 -0
- package/src/resources/profiles/lists.ts +5 -13
- package/src/resources/profiles/profiles.ts +9 -2
- package/src/resources/send.ts +122 -928
- package/src/resources/shared.ts +305 -0
- package/src/resources/tenants/index.ts +10 -0
- package/src/resources/tenants/templates.ts +124 -0
- package/src/resources/tenants/tenant-default-preferences/index.ts +4 -0
- package/src/resources/tenants/{default-preferences → tenant-default-preferences}/items.ts +5 -27
- package/src/resources/tenants/{default-preferences/default-preferences.ts → tenant-default-preferences/tenant-default-preferences.ts} +4 -12
- package/src/resources/tenants/tenant-default-preferences.ts +3 -0
- package/src/resources/tenants/tenants.ts +89 -8
- package/src/resources/users/index.ts +2 -4
- package/src/resources/users/preferences.ts +7 -12
- package/src/resources/users/tenants.ts +3 -23
- package/src/resources/users/tokens.ts +33 -34
- package/src/resources/users/users.ts +4 -8
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.mts.map +1 -1
- package/version.d.ts +1 -1
- package/version.d.ts.map +1 -1
- package/version.js +1 -1
- package/version.js.map +1 -1
- package/version.mjs +1 -1
- package/version.mjs.map +1 -1
- package/resources/tenants/default-preferences/default-preferences.d.mts +0 -10
- package/resources/tenants/default-preferences/default-preferences.d.mts.map +0 -1
- package/resources/tenants/default-preferences/default-preferences.d.ts +0 -10
- package/resources/tenants/default-preferences/default-preferences.d.ts.map +0 -1
- package/resources/tenants/default-preferences/default-preferences.js.map +0 -1
- package/resources/tenants/default-preferences/default-preferences.mjs.map +0 -1
- package/resources/tenants/default-preferences/index.d.mts +0 -3
- package/resources/tenants/default-preferences/index.d.mts.map +0 -1
- package/resources/tenants/default-preferences/index.d.ts +0 -3
- package/resources/tenants/default-preferences/index.d.ts.map +0 -1
- package/resources/tenants/default-preferences/index.js +0 -9
- package/resources/tenants/default-preferences/index.js.map +0 -1
- package/resources/tenants/default-preferences/index.mjs +0 -4
- package/resources/tenants/default-preferences/index.mjs.map +0 -1
- package/resources/tenants/default-preferences/items.d.mts.map +0 -1
- package/resources/tenants/default-preferences/items.d.ts.map +0 -1
- package/resources/tenants/default-preferences/items.js.map +0 -1
- package/resources/tenants/default-preferences/items.mjs.map +0 -1
- package/resources/tenants/default-preferences.d.mts +0 -2
- package/resources/tenants/default-preferences.d.mts.map +0 -1
- package/resources/tenants/default-preferences.d.ts +0 -2
- package/resources/tenants/default-preferences.d.ts.map +0 -1
- package/resources/tenants/default-preferences.js.map +0 -1
- package/resources/tenants/default-preferences.mjs +0 -3
- package/resources/tenants/default-preferences.mjs.map +0 -1
- package/src/resources/tenants/default-preferences/index.ts +0 -10
package/src/resources/brands.ts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
3
|
import { APIResource } from '../core/resource';
|
|
4
|
-
import * as
|
|
4
|
+
import * as BrandsAPI from './brands';
|
|
5
|
+
import * as Shared from './shared';
|
|
5
6
|
import { APIPromise } from '../core/api-promise';
|
|
6
7
|
import { buildHeaders } from '../internal/headers';
|
|
7
8
|
import { RequestOptions } from '../internal/request-options';
|
|
@@ -51,98 +52,152 @@ export class Brands extends APIResource {
|
|
|
51
52
|
}
|
|
52
53
|
|
|
53
54
|
export interface Brand {
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
* Unix epoch.
|
|
57
|
-
*/
|
|
55
|
+
id: string;
|
|
56
|
+
|
|
58
57
|
created: number;
|
|
59
58
|
|
|
60
|
-
/**
|
|
61
|
-
* Brand name
|
|
62
|
-
*/
|
|
63
59
|
name: string;
|
|
64
60
|
|
|
65
|
-
/**
|
|
66
|
-
* The date/time of when the brand was published. Represented in milliseconds since
|
|
67
|
-
* Unix epoch.
|
|
68
|
-
*/
|
|
69
|
-
published: number;
|
|
70
|
-
|
|
71
|
-
settings: BrandSettings;
|
|
72
|
-
|
|
73
|
-
/**
|
|
74
|
-
* The date/time of when the brand was updated. Represented in milliseconds since
|
|
75
|
-
* Unix epoch.
|
|
76
|
-
*/
|
|
77
61
|
updated: number;
|
|
78
62
|
|
|
79
|
-
|
|
80
|
-
* The version identifier for the brand
|
|
81
|
-
*/
|
|
82
|
-
version: string;
|
|
63
|
+
published?: number | null;
|
|
83
64
|
|
|
84
|
-
|
|
85
|
-
* Brand Identifier
|
|
86
|
-
*/
|
|
87
|
-
id?: string | null;
|
|
65
|
+
settings?: BrandSettings | null;
|
|
88
66
|
|
|
89
67
|
snippets?: BrandSnippets | null;
|
|
68
|
+
|
|
69
|
+
version?: string | null;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export interface BrandColors {
|
|
73
|
+
primary?: string;
|
|
74
|
+
|
|
75
|
+
secondary?: string;
|
|
76
|
+
|
|
77
|
+
[k: string]: string | undefined;
|
|
90
78
|
}
|
|
91
79
|
|
|
92
80
|
export interface BrandSettings {
|
|
93
|
-
colors?:
|
|
81
|
+
colors?: BrandColors | null;
|
|
94
82
|
|
|
95
|
-
email?:
|
|
83
|
+
email?: BrandSettingsEmail | null;
|
|
96
84
|
|
|
97
|
-
inapp?:
|
|
85
|
+
inapp?: BrandSettingsInApp | null;
|
|
98
86
|
}
|
|
99
87
|
|
|
100
|
-
export
|
|
101
|
-
|
|
102
|
-
primary?: string | null;
|
|
88
|
+
export interface BrandSettingsEmail {
|
|
89
|
+
footer?: EmailFooter | null;
|
|
103
90
|
|
|
104
|
-
|
|
91
|
+
head?: EmailHead | null;
|
|
105
92
|
|
|
106
|
-
|
|
107
|
-
|
|
93
|
+
header?: EmailHeader | null;
|
|
94
|
+
|
|
95
|
+
templateOverride?: BrandSettingsEmail.TemplateOverride | null;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
export namespace BrandSettingsEmail {
|
|
99
|
+
export interface TemplateOverride extends BrandsAPI.BrandTemplate {
|
|
100
|
+
mjml: BrandsAPI.BrandTemplate;
|
|
108
101
|
|
|
109
|
-
|
|
110
|
-
footer: unknown;
|
|
102
|
+
footerBackgroundColor?: string | null;
|
|
111
103
|
|
|
112
|
-
|
|
104
|
+
footerFullWidth?: boolean | null;
|
|
113
105
|
}
|
|
114
106
|
}
|
|
115
107
|
|
|
108
|
+
export interface BrandSettingsInApp {
|
|
109
|
+
colors: BrandColors;
|
|
110
|
+
|
|
111
|
+
icons: Icons;
|
|
112
|
+
|
|
113
|
+
widgetBackground: WidgetBackground;
|
|
114
|
+
|
|
115
|
+
borderRadius?: string | null;
|
|
116
|
+
|
|
117
|
+
disableMessageIcon?: boolean | null;
|
|
118
|
+
|
|
119
|
+
fontFamily?: string | null;
|
|
120
|
+
|
|
121
|
+
placement?: 'top' | 'bottom' | 'left' | 'right' | null;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
export interface BrandSnippet {
|
|
125
|
+
name: string;
|
|
126
|
+
|
|
127
|
+
value: string;
|
|
128
|
+
}
|
|
129
|
+
|
|
116
130
|
export interface BrandSnippets {
|
|
117
|
-
items
|
|
131
|
+
items?: Array<BrandSnippet> | null;
|
|
118
132
|
}
|
|
119
133
|
|
|
120
|
-
export
|
|
121
|
-
|
|
122
|
-
format: 'handlebars';
|
|
134
|
+
export interface BrandTemplate {
|
|
135
|
+
enabled: boolean;
|
|
123
136
|
|
|
124
|
-
|
|
137
|
+
backgroundColor?: string | null;
|
|
125
138
|
|
|
126
|
-
|
|
127
|
-
|
|
139
|
+
blocksBackgroundColor?: string | null;
|
|
140
|
+
|
|
141
|
+
footer?: string | null;
|
|
142
|
+
|
|
143
|
+
head?: string | null;
|
|
144
|
+
|
|
145
|
+
header?: string | null;
|
|
146
|
+
|
|
147
|
+
width?: string | null;
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
export interface EmailFooter {
|
|
151
|
+
content?: string | null;
|
|
152
|
+
|
|
153
|
+
inheritDefault?: boolean | null;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
export interface EmailHead {
|
|
157
|
+
inheritDefault: boolean;
|
|
158
|
+
|
|
159
|
+
content?: string | null;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
export interface EmailHeader {
|
|
163
|
+
logo: Logo;
|
|
164
|
+
|
|
165
|
+
barColor?: string | null;
|
|
166
|
+
|
|
167
|
+
inheritDefault?: boolean | null;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
export interface Icons {
|
|
171
|
+
bell?: string | null;
|
|
172
|
+
|
|
173
|
+
message?: string | null;
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
export interface Logo {
|
|
177
|
+
href?: string | null;
|
|
178
|
+
|
|
179
|
+
image?: string | null;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
export interface WidgetBackground {
|
|
183
|
+
bottomColor?: string | null;
|
|
184
|
+
|
|
185
|
+
topColor?: string | null;
|
|
128
186
|
}
|
|
129
187
|
|
|
130
188
|
export interface BrandListResponse {
|
|
131
|
-
paging:
|
|
189
|
+
paging: Shared.Paging;
|
|
132
190
|
|
|
133
191
|
results: Array<Brand>;
|
|
134
192
|
}
|
|
135
193
|
|
|
136
194
|
export interface BrandCreateParams {
|
|
137
|
-
/**
|
|
138
|
-
* The name of the brand.
|
|
139
|
-
*/
|
|
140
195
|
name: string;
|
|
141
196
|
|
|
142
|
-
settings: BrandSettings;
|
|
143
|
-
|
|
144
197
|
id?: string | null;
|
|
145
198
|
|
|
199
|
+
settings?: BrandSettings | null;
|
|
200
|
+
|
|
146
201
|
snippets?: BrandSnippets | null;
|
|
147
202
|
}
|
|
148
203
|
|
|
@@ -167,8 +222,19 @@ export interface BrandListParams {
|
|
|
167
222
|
export declare namespace Brands {
|
|
168
223
|
export {
|
|
169
224
|
type Brand as Brand,
|
|
225
|
+
type BrandColors as BrandColors,
|
|
170
226
|
type BrandSettings as BrandSettings,
|
|
227
|
+
type BrandSettingsEmail as BrandSettingsEmail,
|
|
228
|
+
type BrandSettingsInApp as BrandSettingsInApp,
|
|
229
|
+
type BrandSnippet as BrandSnippet,
|
|
171
230
|
type BrandSnippets as BrandSnippets,
|
|
231
|
+
type BrandTemplate as BrandTemplate,
|
|
232
|
+
type EmailFooter as EmailFooter,
|
|
233
|
+
type EmailHead as EmailHead,
|
|
234
|
+
type EmailHeader as EmailHeader,
|
|
235
|
+
type Icons as Icons,
|
|
236
|
+
type Logo as Logo,
|
|
237
|
+
type WidgetBackground as WidgetBackground,
|
|
172
238
|
type BrandListResponse as BrandListResponse,
|
|
173
239
|
type BrandCreateParams as BrandCreateParams,
|
|
174
240
|
type BrandUpdateParams as BrandUpdateParams,
|
package/src/resources/bulk.ts
CHANGED
|
@@ -2,11 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { APIResource } from '../core/resource';
|
|
4
4
|
import * as BulkAPI from './bulk';
|
|
5
|
-
import * as
|
|
6
|
-
import * as SendAPI from './send';
|
|
7
|
-
import * as SubscriptionsAPI from './lists/subscriptions';
|
|
8
|
-
import * as PreferencesAPI from './users/preferences';
|
|
9
|
-
import * as ItemsAPI from './tenants/default-preferences/items';
|
|
5
|
+
import * as Shared from './shared';
|
|
10
6
|
import { APIPromise } from '../core/api-promise';
|
|
11
7
|
import { buildHeaders } from '../internal/headers';
|
|
12
8
|
import { RequestOptions } from '../internal/request-options';
|
|
@@ -60,168 +56,53 @@ export class Bulk extends APIResource {
|
|
|
60
56
|
}
|
|
61
57
|
}
|
|
62
58
|
|
|
63
|
-
export
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
* the notification.
|
|
67
|
-
*/
|
|
68
|
-
brand?: string | null;
|
|
59
|
+
export type InboundBulkMessage =
|
|
60
|
+
| InboundBulkMessage.InboundBulkTemplateMessage
|
|
61
|
+
| InboundBulkMessage.InboundBulkContentMessage;
|
|
69
62
|
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
*/
|
|
74
|
-
data?: { [key: string]: unknown } | null;
|
|
63
|
+
export namespace InboundBulkMessage {
|
|
64
|
+
export interface InboundBulkTemplateMessage {
|
|
65
|
+
template: string;
|
|
75
66
|
|
|
76
|
-
|
|
67
|
+
brand?: string | null;
|
|
77
68
|
|
|
78
|
-
|
|
69
|
+
data?: { [key: string]: unknown } | null;
|
|
79
70
|
|
|
80
|
-
|
|
81
|
-
* Describes the content of the message in a way that will work for email, push,
|
|
82
|
-
* chat, or any channel.
|
|
83
|
-
*/
|
|
84
|
-
message?:
|
|
85
|
-
| InboundBulkMessage.InboundBulkTemplateMessage
|
|
86
|
-
| InboundBulkMessage.InboundBulkContentMessage
|
|
87
|
-
| null;
|
|
71
|
+
event?: string | null;
|
|
88
72
|
|
|
89
|
-
|
|
90
|
-
* JSON that is merged into the request sent by Courier to the provider to override
|
|
91
|
-
* properties or to gain access to features in the provider API that are not
|
|
92
|
-
* natively supported by Courier.
|
|
93
|
-
*/
|
|
94
|
-
override?: unknown;
|
|
95
|
-
}
|
|
73
|
+
locale?: { [key: string]: { [key: string]: unknown } } | null;
|
|
96
74
|
|
|
97
|
-
|
|
98
|
-
/**
|
|
99
|
-
* Describes the content of the message in a way that will work for email, push,
|
|
100
|
-
* chat, or any channel.
|
|
101
|
-
*/
|
|
102
|
-
export interface InboundBulkTemplateMessage extends SendAPI.BaseMessage {
|
|
103
|
-
/**
|
|
104
|
-
* The id of the notification template to be rendered and sent to the recipient(s).
|
|
105
|
-
* This field or the content field must be supplied.
|
|
106
|
-
*/
|
|
107
|
-
template: string;
|
|
75
|
+
override?: { [key: string]: unknown } | null;
|
|
108
76
|
}
|
|
109
77
|
|
|
110
|
-
|
|
111
|
-
* A template for a type of message that can be sent more than once. For example,
|
|
112
|
-
* you might create an "Appointment Reminder" Notification or “Reset Password”
|
|
113
|
-
* Notifications.
|
|
114
|
-
*/
|
|
115
|
-
export interface InboundBulkContentMessage extends SendAPI.BaseMessage {
|
|
78
|
+
export interface InboundBulkContentMessage {
|
|
116
79
|
/**
|
|
117
|
-
*
|
|
118
|
-
* chat, or any channel. Either this or template must be specified.
|
|
80
|
+
* Syntactic sugar to provide a fast shorthand for Courier Elemental Blocks.
|
|
119
81
|
*/
|
|
120
|
-
content:
|
|
121
|
-
}
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
export interface InboundBulkMessageUser {
|
|
125
|
-
data?: unknown;
|
|
126
|
-
|
|
127
|
-
preferences?: SubscriptionsAPI.RecipientPreferences | null;
|
|
128
|
-
|
|
129
|
-
profile?: unknown;
|
|
130
|
-
|
|
131
|
-
recipient?: string | null;
|
|
132
|
-
|
|
133
|
-
to?: UserRecipient | null;
|
|
134
|
-
}
|
|
82
|
+
content: Shared.ElementalContentSugar | Shared.ElementalContent;
|
|
135
83
|
|
|
136
|
-
|
|
137
|
-
/**
|
|
138
|
-
* Use `tenant_id` instad.
|
|
139
|
-
*/
|
|
140
|
-
account_id?: string | null;
|
|
141
|
-
|
|
142
|
-
/**
|
|
143
|
-
* Context information such as tenant_id to send the notification with.
|
|
144
|
-
*/
|
|
145
|
-
context?: SendAPI.MessageContext | null;
|
|
146
|
-
|
|
147
|
-
data?: { [key: string]: unknown } | null;
|
|
148
|
-
|
|
149
|
-
email?: string | null;
|
|
150
|
-
|
|
151
|
-
/**
|
|
152
|
-
* The user's preferred ISO 639-1 language code.
|
|
153
|
-
*/
|
|
154
|
-
locale?: string | null;
|
|
155
|
-
|
|
156
|
-
phone_number?: string | null;
|
|
157
|
-
|
|
158
|
-
preferences?: UserRecipient.Preferences | null;
|
|
84
|
+
brand?: string | null;
|
|
159
85
|
|
|
160
|
-
|
|
161
|
-
* An id of a tenant,
|
|
162
|
-
* [see tenants api docs](https://www.courier.com/docs/reference/tenants). Will
|
|
163
|
-
* load brand, default preferences and any other base context data associated with
|
|
164
|
-
* this tenant.
|
|
165
|
-
*/
|
|
166
|
-
tenant_id?: string | null;
|
|
167
|
-
|
|
168
|
-
user_id?: string | null;
|
|
169
|
-
}
|
|
86
|
+
data?: { [key: string]: unknown } | null;
|
|
170
87
|
|
|
171
|
-
|
|
172
|
-
export interface Preferences {
|
|
173
|
-
notifications: { [key: string]: Preferences.Notifications };
|
|
88
|
+
event?: string | null;
|
|
174
89
|
|
|
175
|
-
|
|
90
|
+
locale?: { [key: string]: { [key: string]: unknown } } | null;
|
|
176
91
|
|
|
177
|
-
|
|
92
|
+
override?: { [key: string]: unknown } | null;
|
|
178
93
|
}
|
|
94
|
+
}
|
|
179
95
|
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
status: PreferencesAPI.PreferenceStatus;
|
|
183
|
-
|
|
184
|
-
channel_preferences?: Array<Notifications.ChannelPreference> | null;
|
|
185
|
-
|
|
186
|
-
rules?: Array<Notifications.Rule> | null;
|
|
187
|
-
|
|
188
|
-
source?: 'subscription' | 'list' | 'recipient' | null;
|
|
189
|
-
}
|
|
190
|
-
|
|
191
|
-
export namespace Notifications {
|
|
192
|
-
export interface ChannelPreference {
|
|
193
|
-
channel: ItemsAPI.ChannelClassification;
|
|
194
|
-
}
|
|
195
|
-
|
|
196
|
-
export interface Rule {
|
|
197
|
-
until: string;
|
|
198
|
-
|
|
199
|
-
start?: string | null;
|
|
200
|
-
}
|
|
201
|
-
}
|
|
202
|
-
|
|
203
|
-
export interface Categories {
|
|
204
|
-
status: PreferencesAPI.PreferenceStatus;
|
|
205
|
-
|
|
206
|
-
channel_preferences?: Array<Categories.ChannelPreference> | null;
|
|
207
|
-
|
|
208
|
-
rules?: Array<Categories.Rule> | null;
|
|
96
|
+
export interface InboundBulkMessageUser {
|
|
97
|
+
data?: unknown;
|
|
209
98
|
|
|
210
|
-
|
|
211
|
-
}
|
|
99
|
+
preferences?: Shared.RecipientPreferences | null;
|
|
212
100
|
|
|
213
|
-
|
|
214
|
-
export interface ChannelPreference {
|
|
215
|
-
channel: ItemsAPI.ChannelClassification;
|
|
216
|
-
}
|
|
101
|
+
profile?: unknown;
|
|
217
102
|
|
|
218
|
-
|
|
219
|
-
until: string;
|
|
103
|
+
recipient?: string | null;
|
|
220
104
|
|
|
221
|
-
|
|
222
|
-
}
|
|
223
|
-
}
|
|
224
|
-
}
|
|
105
|
+
to?: Shared.UserRecipient | null;
|
|
225
106
|
}
|
|
226
107
|
|
|
227
108
|
export interface BulkCreateJobResponse {
|
|
@@ -231,7 +112,7 @@ export interface BulkCreateJobResponse {
|
|
|
231
112
|
export interface BulkListUsersResponse {
|
|
232
113
|
items: Array<BulkListUsersResponse.Item>;
|
|
233
114
|
|
|
234
|
-
paging:
|
|
115
|
+
paging: Shared.Paging;
|
|
235
116
|
}
|
|
236
117
|
|
|
237
118
|
export namespace BulkListUsersResponse {
|
|
@@ -280,7 +161,6 @@ export declare namespace Bulk {
|
|
|
280
161
|
export {
|
|
281
162
|
type InboundBulkMessage as InboundBulkMessage,
|
|
282
163
|
type InboundBulkMessageUser as InboundBulkMessageUser,
|
|
283
|
-
type UserRecipient as UserRecipient,
|
|
284
164
|
type BulkCreateJobResponse as BulkCreateJobResponse,
|
|
285
165
|
type BulkListUsersResponse as BulkListUsersResponse,
|
|
286
166
|
type BulkRetrieveJobResponse as BulkRetrieveJobResponse,
|
package/src/resources/inbound.ts
CHANGED
package/src/resources/index.ts
CHANGED
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
+
export * from './shared';
|
|
3
4
|
export {
|
|
4
5
|
Audiences,
|
|
5
6
|
type Audience,
|
|
6
7
|
type Filter,
|
|
7
8
|
type FilterConfig,
|
|
8
|
-
type NestedFilterConfig,
|
|
9
|
-
type Paging,
|
|
10
9
|
type AudienceUpdateResponse,
|
|
11
10
|
type AudienceListResponse,
|
|
12
11
|
type AudienceListMembersResponse,
|
|
@@ -21,16 +20,23 @@ export {
|
|
|
21
20
|
type AuditEventListParams,
|
|
22
21
|
} from './audit-events';
|
|
23
22
|
export { Auth, type AuthIssueTokenResponse, type AuthIssueTokenParams } from './auth';
|
|
24
|
-
export {
|
|
25
|
-
Automations,
|
|
26
|
-
type AutomationInvokeAdHocParams,
|
|
27
|
-
type AutomationInvokeByTemplateParams,
|
|
28
|
-
} from './automations/automations';
|
|
23
|
+
export { Automations, type AutomationInvokeResponse } from './automations/automations';
|
|
29
24
|
export {
|
|
30
25
|
Brands,
|
|
31
26
|
type Brand,
|
|
27
|
+
type BrandColors,
|
|
32
28
|
type BrandSettings,
|
|
29
|
+
type BrandSettingsEmail,
|
|
30
|
+
type BrandSettingsInApp,
|
|
31
|
+
type BrandSnippet,
|
|
33
32
|
type BrandSnippets,
|
|
33
|
+
type BrandTemplate,
|
|
34
|
+
type EmailFooter,
|
|
35
|
+
type EmailHead,
|
|
36
|
+
type EmailHeader,
|
|
37
|
+
type Icons,
|
|
38
|
+
type Logo,
|
|
39
|
+
type WidgetBackground,
|
|
34
40
|
type BrandListResponse,
|
|
35
41
|
type BrandCreateParams,
|
|
36
42
|
type BrandUpdateParams,
|
|
@@ -40,7 +46,6 @@ export {
|
|
|
40
46
|
Bulk,
|
|
41
47
|
type InboundBulkMessage,
|
|
42
48
|
type InboundBulkMessageUser,
|
|
43
|
-
type UserRecipient,
|
|
44
49
|
type BulkCreateJobResponse,
|
|
45
50
|
type BulkListUsersResponse,
|
|
46
51
|
type BulkRetrieveJobResponse,
|
|
@@ -51,31 +56,34 @@ export {
|
|
|
51
56
|
export { Inbound, type InboundTrackEventResponse, type InboundTrackEventParams } from './inbound';
|
|
52
57
|
export {
|
|
53
58
|
Lists,
|
|
54
|
-
type
|
|
59
|
+
type PutSubscriptionsRecipient,
|
|
60
|
+
type SubscriptionList,
|
|
55
61
|
type ListListResponse,
|
|
56
62
|
type ListUpdateParams,
|
|
57
63
|
type ListListParams,
|
|
64
|
+
type ListRestoreParams,
|
|
58
65
|
} from './lists/lists';
|
|
59
66
|
export {
|
|
60
67
|
Messages,
|
|
61
68
|
type MessageDetails,
|
|
62
69
|
type MessageRetrieveResponse,
|
|
63
70
|
type MessageListResponse,
|
|
64
|
-
type
|
|
71
|
+
type MessageContentResponse,
|
|
65
72
|
type MessageHistoryResponse,
|
|
66
73
|
type MessageListParams,
|
|
67
74
|
type MessageHistoryParams,
|
|
68
75
|
} from './messages';
|
|
69
76
|
export {
|
|
70
77
|
Notifications,
|
|
71
|
-
type
|
|
72
|
-
type
|
|
78
|
+
type BaseCheck,
|
|
79
|
+
type Check,
|
|
73
80
|
type NotificationGetContent,
|
|
74
81
|
type NotificationListResponse,
|
|
75
82
|
type NotificationListParams,
|
|
76
83
|
} from './notifications/notifications';
|
|
77
84
|
export {
|
|
78
85
|
Profiles,
|
|
86
|
+
type SubscribeToListsRequestItem,
|
|
79
87
|
type ProfileCreateResponse,
|
|
80
88
|
type ProfileRetrieveResponse,
|
|
81
89
|
type ProfileReplaceResponse,
|
|
@@ -84,28 +92,14 @@ export {
|
|
|
84
92
|
type ProfileReplaceParams,
|
|
85
93
|
} from './profiles/profiles';
|
|
86
94
|
export { Requests } from './requests';
|
|
87
|
-
export {
|
|
88
|
-
Send,
|
|
89
|
-
type BaseMessage,
|
|
90
|
-
type BaseMessageSendTo,
|
|
91
|
-
type Content,
|
|
92
|
-
type ElementalChannelNode,
|
|
93
|
-
type ElementalGroupNode,
|
|
94
|
-
type ElementalNode,
|
|
95
|
-
type Message,
|
|
96
|
-
type MessageContext,
|
|
97
|
-
type MsTeamsBaseProperties,
|
|
98
|
-
type Recipient,
|
|
99
|
-
type RoutingMethod,
|
|
100
|
-
type SlackBaseProperties,
|
|
101
|
-
type Utm,
|
|
102
|
-
type SendSendMessageResponse,
|
|
103
|
-
type SendSendMessageParams,
|
|
104
|
-
} from './send';
|
|
95
|
+
export { Send, type SendMessageResponse, type SendMessageParams } from './send';
|
|
105
96
|
export {
|
|
106
97
|
Tenants,
|
|
98
|
+
type BaseTemplateTenantAssociation,
|
|
107
99
|
type DefaultPreferences,
|
|
100
|
+
type SubscriptionTopicNew,
|
|
108
101
|
type Tenant,
|
|
102
|
+
type TenantAssociation,
|
|
109
103
|
type TenantListResponse,
|
|
110
104
|
type TenantListUsersResponse,
|
|
111
105
|
type TenantUpdateParams,
|
|
@@ -1,10 +1,16 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
export { Lists, type List, type ListListResponse, type ListUpdateParams, type ListListParams } from './lists';
|
|
4
3
|
export {
|
|
5
|
-
|
|
4
|
+
Lists,
|
|
6
5
|
type PutSubscriptionsRecipient,
|
|
7
|
-
type
|
|
6
|
+
type SubscriptionList,
|
|
7
|
+
type ListListResponse,
|
|
8
|
+
type ListUpdateParams,
|
|
9
|
+
type ListListParams,
|
|
10
|
+
type ListRestoreParams,
|
|
11
|
+
} from './lists';
|
|
12
|
+
export {
|
|
13
|
+
Subscriptions,
|
|
8
14
|
type SubscriptionListResponse,
|
|
9
15
|
type SubscriptionListParams,
|
|
10
16
|
type SubscriptionAddParams,
|