@wildix/wim-knowledge-base-client 0.0.7

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.
Files changed (112) hide show
  1. package/dist-cjs/KnowledgeBase.js +57 -0
  2. package/dist-cjs/KnowledgeBaseClient.js +41 -0
  3. package/dist-cjs/commands/CreateDataSourceCommand.js +21 -0
  4. package/dist-cjs/commands/CreateDocumentCommand.js +21 -0
  5. package/dist-cjs/commands/CreateKnowledgeBaseCommand.js +21 -0
  6. package/dist-cjs/commands/DeleteDataSourceCommand.js +21 -0
  7. package/dist-cjs/commands/DeleteDocumentCommand.js +21 -0
  8. package/dist-cjs/commands/DeleteKnowledgeBaseCommand.js +21 -0
  9. package/dist-cjs/commands/GetAuthorizationSessionForDataSourceCommand.js +21 -0
  10. package/dist-cjs/commands/GetDataSourceCommand.js +21 -0
  11. package/dist-cjs/commands/GetDocumentCommand.js +21 -0
  12. package/dist-cjs/commands/GetDocumentPresignedDownloadUrlCommand.js +21 -0
  13. package/dist-cjs/commands/GetDocumentPresignedUploadUrlCommand.js +21 -0
  14. package/dist-cjs/commands/GetKnowledgeBaseCommand.js +21 -0
  15. package/dist-cjs/commands/GetSyncLogsCommand.js +21 -0
  16. package/dist-cjs/commands/GetSyncStatusCommand.js +21 -0
  17. package/dist-cjs/commands/ListDataSourcesCommand.js +21 -0
  18. package/dist-cjs/commands/ListDocumentsCommand.js +21 -0
  19. package/dist-cjs/commands/ListKnowledgeBasesCommand.js +21 -0
  20. package/dist-cjs/commands/QueryKnowledgeBaseCommand.js +21 -0
  21. package/dist-cjs/commands/SearchKnowledgeBaseCommand.js +21 -0
  22. package/dist-cjs/commands/SyncDataSourceCommand.js +21 -0
  23. package/dist-cjs/commands/UpdateDataSourceCommand.js +21 -0
  24. package/dist-cjs/commands/UpdateDocumentCommand.js +21 -0
  25. package/dist-cjs/commands/UpdateKnowledgeBaseCommand.js +21 -0
  26. package/dist-cjs/commands/index.js +26 -0
  27. package/dist-cjs/extensionConfiguration.js +2 -0
  28. package/dist-cjs/index.js +10 -0
  29. package/dist-cjs/models/KnowledgeBaseServiceException.js +12 -0
  30. package/dist-cjs/models/index.js +4 -0
  31. package/dist-cjs/models/models_0.js +132 -0
  32. package/dist-cjs/protocols/Aws_restJson1.js +936 -0
  33. package/dist-cjs/runtimeConfig.browser.js +32 -0
  34. package/dist-cjs/runtimeConfig.js +37 -0
  35. package/dist-cjs/runtimeConfig.native.js +15 -0
  36. package/dist-cjs/runtimeConfig.shared.js +21 -0
  37. package/dist-cjs/runtimeExtensions.js +11 -0
  38. package/dist-es/KnowledgeBase.js +53 -0
  39. package/dist-es/KnowledgeBaseClient.js +37 -0
  40. package/dist-es/commands/CreateDataSourceCommand.js +17 -0
  41. package/dist-es/commands/CreateDocumentCommand.js +17 -0
  42. package/dist-es/commands/CreateKnowledgeBaseCommand.js +17 -0
  43. package/dist-es/commands/DeleteDataSourceCommand.js +17 -0
  44. package/dist-es/commands/DeleteDocumentCommand.js +17 -0
  45. package/dist-es/commands/DeleteKnowledgeBaseCommand.js +17 -0
  46. package/dist-es/commands/GetAuthorizationSessionForDataSourceCommand.js +17 -0
  47. package/dist-es/commands/GetDataSourceCommand.js +17 -0
  48. package/dist-es/commands/GetDocumentCommand.js +17 -0
  49. package/dist-es/commands/GetDocumentPresignedDownloadUrlCommand.js +17 -0
  50. package/dist-es/commands/GetDocumentPresignedUploadUrlCommand.js +17 -0
  51. package/dist-es/commands/GetKnowledgeBaseCommand.js +17 -0
  52. package/dist-es/commands/GetSyncLogsCommand.js +17 -0
  53. package/dist-es/commands/GetSyncStatusCommand.js +17 -0
  54. package/dist-es/commands/ListDataSourcesCommand.js +17 -0
  55. package/dist-es/commands/ListDocumentsCommand.js +17 -0
  56. package/dist-es/commands/ListKnowledgeBasesCommand.js +17 -0
  57. package/dist-es/commands/QueryKnowledgeBaseCommand.js +17 -0
  58. package/dist-es/commands/SearchKnowledgeBaseCommand.js +17 -0
  59. package/dist-es/commands/SyncDataSourceCommand.js +17 -0
  60. package/dist-es/commands/UpdateDataSourceCommand.js +17 -0
  61. package/dist-es/commands/UpdateDocumentCommand.js +17 -0
  62. package/dist-es/commands/UpdateKnowledgeBaseCommand.js +17 -0
  63. package/dist-es/commands/index.js +23 -0
  64. package/dist-es/extensionConfiguration.js +1 -0
  65. package/dist-es/index.js +5 -0
  66. package/dist-es/models/KnowledgeBaseServiceException.js +8 -0
  67. package/dist-es/models/index.js +1 -0
  68. package/dist-es/models/models_0.js +123 -0
  69. package/dist-es/protocols/Aws_restJson1.js +887 -0
  70. package/dist-es/runtimeConfig.browser.js +27 -0
  71. package/dist-es/runtimeConfig.js +32 -0
  72. package/dist-es/runtimeConfig.native.js +11 -0
  73. package/dist-es/runtimeConfig.shared.js +17 -0
  74. package/dist-es/runtimeExtensions.js +7 -0
  75. package/dist-types/KnowledgeBase.d.ts +172 -0
  76. package/dist-types/KnowledgeBaseClient.d.ts +166 -0
  77. package/dist-types/commands/CreateDataSourceCommand.d.ts +167 -0
  78. package/dist-types/commands/CreateDocumentCommand.d.ts +107 -0
  79. package/dist-types/commands/CreateKnowledgeBaseCommand.d.ts +99 -0
  80. package/dist-types/commands/DeleteDataSourceCommand.d.ts +83 -0
  81. package/dist-types/commands/DeleteDocumentCommand.d.ts +84 -0
  82. package/dist-types/commands/DeleteKnowledgeBaseCommand.d.ts +83 -0
  83. package/dist-types/commands/GetAuthorizationSessionForDataSourceCommand.d.ts +85 -0
  84. package/dist-types/commands/GetDataSourceCommand.d.ts +131 -0
  85. package/dist-types/commands/GetDocumentCommand.d.ts +102 -0
  86. package/dist-types/commands/GetDocumentPresignedDownloadUrlCommand.d.ts +87 -0
  87. package/dist-types/commands/GetDocumentPresignedUploadUrlCommand.d.ts +86 -0
  88. package/dist-types/commands/GetKnowledgeBaseCommand.d.ts +95 -0
  89. package/dist-types/commands/GetSyncLogsCommand.d.ts +91 -0
  90. package/dist-types/commands/GetSyncStatusCommand.d.ts +87 -0
  91. package/dist-types/commands/ListDataSourcesCommand.d.ts +132 -0
  92. package/dist-types/commands/ListDocumentsCommand.d.ts +103 -0
  93. package/dist-types/commands/ListKnowledgeBasesCommand.d.ts +96 -0
  94. package/dist-types/commands/QueryKnowledgeBaseCommand.d.ts +98 -0
  95. package/dist-types/commands/SearchKnowledgeBaseCommand.d.ts +99 -0
  96. package/dist-types/commands/SyncDataSourceCommand.d.ts +84 -0
  97. package/dist-types/commands/UpdateDataSourceCommand.d.ts +168 -0
  98. package/dist-types/commands/UpdateDocumentCommand.d.ts +108 -0
  99. package/dist-types/commands/UpdateKnowledgeBaseCommand.d.ts +100 -0
  100. package/dist-types/commands/index.d.ts +23 -0
  101. package/dist-types/extensionConfiguration.d.ts +7 -0
  102. package/dist-types/index.d.ts +7 -0
  103. package/dist-types/models/KnowledgeBaseServiceException.d.ts +14 -0
  104. package/dist-types/models/index.d.ts +1 -0
  105. package/dist-types/models/models_0.d.ts +981 -0
  106. package/dist-types/protocols/Aws_restJson1.d.ts +209 -0
  107. package/dist-types/runtimeConfig.browser.d.ts +31 -0
  108. package/dist-types/runtimeConfig.d.ts +31 -0
  109. package/dist-types/runtimeConfig.native.d.ts +30 -0
  110. package/dist-types/runtimeConfig.shared.d.ts +15 -0
  111. package/dist-types/runtimeExtensions.d.ts +17 -0
  112. package/package.json +83 -0
@@ -0,0 +1,132 @@
1
+ import { KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../KnowledgeBaseClient";
2
+ import { ListDataSourcesInput, ListDataSourcesOutput } from "../models/models_0";
3
+ import { Command as $Command } from "@smithy/smithy-client";
4
+ import { MetadataBearer as __MetadataBearer } from "@smithy/types";
5
+ /**
6
+ * @public
7
+ */
8
+ export type { __MetadataBearer };
9
+ export { $Command };
10
+ /**
11
+ * @public
12
+ *
13
+ * The input for {@link ListDataSourcesCommand}.
14
+ */
15
+ export interface ListDataSourcesCommandInput extends ListDataSourcesInput {
16
+ }
17
+ /**
18
+ * @public
19
+ *
20
+ * The output of {@link ListDataSourcesCommand}.
21
+ */
22
+ export interface ListDataSourcesCommandOutput extends ListDataSourcesOutput, __MetadataBearer {
23
+ }
24
+ declare const ListDataSourcesCommand_base: {
25
+ new (input: ListDataSourcesCommandInput): import("@smithy/smithy-client").CommandImpl<ListDataSourcesCommandInput, ListDataSourcesCommandOutput, KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
26
+ new (...[input]: [] | [ListDataSourcesCommandInput]): import("@smithy/smithy-client").CommandImpl<ListDataSourcesCommandInput, ListDataSourcesCommandOutput, KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
27
+ getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
28
+ };
29
+ /**
30
+ * List all data sources for the current company
31
+ * @example
32
+ * Use a bare-bones client and the command you need to make an API call.
33
+ * ```javascript
34
+ * import { KnowledgeBaseClient, ListDataSourcesCommand } from "@wildix/wim-knowledge-base-client"; // ES Modules import
35
+ * // const { KnowledgeBaseClient, ListDataSourcesCommand } = require("@wildix/wim-knowledge-base-client"); // CommonJS import
36
+ * const client = new KnowledgeBaseClient(config);
37
+ * const input = { // ListDataSourcesInput
38
+ * companyId: "STRING_VALUE",
39
+ * };
40
+ * const command = new ListDataSourcesCommand(input);
41
+ * const response = await client.send(command);
42
+ * // { // ListDataSourcesOutput
43
+ * // dataSources: [ // DataSourceList // required
44
+ * // { // DataSourceItem
45
+ * // name: "STRING_VALUE", // required
46
+ * // description: "STRING_VALUE",
47
+ * // type: "files" || "confluence" || "gdrive" || "proxy", // required
48
+ * // config: { // DataSourceConfig Union: only one key present
49
+ * // confluence: { // ConfluenceConfig
50
+ * // url: "STRING_VALUE", // required
51
+ * // username: "STRING_VALUE", // required
52
+ * // apiKey: "STRING_VALUE", // required
53
+ * // spaceId: "STRING_VALUE", // required
54
+ * // pages: { // ConfluencePagesConfig
55
+ * // enabled: [ // ConfluencePageIdsList // required
56
+ * // "STRING_VALUE",
57
+ * // ],
58
+ * // disabled: [ // required
59
+ * // "STRING_VALUE",
60
+ * // ],
61
+ * // },
62
+ * // },
63
+ * // gdrive: { // GDriveConfig
64
+ * // nangoConnectionId: "STRING_VALUE", // required
65
+ * // folders: { // GDriveFoldersConfig
66
+ * // enabled: [ // GDriveFolderIds // required
67
+ * // "STRING_VALUE",
68
+ * // ],
69
+ * // disabled: [ // required
70
+ * // "STRING_VALUE",
71
+ * // ],
72
+ * // },
73
+ * // },
74
+ * // files: { // UserFilesConfig
75
+ * // allowedExtensions: [ // StringList // required
76
+ * // "STRING_VALUE",
77
+ * // ],
78
+ * // },
79
+ * // },
80
+ * // enabled: true || false, // required
81
+ * // syncSchedule: "STRING_VALUE",
82
+ * // id: "STRING_VALUE", // required
83
+ * // companyId: "STRING_VALUE", // required
84
+ * // createdAt: "STRING_VALUE", // required
85
+ * // updatedAt: "STRING_VALUE", // required
86
+ * // syncStatus: "idle" || "running" || "success" || "failed", // required
87
+ * // lastSyncedAt: "STRING_VALUE",
88
+ * // lastSyncMode: "full" || "incremental" || "unknown",
89
+ * // lastSyncErrorMessage: "STRING_VALUE",
90
+ * // },
91
+ * // ],
92
+ * // };
93
+ *
94
+ * ```
95
+ *
96
+ * @param ListDataSourcesCommandInput - {@link ListDataSourcesCommandInput}
97
+ * @returns {@link ListDataSourcesCommandOutput}
98
+ * @see {@link ListDataSourcesCommandInput} for command's `input` shape.
99
+ * @see {@link ListDataSourcesCommandOutput} for command's `response` shape.
100
+ * @see {@link KnowledgeBaseClientResolvedConfig | config} for KnowledgeBaseClient's `config` shape.
101
+ *
102
+ * @throws {@link ValidationException} (client fault)
103
+ *
104
+ * @throws {@link UnauthorizedException} (client fault)
105
+ *
106
+ * @throws {@link ForbiddenException} (client fault)
107
+ *
108
+ * @throws {@link KnowledgeBaseNotFoundException} (client fault)
109
+ *
110
+ * @throws {@link DataSourceNotFoundException} (client fault)
111
+ *
112
+ * @throws {@link DocumentNotFoundException} (client fault)
113
+ *
114
+ * @throws {@link KnowledgeBaseServiceException}
115
+ * <p>Base exception class for all service exceptions from KnowledgeBase service.</p>
116
+ *
117
+ *
118
+ * @public
119
+ */
120
+ export declare class ListDataSourcesCommand extends ListDataSourcesCommand_base {
121
+ /** @internal type navigation helper, not in runtime. */
122
+ protected static __types: {
123
+ api: {
124
+ input: ListDataSourcesInput;
125
+ output: ListDataSourcesOutput;
126
+ };
127
+ sdk: {
128
+ input: ListDataSourcesCommandInput;
129
+ output: ListDataSourcesCommandOutput;
130
+ };
131
+ };
132
+ }
@@ -0,0 +1,103 @@
1
+ import { KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../KnowledgeBaseClient";
2
+ import { ListDocumentsInput, ListDocumentsOutput } from "../models/models_0";
3
+ import { Command as $Command } from "@smithy/smithy-client";
4
+ import { MetadataBearer as __MetadataBearer } from "@smithy/types";
5
+ /**
6
+ * @public
7
+ */
8
+ export type { __MetadataBearer };
9
+ export { $Command };
10
+ /**
11
+ * @public
12
+ *
13
+ * The input for {@link ListDocumentsCommand}.
14
+ */
15
+ export interface ListDocumentsCommandInput extends ListDocumentsInput {
16
+ }
17
+ /**
18
+ * @public
19
+ *
20
+ * The output of {@link ListDocumentsCommand}.
21
+ */
22
+ export interface ListDocumentsCommandOutput extends ListDocumentsOutput, __MetadataBearer {
23
+ }
24
+ declare const ListDocumentsCommand_base: {
25
+ new (input: ListDocumentsCommandInput): import("@smithy/smithy-client").CommandImpl<ListDocumentsCommandInput, ListDocumentsCommandOutput, KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
26
+ new (__0_0: ListDocumentsCommandInput): import("@smithy/smithy-client").CommandImpl<ListDocumentsCommandInput, ListDocumentsCommandOutput, KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
27
+ getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
28
+ };
29
+ /**
30
+ * List all documents for a data source by its ID
31
+ * @example
32
+ * Use a bare-bones client and the command you need to make an API call.
33
+ * ```javascript
34
+ * import { KnowledgeBaseClient, ListDocumentsCommand } from "@wildix/wim-knowledge-base-client"; // ES Modules import
35
+ * // const { KnowledgeBaseClient, ListDocumentsCommand } = require("@wildix/wim-knowledge-base-client"); // CommonJS import
36
+ * const client = new KnowledgeBaseClient(config);
37
+ * const input = { // ListDocumentsInput
38
+ * companyId: "STRING_VALUE",
39
+ * dataSourceId: "STRING_VALUE", // required
40
+ * };
41
+ * const command = new ListDocumentsCommand(input);
42
+ * const response = await client.send(command);
43
+ * // { // ListDocumentsOutput
44
+ * // documents: [ // DocumentList // required
45
+ * // { // DocumentItem
46
+ * // title: "STRING_VALUE", // required
47
+ * // url: "STRING_VALUE",
48
+ * // content: "STRING_VALUE",
49
+ * // originalFormat: "STRING_VALUE", // required
50
+ * // originalName: "STRING_VALUE", // required
51
+ * // originalId: "STRING_VALUE",
52
+ * // id: "STRING_VALUE", // required
53
+ * // companyId: "STRING_VALUE", // required
54
+ * // dataSourceId: "STRING_VALUE", // required
55
+ * // s3OriginalKey: "STRING_VALUE",
56
+ * // s3MarkdownKey: "STRING_VALUE",
57
+ * // createdAt: "STRING_VALUE", // required
58
+ * // updatedAt: "STRING_VALUE", // required
59
+ * // status: "pending" || "processing" || "completed" || "failed", // required
60
+ * // errorMessage: "STRING_VALUE",
61
+ * // },
62
+ * // ],
63
+ * // };
64
+ *
65
+ * ```
66
+ *
67
+ * @param ListDocumentsCommandInput - {@link ListDocumentsCommandInput}
68
+ * @returns {@link ListDocumentsCommandOutput}
69
+ * @see {@link ListDocumentsCommandInput} for command's `input` shape.
70
+ * @see {@link ListDocumentsCommandOutput} for command's `response` shape.
71
+ * @see {@link KnowledgeBaseClientResolvedConfig | config} for KnowledgeBaseClient's `config` shape.
72
+ *
73
+ * @throws {@link ValidationException} (client fault)
74
+ *
75
+ * @throws {@link UnauthorizedException} (client fault)
76
+ *
77
+ * @throws {@link ForbiddenException} (client fault)
78
+ *
79
+ * @throws {@link KnowledgeBaseNotFoundException} (client fault)
80
+ *
81
+ * @throws {@link DataSourceNotFoundException} (client fault)
82
+ *
83
+ * @throws {@link DocumentNotFoundException} (client fault)
84
+ *
85
+ * @throws {@link KnowledgeBaseServiceException}
86
+ * <p>Base exception class for all service exceptions from KnowledgeBase service.</p>
87
+ *
88
+ *
89
+ * @public
90
+ */
91
+ export declare class ListDocumentsCommand extends ListDocumentsCommand_base {
92
+ /** @internal type navigation helper, not in runtime. */
93
+ protected static __types: {
94
+ api: {
95
+ input: ListDocumentsInput;
96
+ output: ListDocumentsOutput;
97
+ };
98
+ sdk: {
99
+ input: ListDocumentsCommandInput;
100
+ output: ListDocumentsCommandOutput;
101
+ };
102
+ };
103
+ }
@@ -0,0 +1,96 @@
1
+ import { KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../KnowledgeBaseClient";
2
+ import { ListKnowledgeBasesInput, ListKnowledgeBasesOutput } from "../models/models_0";
3
+ import { Command as $Command } from "@smithy/smithy-client";
4
+ import { MetadataBearer as __MetadataBearer } from "@smithy/types";
5
+ /**
6
+ * @public
7
+ */
8
+ export type { __MetadataBearer };
9
+ export { $Command };
10
+ /**
11
+ * @public
12
+ *
13
+ * The input for {@link ListKnowledgeBasesCommand}.
14
+ */
15
+ export interface ListKnowledgeBasesCommandInput extends ListKnowledgeBasesInput {
16
+ }
17
+ /**
18
+ * @public
19
+ *
20
+ * The output of {@link ListKnowledgeBasesCommand}.
21
+ */
22
+ export interface ListKnowledgeBasesCommandOutput extends ListKnowledgeBasesOutput, __MetadataBearer {
23
+ }
24
+ declare const ListKnowledgeBasesCommand_base: {
25
+ new (input: ListKnowledgeBasesCommandInput): import("@smithy/smithy-client").CommandImpl<ListKnowledgeBasesCommandInput, ListKnowledgeBasesCommandOutput, KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
26
+ new (...[input]: [] | [ListKnowledgeBasesCommandInput]): import("@smithy/smithy-client").CommandImpl<ListKnowledgeBasesCommandInput, ListKnowledgeBasesCommandOutput, KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
27
+ getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
28
+ };
29
+ /**
30
+ * List all knowledge bases for the current company
31
+ * @example
32
+ * Use a bare-bones client and the command you need to make an API call.
33
+ * ```javascript
34
+ * import { KnowledgeBaseClient, ListKnowledgeBasesCommand } from "@wildix/wim-knowledge-base-client"; // ES Modules import
35
+ * // const { KnowledgeBaseClient, ListKnowledgeBasesCommand } = require("@wildix/wim-knowledge-base-client"); // CommonJS import
36
+ * const client = new KnowledgeBaseClient(config);
37
+ * const input = { // ListKnowledgeBasesInput
38
+ * companyId: "STRING_VALUE",
39
+ * };
40
+ * const command = new ListKnowledgeBasesCommand(input);
41
+ * const response = await client.send(command);
42
+ * // { // ListKnowledgeBasesOutput
43
+ * // knowledgeBases: [ // KnowledgeBaseList // required
44
+ * // { // KnowledgeBaseItem
45
+ * // name: "STRING_VALUE", // required
46
+ * // description: "STRING_VALUE",
47
+ * // dataSources: [ // DataSourceIdsList // required
48
+ * // "STRING_VALUE",
49
+ * // ],
50
+ * // id: "STRING_VALUE", // required
51
+ * // companyId: "STRING_VALUE", // required
52
+ * // createdAt: "STRING_VALUE", // required
53
+ * // updatedAt: "STRING_VALUE", // required
54
+ * // },
55
+ * // ],
56
+ * // };
57
+ *
58
+ * ```
59
+ *
60
+ * @param ListKnowledgeBasesCommandInput - {@link ListKnowledgeBasesCommandInput}
61
+ * @returns {@link ListKnowledgeBasesCommandOutput}
62
+ * @see {@link ListKnowledgeBasesCommandInput} for command's `input` shape.
63
+ * @see {@link ListKnowledgeBasesCommandOutput} for command's `response` shape.
64
+ * @see {@link KnowledgeBaseClientResolvedConfig | config} for KnowledgeBaseClient's `config` shape.
65
+ *
66
+ * @throws {@link ValidationException} (client fault)
67
+ *
68
+ * @throws {@link UnauthorizedException} (client fault)
69
+ *
70
+ * @throws {@link ForbiddenException} (client fault)
71
+ *
72
+ * @throws {@link KnowledgeBaseNotFoundException} (client fault)
73
+ *
74
+ * @throws {@link DataSourceNotFoundException} (client fault)
75
+ *
76
+ * @throws {@link DocumentNotFoundException} (client fault)
77
+ *
78
+ * @throws {@link KnowledgeBaseServiceException}
79
+ * <p>Base exception class for all service exceptions from KnowledgeBase service.</p>
80
+ *
81
+ *
82
+ * @public
83
+ */
84
+ export declare class ListKnowledgeBasesCommand extends ListKnowledgeBasesCommand_base {
85
+ /** @internal type navigation helper, not in runtime. */
86
+ protected static __types: {
87
+ api: {
88
+ input: ListKnowledgeBasesInput;
89
+ output: ListKnowledgeBasesOutput;
90
+ };
91
+ sdk: {
92
+ input: ListKnowledgeBasesCommandInput;
93
+ output: ListKnowledgeBasesCommandOutput;
94
+ };
95
+ };
96
+ }
@@ -0,0 +1,98 @@
1
+ import { KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../KnowledgeBaseClient";
2
+ import { QueryKnowledgeBaseInput, QueryKnowledgeBaseOutput } from "../models/models_0";
3
+ import { Command as $Command } from "@smithy/smithy-client";
4
+ import { MetadataBearer as __MetadataBearer } from "@smithy/types";
5
+ /**
6
+ * @public
7
+ */
8
+ export type { __MetadataBearer };
9
+ export { $Command };
10
+ /**
11
+ * @public
12
+ *
13
+ * The input for {@link QueryKnowledgeBaseCommand}.
14
+ */
15
+ export interface QueryKnowledgeBaseCommandInput extends QueryKnowledgeBaseInput {
16
+ }
17
+ /**
18
+ * @public
19
+ *
20
+ * The output of {@link QueryKnowledgeBaseCommand}.
21
+ */
22
+ export interface QueryKnowledgeBaseCommandOutput extends QueryKnowledgeBaseOutput, __MetadataBearer {
23
+ }
24
+ declare const QueryKnowledgeBaseCommand_base: {
25
+ new (input: QueryKnowledgeBaseCommandInput): import("@smithy/smithy-client").CommandImpl<QueryKnowledgeBaseCommandInput, QueryKnowledgeBaseCommandOutput, KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
26
+ new (__0_0: QueryKnowledgeBaseCommandInput): import("@smithy/smithy-client").CommandImpl<QueryKnowledgeBaseCommandInput, QueryKnowledgeBaseCommandOutput, KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
27
+ getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
28
+ };
29
+ /**
30
+ * Query a knowledge base by its ID and return the answer from the LLM
31
+ * @example
32
+ * Use a bare-bones client and the command you need to make an API call.
33
+ * ```javascript
34
+ * import { KnowledgeBaseClient, QueryKnowledgeBaseCommand } from "@wildix/wim-knowledge-base-client"; // ES Modules import
35
+ * // const { KnowledgeBaseClient, QueryKnowledgeBaseCommand } = require("@wildix/wim-knowledge-base-client"); // CommonJS import
36
+ * const client = new KnowledgeBaseClient(config);
37
+ * const input = { // QueryKnowledgeBaseInput
38
+ * companyId: "STRING_VALUE",
39
+ * knowledgeBaseId: "STRING_VALUE", // required
40
+ * query: "STRING_VALUE", // required
41
+ * searchConfig: { // SearchConfig
42
+ * topK: Number("int"),
43
+ * threshold: Number("double"),
44
+ * searchStrategy: "bm25" || "vector" || "hybrid",
45
+ * },
46
+ * llmConfig: { // LlmConfig
47
+ * provider: "STRING_VALUE", // required
48
+ * model: "STRING_VALUE", // required
49
+ * temperature: Number("double"),
50
+ * systemPrompt: "STRING_VALUE",
51
+ * },
52
+ * };
53
+ * const command = new QueryKnowledgeBaseCommand(input);
54
+ * const response = await client.send(command);
55
+ * // { // QueryKnowledgeBaseOutput
56
+ * // result: "STRING_VALUE", // required
57
+ * // metadata: "DOCUMENT_VALUE", // required
58
+ * // };
59
+ *
60
+ * ```
61
+ *
62
+ * @param QueryKnowledgeBaseCommandInput - {@link QueryKnowledgeBaseCommandInput}
63
+ * @returns {@link QueryKnowledgeBaseCommandOutput}
64
+ * @see {@link QueryKnowledgeBaseCommandInput} for command's `input` shape.
65
+ * @see {@link QueryKnowledgeBaseCommandOutput} for command's `response` shape.
66
+ * @see {@link KnowledgeBaseClientResolvedConfig | config} for KnowledgeBaseClient's `config` shape.
67
+ *
68
+ * @throws {@link KnowledgeBaseNotFoundException} (client fault)
69
+ *
70
+ * @throws {@link UnauthorizedException} (client fault)
71
+ *
72
+ * @throws {@link ForbiddenException} (client fault)
73
+ *
74
+ * @throws {@link ValidationException} (client fault)
75
+ *
76
+ * @throws {@link DataSourceNotFoundException} (client fault)
77
+ *
78
+ * @throws {@link DocumentNotFoundException} (client fault)
79
+ *
80
+ * @throws {@link KnowledgeBaseServiceException}
81
+ * <p>Base exception class for all service exceptions from KnowledgeBase service.</p>
82
+ *
83
+ *
84
+ * @public
85
+ */
86
+ export declare class QueryKnowledgeBaseCommand extends QueryKnowledgeBaseCommand_base {
87
+ /** @internal type navigation helper, not in runtime. */
88
+ protected static __types: {
89
+ api: {
90
+ input: QueryKnowledgeBaseInput;
91
+ output: QueryKnowledgeBaseOutput;
92
+ };
93
+ sdk: {
94
+ input: QueryKnowledgeBaseCommandInput;
95
+ output: QueryKnowledgeBaseCommandOutput;
96
+ };
97
+ };
98
+ }
@@ -0,0 +1,99 @@
1
+ import { KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../KnowledgeBaseClient";
2
+ import { SearchKnowledgeBaseInput, SearchKnowledgeBaseOutput } from "../models/models_0";
3
+ import { Command as $Command } from "@smithy/smithy-client";
4
+ import { MetadataBearer as __MetadataBearer } from "@smithy/types";
5
+ /**
6
+ * @public
7
+ */
8
+ export type { __MetadataBearer };
9
+ export { $Command };
10
+ /**
11
+ * @public
12
+ *
13
+ * The input for {@link SearchKnowledgeBaseCommand}.
14
+ */
15
+ export interface SearchKnowledgeBaseCommandInput extends SearchKnowledgeBaseInput {
16
+ }
17
+ /**
18
+ * @public
19
+ *
20
+ * The output of {@link SearchKnowledgeBaseCommand}.
21
+ */
22
+ export interface SearchKnowledgeBaseCommandOutput extends SearchKnowledgeBaseOutput, __MetadataBearer {
23
+ }
24
+ declare const SearchKnowledgeBaseCommand_base: {
25
+ new (input: SearchKnowledgeBaseCommandInput): import("@smithy/smithy-client").CommandImpl<SearchKnowledgeBaseCommandInput, SearchKnowledgeBaseCommandOutput, KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
26
+ new (__0_0: SearchKnowledgeBaseCommandInput): import("@smithy/smithy-client").CommandImpl<SearchKnowledgeBaseCommandInput, SearchKnowledgeBaseCommandOutput, KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
27
+ getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
28
+ };
29
+ /**
30
+ * Search a knowledge base by its ID and return the chunks that match the query with its score
31
+ * @example
32
+ * Use a bare-bones client and the command you need to make an API call.
33
+ * ```javascript
34
+ * import { KnowledgeBaseClient, SearchKnowledgeBaseCommand } from "@wildix/wim-knowledge-base-client"; // ES Modules import
35
+ * // const { KnowledgeBaseClient, SearchKnowledgeBaseCommand } = require("@wildix/wim-knowledge-base-client"); // CommonJS import
36
+ * const client = new KnowledgeBaseClient(config);
37
+ * const input = { // SearchKnowledgeBaseInput
38
+ * companyId: "STRING_VALUE",
39
+ * knowledgeBaseId: "STRING_VALUE", // required
40
+ * query: "STRING_VALUE", // required
41
+ * searchConfig: { // SearchConfig
42
+ * topK: Number("int"),
43
+ * threshold: Number("double"),
44
+ * searchStrategy: "bm25" || "vector" || "hybrid",
45
+ * },
46
+ * };
47
+ * const command = new SearchKnowledgeBaseCommand(input);
48
+ * const response = await client.send(command);
49
+ * // { // SearchKnowledgeBaseOutput
50
+ * // results: [ // SearchKnowledgeBaseResults // required
51
+ * // { // SearchKnowledgeBaseResult
52
+ * // documentId: "STRING_VALUE", // required
53
+ * // score: Number("double"), // required
54
+ * // source: "STRING_VALUE", // required
55
+ * // content: "STRING_VALUE", // required
56
+ * // url: "STRING_VALUE", // required
57
+ * // },
58
+ * // ],
59
+ * // };
60
+ *
61
+ * ```
62
+ *
63
+ * @param SearchKnowledgeBaseCommandInput - {@link SearchKnowledgeBaseCommandInput}
64
+ * @returns {@link SearchKnowledgeBaseCommandOutput}
65
+ * @see {@link SearchKnowledgeBaseCommandInput} for command's `input` shape.
66
+ * @see {@link SearchKnowledgeBaseCommandOutput} for command's `response` shape.
67
+ * @see {@link KnowledgeBaseClientResolvedConfig | config} for KnowledgeBaseClient's `config` shape.
68
+ *
69
+ * @throws {@link KnowledgeBaseNotFoundException} (client fault)
70
+ *
71
+ * @throws {@link UnauthorizedException} (client fault)
72
+ *
73
+ * @throws {@link ForbiddenException} (client fault)
74
+ *
75
+ * @throws {@link ValidationException} (client fault)
76
+ *
77
+ * @throws {@link DataSourceNotFoundException} (client fault)
78
+ *
79
+ * @throws {@link DocumentNotFoundException} (client fault)
80
+ *
81
+ * @throws {@link KnowledgeBaseServiceException}
82
+ * <p>Base exception class for all service exceptions from KnowledgeBase service.</p>
83
+ *
84
+ *
85
+ * @public
86
+ */
87
+ export declare class SearchKnowledgeBaseCommand extends SearchKnowledgeBaseCommand_base {
88
+ /** @internal type navigation helper, not in runtime. */
89
+ protected static __types: {
90
+ api: {
91
+ input: SearchKnowledgeBaseInput;
92
+ output: SearchKnowledgeBaseOutput;
93
+ };
94
+ sdk: {
95
+ input: SearchKnowledgeBaseCommandInput;
96
+ output: SearchKnowledgeBaseCommandOutput;
97
+ };
98
+ };
99
+ }
@@ -0,0 +1,84 @@
1
+ import { KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../KnowledgeBaseClient";
2
+ import { SyncDataSourceInput, SyncDataSourceOutput } from "../models/models_0";
3
+ import { Command as $Command } from "@smithy/smithy-client";
4
+ import { MetadataBearer as __MetadataBearer } from "@smithy/types";
5
+ /**
6
+ * @public
7
+ */
8
+ export type { __MetadataBearer };
9
+ export { $Command };
10
+ /**
11
+ * @public
12
+ *
13
+ * The input for {@link SyncDataSourceCommand}.
14
+ */
15
+ export interface SyncDataSourceCommandInput extends SyncDataSourceInput {
16
+ }
17
+ /**
18
+ * @public
19
+ *
20
+ * The output of {@link SyncDataSourceCommand}.
21
+ */
22
+ export interface SyncDataSourceCommandOutput extends SyncDataSourceOutput, __MetadataBearer {
23
+ }
24
+ declare const SyncDataSourceCommand_base: {
25
+ new (input: SyncDataSourceCommandInput): import("@smithy/smithy-client").CommandImpl<SyncDataSourceCommandInput, SyncDataSourceCommandOutput, KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
26
+ new (__0_0: SyncDataSourceCommandInput): import("@smithy/smithy-client").CommandImpl<SyncDataSourceCommandInput, SyncDataSourceCommandOutput, KnowledgeBaseClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
27
+ getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
28
+ };
29
+ /**
30
+ * Sync a data source by its ID
31
+ * @example
32
+ * Use a bare-bones client and the command you need to make an API call.
33
+ * ```javascript
34
+ * import { KnowledgeBaseClient, SyncDataSourceCommand } from "@wildix/wim-knowledge-base-client"; // ES Modules import
35
+ * // const { KnowledgeBaseClient, SyncDataSourceCommand } = require("@wildix/wim-knowledge-base-client"); // CommonJS import
36
+ * const client = new KnowledgeBaseClient(config);
37
+ * const input = { // SyncDataSourceInput
38
+ * companyId: "STRING_VALUE",
39
+ * dataSourceId: "STRING_VALUE", // required
40
+ * syncType: "full" || "incremental" || "unknown", // required
41
+ * };
42
+ * const command = new SyncDataSourceCommand(input);
43
+ * const response = await client.send(command);
44
+ * // {};
45
+ *
46
+ * ```
47
+ *
48
+ * @param SyncDataSourceCommandInput - {@link SyncDataSourceCommandInput}
49
+ * @returns {@link SyncDataSourceCommandOutput}
50
+ * @see {@link SyncDataSourceCommandInput} for command's `input` shape.
51
+ * @see {@link SyncDataSourceCommandOutput} for command's `response` shape.
52
+ * @see {@link KnowledgeBaseClientResolvedConfig | config} for KnowledgeBaseClient's `config` shape.
53
+ *
54
+ * @throws {@link DataSourceNotFoundException} (client fault)
55
+ *
56
+ * @throws {@link UnauthorizedException} (client fault)
57
+ *
58
+ * @throws {@link ForbiddenException} (client fault)
59
+ *
60
+ * @throws {@link ValidationException} (client fault)
61
+ *
62
+ * @throws {@link KnowledgeBaseNotFoundException} (client fault)
63
+ *
64
+ * @throws {@link DocumentNotFoundException} (client fault)
65
+ *
66
+ * @throws {@link KnowledgeBaseServiceException}
67
+ * <p>Base exception class for all service exceptions from KnowledgeBase service.</p>
68
+ *
69
+ *
70
+ * @public
71
+ */
72
+ export declare class SyncDataSourceCommand extends SyncDataSourceCommand_base {
73
+ /** @internal type navigation helper, not in runtime. */
74
+ protected static __types: {
75
+ api: {
76
+ input: SyncDataSourceInput;
77
+ output: {};
78
+ };
79
+ sdk: {
80
+ input: SyncDataSourceCommandInput;
81
+ output: SyncDataSourceCommandOutput;
82
+ };
83
+ };
84
+ }