@foru-ms/sdk 2.1.0 → 2.1.1
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.js +2 -2
- package/dist/cjs/Client.d.ts +4 -1
- package/dist/cjs/Client.js +16 -11
- package/dist/cjs/api/resources/auth/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/auth/client/Client.js +1 -1
- package/dist/cjs/api/resources/index.d.ts +3 -0
- package/dist/cjs/api/resources/index.js +4 -1
- package/dist/cjs/api/resources/integrations/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/integrations/client/Client.js +6 -9
- package/dist/cjs/api/resources/integrations/client/requests/CreateIntegrationsRequest.d.ts +2 -0
- package/dist/cjs/api/resources/integrations/client/requests/ListIntegrationsRequest.d.ts +2 -2
- package/dist/cjs/api/resources/integrations/client/requests/UpdateIntegrationsRequest.d.ts +2 -0
- package/dist/cjs/api/resources/integrations/types/UpdateIntegrationsResponse.d.ts +2 -0
- package/dist/cjs/api/resources/notifications/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/notifications/client/Client.js +7 -14
- package/dist/cjs/api/resources/notifications/client/requests/index.d.ts +2 -2
- package/dist/cjs/api/resources/notifications/client/requests/index.js +5 -0
- package/dist/cjs/api/resources/posts/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/posts/client/Client.js +22 -49
- package/dist/cjs/api/resources/posts/client/requests/index.d.ts +1 -1
- package/dist/cjs/api/resources/posts/client/requests/index.js +3 -0
- package/dist/cjs/api/resources/privateMessages/client/Client.d.ts +21 -1
- package/dist/cjs/api/resources/privateMessages/client/Client.js +79 -18
- package/dist/cjs/api/resources/privateMessages/client/requests/UpdatePrivateMessagesRequest.d.ts +16 -0
- package/dist/cjs/api/resources/privateMessages/client/requests/UpdatePrivateMessagesRequest.js +3 -0
- package/dist/cjs/api/resources/privateMessages/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/privateMessages/types/UpdatePrivateMessagesResponse.d.ts +26 -0
- package/dist/cjs/api/resources/privateMessages/types/UpdatePrivateMessagesResponse.js +3 -0
- package/dist/cjs/api/resources/privateMessages/types/index.d.ts +1 -0
- package/dist/cjs/api/resources/privateMessages/types/index.js +1 -0
- package/dist/cjs/api/resources/reports/client/Client.d.ts +21 -1
- package/dist/cjs/api/resources/reports/client/Client.js +88 -17
- package/dist/cjs/api/resources/reports/client/requests/UpdateReportsRequest.d.ts +16 -0
- package/dist/cjs/api/resources/reports/client/requests/UpdateReportsRequest.js +3 -0
- package/dist/cjs/api/resources/reports/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/reports/index.d.ts +1 -0
- package/dist/cjs/api/resources/reports/index.js +1 -0
- package/dist/cjs/api/resources/reports/types/UpdateReportsResponse.d.ts +28 -0
- package/dist/cjs/api/resources/reports/types/UpdateReportsResponse.js +3 -0
- package/dist/cjs/api/resources/reports/types/index.d.ts +1 -0
- package/dist/cjs/api/resources/reports/types/index.js +17 -0
- package/dist/cjs/api/resources/roles/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/roles/client/Client.js +8 -9
- package/dist/cjs/api/resources/roles/client/requests/ListRolesRequest.d.ts +7 -2
- package/dist/cjs/api/resources/roles/types/ListRolesRequestSort.d.ts +6 -0
- package/dist/cjs/api/resources/roles/types/ListRolesRequestSort.js +9 -0
- package/dist/cjs/api/resources/roles/types/index.d.ts +1 -0
- package/dist/cjs/api/resources/roles/types/index.js +1 -0
- package/dist/cjs/api/resources/search/client/Client.d.ts +29 -0
- package/dist/cjs/api/resources/search/client/Client.js +115 -0
- package/dist/cjs/api/resources/search/client/index.d.ts +1 -0
- package/dist/cjs/api/resources/search/client/index.js +2 -0
- package/dist/cjs/api/resources/search/index.d.ts +2 -0
- package/dist/cjs/api/resources/search/index.js +18 -0
- package/dist/cjs/api/resources/search/types/SearchSearchResponse.d.ts +33 -0
- package/dist/cjs/api/resources/search/types/SearchSearchResponse.js +22 -0
- package/dist/cjs/api/resources/search/types/index.d.ts +1 -0
- package/dist/cjs/api/resources/search/types/index.js +17 -0
- package/dist/cjs/api/resources/ssOs/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/ssOs/client/Client.js +6 -9
- package/dist/cjs/api/resources/ssOs/client/requests/CreateSsOsRequest.d.ts +2 -0
- package/dist/cjs/api/resources/ssOs/client/requests/ListSsOsRequest.d.ts +2 -2
- package/dist/cjs/api/resources/ssOs/client/requests/UpdateSsOsRequest.d.ts +2 -0
- package/dist/cjs/api/resources/ssOs/types/UpdateSsOsResponse.d.ts +2 -0
- package/dist/cjs/api/resources/tags/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/tags/client/Client.js +10 -18
- package/dist/cjs/api/resources/threads/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/threads/client/Client.js +26 -56
- package/dist/cjs/api/resources/threads/client/requests/CreateThreadsRequest.d.ts +6 -0
- package/dist/cjs/api/resources/threads/client/requests/index.d.ts +1 -1
- package/dist/cjs/api/resources/threads/client/requests/index.js +3 -0
- package/dist/cjs/api/resources/threads/types/UpdateThreadsResponse.d.ts +5 -5
- package/dist/cjs/api/resources/users/client/Client.d.ts +20 -1
- package/dist/cjs/api/resources/users/client/Client.js +80 -28
- package/dist/cjs/api/resources/users/client/requests/CreateUsersRequest.d.ts +26 -0
- package/dist/cjs/api/resources/users/client/requests/CreateUsersRequest.js +3 -0
- package/dist/cjs/api/resources/users/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/webhooks/client/Client.d.ts +23 -1
- package/dist/cjs/api/resources/webhooks/client/Client.js +91 -15
- package/dist/cjs/api/resources/webhooks/client/requests/CreateWebhooksRequest.d.ts +4 -0
- package/dist/cjs/api/resources/webhooks/client/requests/UpdateWebhooksRequest.d.ts +22 -0
- package/dist/cjs/api/resources/webhooks/client/requests/UpdateWebhooksRequest.js +3 -0
- package/dist/cjs/api/resources/webhooks/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/webhooks/types/UpdateWebhooksResponse.d.ts +26 -0
- package/dist/cjs/api/resources/webhooks/types/UpdateWebhooksResponse.js +3 -0
- package/dist/cjs/api/resources/webhooks/types/index.d.ts +1 -0
- package/dist/cjs/api/resources/webhooks/types/index.js +1 -0
- package/dist/cjs/api/types/Integration.d.ts +2 -0
- package/dist/cjs/api/types/IntegrationCreate.d.ts +2 -0
- package/dist/cjs/api/types/IntegrationList.d.ts +6 -0
- package/dist/cjs/api/types/IntegrationList.js +3 -0
- package/dist/cjs/api/types/IntegrationListResponse.d.ts +2 -0
- package/dist/cjs/api/types/IntegrationResponse.d.ts +2 -0
- package/dist/cjs/api/types/IntegrationUpdate.d.ts +2 -0
- package/dist/cjs/api/types/MeResponse.d.ts +22 -0
- package/dist/cjs/api/types/PrivateMessageUpdate.d.ts +8 -0
- package/dist/cjs/api/types/PrivateMessageUpdate.js +3 -0
- package/dist/cjs/api/types/ReportUpdate.d.ts +8 -0
- package/dist/cjs/api/types/ReportUpdate.js +3 -0
- package/dist/cjs/api/types/RoleList.d.ts +19 -0
- package/dist/cjs/api/types/RoleList.js +13 -0
- package/dist/cjs/api/types/Search.d.ts +1 -0
- package/dist/cjs/api/types/Search.js +3 -0
- package/dist/cjs/api/types/SearchListResponse.d.ts +18 -0
- package/dist/cjs/api/types/SearchListResponse.js +3 -0
- package/dist/cjs/api/types/SearchResponse.d.ts +6 -0
- package/dist/cjs/api/types/SearchResponse.js +3 -0
- package/dist/cjs/api/types/Sso.d.ts +2 -0
- package/dist/cjs/api/types/SsoCreate.d.ts +2 -0
- package/dist/cjs/api/types/SsoList.d.ts +6 -0
- package/dist/cjs/api/types/SsoList.js +3 -0
- package/dist/cjs/api/types/SsoListResponse.d.ts +2 -0
- package/dist/cjs/api/types/SsoResponse.d.ts +2 -0
- package/dist/cjs/api/types/SsoUpdate.d.ts +2 -0
- package/dist/cjs/api/types/Thread.d.ts +5 -5
- package/dist/cjs/api/types/ThreadCreate.d.ts +6 -0
- package/dist/cjs/api/types/ThreadListResponse.d.ts +5 -5
- package/dist/cjs/api/types/ThreadResponse.d.ts +5 -5
- package/dist/cjs/api/types/UserCreate.d.ts +20 -0
- package/dist/cjs/api/types/UserCreate.js +3 -0
- package/dist/cjs/api/types/Webhook.d.ts +2 -0
- package/dist/cjs/api/types/WebhookCreate.d.ts +4 -0
- package/dist/cjs/api/types/WebhookListResponse.d.ts +2 -0
- package/dist/cjs/api/types/WebhookResponse.d.ts +2 -0
- package/dist/cjs/api/types/WebhookUpdate.d.ts +14 -0
- package/dist/cjs/api/types/WebhookUpdate.js +3 -0
- package/dist/cjs/api/types/index.d.ts +10 -0
- package/dist/cjs/api/types/index.js +10 -0
- package/dist/cjs/auth/HeaderAuthProvider.d.ts +14 -10
- package/dist/cjs/auth/HeaderAuthProvider.js +18 -9
- package/dist/cjs/core/fetcher/EndpointSupplier.d.ts +2 -2
- package/dist/cjs/core/fetcher/Fetcher.d.ts +1 -2
- package/dist/cjs/core/headers.d.ts +2 -2
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.mjs +2 -2
- package/dist/esm/Client.d.mts +4 -1
- package/dist/esm/Client.mjs +6 -1
- package/dist/esm/api/resources/auth/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/auth/client/Client.mjs +1 -1
- package/dist/esm/api/resources/index.d.mts +3 -0
- package/dist/esm/api/resources/index.mjs +3 -0
- package/dist/esm/api/resources/integrations/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/integrations/client/Client.mjs +6 -9
- package/dist/esm/api/resources/integrations/client/requests/CreateIntegrationsRequest.d.mts +2 -0
- package/dist/esm/api/resources/integrations/client/requests/ListIntegrationsRequest.d.mts +2 -2
- package/dist/esm/api/resources/integrations/client/requests/UpdateIntegrationsRequest.d.mts +2 -0
- package/dist/esm/api/resources/integrations/types/UpdateIntegrationsResponse.d.mts +2 -0
- package/dist/esm/api/resources/notifications/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/notifications/client/Client.mjs +7 -14
- package/dist/esm/api/resources/notifications/client/requests/index.d.mts +2 -2
- package/dist/esm/api/resources/notifications/client/requests/index.mjs +2 -1
- package/dist/esm/api/resources/posts/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/posts/client/Client.mjs +22 -49
- package/dist/esm/api/resources/posts/client/requests/index.d.mts +1 -1
- package/dist/esm/api/resources/posts/client/requests/index.mjs +1 -1
- package/dist/esm/api/resources/privateMessages/client/Client.d.mts +21 -1
- package/dist/esm/api/resources/privateMessages/client/Client.mjs +79 -18
- package/dist/esm/api/resources/privateMessages/client/requests/UpdatePrivateMessagesRequest.d.mts +16 -0
- package/dist/esm/api/resources/privateMessages/client/requests/UpdatePrivateMessagesRequest.mjs +2 -0
- package/dist/esm/api/resources/privateMessages/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/privateMessages/types/UpdatePrivateMessagesResponse.d.mts +26 -0
- package/dist/esm/api/resources/privateMessages/types/UpdatePrivateMessagesResponse.mjs +2 -0
- package/dist/esm/api/resources/privateMessages/types/index.d.mts +1 -0
- package/dist/esm/api/resources/privateMessages/types/index.mjs +1 -0
- package/dist/esm/api/resources/reports/client/Client.d.mts +21 -1
- package/dist/esm/api/resources/reports/client/Client.mjs +88 -17
- package/dist/esm/api/resources/reports/client/requests/UpdateReportsRequest.d.mts +16 -0
- package/dist/esm/api/resources/reports/client/requests/UpdateReportsRequest.mjs +2 -0
- package/dist/esm/api/resources/reports/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/reports/index.d.mts +1 -0
- package/dist/esm/api/resources/reports/index.mjs +1 -0
- package/dist/esm/api/resources/reports/types/UpdateReportsResponse.d.mts +28 -0
- package/dist/esm/api/resources/reports/types/UpdateReportsResponse.mjs +2 -0
- package/dist/esm/api/resources/reports/types/index.d.mts +1 -0
- package/dist/esm/api/resources/reports/types/index.mjs +1 -0
- package/dist/esm/api/resources/roles/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/roles/client/Client.mjs +8 -9
- package/dist/esm/api/resources/roles/client/requests/ListRolesRequest.d.mts +7 -2
- package/dist/esm/api/resources/roles/types/ListRolesRequestSort.d.mts +6 -0
- package/dist/esm/api/resources/roles/types/ListRolesRequestSort.mjs +6 -0
- package/dist/esm/api/resources/roles/types/index.d.mts +1 -0
- package/dist/esm/api/resources/roles/types/index.mjs +1 -0
- package/dist/esm/api/resources/search/client/Client.d.mts +29 -0
- package/dist/esm/api/resources/search/client/Client.mjs +78 -0
- package/dist/esm/api/resources/search/client/index.d.mts +1 -0
- package/dist/esm/api/resources/search/client/index.mjs +1 -0
- package/dist/esm/api/resources/search/index.d.mts +2 -0
- package/dist/esm/api/resources/search/index.mjs +2 -0
- package/dist/esm/api/resources/search/types/SearchSearchResponse.d.mts +33 -0
- package/dist/esm/api/resources/search/types/SearchSearchResponse.mjs +19 -0
- package/dist/esm/api/resources/search/types/index.d.mts +1 -0
- package/dist/esm/api/resources/search/types/index.mjs +1 -0
- package/dist/esm/api/resources/ssOs/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/ssOs/client/Client.mjs +6 -9
- package/dist/esm/api/resources/ssOs/client/requests/CreateSsOsRequest.d.mts +2 -0
- package/dist/esm/api/resources/ssOs/client/requests/ListSsOsRequest.d.mts +2 -2
- package/dist/esm/api/resources/ssOs/client/requests/UpdateSsOsRequest.d.mts +2 -0
- package/dist/esm/api/resources/ssOs/types/UpdateSsOsResponse.d.mts +2 -0
- package/dist/esm/api/resources/tags/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/tags/client/Client.mjs +10 -18
- package/dist/esm/api/resources/threads/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/threads/client/Client.mjs +26 -56
- package/dist/esm/api/resources/threads/client/requests/CreateThreadsRequest.d.mts +6 -0
- package/dist/esm/api/resources/threads/client/requests/index.d.mts +1 -1
- package/dist/esm/api/resources/threads/client/requests/index.mjs +1 -1
- package/dist/esm/api/resources/threads/types/UpdateThreadsResponse.d.mts +5 -5
- package/dist/esm/api/resources/users/client/Client.d.mts +20 -1
- package/dist/esm/api/resources/users/client/Client.mjs +80 -28
- package/dist/esm/api/resources/users/client/requests/CreateUsersRequest.d.mts +26 -0
- package/dist/esm/api/resources/users/client/requests/CreateUsersRequest.mjs +2 -0
- package/dist/esm/api/resources/users/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/webhooks/client/Client.d.mts +23 -1
- package/dist/esm/api/resources/webhooks/client/Client.mjs +91 -15
- package/dist/esm/api/resources/webhooks/client/requests/CreateWebhooksRequest.d.mts +4 -0
- package/dist/esm/api/resources/webhooks/client/requests/UpdateWebhooksRequest.d.mts +22 -0
- package/dist/esm/api/resources/webhooks/client/requests/UpdateWebhooksRequest.mjs +2 -0
- package/dist/esm/api/resources/webhooks/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/webhooks/types/UpdateWebhooksResponse.d.mts +26 -0
- package/dist/esm/api/resources/webhooks/types/UpdateWebhooksResponse.mjs +2 -0
- package/dist/esm/api/resources/webhooks/types/index.d.mts +1 -0
- package/dist/esm/api/resources/webhooks/types/index.mjs +1 -0
- package/dist/esm/api/types/Integration.d.mts +2 -0
- package/dist/esm/api/types/IntegrationCreate.d.mts +2 -0
- package/dist/esm/api/types/IntegrationList.d.mts +6 -0
- package/dist/esm/api/types/IntegrationList.mjs +2 -0
- package/dist/esm/api/types/IntegrationListResponse.d.mts +2 -0
- package/dist/esm/api/types/IntegrationResponse.d.mts +2 -0
- package/dist/esm/api/types/IntegrationUpdate.d.mts +2 -0
- package/dist/esm/api/types/MeResponse.d.mts +22 -0
- package/dist/esm/api/types/PrivateMessageUpdate.d.mts +8 -0
- package/dist/esm/api/types/PrivateMessageUpdate.mjs +2 -0
- package/dist/esm/api/types/ReportUpdate.d.mts +8 -0
- package/dist/esm/api/types/ReportUpdate.mjs +2 -0
- package/dist/esm/api/types/RoleList.d.mts +19 -0
- package/dist/esm/api/types/RoleList.mjs +10 -0
- package/dist/esm/api/types/Search.d.mts +1 -0
- package/dist/esm/api/types/Search.mjs +2 -0
- package/dist/esm/api/types/SearchListResponse.d.mts +18 -0
- package/dist/esm/api/types/SearchListResponse.mjs +2 -0
- package/dist/esm/api/types/SearchResponse.d.mts +6 -0
- package/dist/esm/api/types/SearchResponse.mjs +2 -0
- package/dist/esm/api/types/Sso.d.mts +2 -0
- package/dist/esm/api/types/SsoCreate.d.mts +2 -0
- package/dist/esm/api/types/SsoList.d.mts +6 -0
- package/dist/esm/api/types/SsoList.mjs +2 -0
- package/dist/esm/api/types/SsoListResponse.d.mts +2 -0
- package/dist/esm/api/types/SsoResponse.d.mts +2 -0
- package/dist/esm/api/types/SsoUpdate.d.mts +2 -0
- package/dist/esm/api/types/Thread.d.mts +5 -5
- package/dist/esm/api/types/ThreadCreate.d.mts +6 -0
- package/dist/esm/api/types/ThreadListResponse.d.mts +5 -5
- package/dist/esm/api/types/ThreadResponse.d.mts +5 -5
- package/dist/esm/api/types/UserCreate.d.mts +20 -0
- package/dist/esm/api/types/UserCreate.mjs +2 -0
- package/dist/esm/api/types/Webhook.d.mts +2 -0
- package/dist/esm/api/types/WebhookCreate.d.mts +4 -0
- package/dist/esm/api/types/WebhookListResponse.d.mts +2 -0
- package/dist/esm/api/types/WebhookResponse.d.mts +2 -0
- package/dist/esm/api/types/WebhookUpdate.d.mts +14 -0
- package/dist/esm/api/types/WebhookUpdate.mjs +2 -0
- package/dist/esm/api/types/index.d.mts +10 -0
- package/dist/esm/api/types/index.mjs +10 -0
- package/dist/esm/auth/HeaderAuthProvider.d.mts +14 -10
- package/dist/esm/auth/HeaderAuthProvider.mjs +18 -9
- package/dist/esm/core/fetcher/EndpointSupplier.d.mts +2 -2
- package/dist/esm/core/fetcher/Fetcher.d.mts +1 -2
- package/dist/esm/core/headers.d.mts +2 -2
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +2 -2
- package/reference.md +304 -0
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./SearchSearchResponse.js"), exports);
|
|
@@ -12,7 +12,7 @@ export declare namespace SsOsClient {
|
|
|
12
12
|
*/
|
|
13
13
|
export declare class SsOsClient {
|
|
14
14
|
protected readonly _options: NormalizedClientOptionsWithAuth<SsOsClient.Options>;
|
|
15
|
-
constructor(options
|
|
15
|
+
constructor(options?: SsOsClient.Options);
|
|
16
16
|
/**
|
|
17
17
|
* Retrieve a paginated list of ssos. Use cursor for pagination.
|
|
18
18
|
*
|
|
@@ -66,7 +66,7 @@ const Forum = __importStar(require("../../../index.js"));
|
|
|
66
66
|
* Operations for sso
|
|
67
67
|
*/
|
|
68
68
|
class SsOsClient {
|
|
69
|
-
constructor(options) {
|
|
69
|
+
constructor(options = {}) {
|
|
70
70
|
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
71
71
|
}
|
|
72
72
|
/**
|
|
@@ -91,14 +91,11 @@ class SsOsClient {
|
|
|
91
91
|
__list() {
|
|
92
92
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
93
93
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
94
|
-
const {
|
|
95
|
-
const _queryParams = {
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
}
|
|
99
|
-
if (limit != null) {
|
|
100
|
-
_queryParams.limit = limit.toString();
|
|
101
|
-
}
|
|
94
|
+
const { limit, cursor } = request;
|
|
95
|
+
const _queryParams = {
|
|
96
|
+
limit,
|
|
97
|
+
cursor,
|
|
98
|
+
};
|
|
102
99
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
103
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);
|
|
104
101
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
@@ -10,6 +10,8 @@ export declare namespace UpdateSsOsResponse {
|
|
|
10
10
|
domain: string;
|
|
11
11
|
/** Whether SSO is active */
|
|
12
12
|
active: boolean;
|
|
13
|
+
/** Custom extended data */
|
|
14
|
+
extendedData: Record<string, unknown> | null;
|
|
13
15
|
/** SSO configuration creation timestamp */
|
|
14
16
|
createdAt: string;
|
|
15
17
|
/** SSO configuration last update timestamp */
|
|
@@ -12,7 +12,7 @@ export declare namespace TagsClient {
|
|
|
12
12
|
*/
|
|
13
13
|
export declare class TagsClient {
|
|
14
14
|
protected readonly _options: NormalizedClientOptionsWithAuth<TagsClient.Options>;
|
|
15
|
-
constructor(options
|
|
15
|
+
constructor(options?: TagsClient.Options);
|
|
16
16
|
/**
|
|
17
17
|
* Retrieve a paginated list of tags. Use cursor for pagination.
|
|
18
18
|
*
|
|
@@ -66,7 +66,7 @@ const Forum = __importStar(require("../../../index.js"));
|
|
|
66
66
|
* Operations for tags
|
|
67
67
|
*/
|
|
68
68
|
class TagsClient {
|
|
69
|
-
constructor(options) {
|
|
69
|
+
constructor(options = {}) {
|
|
70
70
|
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
71
71
|
}
|
|
72
72
|
/**
|
|
@@ -90,16 +90,11 @@ class TagsClient {
|
|
|
90
90
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
91
91
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
92
92
|
const { limit, cursor, search } = request;
|
|
93
|
-
const _queryParams = {
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
_queryParams.cursor = cursor;
|
|
99
|
-
}
|
|
100
|
-
if (search != null) {
|
|
101
|
-
_queryParams.search = search;
|
|
102
|
-
}
|
|
93
|
+
const _queryParams = {
|
|
94
|
+
limit,
|
|
95
|
+
cursor,
|
|
96
|
+
search,
|
|
97
|
+
};
|
|
103
98
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
104
99
|
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);
|
|
105
100
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
@@ -420,13 +415,10 @@ class TagsClient {
|
|
|
420
415
|
return __awaiter(this, void 0, void 0, function* () {
|
|
421
416
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
422
417
|
const { id, limit, cursor } = request;
|
|
423
|
-
const _queryParams = {
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
}
|
|
427
|
-
if (cursor != null) {
|
|
428
|
-
_queryParams.cursor = cursor;
|
|
429
|
-
}
|
|
418
|
+
const _queryParams = {
|
|
419
|
+
limit,
|
|
420
|
+
cursor,
|
|
421
|
+
};
|
|
430
422
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
431
423
|
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);
|
|
432
424
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
@@ -12,7 +12,7 @@ export declare namespace ThreadsClient {
|
|
|
12
12
|
*/
|
|
13
13
|
export declare class ThreadsClient {
|
|
14
14
|
protected readonly _options: NormalizedClientOptionsWithAuth<ThreadsClient.Options>;
|
|
15
|
-
constructor(options
|
|
15
|
+
constructor(options?: ThreadsClient.Options);
|
|
16
16
|
/**
|
|
17
17
|
* Retrieve a paginated list of threads. Use cursor for pagination.
|
|
18
18
|
*
|
|
@@ -66,7 +66,7 @@ const Forum = __importStar(require("../../../index.js"));
|
|
|
66
66
|
* Operations for threads
|
|
67
67
|
*/
|
|
68
68
|
class ThreadsClient {
|
|
69
|
-
constructor(options) {
|
|
69
|
+
constructor(options = {}) {
|
|
70
70
|
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
71
71
|
}
|
|
72
72
|
/**
|
|
@@ -90,25 +90,14 @@ class ThreadsClient {
|
|
|
90
90
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
91
91
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
92
92
|
const { limit, cursor, search, tagId, userId, sort } = request;
|
|
93
|
-
const _queryParams = {
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
_queryParams.search = search;
|
|
102
|
-
}
|
|
103
|
-
if (tagId != null) {
|
|
104
|
-
_queryParams.tagId = tagId;
|
|
105
|
-
}
|
|
106
|
-
if (userId != null) {
|
|
107
|
-
_queryParams.userId = userId;
|
|
108
|
-
}
|
|
109
|
-
if (sort != null) {
|
|
110
|
-
_queryParams.sort = sort;
|
|
111
|
-
}
|
|
93
|
+
const _queryParams = {
|
|
94
|
+
limit,
|
|
95
|
+
cursor,
|
|
96
|
+
search,
|
|
97
|
+
tagId,
|
|
98
|
+
userId,
|
|
99
|
+
sort: sort != null ? sort : undefined,
|
|
100
|
+
};
|
|
112
101
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
113
102
|
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);
|
|
114
103
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
@@ -430,25 +419,14 @@ class ThreadsClient {
|
|
|
430
419
|
return __awaiter(this, void 0, void 0, function* () {
|
|
431
420
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
432
421
|
const { id, limit, cursor, userId, sort, search, type: type_ } = request;
|
|
433
|
-
const _queryParams = {
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
_queryParams.userId = userId;
|
|
442
|
-
}
|
|
443
|
-
if (sort != null) {
|
|
444
|
-
_queryParams.sort = sort;
|
|
445
|
-
}
|
|
446
|
-
if (search != null) {
|
|
447
|
-
_queryParams.search = search;
|
|
448
|
-
}
|
|
449
|
-
if (type_ != null) {
|
|
450
|
-
_queryParams.type = type_;
|
|
451
|
-
}
|
|
422
|
+
const _queryParams = {
|
|
423
|
+
limit,
|
|
424
|
+
cursor,
|
|
425
|
+
userId,
|
|
426
|
+
sort: sort != null ? sort : undefined,
|
|
427
|
+
search,
|
|
428
|
+
type: type_ != null ? type_ : undefined,
|
|
429
|
+
};
|
|
452
430
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
453
431
|
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);
|
|
454
432
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
@@ -627,16 +605,11 @@ class ThreadsClient {
|
|
|
627
605
|
return __awaiter(this, void 0, void 0, function* () {
|
|
628
606
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
629
607
|
const { id, limit, cursor, type: type_ } = request;
|
|
630
|
-
const _queryParams = {
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
_queryParams.cursor = cursor;
|
|
636
|
-
}
|
|
637
|
-
if (type_ != null) {
|
|
638
|
-
_queryParams.type = type_;
|
|
639
|
-
}
|
|
608
|
+
const _queryParams = {
|
|
609
|
+
limit,
|
|
610
|
+
cursor,
|
|
611
|
+
type: type_ != null ? type_ : undefined,
|
|
612
|
+
};
|
|
640
613
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
641
614
|
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);
|
|
642
615
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
@@ -885,13 +858,10 @@ class ThreadsClient {
|
|
|
885
858
|
return __awaiter(this, void 0, void 0, function* () {
|
|
886
859
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
887
860
|
const { id, limit, cursor } = request;
|
|
888
|
-
const _queryParams = {
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
}
|
|
892
|
-
if (cursor != null) {
|
|
893
|
-
_queryParams.cursor = cursor;
|
|
894
|
-
}
|
|
861
|
+
const _queryParams = {
|
|
862
|
+
limit,
|
|
863
|
+
cursor,
|
|
864
|
+
};
|
|
895
865
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
896
866
|
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);
|
|
897
867
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
@@ -16,6 +16,12 @@ export interface CreateThreadsRequest {
|
|
|
16
16
|
tags?: string[];
|
|
17
17
|
/** Poll data */
|
|
18
18
|
poll?: CreateThreadsRequest.Poll;
|
|
19
|
+
/** Lock thread on creation */
|
|
20
|
+
locked?: boolean;
|
|
21
|
+
/** Pin thread on creation */
|
|
22
|
+
pinned?: boolean;
|
|
23
|
+
/** Custom extended data */
|
|
24
|
+
extendedData?: Record<string, unknown>;
|
|
19
25
|
}
|
|
20
26
|
export declare namespace CreateThreadsRequest {
|
|
21
27
|
/**
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export type { CreatePollThreadsRequest } from "./CreatePollThreadsRequest.js";
|
|
2
|
-
export
|
|
2
|
+
export { CreateReactionThreadsRequest } from "./CreateReactionThreadsRequest.js";
|
|
3
3
|
export type { CreateThreadsRequest } from "./CreateThreadsRequest.js";
|
|
4
4
|
export type { DeletePostThreadsRequest } from "./DeletePostThreadsRequest.js";
|
|
5
5
|
export type { DeleteReactionThreadsRequest } from "./DeleteReactionThreadsRequest.js";
|
|
@@ -1,2 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CreateReactionThreadsRequest = void 0;
|
|
4
|
+
var CreateReactionThreadsRequest_js_1 = require("./CreateReactionThreadsRequest.js");
|
|
5
|
+
Object.defineProperty(exports, "CreateReactionThreadsRequest", { enumerable: true, get: function () { return CreateReactionThreadsRequest_js_1.CreateReactionThreadsRequest; } });
|
|
@@ -13,21 +13,21 @@ export declare namespace UpdateThreadsResponse {
|
|
|
13
13
|
tags?: string[];
|
|
14
14
|
/** Poll data */
|
|
15
15
|
poll?: Data.Poll;
|
|
16
|
-
id: string;
|
|
17
|
-
/** URL-friendly identifier */
|
|
18
|
-
slug: string | null;
|
|
19
16
|
/** Whether thread is locked */
|
|
20
17
|
locked: boolean | null;
|
|
21
18
|
/** Whether thread is pinned */
|
|
22
19
|
pinned: boolean | null;
|
|
20
|
+
/** Custom metadata */
|
|
21
|
+
extendedData: Record<string, unknown> | null;
|
|
22
|
+
id: string;
|
|
23
|
+
/** URL-friendly identifier */
|
|
24
|
+
slug: string | null;
|
|
23
25
|
/** View count */
|
|
24
26
|
views: number;
|
|
25
27
|
/** Number of posts/replies */
|
|
26
28
|
postsCount: number;
|
|
27
29
|
/** Timestamp of the last post */
|
|
28
30
|
lastPostAt: string | null;
|
|
29
|
-
/** Custom metadata */
|
|
30
|
-
extendedData: Record<string, unknown> | null;
|
|
31
31
|
createdAt: string;
|
|
32
32
|
updatedAt: string;
|
|
33
33
|
}
|
|
@@ -12,7 +12,7 @@ export declare namespace UsersClient {
|
|
|
12
12
|
*/
|
|
13
13
|
export declare class UsersClient {
|
|
14
14
|
protected readonly _options: NormalizedClientOptionsWithAuth<UsersClient.Options>;
|
|
15
|
-
constructor(options
|
|
15
|
+
constructor(options?: UsersClient.Options);
|
|
16
16
|
/**
|
|
17
17
|
* Retrieve a paginated list of users. Use cursor for pagination.
|
|
18
18
|
*
|
|
@@ -29,6 +29,25 @@ export declare class UsersClient {
|
|
|
29
29
|
*/
|
|
30
30
|
list(request?: Forum.ListUsersRequest, requestOptions?: UsersClient.RequestOptions): core.HttpResponsePromise<Forum.UserListResponse>;
|
|
31
31
|
private __list;
|
|
32
|
+
/**
|
|
33
|
+
* Create a new user.
|
|
34
|
+
*
|
|
35
|
+
* @param {Forum.CreateUsersRequest} request
|
|
36
|
+
* @param {UsersClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
37
|
+
*
|
|
38
|
+
* @throws {@link Forum.BadRequestError}
|
|
39
|
+
* @throws {@link Forum.UnauthorizedError}
|
|
40
|
+
* @throws {@link Forum.PaymentRequiredError}
|
|
41
|
+
* @throws {@link Forum.TooManyRequestsError}
|
|
42
|
+
* @throws {@link Forum.InternalServerError}
|
|
43
|
+
*
|
|
44
|
+
* @example
|
|
45
|
+
* await client.users.create({
|
|
46
|
+
* username: "username"
|
|
47
|
+
* })
|
|
48
|
+
*/
|
|
49
|
+
create(request: Forum.CreateUsersRequest, requestOptions?: UsersClient.RequestOptions): core.HttpResponsePromise<Forum.UserResponse>;
|
|
50
|
+
private __create;
|
|
32
51
|
/**
|
|
33
52
|
* Retrieve a user by ID or slug (if supported).
|
|
34
53
|
*
|
|
@@ -66,7 +66,7 @@ const Forum = __importStar(require("../../../index.js"));
|
|
|
66
66
|
* Operations for users
|
|
67
67
|
*/
|
|
68
68
|
class UsersClient {
|
|
69
|
-
constructor(options) {
|
|
69
|
+
constructor(options = {}) {
|
|
70
70
|
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
71
71
|
}
|
|
72
72
|
/**
|
|
@@ -90,19 +90,12 @@ class UsersClient {
|
|
|
90
90
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
91
91
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
92
92
|
const { limit, cursor, search, sort } = request;
|
|
93
|
-
const _queryParams = {
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
}
|
|
100
|
-
if (search != null) {
|
|
101
|
-
_queryParams.search = search;
|
|
102
|
-
}
|
|
103
|
-
if (sort != null) {
|
|
104
|
-
_queryParams.sort = sort;
|
|
105
|
-
}
|
|
93
|
+
const _queryParams = {
|
|
94
|
+
limit,
|
|
95
|
+
cursor,
|
|
96
|
+
search,
|
|
97
|
+
sort: sort != null ? sort : undefined,
|
|
98
|
+
};
|
|
106
99
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
107
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);
|
|
108
101
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
@@ -140,6 +133,71 @@ class UsersClient {
|
|
|
140
133
|
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/users");
|
|
141
134
|
});
|
|
142
135
|
}
|
|
136
|
+
/**
|
|
137
|
+
* Create a new user.
|
|
138
|
+
*
|
|
139
|
+
* @param {Forum.CreateUsersRequest} request
|
|
140
|
+
* @param {UsersClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
141
|
+
*
|
|
142
|
+
* @throws {@link Forum.BadRequestError}
|
|
143
|
+
* @throws {@link Forum.UnauthorizedError}
|
|
144
|
+
* @throws {@link Forum.PaymentRequiredError}
|
|
145
|
+
* @throws {@link Forum.TooManyRequestsError}
|
|
146
|
+
* @throws {@link Forum.InternalServerError}
|
|
147
|
+
*
|
|
148
|
+
* @example
|
|
149
|
+
* await client.users.create({
|
|
150
|
+
* username: "username"
|
|
151
|
+
* })
|
|
152
|
+
*/
|
|
153
|
+
create(request, requestOptions) {
|
|
154
|
+
return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions));
|
|
155
|
+
}
|
|
156
|
+
__create(request, requestOptions) {
|
|
157
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
158
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
159
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
160
|
+
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);
|
|
161
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
162
|
+
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, "users"),
|
|
163
|
+
method: "POST",
|
|
164
|
+
headers: _headers,
|
|
165
|
+
contentType: "application/json",
|
|
166
|
+
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
167
|
+
requestType: "json",
|
|
168
|
+
body: request,
|
|
169
|
+
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,
|
|
170
|
+
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,
|
|
171
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
172
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
173
|
+
logging: this._options.logging,
|
|
174
|
+
});
|
|
175
|
+
if (_response.ok) {
|
|
176
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
177
|
+
}
|
|
178
|
+
if (_response.error.reason === "status-code") {
|
|
179
|
+
switch (_response.error.statusCode) {
|
|
180
|
+
case 400:
|
|
181
|
+
throw new Forum.BadRequestError(_response.error.body, _response.rawResponse);
|
|
182
|
+
case 401:
|
|
183
|
+
throw new Forum.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
184
|
+
case 402:
|
|
185
|
+
throw new Forum.PaymentRequiredError(_response.error.body, _response.rawResponse);
|
|
186
|
+
case 429:
|
|
187
|
+
throw new Forum.TooManyRequestsError(_response.error.body, _response.rawResponse);
|
|
188
|
+
case 500:
|
|
189
|
+
throw new Forum.InternalServerError(_response.error.body, _response.rawResponse);
|
|
190
|
+
default:
|
|
191
|
+
throw new errors.ForumError({
|
|
192
|
+
statusCode: _response.error.statusCode,
|
|
193
|
+
body: _response.error.body,
|
|
194
|
+
rawResponse: _response.rawResponse,
|
|
195
|
+
});
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/users");
|
|
199
|
+
});
|
|
200
|
+
}
|
|
143
201
|
/**
|
|
144
202
|
* Retrieve a user by ID or slug (if supported).
|
|
145
203
|
*
|
|
@@ -358,13 +416,10 @@ class UsersClient {
|
|
|
358
416
|
return __awaiter(this, void 0, void 0, function* () {
|
|
359
417
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
360
418
|
const { id, limit, cursor } = request;
|
|
361
|
-
const _queryParams = {
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
}
|
|
365
|
-
if (cursor != null) {
|
|
366
|
-
_queryParams.cursor = cursor;
|
|
367
|
-
}
|
|
419
|
+
const _queryParams = {
|
|
420
|
+
limit,
|
|
421
|
+
cursor,
|
|
422
|
+
};
|
|
368
423
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
369
424
|
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);
|
|
370
425
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
@@ -543,13 +598,10 @@ class UsersClient {
|
|
|
543
598
|
return __awaiter(this, void 0, void 0, function* () {
|
|
544
599
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
545
600
|
const { id, limit, cursor } = request;
|
|
546
|
-
const _queryParams = {
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
}
|
|
550
|
-
if (cursor != null) {
|
|
551
|
-
_queryParams.cursor = cursor;
|
|
552
|
-
}
|
|
601
|
+
const _queryParams = {
|
|
602
|
+
limit,
|
|
603
|
+
cursor,
|
|
604
|
+
};
|
|
553
605
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
554
606
|
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);
|
|
555
607
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @example
|
|
3
|
+
* {
|
|
4
|
+
* username: "username"
|
|
5
|
+
* }
|
|
6
|
+
*/
|
|
7
|
+
export interface CreateUsersRequest {
|
|
8
|
+
/** Username (letters, numbers, underscores, hyphens) */
|
|
9
|
+
username: string;
|
|
10
|
+
/** Email address */
|
|
11
|
+
email?: string;
|
|
12
|
+
/** Password (min 8 chars) */
|
|
13
|
+
password?: string;
|
|
14
|
+
/** Display name */
|
|
15
|
+
displayName?: string;
|
|
16
|
+
/** User bio */
|
|
17
|
+
bio?: string;
|
|
18
|
+
/** Forum signature */
|
|
19
|
+
signature?: string;
|
|
20
|
+
/** Website URL */
|
|
21
|
+
url?: string;
|
|
22
|
+
/** Role slugs to assign */
|
|
23
|
+
roles?: string[];
|
|
24
|
+
/** Custom extended data */
|
|
25
|
+
extendedData?: Record<string, unknown>;
|
|
26
|
+
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
export type { CreateUsersRequest } from "./CreateUsersRequest.js";
|
|
1
2
|
export type { DeleteFollowerUsersRequest } from "./DeleteFollowerUsersRequest.js";
|
|
2
3
|
export type { DeleteFollowingUsersRequest } from "./DeleteFollowingUsersRequest.js";
|
|
3
4
|
export type { DeleteUsersRequest } from "./DeleteUsersRequest.js";
|
|
@@ -12,7 +12,7 @@ export declare namespace WebhooksClient {
|
|
|
12
12
|
*/
|
|
13
13
|
export declare class WebhooksClient {
|
|
14
14
|
protected readonly _options: NormalizedClientOptionsWithAuth<WebhooksClient.Options>;
|
|
15
|
-
constructor(options
|
|
15
|
+
constructor(options?: WebhooksClient.Options);
|
|
16
16
|
/**
|
|
17
17
|
* Retrieve a paginated list of webhooks. Use cursor for pagination.
|
|
18
18
|
*
|
|
@@ -96,6 +96,28 @@ export declare class WebhooksClient {
|
|
|
96
96
|
*/
|
|
97
97
|
delete(request: Forum.DeleteWebhooksRequest, requestOptions?: WebhooksClient.RequestOptions): core.HttpResponsePromise<Forum.SuccessResponse>;
|
|
98
98
|
private __delete;
|
|
99
|
+
/**
|
|
100
|
+
* Update an existing webhook. Only provided fields will be modified.
|
|
101
|
+
*
|
|
102
|
+
* **Requires feature: webhooks**
|
|
103
|
+
*
|
|
104
|
+
* @param {Forum.UpdateWebhooksRequest} request
|
|
105
|
+
* @param {WebhooksClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
106
|
+
*
|
|
107
|
+
* @throws {@link Forum.BadRequestError}
|
|
108
|
+
* @throws {@link Forum.UnauthorizedError}
|
|
109
|
+
* @throws {@link Forum.PaymentRequiredError}
|
|
110
|
+
* @throws {@link Forum.NotFoundError}
|
|
111
|
+
* @throws {@link Forum.TooManyRequestsError}
|
|
112
|
+
* @throws {@link Forum.InternalServerError}
|
|
113
|
+
*
|
|
114
|
+
* @example
|
|
115
|
+
* await client.webhooks.update({
|
|
116
|
+
* id: "id"
|
|
117
|
+
* })
|
|
118
|
+
*/
|
|
119
|
+
update(request: Forum.UpdateWebhooksRequest, requestOptions?: WebhooksClient.RequestOptions): core.HttpResponsePromise<Forum.UpdateWebhooksResponse>;
|
|
120
|
+
private __update;
|
|
99
121
|
/**
|
|
100
122
|
* Retrieve a paginated list of deliveries for Webhook.
|
|
101
123
|
*
|