@trycourier/courier 6.0.3 → 6.0.5
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.js +1 -1
- package/api/resources/audiences/client/Client.d.ts +1 -1
- package/api/resources/audiences/client/Client.js +6 -6
- 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.js +5 -5
- package/api/resources/brands/types/BrandSettings.d.ts +1 -0
- package/api/resources/bulk/client/Client.js +6 -6
- package/api/resources/commons/types/ChannelClassification.d.ts +3 -1
- package/api/resources/commons/types/ChannelClassification.js +2 -0
- package/api/resources/lists/client/Client.js +10 -10
- package/api/resources/messages/client/Client.js +7 -7
- package/api/resources/notifications/client/Client.js +8 -8
- package/api/resources/profiles/client/Client.d.ts +1 -1
- package/api/resources/profiles/client/Client.js +8 -8
- package/api/resources/profiles/types/GetListSubscriptionsList.d.ts +14 -0
- package/api/resources/profiles/types/GetListSubscriptionsList.js +5 -0
- package/api/resources/profiles/types/GetListSubscriptionsResponse.d.ts +9 -0
- package/api/resources/profiles/types/GetListSubscriptionsResponse.js +5 -0
- package/api/resources/profiles/types/SubscribeToListsRequest.d.ts +1 -2
- package/api/resources/profiles/types/SubscribeToListsRequestListObject.d.ts +8 -0
- package/api/resources/profiles/types/SubscribeToListsRequestListObject.js +5 -0
- package/api/resources/profiles/types/index.d.ts +3 -0
- package/api/resources/profiles/types/index.js +3 -0
- package/api/resources/templates/client/Client.js +1 -1
- package/api/resources/tenants/client/Client.js +4 -4
- package/api/resources/translations/client/Client.js +2 -2
- package/api/resources/users/resources/preferences/client/Client.d.ts +1 -1
- package/api/resources/users/resources/preferences/client/Client.js +4 -4
- package/api/resources/users/resources/preferences/client/requests/UserPreferencesUpdateParams.d.ts +1 -1
- package/api/resources/users/resources/preferences/types/TopicPreference.d.ts +1 -1
- package/api/resources/users/resources/tenants/client/Client.js +4 -4
- package/api/resources/users/resources/tokens/client/Client.js +5 -5
- package/core/fetcher/Fetcher.js +16 -13
- package/dist/Client.js +1 -1
- package/dist/api/resources/audiences/client/Client.d.ts +1 -1
- package/dist/api/resources/audiences/client/Client.js +6 -6
- 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.js +5 -5
- package/dist/api/resources/brands/types/BrandSettings.d.ts +1 -0
- package/dist/api/resources/bulk/client/Client.js +6 -6
- package/dist/api/resources/commons/types/ChannelClassification.d.ts +3 -1
- package/dist/api/resources/commons/types/ChannelClassification.js +2 -0
- package/dist/api/resources/lists/client/Client.js +10 -10
- package/dist/api/resources/messages/client/Client.js +7 -7
- package/dist/api/resources/notifications/client/Client.js +8 -8
- package/dist/api/resources/profiles/client/Client.d.ts +1 -1
- package/dist/api/resources/profiles/client/Client.js +8 -8
- package/dist/api/resources/profiles/types/GetListSubscriptionsList.d.ts +14 -0
- package/dist/api/resources/profiles/types/GetListSubscriptionsList.js +5 -0
- package/dist/api/resources/profiles/types/GetListSubscriptionsResponse.d.ts +9 -0
- package/dist/api/resources/profiles/types/GetListSubscriptionsResponse.js +5 -0
- package/dist/api/resources/profiles/types/SubscribeToListsRequest.d.ts +1 -2
- package/dist/api/resources/profiles/types/SubscribeToListsRequestListObject.d.ts +8 -0
- package/dist/api/resources/profiles/types/SubscribeToListsRequestListObject.js +5 -0
- package/dist/api/resources/profiles/types/index.d.ts +3 -0
- package/dist/api/resources/profiles/types/index.js +3 -0
- package/dist/api/resources/templates/client/Client.js +1 -1
- package/dist/api/resources/tenants/client/Client.js +4 -4
- package/dist/api/resources/translations/client/Client.js +2 -2
- package/dist/api/resources/users/resources/preferences/client/Client.d.ts +1 -1
- package/dist/api/resources/users/resources/preferences/client/Client.js +4 -4
- package/dist/api/resources/users/resources/preferences/client/requests/UserPreferencesUpdateParams.d.ts +1 -1
- package/dist/api/resources/users/resources/preferences/types/TopicPreference.d.ts +1 -1
- package/dist/api/resources/users/resources/tenants/client/Client.js +4 -4
- package/dist/api/resources/users/resources/tokens/client/Client.js +5 -5
- package/dist/core/fetcher/Fetcher.js +16 -13
- package/package.json +1 -1
|
@@ -21,5 +21,8 @@ export * from "./ProfileGetResponse";
|
|
|
21
21
|
export * from "./MergeProfileResponse";
|
|
22
22
|
export * from "./ReplaceProfileResponse";
|
|
23
23
|
export * from "./SubscribeToListsRequest";
|
|
24
|
+
export * from "./SubscribeToListsRequestListObject";
|
|
24
25
|
export * from "./SubscribeToListsResponse";
|
|
25
26
|
export * from "./DeleteListSubscriptionResponse";
|
|
27
|
+
export * from "./GetListSubscriptionsList";
|
|
28
|
+
export * from "./GetListSubscriptionsResponse";
|
|
@@ -37,5 +37,8 @@ __exportStar(require("./ProfileGetResponse"), exports);
|
|
|
37
37
|
__exportStar(require("./MergeProfileResponse"), exports);
|
|
38
38
|
__exportStar(require("./ReplaceProfileResponse"), exports);
|
|
39
39
|
__exportStar(require("./SubscribeToListsRequest"), exports);
|
|
40
|
+
__exportStar(require("./SubscribeToListsRequestListObject"), exports);
|
|
40
41
|
__exportStar(require("./SubscribeToListsResponse"), exports);
|
|
41
42
|
__exportStar(require("./DeleteListSubscriptionResponse"), exports);
|
|
43
|
+
__exportStar(require("./GetListSubscriptionsList"), exports);
|
|
44
|
+
__exportStar(require("./GetListSubscriptionsResponse"), exports);
|
|
@@ -65,7 +65,7 @@ class Templates {
|
|
|
65
65
|
Authorization: yield this._getAuthorizationHeader(),
|
|
66
66
|
"X-Fern-Language": "JavaScript",
|
|
67
67
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
68
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
68
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
69
69
|
},
|
|
70
70
|
contentType: "application/json",
|
|
71
71
|
queryParameters: _queryParams,
|
|
@@ -61,7 +61,7 @@ class Tenants {
|
|
|
61
61
|
Authorization: yield this._getAuthorizationHeader(),
|
|
62
62
|
"X-Fern-Language": "JavaScript",
|
|
63
63
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
64
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
64
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
65
65
|
},
|
|
66
66
|
contentType: "application/json",
|
|
67
67
|
body: request,
|
|
@@ -110,7 +110,7 @@ class Tenants {
|
|
|
110
110
|
Authorization: yield this._getAuthorizationHeader(),
|
|
111
111
|
"X-Fern-Language": "JavaScript",
|
|
112
112
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
113
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
113
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
114
114
|
},
|
|
115
115
|
contentType: "application/json",
|
|
116
116
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -155,7 +155,7 @@ class Tenants {
|
|
|
155
155
|
Authorization: yield this._getAuthorizationHeader(),
|
|
156
156
|
"X-Fern-Language": "JavaScript",
|
|
157
157
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
158
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
158
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
159
159
|
},
|
|
160
160
|
contentType: "application/json",
|
|
161
161
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -195,7 +195,7 @@ class Tenants {
|
|
|
195
195
|
Authorization: yield this._getAuthorizationHeader(),
|
|
196
196
|
"X-Fern-Language": "JavaScript",
|
|
197
197
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
198
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
198
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
199
199
|
},
|
|
200
200
|
contentType: "application/json",
|
|
201
201
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -62,7 +62,7 @@ class Translations {
|
|
|
62
62
|
Authorization: yield this._getAuthorizationHeader(),
|
|
63
63
|
"X-Fern-Language": "JavaScript",
|
|
64
64
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
65
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
65
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
66
66
|
},
|
|
67
67
|
contentType: "application/json",
|
|
68
68
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -111,7 +111,7 @@ class Translations {
|
|
|
111
111
|
Authorization: yield this._getAuthorizationHeader(),
|
|
112
112
|
"X-Fern-Language": "JavaScript",
|
|
113
113
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
114
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
114
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
115
115
|
},
|
|
116
116
|
contentType: "application/json",
|
|
117
117
|
body: request,
|
|
@@ -28,7 +28,7 @@ export declare class Preferences {
|
|
|
28
28
|
*/
|
|
29
29
|
get(userId: string, topicId: string, requestOptions?: Preferences.RequestOptions): Promise<Courier.users.UserPreferencesGetResponse>;
|
|
30
30
|
/**
|
|
31
|
-
*
|
|
31
|
+
* Update or Create user preferences for a specific subscription topic.
|
|
32
32
|
* @throws {@link Courier.BadRequestError}
|
|
33
33
|
*/
|
|
34
34
|
update(userId: string, topicId: string, request: Courier.users.UserPreferencesUpdateParams, requestOptions?: Preferences.RequestOptions): Promise<Courier.users.UserPreferencesUpdateResponse>;
|
|
@@ -62,7 +62,7 @@ class Preferences {
|
|
|
62
62
|
Authorization: yield this._getAuthorizationHeader(),
|
|
63
63
|
"X-Fern-Language": "JavaScript",
|
|
64
64
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
65
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
65
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
66
66
|
},
|
|
67
67
|
contentType: "application/json",
|
|
68
68
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -111,7 +111,7 @@ class Preferences {
|
|
|
111
111
|
Authorization: yield this._getAuthorizationHeader(),
|
|
112
112
|
"X-Fern-Language": "JavaScript",
|
|
113
113
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
114
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
114
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
115
115
|
},
|
|
116
116
|
contentType: "application/json",
|
|
117
117
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -147,7 +147,7 @@ class Preferences {
|
|
|
147
147
|
});
|
|
148
148
|
}
|
|
149
149
|
/**
|
|
150
|
-
*
|
|
150
|
+
* Update or Create user preferences for a specific subscription topic.
|
|
151
151
|
* @throws {@link Courier.BadRequestError}
|
|
152
152
|
*/
|
|
153
153
|
update(userId, topicId, request, requestOptions) {
|
|
@@ -160,7 +160,7 @@ class Preferences {
|
|
|
160
160
|
Authorization: yield this._getAuthorizationHeader(),
|
|
161
161
|
"X-Fern-Language": "JavaScript",
|
|
162
162
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
163
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
163
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
164
164
|
},
|
|
165
165
|
contentType: "application/json",
|
|
166
166
|
body: request,
|
package/api/resources/users/resources/preferences/client/requests/UserPreferencesUpdateParams.d.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
import * as Courier from "../../../../../..";
|
|
5
5
|
export interface UserPreferencesUpdateParams {
|
|
6
6
|
status: Courier.PreferenceStatus;
|
|
7
|
-
/**
|
|
7
|
+
/** The Channels a user has chosen to receive notifications through for this topic */
|
|
8
8
|
custom_routing?: Courier.ChannelClassification[];
|
|
9
9
|
default_status: Courier.PreferenceStatus;
|
|
10
10
|
has_custom_routing?: boolean;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
*/
|
|
4
4
|
import * as Courier from "../../../../..";
|
|
5
5
|
export interface TopicPreference {
|
|
6
|
-
/**
|
|
6
|
+
/** The Channels a user has chosen to receive notifications through for this topic */
|
|
7
7
|
custom_routing?: Courier.ChannelClassification[];
|
|
8
8
|
default_status: Courier.PreferenceStatus;
|
|
9
9
|
has_custom_routing?: boolean;
|
|
@@ -64,7 +64,7 @@ class Tenants {
|
|
|
64
64
|
Authorization: yield this._getAuthorizationHeader(),
|
|
65
65
|
"X-Fern-Language": "JavaScript",
|
|
66
66
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
67
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
67
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
68
68
|
},
|
|
69
69
|
contentType: "application/json",
|
|
70
70
|
body: request,
|
|
@@ -112,7 +112,7 @@ class Tenants {
|
|
|
112
112
|
Authorization: yield this._getAuthorizationHeader(),
|
|
113
113
|
"X-Fern-Language": "JavaScript",
|
|
114
114
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
115
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
115
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
116
116
|
},
|
|
117
117
|
contentType: "application/json",
|
|
118
118
|
body: request,
|
|
@@ -156,7 +156,7 @@ class Tenants {
|
|
|
156
156
|
Authorization: yield this._getAuthorizationHeader(),
|
|
157
157
|
"X-Fern-Language": "JavaScript",
|
|
158
158
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
159
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
159
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
160
160
|
},
|
|
161
161
|
contentType: "application/json",
|
|
162
162
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -207,7 +207,7 @@ class Tenants {
|
|
|
207
207
|
Authorization: yield this._getAuthorizationHeader(),
|
|
208
208
|
"X-Fern-Language": "JavaScript",
|
|
209
209
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
210
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
210
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
211
211
|
},
|
|
212
212
|
contentType: "application/json",
|
|
213
213
|
queryParameters: _queryParams,
|
|
@@ -62,7 +62,7 @@ class Tokens {
|
|
|
62
62
|
Authorization: yield this._getAuthorizationHeader(),
|
|
63
63
|
"X-Fern-Language": "JavaScript",
|
|
64
64
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
65
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
65
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
66
66
|
},
|
|
67
67
|
contentType: "application/json",
|
|
68
68
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -111,7 +111,7 @@ class Tokens {
|
|
|
111
111
|
Authorization: yield this._getAuthorizationHeader(),
|
|
112
112
|
"X-Fern-Language": "JavaScript",
|
|
113
113
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
114
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
114
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
115
115
|
},
|
|
116
116
|
contentType: "application/json",
|
|
117
117
|
body: request,
|
|
@@ -161,7 +161,7 @@ class Tokens {
|
|
|
161
161
|
Authorization: yield this._getAuthorizationHeader(),
|
|
162
162
|
"X-Fern-Language": "JavaScript",
|
|
163
163
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
164
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
164
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
165
165
|
},
|
|
166
166
|
contentType: "application/json",
|
|
167
167
|
body: request,
|
|
@@ -211,7 +211,7 @@ class Tokens {
|
|
|
211
211
|
Authorization: yield this._getAuthorizationHeader(),
|
|
212
212
|
"X-Fern-Language": "JavaScript",
|
|
213
213
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
214
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
214
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
215
215
|
},
|
|
216
216
|
contentType: "application/json",
|
|
217
217
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -260,7 +260,7 @@ class Tokens {
|
|
|
260
260
|
Authorization: yield this._getAuthorizationHeader(),
|
|
261
261
|
"X-Fern-Language": "JavaScript",
|
|
262
262
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
263
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
263
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
264
264
|
},
|
|
265
265
|
contentType: "application/json",
|
|
266
266
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
package/core/fetcher/Fetcher.js
CHANGED
|
@@ -86,19 +86,22 @@ function fetcherImpl(args) {
|
|
|
86
86
|
else if (response.body != null && args.responseType === "streaming") {
|
|
87
87
|
body = response.body;
|
|
88
88
|
}
|
|
89
|
-
else
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
89
|
+
else {
|
|
90
|
+
const text = yield response.text();
|
|
91
|
+
if (text.length > 0) {
|
|
92
|
+
try {
|
|
93
|
+
body = JSON.parse(text);
|
|
94
|
+
}
|
|
95
|
+
catch (err) {
|
|
96
|
+
return {
|
|
97
|
+
ok: false,
|
|
98
|
+
error: {
|
|
99
|
+
reason: "non-json",
|
|
100
|
+
statusCode: response.status,
|
|
101
|
+
rawBody: text,
|
|
102
|
+
},
|
|
103
|
+
};
|
|
104
|
+
}
|
|
102
105
|
}
|
|
103
106
|
}
|
|
104
107
|
if (response.status >= 200 && response.status < 400) {
|
package/dist/Client.js
CHANGED
|
@@ -74,7 +74,7 @@ class CourierClient {
|
|
|
74
74
|
Authorization: yield this._getAuthorizationHeader(),
|
|
75
75
|
"X-Fern-Language": "JavaScript",
|
|
76
76
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
77
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
77
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
78
78
|
"Idempotency-Key": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey) != null ? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey : undefined,
|
|
79
79
|
"X-Idempotency-Expiration": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry) != null
|
|
80
80
|
? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry.toString()
|
|
@@ -26,7 +26,7 @@ export declare class Audiences {
|
|
|
26
26
|
*/
|
|
27
27
|
update(audienceId: string, request?: Courier.AudienceUpdateParams, requestOptions?: Audiences.RequestOptions): Promise<Courier.AudienceUpdateResponse>;
|
|
28
28
|
/**
|
|
29
|
-
* Deletes the specified
|
|
29
|
+
* Deletes the specified audience.
|
|
30
30
|
*/
|
|
31
31
|
delete(audienceId: string, requestOptions?: Audiences.RequestOptions): Promise<void>;
|
|
32
32
|
/**
|
|
@@ -61,7 +61,7 @@ class Audiences {
|
|
|
61
61
|
Authorization: yield this._getAuthorizationHeader(),
|
|
62
62
|
"X-Fern-Language": "JavaScript",
|
|
63
63
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
64
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
64
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
65
65
|
},
|
|
66
66
|
contentType: "application/json",
|
|
67
67
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -104,7 +104,7 @@ class Audiences {
|
|
|
104
104
|
Authorization: yield this._getAuthorizationHeader(),
|
|
105
105
|
"X-Fern-Language": "JavaScript",
|
|
106
106
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
107
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
107
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
108
108
|
},
|
|
109
109
|
contentType: "application/json",
|
|
110
110
|
body: request,
|
|
@@ -136,7 +136,7 @@ class Audiences {
|
|
|
136
136
|
});
|
|
137
137
|
}
|
|
138
138
|
/**
|
|
139
|
-
* Deletes the specified
|
|
139
|
+
* Deletes the specified audience.
|
|
140
140
|
*/
|
|
141
141
|
delete(audienceId, requestOptions) {
|
|
142
142
|
var _a;
|
|
@@ -148,7 +148,7 @@ class Audiences {
|
|
|
148
148
|
Authorization: yield this._getAuthorizationHeader(),
|
|
149
149
|
"X-Fern-Language": "JavaScript",
|
|
150
150
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
151
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
151
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
152
152
|
},
|
|
153
153
|
contentType: "application/json",
|
|
154
154
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -197,7 +197,7 @@ class Audiences {
|
|
|
197
197
|
Authorization: yield this._getAuthorizationHeader(),
|
|
198
198
|
"X-Fern-Language": "JavaScript",
|
|
199
199
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
200
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
200
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
201
201
|
},
|
|
202
202
|
contentType: "application/json",
|
|
203
203
|
queryParameters: _queryParams,
|
|
@@ -252,7 +252,7 @@ class Audiences {
|
|
|
252
252
|
Authorization: yield this._getAuthorizationHeader(),
|
|
253
253
|
"X-Fern-Language": "JavaScript",
|
|
254
254
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
255
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
255
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
256
256
|
},
|
|
257
257
|
contentType: "application/json",
|
|
258
258
|
queryParameters: _queryParams,
|
|
@@ -65,7 +65,7 @@ class AuditEvents {
|
|
|
65
65
|
Authorization: yield this._getAuthorizationHeader(),
|
|
66
66
|
"X-Fern-Language": "JavaScript",
|
|
67
67
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
68
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
68
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
69
69
|
},
|
|
70
70
|
contentType: "application/json",
|
|
71
71
|
queryParameters: _queryParams,
|
|
@@ -109,7 +109,7 @@ class AuditEvents {
|
|
|
109
109
|
Authorization: yield this._getAuthorizationHeader(),
|
|
110
110
|
"X-Fern-Language": "JavaScript",
|
|
111
111
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
112
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
112
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
113
113
|
},
|
|
114
114
|
contentType: "application/json",
|
|
115
115
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -60,7 +60,7 @@ class AuthTokens {
|
|
|
60
60
|
Authorization: yield this._getAuthorizationHeader(),
|
|
61
61
|
"X-Fern-Language": "JavaScript",
|
|
62
62
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
63
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
63
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
64
64
|
"Idempotency-Key": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey) != null ? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey : undefined,
|
|
65
65
|
"X-Idempotency-Expiration": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry) != null
|
|
66
66
|
? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry.toString()
|
|
@@ -60,7 +60,7 @@ class Automations {
|
|
|
60
60
|
Authorization: yield this._getAuthorizationHeader(),
|
|
61
61
|
"X-Fern-Language": "JavaScript",
|
|
62
62
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
63
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
63
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
64
64
|
"Idempotency-Key": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey) != null ? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey : undefined,
|
|
65
65
|
"X-Idempotency-Expiration": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry) != null
|
|
66
66
|
? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry.toString()
|
|
@@ -108,7 +108,7 @@ class Automations {
|
|
|
108
108
|
Authorization: yield this._getAuthorizationHeader(),
|
|
109
109
|
"X-Fern-Language": "JavaScript",
|
|
110
110
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
111
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
111
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
112
112
|
"Idempotency-Key": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey) != null ? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey : undefined,
|
|
113
113
|
"X-Idempotency-Expiration": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry) != null
|
|
114
114
|
? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry.toString()
|
|
@@ -63,7 +63,7 @@ class Brands {
|
|
|
63
63
|
Authorization: yield this._getAuthorizationHeader(),
|
|
64
64
|
"X-Fern-Language": "JavaScript",
|
|
65
65
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
66
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
66
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
67
67
|
"Idempotency-Key": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey) != null ? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey : undefined,
|
|
68
68
|
"X-Idempotency-Expiration": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry) != null
|
|
69
69
|
? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry.toString()
|
|
@@ -120,7 +120,7 @@ class Brands {
|
|
|
120
120
|
Authorization: yield this._getAuthorizationHeader(),
|
|
121
121
|
"X-Fern-Language": "JavaScript",
|
|
122
122
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
123
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
123
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
124
124
|
},
|
|
125
125
|
contentType: "application/json",
|
|
126
126
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -168,7 +168,7 @@ class Brands {
|
|
|
168
168
|
Authorization: yield this._getAuthorizationHeader(),
|
|
169
169
|
"X-Fern-Language": "JavaScript",
|
|
170
170
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
171
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
171
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
172
172
|
},
|
|
173
173
|
contentType: "application/json",
|
|
174
174
|
queryParameters: _queryParams,
|
|
@@ -213,7 +213,7 @@ class Brands {
|
|
|
213
213
|
Authorization: yield this._getAuthorizationHeader(),
|
|
214
214
|
"X-Fern-Language": "JavaScript",
|
|
215
215
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
216
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
216
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
217
217
|
},
|
|
218
218
|
contentType: "application/json",
|
|
219
219
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -261,7 +261,7 @@ class Brands {
|
|
|
261
261
|
Authorization: yield this._getAuthorizationHeader(),
|
|
262
262
|
"X-Fern-Language": "JavaScript",
|
|
263
263
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
264
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
264
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
265
265
|
},
|
|
266
266
|
contentType: "application/json",
|
|
267
267
|
body: request,
|
|
@@ -61,7 +61,7 @@ class Bulk {
|
|
|
61
61
|
Authorization: yield this._getAuthorizationHeader(),
|
|
62
62
|
"X-Fern-Language": "JavaScript",
|
|
63
63
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
64
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
64
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
65
65
|
"Idempotency-Key": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey) != null ? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey : undefined,
|
|
66
66
|
"X-Idempotency-Expiration": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry) != null
|
|
67
67
|
? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry.toString()
|
|
@@ -114,7 +114,7 @@ class Bulk {
|
|
|
114
114
|
Authorization: yield this._getAuthorizationHeader(),
|
|
115
115
|
"X-Fern-Language": "JavaScript",
|
|
116
116
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
117
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
117
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
118
118
|
"Idempotency-Key": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey) != null ? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey : undefined,
|
|
119
119
|
"X-Idempotency-Expiration": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry) != null
|
|
120
120
|
? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry.toString()
|
|
@@ -163,7 +163,7 @@ class Bulk {
|
|
|
163
163
|
Authorization: yield this._getAuthorizationHeader(),
|
|
164
164
|
"X-Fern-Language": "JavaScript",
|
|
165
165
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
166
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
166
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
167
167
|
"Idempotency-Key": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey) != null ? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey : undefined,
|
|
168
168
|
"X-Idempotency-Expiration": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry) != null
|
|
169
169
|
? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry.toString()
|
|
@@ -210,13 +210,13 @@ class Bulk {
|
|
|
210
210
|
var _a;
|
|
211
211
|
return __awaiter(this, void 0, void 0, function* () {
|
|
212
212
|
const _response = yield core.fetcher({
|
|
213
|
-
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.CourierEnvironment.Production, `/bulk/${jobId}
|
|
213
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.CourierEnvironment.Production, `/bulk/${jobId}`),
|
|
214
214
|
method: "GET",
|
|
215
215
|
headers: {
|
|
216
216
|
Authorization: yield this._getAuthorizationHeader(),
|
|
217
217
|
"X-Fern-Language": "JavaScript",
|
|
218
218
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
219
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
219
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
220
220
|
},
|
|
221
221
|
contentType: "application/json",
|
|
222
222
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -265,7 +265,7 @@ class Bulk {
|
|
|
265
265
|
Authorization: yield this._getAuthorizationHeader(),
|
|
266
266
|
"X-Fern-Language": "JavaScript",
|
|
267
267
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
268
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
268
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
269
269
|
},
|
|
270
270
|
contentType: "application/json",
|
|
271
271
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* This file was auto-generated by Fern from our API Definition.
|
|
3
3
|
*/
|
|
4
|
-
export declare type ChannelClassification = "direct_message" | "email" | "push" | "sms";
|
|
4
|
+
export declare type ChannelClassification = "direct_message" | "email" | "push" | "sms" | "webhook" | "inbox";
|
|
5
5
|
export declare const ChannelClassification: {
|
|
6
6
|
readonly DirectMessage: "direct_message";
|
|
7
7
|
readonly Email: "email";
|
|
8
8
|
readonly Push: "push";
|
|
9
9
|
readonly Sms: "sms";
|
|
10
|
+
readonly Webhook: "webhook";
|
|
11
|
+
readonly Inbox: "inbox";
|
|
10
12
|
};
|
|
@@ -70,7 +70,7 @@ class Lists {
|
|
|
70
70
|
Authorization: yield this._getAuthorizationHeader(),
|
|
71
71
|
"X-Fern-Language": "JavaScript",
|
|
72
72
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
73
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
73
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
74
74
|
},
|
|
75
75
|
contentType: "application/json",
|
|
76
76
|
queryParameters: _queryParams,
|
|
@@ -128,7 +128,7 @@ class Lists {
|
|
|
128
128
|
Authorization: yield this._getAuthorizationHeader(),
|
|
129
129
|
"X-Fern-Language": "JavaScript",
|
|
130
130
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
131
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
131
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
132
132
|
},
|
|
133
133
|
contentType: "application/json",
|
|
134
134
|
queryParameters: _queryParams,
|
|
@@ -177,7 +177,7 @@ class Lists {
|
|
|
177
177
|
Authorization: yield this._getAuthorizationHeader(),
|
|
178
178
|
"X-Fern-Language": "JavaScript",
|
|
179
179
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
180
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
180
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
181
181
|
},
|
|
182
182
|
contentType: "application/json",
|
|
183
183
|
body: request,
|
|
@@ -221,7 +221,7 @@ class Lists {
|
|
|
221
221
|
Authorization: yield this._getAuthorizationHeader(),
|
|
222
222
|
"X-Fern-Language": "JavaScript",
|
|
223
223
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
224
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
224
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
225
225
|
},
|
|
226
226
|
contentType: "application/json",
|
|
227
227
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -264,7 +264,7 @@ class Lists {
|
|
|
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.0.
|
|
267
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
268
268
|
},
|
|
269
269
|
contentType: "application/json",
|
|
270
270
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -313,7 +313,7 @@ class Lists {
|
|
|
313
313
|
Authorization: yield this._getAuthorizationHeader(),
|
|
314
314
|
"X-Fern-Language": "JavaScript",
|
|
315
315
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
316
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
316
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
317
317
|
},
|
|
318
318
|
contentType: "application/json",
|
|
319
319
|
queryParameters: _queryParams,
|
|
@@ -363,7 +363,7 @@ class Lists {
|
|
|
363
363
|
Authorization: yield this._getAuthorizationHeader(),
|
|
364
364
|
"X-Fern-Language": "JavaScript",
|
|
365
365
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
366
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
366
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
367
367
|
},
|
|
368
368
|
contentType: "application/json",
|
|
369
369
|
body: request,
|
|
@@ -413,7 +413,7 @@ class Lists {
|
|
|
413
413
|
Authorization: yield this._getAuthorizationHeader(),
|
|
414
414
|
"X-Fern-Language": "JavaScript",
|
|
415
415
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
416
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
416
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
417
417
|
"Idempotency-Key": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey) != null ? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyKey : undefined,
|
|
418
418
|
"X-Idempotency-Expiration": (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry) != null
|
|
419
419
|
? requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.idempotencyExpiry.toString()
|
|
@@ -466,7 +466,7 @@ class Lists {
|
|
|
466
466
|
Authorization: yield this._getAuthorizationHeader(),
|
|
467
467
|
"X-Fern-Language": "JavaScript",
|
|
468
468
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
469
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
469
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
470
470
|
},
|
|
471
471
|
contentType: "application/json",
|
|
472
472
|
body: request,
|
|
@@ -511,7 +511,7 @@ class Lists {
|
|
|
511
511
|
Authorization: yield this._getAuthorizationHeader(),
|
|
512
512
|
"X-Fern-Language": "JavaScript",
|
|
513
513
|
"X-Fern-SDK-Name": "@trycourier/courier",
|
|
514
|
-
"X-Fern-SDK-Version": "v6.0.
|
|
514
|
+
"X-Fern-SDK-Version": "v6.0.5",
|
|
515
515
|
},
|
|
516
516
|
contentType: "application/json",
|
|
517
517
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|