@foru-ms/sdk 2.1.5 → 2.1.6
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/README.md +1 -1
- package/dist/cjs/BaseClient.d.ts +0 -4
- package/dist/cjs/BaseClient.js +2 -3
- package/dist/cjs/Client.d.ts +1 -1
- package/dist/cjs/Client.js +1 -1
- package/dist/cjs/api/resources/auth/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/auth/client/Client.js +36 -46
- package/dist/cjs/api/resources/integrations/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/integrations/client/Client.js +36 -46
- package/dist/cjs/api/resources/notifications/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/notifications/client/Client.js +36 -46
- package/dist/cjs/api/resources/posts/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/posts/client/Client.js +85 -109
- package/dist/cjs/api/resources/privateMessages/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/privateMessages/client/Client.js +64 -82
- package/dist/cjs/api/resources/provisioning/client/Client.d.ts +25 -3
- package/dist/cjs/api/resources/provisioning/client/Client.js +234 -233
- package/dist/cjs/api/resources/provisioning/client/requests/AddDomainProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/CreateInstance.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/CreateWebhookProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/DeleteInstance.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/DeleteWebhookProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/ExportDataProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/GetBillingProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/GetOwnershipProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/GetUsageProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/InviteTeamProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/ListDomainsProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/ListProvisioningRequest.d.ts +5 -1
- package/dist/cjs/api/resources/provisioning/client/requests/ListTeamProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/ListWebhooksProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/RegenerateApiKeyProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/RemoveDomainProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/RemoveTeamMemberProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/TransferOwnershipProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/UpdateInstance.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/UpdateWebhookProvisioningRequest.d.ts +3 -0
- package/dist/cjs/api/resources/provisioning/client/requests/UpgradeInstance.d.ts +3 -0
- package/dist/cjs/api/resources/reports/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/reports/client/Client.js +36 -46
- package/dist/cjs/api/resources/roles/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/roles/client/Client.js +36 -46
- package/dist/cjs/api/resources/search/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/search/client/Client.js +8 -10
- package/dist/cjs/api/resources/ssOs/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/ssOs/client/Client.js +36 -46
- package/dist/cjs/api/resources/tags/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/tags/client/Client.js +57 -73
- package/dist/cjs/api/resources/threads/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/threads/client/Client.js +127 -163
- package/dist/cjs/api/resources/users/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/users/client/Client.js +78 -100
- package/dist/cjs/api/resources/webhooks/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/webhooks/client/Client.js +57 -73
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.d.mts +0 -4
- package/dist/esm/BaseClient.mjs +2 -3
- package/dist/esm/Client.d.mts +1 -1
- package/dist/esm/Client.mjs +1 -1
- package/dist/esm/api/resources/auth/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/auth/client/Client.mjs +37 -47
- package/dist/esm/api/resources/integrations/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/integrations/client/Client.mjs +37 -47
- package/dist/esm/api/resources/notifications/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/notifications/client/Client.mjs +37 -47
- package/dist/esm/api/resources/posts/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/posts/client/Client.mjs +86 -110
- package/dist/esm/api/resources/privateMessages/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/privateMessages/client/Client.mjs +65 -83
- package/dist/esm/api/resources/provisioning/client/Client.d.mts +25 -3
- package/dist/esm/api/resources/provisioning/client/Client.mjs +234 -233
- package/dist/esm/api/resources/provisioning/client/requests/AddDomainProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/CreateInstance.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/CreateWebhookProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/DeleteInstance.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/DeleteWebhookProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/ExportDataProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/GetBillingProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/GetOwnershipProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/GetUsageProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/InviteTeamProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/ListDomainsProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/ListProvisioningRequest.d.mts +5 -1
- package/dist/esm/api/resources/provisioning/client/requests/ListTeamProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/ListWebhooksProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/RegenerateApiKeyProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/RemoveDomainProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/RemoveTeamMemberProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/TransferOwnershipProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/UpdateInstance.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/UpdateWebhookProvisioningRequest.d.mts +3 -0
- package/dist/esm/api/resources/provisioning/client/requests/UpgradeInstance.d.mts +3 -0
- package/dist/esm/api/resources/reports/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/reports/client/Client.mjs +37 -47
- package/dist/esm/api/resources/roles/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/roles/client/Client.mjs +37 -47
- package/dist/esm/api/resources/search/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/search/client/Client.mjs +9 -11
- package/dist/esm/api/resources/ssOs/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/ssOs/client/Client.mjs +37 -47
- package/dist/esm/api/resources/tags/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/tags/client/Client.mjs +58 -74
- package/dist/esm/api/resources/threads/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/threads/client/Client.mjs +128 -164
- package/dist/esm/api/resources/users/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/users/client/Client.mjs +79 -101
- package/dist/esm/api/resources/webhooks/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/webhooks/client/Client.mjs +58 -74
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
- package/reference.md +23 -1
package/README.md
CHANGED
|
@@ -46,7 +46,7 @@ Instantiate and use the client with the following:
|
|
|
46
46
|
```typescript
|
|
47
47
|
import { ForumClient } from "@foru-ms/sdk";
|
|
48
48
|
|
|
49
|
-
const client = new ForumClient({ apiKey: "YOUR_API_KEY"
|
|
49
|
+
const client = new ForumClient({ apiKey: "YOUR_API_KEY" });
|
|
50
50
|
await client.auth.register({
|
|
51
51
|
username: "username",
|
|
52
52
|
email: "email",
|
package/dist/cjs/BaseClient.d.ts
CHANGED
|
@@ -5,8 +5,6 @@ export type BaseClientOptions = {
|
|
|
5
5
|
environment?: core.Supplier<environments.ForumEnvironment | string>;
|
|
6
6
|
/** Specify a custom URL to connect the client to. */
|
|
7
7
|
baseUrl?: core.Supplier<string>;
|
|
8
|
-
/** Override the x-provisioning-key header */
|
|
9
|
-
provisioningKey: core.Supplier<string>;
|
|
10
8
|
/** Additional headers to include in requests. */
|
|
11
9
|
headers?: Record<string, string | core.Supplier<string | null | undefined> | null | undefined>;
|
|
12
10
|
/** The default maximum time to wait for a response in seconds. */
|
|
@@ -26,8 +24,6 @@ export interface BaseRequestOptions {
|
|
|
26
24
|
maxRetries?: number;
|
|
27
25
|
/** A hook to abort the request. */
|
|
28
26
|
abortSignal?: AbortSignal;
|
|
29
|
-
/** Override the x-provisioning-key header */
|
|
30
|
-
provisioningKey?: string;
|
|
31
27
|
/** Additional query string parameters to include in the request. */
|
|
32
28
|
queryParams?: Record<string, unknown>;
|
|
33
29
|
/** Additional headers to include in the request. */
|
package/dist/cjs/BaseClient.js
CHANGED
|
@@ -43,11 +43,10 @@ function normalizeClientOptions(options) {
|
|
|
43
43
|
const headers = (0, headers_js_1.mergeHeaders)({
|
|
44
44
|
"X-Fern-Language": "JavaScript",
|
|
45
45
|
"X-Fern-SDK-Name": "@foru-ms/sdk",
|
|
46
|
-
"X-Fern-SDK-Version": "2.1.
|
|
47
|
-
"User-Agent": "@foru-ms/sdk/2.1.
|
|
46
|
+
"X-Fern-SDK-Version": "2.1.6",
|
|
47
|
+
"User-Agent": "@foru-ms/sdk/2.1.6",
|
|
48
48
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
49
49
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
50
|
-
"x-provisioning-key": options === null || options === void 0 ? void 0 : options.provisioningKey,
|
|
51
50
|
}, options === null || options === void 0 ? void 0 : options.headers);
|
|
52
51
|
return Object.assign(Object.assign({}, options), { logging: core.logging.createLogger(options === null || options === void 0 ? void 0 : options.logging), headers });
|
|
53
52
|
}
|
package/dist/cjs/Client.d.ts
CHANGED
|
@@ -35,7 +35,7 @@ export declare class ForumClient {
|
|
|
35
35
|
protected _integrations: IntegrationsClient | undefined;
|
|
36
36
|
protected _ssOs: SsOsClient | undefined;
|
|
37
37
|
protected _provisioning: ProvisioningClient | undefined;
|
|
38
|
-
constructor(options
|
|
38
|
+
constructor(options?: ForumClient.Options);
|
|
39
39
|
get auth(): AuthClient;
|
|
40
40
|
get search(): SearchClient;
|
|
41
41
|
get tags(): TagsClient;
|
package/dist/cjs/Client.js
CHANGED
|
@@ -18,7 +18,7 @@ const Client_js_13 = require("./api/resources/users/client/Client.js");
|
|
|
18
18
|
const Client_js_14 = require("./api/resources/webhooks/client/Client.js");
|
|
19
19
|
const BaseClient_js_1 = require("./BaseClient.js");
|
|
20
20
|
class ForumClient {
|
|
21
|
-
constructor(options) {
|
|
21
|
+
constructor(options = {}) {
|
|
22
22
|
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
23
23
|
}
|
|
24
24
|
get auth() {
|
|
@@ -12,7 +12,7 @@ export declare namespace AuthClient {
|
|
|
12
12
|
*/
|
|
13
13
|
export declare class AuthClient {
|
|
14
14
|
protected readonly _options: NormalizedClientOptionsWithAuth<AuthClient.Options>;
|
|
15
|
-
constructor(options
|
|
15
|
+
constructor(options?: AuthClient.Options);
|
|
16
16
|
/**
|
|
17
17
|
* Register a new user in your forum instance. Requires API key for instance identification. Returns a JWT token for subsequent authenticated requests.
|
|
18
18
|
*
|
|
@@ -55,7 +55,7 @@ const Forum = __importStar(require("../../../index.js"));
|
|
|
55
55
|
* Operations for auth
|
|
56
56
|
*/
|
|
57
57
|
class AuthClient {
|
|
58
|
-
constructor(options) {
|
|
58
|
+
constructor(options = {}) {
|
|
59
59
|
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
60
60
|
}
|
|
61
61
|
/**
|
|
@@ -82,23 +82,21 @@ class AuthClient {
|
|
|
82
82
|
}
|
|
83
83
|
__register(request, requestOptions) {
|
|
84
84
|
return __awaiter(this, void 0, void 0, function* () {
|
|
85
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k
|
|
85
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
86
86
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
87
|
-
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers,
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
|
|
91
|
-
url: core.url.join((_f = (_e = (yield core.Supplier.get(this._options.baseUrl))) !== null && _e !== void 0 ? _e : (yield core.Supplier.get(this._options.environment))) !== null && _f !== void 0 ? _f : environments.ForumEnvironment.Production, "auth/register"),
|
|
87
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
88
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
89
|
+
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, "auth/register"),
|
|
92
90
|
method: "POST",
|
|
93
91
|
headers: _headers,
|
|
94
92
|
contentType: "application/json",
|
|
95
93
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
96
94
|
requestType: "json",
|
|
97
95
|
body: request,
|
|
98
|
-
timeoutMs: ((
|
|
99
|
-
maxRetries: (
|
|
96
|
+
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,
|
|
97
|
+
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,
|
|
100
98
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
101
|
-
fetchFn: (
|
|
99
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
102
100
|
logging: this._options.logging,
|
|
103
101
|
});
|
|
104
102
|
if (_response.ok) {
|
|
@@ -150,23 +148,21 @@ class AuthClient {
|
|
|
150
148
|
}
|
|
151
149
|
__login(request, requestOptions) {
|
|
152
150
|
return __awaiter(this, void 0, void 0, function* () {
|
|
153
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k
|
|
151
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
154
152
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
155
|
-
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers,
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
|
|
159
|
-
url: core.url.join((_f = (_e = (yield core.Supplier.get(this._options.baseUrl))) !== null && _e !== void 0 ? _e : (yield core.Supplier.get(this._options.environment))) !== null && _f !== void 0 ? _f : environments.ForumEnvironment.Production, "auth/login"),
|
|
153
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
154
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
155
|
+
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, "auth/login"),
|
|
160
156
|
method: "POST",
|
|
161
157
|
headers: _headers,
|
|
162
158
|
contentType: "application/json",
|
|
163
159
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
164
160
|
requestType: "json",
|
|
165
161
|
body: request,
|
|
166
|
-
timeoutMs: ((
|
|
167
|
-
maxRetries: (
|
|
162
|
+
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,
|
|
163
|
+
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,
|
|
168
164
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
169
|
-
fetchFn: (
|
|
165
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
170
166
|
logging: this._options.logging,
|
|
171
167
|
});
|
|
172
168
|
if (_response.ok) {
|
|
@@ -211,20 +207,18 @@ class AuthClient {
|
|
|
211
207
|
}
|
|
212
208
|
__me(requestOptions) {
|
|
213
209
|
return __awaiter(this, void 0, void 0, function* () {
|
|
214
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k
|
|
210
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
215
211
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
216
|
-
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers,
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
|
|
220
|
-
url: core.url.join((_f = (_e = (yield core.Supplier.get(this._options.baseUrl))) !== null && _e !== void 0 ? _e : (yield core.Supplier.get(this._options.environment))) !== null && _f !== void 0 ? _f : environments.ForumEnvironment.Production, "auth/me"),
|
|
212
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
213
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
214
|
+
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, "auth/me"),
|
|
221
215
|
method: "GET",
|
|
222
216
|
headers: _headers,
|
|
223
217
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
224
|
-
timeoutMs: ((
|
|
225
|
-
maxRetries: (
|
|
218
|
+
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,
|
|
219
|
+
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,
|
|
226
220
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
227
|
-
fetchFn: (
|
|
221
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
228
222
|
logging: this._options.logging,
|
|
229
223
|
});
|
|
230
224
|
if (_response.ok) {
|
|
@@ -273,23 +267,21 @@ class AuthClient {
|
|
|
273
267
|
}
|
|
274
268
|
__forgotPassword(request, requestOptions) {
|
|
275
269
|
return __awaiter(this, void 0, void 0, function* () {
|
|
276
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k
|
|
270
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
277
271
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
278
|
-
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers,
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
|
|
282
|
-
url: core.url.join((_f = (_e = (yield core.Supplier.get(this._options.baseUrl))) !== null && _e !== void 0 ? _e : (yield core.Supplier.get(this._options.environment))) !== null && _f !== void 0 ? _f : environments.ForumEnvironment.Production, "auth/forgot-password"),
|
|
272
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
273
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
274
|
+
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, "auth/forgot-password"),
|
|
283
275
|
method: "POST",
|
|
284
276
|
headers: _headers,
|
|
285
277
|
contentType: "application/json",
|
|
286
278
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
287
279
|
requestType: "json",
|
|
288
280
|
body: request,
|
|
289
|
-
timeoutMs: ((
|
|
290
|
-
maxRetries: (
|
|
281
|
+
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,
|
|
282
|
+
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,
|
|
291
283
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
292
|
-
fetchFn: (
|
|
284
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
293
285
|
logging: this._options.logging,
|
|
294
286
|
});
|
|
295
287
|
if (_response.ok) {
|
|
@@ -340,23 +332,21 @@ class AuthClient {
|
|
|
340
332
|
}
|
|
341
333
|
__resetPassword(request, requestOptions) {
|
|
342
334
|
return __awaiter(this, void 0, void 0, function* () {
|
|
343
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k
|
|
335
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
344
336
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
345
|
-
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers,
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
|
|
349
|
-
url: core.url.join((_f = (_e = (yield core.Supplier.get(this._options.baseUrl))) !== null && _e !== void 0 ? _e : (yield core.Supplier.get(this._options.environment))) !== null && _f !== void 0 ? _f : environments.ForumEnvironment.Production, "auth/reset-password"),
|
|
337
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
338
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
339
|
+
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, "auth/reset-password"),
|
|
350
340
|
method: "POST",
|
|
351
341
|
headers: _headers,
|
|
352
342
|
contentType: "application/json",
|
|
353
343
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
354
344
|
requestType: "json",
|
|
355
345
|
body: request,
|
|
356
|
-
timeoutMs: ((
|
|
357
|
-
maxRetries: (
|
|
346
|
+
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,
|
|
347
|
+
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,
|
|
358
348
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
359
|
-
fetchFn: (
|
|
349
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
360
350
|
logging: this._options.logging,
|
|
361
351
|
});
|
|
362
352
|
if (_response.ok) {
|
|
@@ -12,7 +12,7 @@ export declare namespace IntegrationsClient {
|
|
|
12
12
|
*/
|
|
13
13
|
export declare class IntegrationsClient {
|
|
14
14
|
protected readonly _options: NormalizedClientOptionsWithAuth<IntegrationsClient.Options>;
|
|
15
|
-
constructor(options
|
|
15
|
+
constructor(options?: IntegrationsClient.Options);
|
|
16
16
|
/**
|
|
17
17
|
* Retrieve a paginated list of integrations. Use cursor for pagination.
|
|
18
18
|
*
|
|
@@ -66,7 +66,7 @@ const Forum = __importStar(require("../../../index.js"));
|
|
|
66
66
|
* Operations for integrations
|
|
67
67
|
*/
|
|
68
68
|
class IntegrationsClient {
|
|
69
|
-
constructor(options) {
|
|
69
|
+
constructor(options = {}) {
|
|
70
70
|
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
71
71
|
}
|
|
72
72
|
/**
|
|
@@ -90,25 +90,23 @@ class IntegrationsClient {
|
|
|
90
90
|
}
|
|
91
91
|
__list() {
|
|
92
92
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
93
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k
|
|
93
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
94
94
|
const { limit, cursor } = request;
|
|
95
95
|
const _queryParams = {
|
|
96
96
|
limit,
|
|
97
97
|
cursor,
|
|
98
98
|
};
|
|
99
99
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
100
|
-
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers,
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
|
|
104
|
-
url: core.url.join((_f = (_e = (yield core.Supplier.get(this._options.baseUrl))) !== null && _e !== void 0 ? _e : (yield core.Supplier.get(this._options.environment))) !== null && _f !== void 0 ? _f : environments.ForumEnvironment.Production, "integrations"),
|
|
100
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
101
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
102
|
+
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, "integrations"),
|
|
105
103
|
method: "GET",
|
|
106
104
|
headers: _headers,
|
|
107
105
|
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
108
|
-
timeoutMs: ((
|
|
109
|
-
maxRetries: (
|
|
106
|
+
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,
|
|
107
|
+
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,
|
|
110
108
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
111
|
-
fetchFn: (
|
|
109
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
112
110
|
logging: this._options.logging,
|
|
113
111
|
});
|
|
114
112
|
if (_response.ok) {
|
|
@@ -163,23 +161,21 @@ class IntegrationsClient {
|
|
|
163
161
|
}
|
|
164
162
|
__create(request, requestOptions) {
|
|
165
163
|
return __awaiter(this, void 0, void 0, function* () {
|
|
166
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k
|
|
164
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
167
165
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
168
|
-
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers,
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
|
|
172
|
-
url: core.url.join((_f = (_e = (yield core.Supplier.get(this._options.baseUrl))) !== null && _e !== void 0 ? _e : (yield core.Supplier.get(this._options.environment))) !== null && _f !== void 0 ? _f : environments.ForumEnvironment.Production, "integrations"),
|
|
166
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
167
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
168
|
+
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, "integrations"),
|
|
173
169
|
method: "POST",
|
|
174
170
|
headers: _headers,
|
|
175
171
|
contentType: "application/json",
|
|
176
172
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
177
173
|
requestType: "json",
|
|
178
174
|
body: request,
|
|
179
|
-
timeoutMs: ((
|
|
180
|
-
maxRetries: (
|
|
175
|
+
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,
|
|
176
|
+
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,
|
|
181
177
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
182
|
-
fetchFn: (
|
|
178
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
183
179
|
logging: this._options.logging,
|
|
184
180
|
});
|
|
185
181
|
if (_response.ok) {
|
|
@@ -232,21 +228,19 @@ class IntegrationsClient {
|
|
|
232
228
|
}
|
|
233
229
|
__retrieve(request, requestOptions) {
|
|
234
230
|
return __awaiter(this, void 0, void 0, function* () {
|
|
235
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k
|
|
231
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
236
232
|
const { id } = request;
|
|
237
233
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
238
|
-
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers,
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
|
|
242
|
-
url: core.url.join((_f = (_e = (yield core.Supplier.get(this._options.baseUrl))) !== null && _e !== void 0 ? _e : (yield core.Supplier.get(this._options.environment))) !== null && _f !== void 0 ? _f : environments.ForumEnvironment.Production, `integrations/${core.url.encodePathParam(id)}`),
|
|
234
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
235
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
236
|
+
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, `integrations/${core.url.encodePathParam(id)}`),
|
|
243
237
|
method: "GET",
|
|
244
238
|
headers: _headers,
|
|
245
239
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
246
|
-
timeoutMs: ((
|
|
247
|
-
maxRetries: (
|
|
240
|
+
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,
|
|
241
|
+
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,
|
|
248
242
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
249
|
-
fetchFn: (
|
|
243
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
250
244
|
logging: this._options.logging,
|
|
251
245
|
});
|
|
252
246
|
if (_response.ok) {
|
|
@@ -299,21 +293,19 @@ class IntegrationsClient {
|
|
|
299
293
|
}
|
|
300
294
|
__delete(request, requestOptions) {
|
|
301
295
|
return __awaiter(this, void 0, void 0, function* () {
|
|
302
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k
|
|
296
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
303
297
|
const { id } = request;
|
|
304
298
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
305
|
-
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers,
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
|
|
309
|
-
url: core.url.join((_f = (_e = (yield core.Supplier.get(this._options.baseUrl))) !== null && _e !== void 0 ? _e : (yield core.Supplier.get(this._options.environment))) !== null && _f !== void 0 ? _f : environments.ForumEnvironment.Production, `integrations/${core.url.encodePathParam(id)}`),
|
|
299
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
300
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
301
|
+
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, `integrations/${core.url.encodePathParam(id)}`),
|
|
310
302
|
method: "DELETE",
|
|
311
303
|
headers: _headers,
|
|
312
304
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
313
|
-
timeoutMs: ((
|
|
314
|
-
maxRetries: (
|
|
305
|
+
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,
|
|
306
|
+
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,
|
|
315
307
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
316
|
-
fetchFn: (
|
|
308
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
317
309
|
logging: this._options.logging,
|
|
318
310
|
});
|
|
319
311
|
if (_response.ok) {
|
|
@@ -367,24 +359,22 @@ class IntegrationsClient {
|
|
|
367
359
|
}
|
|
368
360
|
__update(request, requestOptions) {
|
|
369
361
|
return __awaiter(this, void 0, void 0, function* () {
|
|
370
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k
|
|
362
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
371
363
|
const { id } = request, _body = __rest(request, ["id"]);
|
|
372
364
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
373
|
-
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers,
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
|
|
377
|
-
url: core.url.join((_f = (_e = (yield core.Supplier.get(this._options.baseUrl))) !== null && _e !== void 0 ? _e : (yield core.Supplier.get(this._options.environment))) !== null && _f !== void 0 ? _f : environments.ForumEnvironment.Production, `integrations/${core.url.encodePathParam(id)}`),
|
|
365
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
366
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
367
|
+
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, `integrations/${core.url.encodePathParam(id)}`),
|
|
378
368
|
method: "PATCH",
|
|
379
369
|
headers: _headers,
|
|
380
370
|
contentType: "application/json",
|
|
381
371
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
382
372
|
requestType: "json",
|
|
383
373
|
body: _body,
|
|
384
|
-
timeoutMs: ((
|
|
385
|
-
maxRetries: (
|
|
374
|
+
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,
|
|
375
|
+
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,
|
|
386
376
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
387
|
-
fetchFn: (
|
|
377
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
388
378
|
logging: this._options.logging,
|
|
389
379
|
});
|
|
390
380
|
if (_response.ok) {
|
|
@@ -12,7 +12,7 @@ export declare namespace NotificationsClient {
|
|
|
12
12
|
*/
|
|
13
13
|
export declare class NotificationsClient {
|
|
14
14
|
protected readonly _options: NormalizedClientOptionsWithAuth<NotificationsClient.Options>;
|
|
15
|
-
constructor(options
|
|
15
|
+
constructor(options?: NotificationsClient.Options);
|
|
16
16
|
/**
|
|
17
17
|
* Retrieve a paginated list of notifications. Use cursor for pagination.
|
|
18
18
|
*
|