@foru-ms/sdk 2.0.7 → 2.0.8
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/dist/cjs/BaseClient.d.ts +1 -0
- package/dist/cjs/BaseClient.js +2 -2
- package/dist/cjs/api/resources/auth/client/Client.js +30 -30
- package/dist/cjs/api/resources/integrations/client/Client.js +30 -30
- package/dist/cjs/api/resources/notifications/client/Client.js +30 -30
- package/dist/cjs/api/resources/posts/client/Client.js +78 -78
- package/dist/cjs/api/resources/privateMessages/client/Client.js +48 -48
- package/dist/cjs/api/resources/reports/client/Client.js +24 -24
- package/dist/cjs/api/resources/roles/client/Client.js +30 -30
- package/dist/cjs/api/resources/ssOs/client/Client.js +30 -30
- package/dist/cjs/api/resources/tags/client/Client.js +48 -48
- package/dist/cjs/api/resources/threads/client/Client.js +114 -114
- package/dist/cjs/api/resources/users/client/Client.js +60 -60
- package/dist/cjs/api/resources/webhooks/client/Client.js +42 -42
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.d.mts +1 -0
- package/dist/esm/BaseClient.mjs +2 -2
- package/dist/esm/api/resources/auth/client/Client.mjs +30 -30
- package/dist/esm/api/resources/integrations/client/Client.mjs +30 -30
- package/dist/esm/api/resources/notifications/client/Client.mjs +30 -30
- package/dist/esm/api/resources/posts/client/Client.mjs +78 -78
- package/dist/esm/api/resources/privateMessages/client/Client.mjs +48 -48
- package/dist/esm/api/resources/reports/client/Client.mjs +24 -24
- package/dist/esm/api/resources/roles/client/Client.mjs +30 -30
- package/dist/esm/api/resources/ssOs/client/Client.mjs +30 -30
- package/dist/esm/api/resources/tags/client/Client.mjs +48 -48
- package/dist/esm/api/resources/threads/client/Client.mjs +114 -114
- package/dist/esm/api/resources/users/client/Client.mjs +60 -60
- package/dist/esm/api/resources/webhooks/client/Client.mjs +42 -42
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
|
@@ -47,7 +47,7 @@ export class SsOsClient {
|
|
|
47
47
|
}
|
|
48
48
|
__listAllSsOs() {
|
|
49
49
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
50
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
50
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
51
51
|
const { page, limit, search } = request;
|
|
52
52
|
const _queryParams = {};
|
|
53
53
|
if (page != null) {
|
|
@@ -61,15 +61,15 @@ export class SsOsClient {
|
|
|
61
61
|
}
|
|
62
62
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
63
63
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
64
|
-
const _response = yield core.fetcher({
|
|
65
|
-
url: core.url.join((
|
|
64
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
65
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ForumEnvironment.Production, "sso"),
|
|
66
66
|
method: "GET",
|
|
67
67
|
headers: _headers,
|
|
68
68
|
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
69
|
-
timeoutMs: ((
|
|
70
|
-
maxRetries: (
|
|
69
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
70
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
71
71
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
72
|
-
fetchFn: (
|
|
72
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
73
73
|
logging: this._options.logging,
|
|
74
74
|
});
|
|
75
75
|
if (_response.ok) {
|
|
@@ -122,21 +122,21 @@ export class SsOsClient {
|
|
|
122
122
|
}
|
|
123
123
|
__createAnSso(request, requestOptions) {
|
|
124
124
|
return __awaiter(this, void 0, void 0, function* () {
|
|
125
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
125
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
126
126
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
127
127
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
128
|
-
const _response = yield core.fetcher({
|
|
129
|
-
url: core.url.join((
|
|
128
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
129
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ForumEnvironment.Production, "sso"),
|
|
130
130
|
method: "POST",
|
|
131
131
|
headers: _headers,
|
|
132
132
|
contentType: "application/json",
|
|
133
133
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
134
134
|
requestType: "json",
|
|
135
135
|
body: request,
|
|
136
|
-
timeoutMs: ((
|
|
137
|
-
maxRetries: (
|
|
136
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
137
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
138
138
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
139
|
-
fetchFn: (
|
|
139
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
140
140
|
logging: this._options.logging,
|
|
141
141
|
});
|
|
142
142
|
if (_response.ok) {
|
|
@@ -185,19 +185,19 @@ export class SsOsClient {
|
|
|
185
185
|
}
|
|
186
186
|
__getAnSso(request, requestOptions) {
|
|
187
187
|
return __awaiter(this, void 0, void 0, function* () {
|
|
188
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
188
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
189
189
|
const { id } = request;
|
|
190
190
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
191
191
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
192
|
-
const _response = yield core.fetcher({
|
|
193
|
-
url: core.url.join((
|
|
192
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
193
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ForumEnvironment.Production, `sso/${core.url.encodePathParam(id)}`),
|
|
194
194
|
method: "GET",
|
|
195
195
|
headers: _headers,
|
|
196
196
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
197
|
-
timeoutMs: ((
|
|
198
|
-
maxRetries: (
|
|
197
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
198
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
199
199
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
200
|
-
fetchFn: (
|
|
200
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
201
201
|
logging: this._options.logging,
|
|
202
202
|
});
|
|
203
203
|
if (_response.ok) {
|
|
@@ -246,19 +246,19 @@ export class SsOsClient {
|
|
|
246
246
|
}
|
|
247
247
|
__deleteAnSso(request, requestOptions) {
|
|
248
248
|
return __awaiter(this, void 0, void 0, function* () {
|
|
249
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
249
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
250
250
|
const { id } = request;
|
|
251
251
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
252
252
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
253
|
-
const _response = yield core.fetcher({
|
|
254
|
-
url: core.url.join((
|
|
253
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
254
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ForumEnvironment.Production, `sso/${core.url.encodePathParam(id)}`),
|
|
255
255
|
method: "DELETE",
|
|
256
256
|
headers: _headers,
|
|
257
257
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
258
|
-
timeoutMs: ((
|
|
259
|
-
maxRetries: (
|
|
258
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
259
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
260
260
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
261
|
-
fetchFn: (
|
|
261
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
262
262
|
logging: this._options.logging,
|
|
263
263
|
});
|
|
264
264
|
if (_response.ok) {
|
|
@@ -308,22 +308,22 @@ export class SsOsClient {
|
|
|
308
308
|
}
|
|
309
309
|
__updateAnSso(request, requestOptions) {
|
|
310
310
|
return __awaiter(this, void 0, void 0, function* () {
|
|
311
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
311
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
312
312
|
const { id } = request, _body = __rest(request, ["id"]);
|
|
313
313
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
314
314
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
315
|
-
const _response = yield core.fetcher({
|
|
316
|
-
url: core.url.join((
|
|
315
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
316
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ForumEnvironment.Production, `sso/${core.url.encodePathParam(id)}`),
|
|
317
317
|
method: "PATCH",
|
|
318
318
|
headers: _headers,
|
|
319
319
|
contentType: "application/json",
|
|
320
320
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
321
321
|
requestType: "json",
|
|
322
322
|
body: _body,
|
|
323
|
-
timeoutMs: ((
|
|
324
|
-
maxRetries: (
|
|
323
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
324
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
325
325
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
326
|
-
fetchFn: (
|
|
326
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
327
327
|
logging: this._options.logging,
|
|
328
328
|
});
|
|
329
329
|
if (_response.ok) {
|
|
@@ -47,7 +47,7 @@ export class TagsClient {
|
|
|
47
47
|
}
|
|
48
48
|
__listAllTags() {
|
|
49
49
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
50
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
50
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
51
51
|
const { page, limit, search } = request;
|
|
52
52
|
const _queryParams = {};
|
|
53
53
|
if (page != null) {
|
|
@@ -61,15 +61,15 @@ export class TagsClient {
|
|
|
61
61
|
}
|
|
62
62
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
63
63
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
64
|
-
const _response = yield core.fetcher({
|
|
65
|
-
url: core.url.join((
|
|
64
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
65
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ForumEnvironment.Production, "tags"),
|
|
66
66
|
method: "GET",
|
|
67
67
|
headers: _headers,
|
|
68
68
|
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
69
|
-
timeoutMs: ((
|
|
70
|
-
maxRetries: (
|
|
69
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
70
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
71
71
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
72
|
-
fetchFn: (
|
|
72
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
73
73
|
logging: this._options.logging,
|
|
74
74
|
});
|
|
75
75
|
if (_response.ok) {
|
|
@@ -116,21 +116,21 @@ export class TagsClient {
|
|
|
116
116
|
}
|
|
117
117
|
__createATag(request, requestOptions) {
|
|
118
118
|
return __awaiter(this, void 0, void 0, function* () {
|
|
119
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
119
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
120
120
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
121
121
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
122
|
-
const _response = yield core.fetcher({
|
|
123
|
-
url: core.url.join((
|
|
122
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
123
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ForumEnvironment.Production, "tags"),
|
|
124
124
|
method: "POST",
|
|
125
125
|
headers: _headers,
|
|
126
126
|
contentType: "application/json",
|
|
127
127
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
128
128
|
requestType: "json",
|
|
129
129
|
body: request,
|
|
130
|
-
timeoutMs: ((
|
|
131
|
-
maxRetries: (
|
|
130
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
131
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
132
132
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
133
|
-
fetchFn: (
|
|
133
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
134
134
|
logging: this._options.logging,
|
|
135
135
|
});
|
|
136
136
|
if (_response.ok) {
|
|
@@ -179,19 +179,19 @@ export class TagsClient {
|
|
|
179
179
|
}
|
|
180
180
|
__getATag(request, requestOptions) {
|
|
181
181
|
return __awaiter(this, void 0, void 0, function* () {
|
|
182
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
182
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
183
183
|
const { id } = request;
|
|
184
184
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
185
185
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
186
|
-
const _response = yield core.fetcher({
|
|
187
|
-
url: core.url.join((
|
|
186
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
187
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ForumEnvironment.Production, `tags/${core.url.encodePathParam(id)}`),
|
|
188
188
|
method: "GET",
|
|
189
189
|
headers: _headers,
|
|
190
190
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
191
|
-
timeoutMs: ((
|
|
192
|
-
maxRetries: (
|
|
191
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
192
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
193
193
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
194
|
-
fetchFn: (
|
|
194
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
195
195
|
logging: this._options.logging,
|
|
196
196
|
});
|
|
197
197
|
if (_response.ok) {
|
|
@@ -240,19 +240,19 @@ export class TagsClient {
|
|
|
240
240
|
}
|
|
241
241
|
__deleteATag(request, requestOptions) {
|
|
242
242
|
return __awaiter(this, void 0, void 0, function* () {
|
|
243
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
243
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
244
244
|
const { id } = request;
|
|
245
245
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
246
246
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
247
|
-
const _response = yield core.fetcher({
|
|
248
|
-
url: core.url.join((
|
|
247
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
248
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ForumEnvironment.Production, `tags/${core.url.encodePathParam(id)}`),
|
|
249
249
|
method: "DELETE",
|
|
250
250
|
headers: _headers,
|
|
251
251
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
252
|
-
timeoutMs: ((
|
|
253
|
-
maxRetries: (
|
|
252
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
253
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
254
254
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
255
|
-
fetchFn: (
|
|
255
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
256
256
|
logging: this._options.logging,
|
|
257
257
|
});
|
|
258
258
|
if (_response.ok) {
|
|
@@ -302,22 +302,22 @@ export class TagsClient {
|
|
|
302
302
|
}
|
|
303
303
|
__updateATag(request, requestOptions) {
|
|
304
304
|
return __awaiter(this, void 0, void 0, function* () {
|
|
305
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
305
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
306
306
|
const { id } = request, _body = __rest(request, ["id"]);
|
|
307
307
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
308
308
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
309
|
-
const _response = yield core.fetcher({
|
|
310
|
-
url: core.url.join((
|
|
309
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
310
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ForumEnvironment.Production, `tags/${core.url.encodePathParam(id)}`),
|
|
311
311
|
method: "PATCH",
|
|
312
312
|
headers: _headers,
|
|
313
313
|
contentType: "application/json",
|
|
314
314
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
315
315
|
requestType: "json",
|
|
316
316
|
body: _body,
|
|
317
|
-
timeoutMs: ((
|
|
318
|
-
maxRetries: (
|
|
317
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
318
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
319
319
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
320
|
-
fetchFn: (
|
|
320
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
321
321
|
logging: this._options.logging,
|
|
322
322
|
});
|
|
323
323
|
if (_response.ok) {
|
|
@@ -367,7 +367,7 @@ export class TagsClient {
|
|
|
367
367
|
}
|
|
368
368
|
__listTagSubscribers(request, requestOptions) {
|
|
369
369
|
return __awaiter(this, void 0, void 0, function* () {
|
|
370
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
370
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
371
371
|
const { id, cursor, limit } = request;
|
|
372
372
|
const _queryParams = {};
|
|
373
373
|
if (cursor != null) {
|
|
@@ -378,15 +378,15 @@ export class TagsClient {
|
|
|
378
378
|
}
|
|
379
379
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
380
380
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
381
|
-
const _response = yield core.fetcher({
|
|
382
|
-
url: core.url.join((
|
|
381
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
382
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ForumEnvironment.Production, `tags/${core.url.encodePathParam(id)}/subscribers`),
|
|
383
383
|
method: "GET",
|
|
384
384
|
headers: _headers,
|
|
385
385
|
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
386
|
-
timeoutMs: ((
|
|
387
|
-
maxRetries: (
|
|
386
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
387
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
388
388
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
389
|
-
fetchFn: (
|
|
389
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
390
390
|
logging: this._options.logging,
|
|
391
391
|
});
|
|
392
392
|
if (_response.ok) {
|
|
@@ -433,19 +433,19 @@ export class TagsClient {
|
|
|
433
433
|
}
|
|
434
434
|
__getASubscriberFromTag(request, requestOptions) {
|
|
435
435
|
return __awaiter(this, void 0, void 0, function* () {
|
|
436
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
436
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
437
437
|
const { id, subId } = request;
|
|
438
438
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
439
439
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
440
|
-
const _response = yield core.fetcher({
|
|
441
|
-
url: core.url.join((
|
|
440
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
441
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ForumEnvironment.Production, `tags/${core.url.encodePathParam(id)}/subscribers/${core.url.encodePathParam(subId)}`),
|
|
442
442
|
method: "GET",
|
|
443
443
|
headers: _headers,
|
|
444
444
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
445
|
-
timeoutMs: ((
|
|
446
|
-
maxRetries: (
|
|
445
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
446
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
447
447
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
448
|
-
fetchFn: (
|
|
448
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
449
449
|
logging: this._options.logging,
|
|
450
450
|
});
|
|
451
451
|
if (_response.ok) {
|
|
@@ -495,19 +495,19 @@ export class TagsClient {
|
|
|
495
495
|
}
|
|
496
496
|
__deleteASubscriberFromTag(request, requestOptions) {
|
|
497
497
|
return __awaiter(this, void 0, void 0, function* () {
|
|
498
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
498
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
499
499
|
const { id, subId } = request;
|
|
500
500
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
501
501
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
502
|
-
const _response = yield core.fetcher({
|
|
503
|
-
url: core.url.join((
|
|
502
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
503
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ForumEnvironment.Production, `tags/${core.url.encodePathParam(id)}/subscribers/${core.url.encodePathParam(subId)}`),
|
|
504
504
|
method: "DELETE",
|
|
505
505
|
headers: _headers,
|
|
506
506
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
507
|
-
timeoutMs: ((
|
|
508
|
-
maxRetries: (
|
|
507
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
508
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
509
509
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
510
|
-
fetchFn: (
|
|
510
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
511
511
|
logging: this._options.logging,
|
|
512
512
|
});
|
|
513
513
|
if (_response.ok) {
|