@wildix/wim-knowledge-base-client 0.0.16 → 0.0.17

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.
@@ -206,6 +206,7 @@ const se_GetDocumentCommand = async (input, context) => {
206
206
  b.p('documentId', () => input.documentId, '{documentId}', false);
207
207
  const query = (0, smithy_client_1.map)({
208
208
  [_c]: [, input[_cI]],
209
+ [_wC]: [() => input.withChunks !== void 0, () => (input[_wC].toString())],
209
210
  });
210
211
  let body;
211
212
  b.m("GET")
@@ -643,6 +644,7 @@ const de_GetDocumentCommand = async (output, context) => {
643
644
  });
644
645
  const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context))), "body");
645
646
  const doc = (0, smithy_client_1.take)(data, {
647
+ 'chunks': smithy_client_1._json,
646
648
  'document': smithy_client_1._json,
647
649
  });
648
650
  Object.assign(contents, doc);
@@ -1119,3 +1121,4 @@ const _l = "limit";
1119
1121
  const _o = "offset";
1120
1122
  const _q = "query";
1121
1123
  const _sT = "syncType";
1124
+ const _wC = "withChunks";
@@ -192,6 +192,7 @@ export const se_GetDocumentCommand = async (input, context) => {
192
192
  b.p('documentId', () => input.documentId, '{documentId}', false);
193
193
  const query = map({
194
194
  [_c]: [, input[_cI]],
195
+ [_wC]: [() => input.withChunks !== void 0, () => (input[_wC].toString())],
195
196
  });
196
197
  let body;
197
198
  b.m("GET")
@@ -603,6 +604,7 @@ export const de_GetDocumentCommand = async (output, context) => {
603
604
  });
604
605
  const data = __expectNonNull((__expectObject(await parseBody(output.body, context))), "body");
605
606
  const doc = take(data, {
607
+ 'chunks': _json,
606
608
  'document': _json,
607
609
  });
608
610
  Object.assign(contents, doc);
@@ -1063,3 +1065,4 @@ const _l = "limit";
1063
1065
  const _o = "offset";
1064
1066
  const _q = "query";
1065
1067
  const _sT = "syncType";
1068
+ const _wC = "withChunks";
@@ -38,6 +38,7 @@ declare const GetDocumentCommand_base: {
38
38
  * companyId: "STRING_VALUE",
39
39
  * dataSourceId: "STRING_VALUE", // required
40
40
  * documentId: "STRING_VALUE", // required
41
+ * withChunks: true || false,
41
42
  * };
42
43
  * const command = new GetDocumentCommand(input);
43
44
  * const response = await client.send(command);
@@ -59,6 +60,15 @@ declare const GetDocumentCommand_base: {
59
60
  * // status: "draft" || "pending" || "processing" || "completed" || "failed", // required
60
61
  * // errorMessage: "STRING_VALUE",
61
62
  * // },
63
+ * // chunks: [ // ChunksList
64
+ * // { // ChunkItem
65
+ * // id: "STRING_VALUE", // required
66
+ * // documentId: "STRING_VALUE", // required
67
+ * // content: "STRING_VALUE", // required
68
+ * // createdAt: "STRING_VALUE", // required
69
+ * // updatedAt: "STRING_VALUE", // required
70
+ * // },
71
+ * // ],
62
72
  * // };
63
73
  *
64
74
  * ```
@@ -34,6 +34,24 @@ export declare class UnauthorizedException extends __BaseException {
34
34
  */
35
35
  constructor(opts: __ExceptionOptionType<UnauthorizedException, __BaseException>);
36
36
  }
37
+ /**
38
+ * @public
39
+ */
40
+ export interface ChunkItem {
41
+ /**
42
+ * The ID of the chunk. Example: 123e4567-e89b-12d3-a456-426614174000
43
+ * @public
44
+ */
45
+ id: string;
46
+ /**
47
+ * The ID of the document. Example: 123e4567-e89b-12d3-a456-426614174000
48
+ * @public
49
+ */
50
+ documentId: string;
51
+ content: string;
52
+ createdAt: string;
53
+ updatedAt: string;
54
+ }
37
55
  /**
38
56
  * @public
39
57
  */
@@ -732,12 +750,14 @@ export interface GetDocumentInput {
732
750
  * @public
733
751
  */
734
752
  documentId: string;
753
+ withChunks?: boolean | undefined;
735
754
  }
736
755
  /**
737
756
  * @public
738
757
  */
739
758
  export interface GetDocumentOutput {
740
759
  document: DocumentItem;
760
+ chunks?: (ChunkItem)[] | undefined;
741
761
  }
742
762
  /**
743
763
  * @public
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@wildix/wim-knowledge-base-client",
3
3
  "description": "@wildix/wim-knowledge-base-client client",
4
- "version": "0.0.16",
4
+ "version": "0.0.17",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "tsc -p tsconfig.cjs.json",