@amgix/amgix-client 1.0.0-beta3.2 → 1.1.0

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 (67) hide show
  1. package/README.md +8 -2
  2. package/dist/apis/AmgixApi.d.ts +74 -2
  3. package/dist/apis/AmgixApi.d.ts.map +1 -1
  4. package/dist/apis/AmgixApi.js +218 -92
  5. package/dist/models/BulkUploadRequest.d.ts +2 -2
  6. package/dist/models/BulkUploadRequest.js +2 -2
  7. package/dist/models/CollectionConfig.d.ts +2 -2
  8. package/dist/models/CollectionConfig.js +2 -2
  9. package/dist/models/CollectionExistsResponse.d.ts +2 -2
  10. package/dist/models/CollectionExistsResponse.js +2 -2
  11. package/dist/models/CustomDocumentVector.d.ts +3 -3
  12. package/dist/models/CustomDocumentVector.js +2 -2
  13. package/dist/models/CustomVector.d.ts +2 -2
  14. package/dist/models/CustomVector.js +2 -2
  15. package/dist/models/Document.d.ts +6 -5
  16. package/dist/models/Document.d.ts.map +1 -1
  17. package/dist/models/Document.js +3 -5
  18. package/dist/models/DocumentStatus.d.ts +3 -3
  19. package/dist/models/DocumentStatus.js +3 -3
  20. package/dist/models/DocumentStatusResponse.d.ts +2 -2
  21. package/dist/models/DocumentStatusResponse.js +2 -2
  22. package/dist/models/HTTPValidationError.d.ts +2 -2
  23. package/dist/models/HTTPValidationError.js +2 -2
  24. package/dist/models/LocationInner.d.ts +27 -0
  25. package/dist/models/LocationInner.d.ts.map +1 -0
  26. package/dist/models/LocationInner.js +38 -0
  27. package/dist/models/MetadataFilter.d.ts +3 -3
  28. package/dist/models/MetadataFilter.js +2 -2
  29. package/dist/models/MetadataIndex.d.ts +3 -3
  30. package/dist/models/MetadataIndex.js +2 -2
  31. package/dist/models/OkResponse.d.ts +2 -2
  32. package/dist/models/OkResponse.js +2 -2
  33. package/dist/models/QueueInfo.d.ts +2 -2
  34. package/dist/models/QueueInfo.js +2 -2
  35. package/dist/models/ReadyResponse.d.ts +2 -2
  36. package/dist/models/ReadyResponse.js +2 -2
  37. package/dist/models/SearchQuery.d.ts +22 -2
  38. package/dist/models/SearchQuery.d.ts.map +1 -1
  39. package/dist/models/SearchQuery.js +14 -2
  40. package/dist/models/SearchResult.d.ts +6 -5
  41. package/dist/models/SearchResult.d.ts.map +1 -1
  42. package/dist/models/SearchResult.js +3 -5
  43. package/dist/models/ValidationError.d.ts +5 -5
  44. package/dist/models/ValidationError.d.ts.map +1 -1
  45. package/dist/models/ValidationError.js +5 -5
  46. package/dist/models/ValidationErrorLocItem.d.ts +27 -0
  47. package/dist/models/ValidationErrorLocItem.d.ts.map +1 -0
  48. package/dist/models/ValidationErrorLocItem.js +38 -0
  49. package/dist/models/Vector.d.ts +2 -2
  50. package/dist/models/Vector.js +2 -2
  51. package/dist/models/VectorConfig.d.ts +5 -6
  52. package/dist/models/VectorConfig.d.ts.map +1 -1
  53. package/dist/models/VectorConfig.js +2 -4
  54. package/dist/models/VectorScore.d.ts +2 -2
  55. package/dist/models/VectorScore.js +2 -2
  56. package/dist/models/VectorSearchWeight.d.ts +3 -4
  57. package/dist/models/VectorSearchWeight.d.ts.map +1 -1
  58. package/dist/models/VectorSearchWeight.js +2 -4
  59. package/dist/models/VersionResponse.d.ts +2 -2
  60. package/dist/models/VersionResponse.js +2 -2
  61. package/dist/models/index.d.ts +1 -1
  62. package/dist/models/index.d.ts.map +1 -1
  63. package/dist/models/index.js +1 -1
  64. package/dist/runtime.d.ts +2 -2
  65. package/dist/runtime.d.ts.map +1 -1
  66. package/dist/runtime.js +17 -2
  67. package/package.json +1 -1
@@ -3,9 +3,9 @@
3
3
  /* eslint-disable */
4
4
  /**
5
5
  * Amalgam Index API
6
- * Amalgam Index (Amgix). The Hybrid Semantic Search Platform, API
6
+ * Amalgam Index (Amgix). Open-Source Hybrid Search System
7
7
  *
8
- * The version of the OpenAPI document: 1.0.0-beta3.2
8
+ * The version of the OpenAPI document: 1.1.0
9
9
  *
10
10
  *
11
11
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -54,10 +54,9 @@ const index_1 = require("../models/index");
54
54
  */
55
55
  class AmgixApi extends runtime.BaseAPI {
56
56
  /**
57
- * Check if a collection exists. Always returns 200 with exists true or false.
58
- * Collection Exists
57
+ * Creates request options for collectionExists without sending the request
59
58
  */
60
- async collectionExistsRaw(requestParameters, initOverrides) {
59
+ async collectionExistsRequestOpts(requestParameters) {
61
60
  if (requestParameters['collectionName'] == null) {
62
61
  throw new runtime.RequiredError('collectionName', 'Required parameter "collectionName" was null or undefined when calling collectionExists().');
63
62
  }
@@ -65,12 +64,20 @@ class AmgixApi extends runtime.BaseAPI {
65
64
  const headerParameters = {};
66
65
  let urlPath = `/v1/collections/{collection_name}/exists`;
67
66
  urlPath = urlPath.replace(`{${"collection_name"}}`, encodeURIComponent(String(requestParameters['collectionName'])));
68
- const response = await this.request({
67
+ return {
69
68
  path: urlPath,
70
69
  method: 'GET',
71
70
  headers: headerParameters,
72
71
  query: queryParameters,
73
- }, initOverrides);
72
+ };
73
+ }
74
+ /**
75
+ * Check if a collection exists. Always returns 200 with exists true or false.
76
+ * Collection Exists
77
+ */
78
+ async collectionExistsRaw(requestParameters, initOverrides) {
79
+ const requestOptions = await this.collectionExistsRequestOpts(requestParameters);
80
+ const response = await this.request(requestOptions, initOverrides);
74
81
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.CollectionExistsResponseFromJSON)(jsonValue));
75
82
  }
76
83
  /**
@@ -82,10 +89,9 @@ class AmgixApi extends runtime.BaseAPI {
82
89
  return await response.value();
83
90
  }
84
91
  /**
85
- * Create a new collection. This endpoint creates a new collection with the specified name and vector configurations. It validates the provided model configurations and ensures all required features are supported by the database. Args: collection_name: The unique name for the new collection (alphanumeric, underscores, hyphens only). config: Configuration details for the collection, including vector types and storage options. Returns: An `OkResponse` object indicating the success of the operation. Raises: HTTPException: - 400 if model validation fails or required features are not supported. - 409 if a collection with the same name already exists. - 500 if the collection creation fails in the database.
86
- * Create Collection
92
+ * Creates request options for createCollection without sending the request
87
93
  */
88
- async createCollectionRaw(requestParameters, initOverrides) {
94
+ async createCollectionRequestOpts(requestParameters) {
89
95
  if (requestParameters['collectionName'] == null) {
90
96
  throw new runtime.RequiredError('collectionName', 'Required parameter "collectionName" was null or undefined when calling createCollection().');
91
97
  }
@@ -97,13 +103,21 @@ class AmgixApi extends runtime.BaseAPI {
97
103
  headerParameters['Content-Type'] = 'application/json';
98
104
  let urlPath = `/v1/collections/{collection_name}`;
99
105
  urlPath = urlPath.replace(`{${"collection_name"}}`, encodeURIComponent(String(requestParameters['collectionName'])));
100
- const response = await this.request({
106
+ return {
101
107
  path: urlPath,
102
108
  method: 'POST',
103
109
  headers: headerParameters,
104
110
  query: queryParameters,
105
111
  body: (0, index_1.CollectionConfigToJSON)(requestParameters['collectionConfig']),
106
- }, initOverrides);
112
+ };
113
+ }
114
+ /**
115
+ * Create a new collection. This endpoint creates a new collection with the specified name and vector configurations. It validates the provided model configurations and ensures all required features are supported by the database. Args: collection_name: The unique name for the new collection (alphanumeric, underscores, hyphens only). config: Configuration details for the collection, including vector types and storage options. Returns: An `OkResponse` object indicating the success of the operation. Raises: HTTPException: - 400 if model validation fails or required features are not supported. - 409 if a collection with the same name already exists. - 500 if the collection creation fails in the database.
116
+ * Create Collection
117
+ */
118
+ async createCollectionRaw(requestParameters, initOverrides) {
119
+ const requestOptions = await this.createCollectionRequestOpts(requestParameters);
120
+ const response = await this.request(requestOptions, initOverrides);
107
121
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.OkResponseFromJSON)(jsonValue));
108
122
  }
109
123
  /**
@@ -115,10 +129,9 @@ class AmgixApi extends runtime.BaseAPI {
115
129
  return await response.value();
116
130
  }
117
131
  /**
118
- * Delete a collection. Deletes a collection and all its associated data. This operation is irreversible. Args: collection_name: The name of the collection to delete. Returns: An `OkResponse` object indicating the success of the operation.
119
- * Delete Collection
132
+ * Creates request options for deleteCollection without sending the request
120
133
  */
121
- async deleteCollectionRaw(requestParameters, initOverrides) {
134
+ async deleteCollectionRequestOpts(requestParameters) {
122
135
  if (requestParameters['collectionName'] == null) {
123
136
  throw new runtime.RequiredError('collectionName', 'Required parameter "collectionName" was null or undefined when calling deleteCollection().');
124
137
  }
@@ -126,12 +139,20 @@ class AmgixApi extends runtime.BaseAPI {
126
139
  const headerParameters = {};
127
140
  let urlPath = `/v1/collections/{collection_name}`;
128
141
  urlPath = urlPath.replace(`{${"collection_name"}}`, encodeURIComponent(String(requestParameters['collectionName'])));
129
- const response = await this.request({
142
+ return {
130
143
  path: urlPath,
131
144
  method: 'DELETE',
132
145
  headers: headerParameters,
133
146
  query: queryParameters,
134
- }, initOverrides);
147
+ };
148
+ }
149
+ /**
150
+ * Delete a collection. Deletes a collection and all its associated data. This operation is irreversible. Args: collection_name: The name of the collection to delete. Returns: An `OkResponse` object indicating the success of the operation.
151
+ * Delete Collection
152
+ */
153
+ async deleteCollectionRaw(requestParameters, initOverrides) {
154
+ const requestOptions = await this.deleteCollectionRequestOpts(requestParameters);
155
+ const response = await this.request(requestOptions, initOverrides);
135
156
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.OkResponseFromJSON)(jsonValue));
136
157
  }
137
158
  /**
@@ -143,10 +164,9 @@ class AmgixApi extends runtime.BaseAPI {
143
164
  return await response.value();
144
165
  }
145
166
  /**
146
- * Delete all queue entries for a collection. Removes all documents from the processing queue for a specified collection. This does not affect documents already indexed in the collection. Args: collection_name: The name of the collection for which to delete queue entries. Returns: An `OkResponse` object indicating the success of the operation.
147
- * Delete Collection Queue
167
+ * Creates request options for deleteCollectionQueue without sending the request
148
168
  */
149
- async deleteCollectionQueueRaw(requestParameters, initOverrides) {
169
+ async deleteCollectionQueueRequestOpts(requestParameters) {
150
170
  if (requestParameters['collectionName'] == null) {
151
171
  throw new runtime.RequiredError('collectionName', 'Required parameter "collectionName" was null or undefined when calling deleteCollectionQueue().');
152
172
  }
@@ -154,12 +174,20 @@ class AmgixApi extends runtime.BaseAPI {
154
174
  const headerParameters = {};
155
175
  let urlPath = `/v1/collections/{collection_name}/queue`;
156
176
  urlPath = urlPath.replace(`{${"collection_name"}}`, encodeURIComponent(String(requestParameters['collectionName'])));
157
- const response = await this.request({
177
+ return {
158
178
  path: urlPath,
159
179
  method: 'DELETE',
160
180
  headers: headerParameters,
161
181
  query: queryParameters,
162
- }, initOverrides);
182
+ };
183
+ }
184
+ /**
185
+ * Delete all queue entries for a collection. Removes all documents from the processing queue for a specified collection. This does not affect documents already indexed in the collection. Args: collection_name: The name of the collection for which to delete queue entries. Returns: An `OkResponse` object indicating the success of the operation.
186
+ * Delete Collection Queue
187
+ */
188
+ async deleteCollectionQueueRaw(requestParameters, initOverrides) {
189
+ const requestOptions = await this.deleteCollectionQueueRequestOpts(requestParameters);
190
+ const response = await this.request(requestOptions, initOverrides);
163
191
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.OkResponseFromJSON)(jsonValue));
164
192
  }
165
193
  /**
@@ -171,10 +199,9 @@ class AmgixApi extends runtime.BaseAPI {
171
199
  return await response.value();
172
200
  }
173
201
  /**
174
- * Delete a document. Deletes a specific document by its ID from the specified collection. Args: collection_name: The name of the collection. document_id: The unique identifier of the document to delete. Returns: An `OkResponse` object indicating the success of the operation.
175
- * Delete Document
202
+ * Creates request options for deleteDocument without sending the request
176
203
  */
177
- async deleteDocumentRaw(requestParameters, initOverrides) {
204
+ async deleteDocumentRequestOpts(requestParameters) {
178
205
  if (requestParameters['collectionName'] == null) {
179
206
  throw new runtime.RequiredError('collectionName', 'Required parameter "collectionName" was null or undefined when calling deleteDocument().');
180
207
  }
@@ -186,12 +213,20 @@ class AmgixApi extends runtime.BaseAPI {
186
213
  let urlPath = `/v1/collections/{collection_name}/documents/{document_id}`;
187
214
  urlPath = urlPath.replace(`{${"collection_name"}}`, encodeURIComponent(String(requestParameters['collectionName'])));
188
215
  urlPath = urlPath.replace(`{${"document_id"}}`, encodeURIComponent(String(requestParameters['documentId'])));
189
- const response = await this.request({
216
+ return {
190
217
  path: urlPath,
191
218
  method: 'DELETE',
192
219
  headers: headerParameters,
193
220
  query: queryParameters,
194
- }, initOverrides);
221
+ };
222
+ }
223
+ /**
224
+ * Delete a document. Deletes a specific document by its ID from the specified collection. Args: collection_name: The name of the collection. document_id: The unique identifier of the document to delete. Returns: An `OkResponse` object indicating the success of the operation.
225
+ * Delete Document
226
+ */
227
+ async deleteDocumentRaw(requestParameters, initOverrides) {
228
+ const requestOptions = await this.deleteDocumentRequestOpts(requestParameters);
229
+ const response = await this.request(requestOptions, initOverrides);
195
230
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.OkResponseFromJSON)(jsonValue));
196
231
  }
197
232
  /**
@@ -203,10 +238,9 @@ class AmgixApi extends runtime.BaseAPI {
203
238
  return await response.value();
204
239
  }
205
240
  /**
206
- * Empty a collection. Removes all documents and their associated vector data from a specified collection, but keeps the collection\'s configuration. Args: collection_name: The name of the collection to empty. Returns: An `OkResponse` object indicating the success of the operation.
207
- * Empty Collection
241
+ * Creates request options for emptyCollection without sending the request
208
242
  */
209
- async emptyCollectionRaw(requestParameters, initOverrides) {
243
+ async emptyCollectionRequestOpts(requestParameters) {
210
244
  if (requestParameters['collectionName'] == null) {
211
245
  throw new runtime.RequiredError('collectionName', 'Required parameter "collectionName" was null or undefined when calling emptyCollection().');
212
246
  }
@@ -214,12 +248,20 @@ class AmgixApi extends runtime.BaseAPI {
214
248
  const headerParameters = {};
215
249
  let urlPath = `/v1/collections/{collection_name}/empty`;
216
250
  urlPath = urlPath.replace(`{${"collection_name"}}`, encodeURIComponent(String(requestParameters['collectionName'])));
217
- const response = await this.request({
251
+ return {
218
252
  path: urlPath,
219
253
  method: 'POST',
220
254
  headers: headerParameters,
221
255
  query: queryParameters,
222
- }, initOverrides);
256
+ };
257
+ }
258
+ /**
259
+ * Empty a collection. Removes all documents and their associated vector data from a specified collection, but keeps the collection\'s configuration. Args: collection_name: The name of the collection to empty. Returns: An `OkResponse` object indicating the success of the operation.
260
+ * Empty Collection
261
+ */
262
+ async emptyCollectionRaw(requestParameters, initOverrides) {
263
+ const requestOptions = await this.emptyCollectionRequestOpts(requestParameters);
264
+ const response = await this.request(requestOptions, initOverrides);
223
265
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.OkResponseFromJSON)(jsonValue));
224
266
  }
225
267
  /**
@@ -231,10 +273,9 @@ class AmgixApi extends runtime.BaseAPI {
231
273
  return await response.value();
232
274
  }
233
275
  /**
234
- * Get collection configuration. Retrieves the configuration details for a specific collection. Args: collection_name: The name of the collection. Returns: The configuration of the specified collection.
235
- * Get Collection Config
276
+ * Creates request options for getCollectionConfig without sending the request
236
277
  */
237
- async getCollectionConfigRaw(requestParameters, initOverrides) {
278
+ async getCollectionConfigRequestOpts(requestParameters) {
238
279
  if (requestParameters['collectionName'] == null) {
239
280
  throw new runtime.RequiredError('collectionName', 'Required parameter "collectionName" was null or undefined when calling getCollectionConfig().');
240
281
  }
@@ -242,12 +283,20 @@ class AmgixApi extends runtime.BaseAPI {
242
283
  const headerParameters = {};
243
284
  let urlPath = `/v1/collections/{collection_name}`;
244
285
  urlPath = urlPath.replace(`{${"collection_name"}}`, encodeURIComponent(String(requestParameters['collectionName'])));
245
- const response = await this.request({
286
+ return {
246
287
  path: urlPath,
247
288
  method: 'GET',
248
289
  headers: headerParameters,
249
290
  query: queryParameters,
250
- }, initOverrides);
291
+ };
292
+ }
293
+ /**
294
+ * Get collection configuration. Retrieves the configuration details for a specific collection. Args: collection_name: The name of the collection. Returns: The configuration of the specified collection.
295
+ * Get Collection Config
296
+ */
297
+ async getCollectionConfigRaw(requestParameters, initOverrides) {
298
+ const requestOptions = await this.getCollectionConfigRequestOpts(requestParameters);
299
+ const response = await this.request(requestOptions, initOverrides);
251
300
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.CollectionConfigFromJSON)(jsonValue));
252
301
  }
253
302
  /**
@@ -259,10 +308,9 @@ class AmgixApi extends runtime.BaseAPI {
259
308
  return await response.value();
260
309
  }
261
310
  /**
262
- * Get queue statistics for a collection. Retrieves counts of documents in different queue states (queued, requeued, failed). Args: collection_name: The name of the collection. Returns: A `QueueInfo` object with counts for each queue state.
263
- * Get Collection Queue Info
311
+ * Creates request options for getCollectionQueueInfo without sending the request
264
312
  */
265
- async getCollectionQueueInfoRaw(requestParameters, initOverrides) {
313
+ async getCollectionQueueInfoRequestOpts(requestParameters) {
266
314
  if (requestParameters['collectionName'] == null) {
267
315
  throw new runtime.RequiredError('collectionName', 'Required parameter "collectionName" was null or undefined when calling getCollectionQueueInfo().');
268
316
  }
@@ -270,12 +318,20 @@ class AmgixApi extends runtime.BaseAPI {
270
318
  const headerParameters = {};
271
319
  let urlPath = `/v1/collections/{collection_name}/queue/info`;
272
320
  urlPath = urlPath.replace(`{${"collection_name"}}`, encodeURIComponent(String(requestParameters['collectionName'])));
273
- const response = await this.request({
321
+ return {
274
322
  path: urlPath,
275
323
  method: 'GET',
276
324
  headers: headerParameters,
277
325
  query: queryParameters,
278
- }, initOverrides);
326
+ };
327
+ }
328
+ /**
329
+ * Get queue statistics for a collection. Retrieves counts of documents in different queue states (queued, requeued, failed). Args: collection_name: The name of the collection. Returns: A `QueueInfo` object with counts for each queue state.
330
+ * Get Collection Queue Info
331
+ */
332
+ async getCollectionQueueInfoRaw(requestParameters, initOverrides) {
333
+ const requestOptions = await this.getCollectionQueueInfoRequestOpts(requestParameters);
334
+ const response = await this.request(requestOptions, initOverrides);
279
335
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.QueueInfoFromJSON)(jsonValue));
280
336
  }
281
337
  /**
@@ -287,10 +343,9 @@ class AmgixApi extends runtime.BaseAPI {
287
343
  return await response.value();
288
344
  }
289
345
  /**
290
- * Retrieve a single document. Retrieves a specific document by its ID from the specified collection. Args: collection_name: The name of the collection. document_id: The unique identifier of the document to retrieve. Returns: The retrieved `Document` object. Raises: HTTPException: 404 if the document is not found in the collection.
291
- * Get Document
346
+ * Creates request options for getDocument without sending the request
292
347
  */
293
- async getDocumentRaw(requestParameters, initOverrides) {
348
+ async getDocumentRequestOpts(requestParameters) {
294
349
  if (requestParameters['collectionName'] == null) {
295
350
  throw new runtime.RequiredError('collectionName', 'Required parameter "collectionName" was null or undefined when calling getDocument().');
296
351
  }
@@ -302,12 +357,20 @@ class AmgixApi extends runtime.BaseAPI {
302
357
  let urlPath = `/v1/collections/{collection_name}/documents/{document_id}`;
303
358
  urlPath = urlPath.replace(`{${"collection_name"}}`, encodeURIComponent(String(requestParameters['collectionName'])));
304
359
  urlPath = urlPath.replace(`{${"document_id"}}`, encodeURIComponent(String(requestParameters['documentId'])));
305
- const response = await this.request({
360
+ return {
306
361
  path: urlPath,
307
362
  method: 'GET',
308
363
  headers: headerParameters,
309
364
  query: queryParameters,
310
- }, initOverrides);
365
+ };
366
+ }
367
+ /**
368
+ * Retrieve a single document. Retrieves a specific document by its ID from the specified collection. Args: collection_name: The name of the collection. document_id: The unique identifier of the document to retrieve. Returns: The retrieved `Document` object. Raises: HTTPException: 404 if the document is not found in the collection.
369
+ * Get Document
370
+ */
371
+ async getDocumentRaw(requestParameters, initOverrides) {
372
+ const requestOptions = await this.getDocumentRequestOpts(requestParameters);
373
+ const response = await this.request(requestOptions, initOverrides);
311
374
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.DocumentFromJSON)(jsonValue));
312
375
  }
313
376
  /**
@@ -319,10 +382,9 @@ class AmgixApi extends runtime.BaseAPI {
319
382
  return await response.value();
320
383
  }
321
384
  /**
322
- * Get document processing status. Retrieves the processing status of a document, including its current state in the queue and any associated messages. Args: collection_name: The name of the collection. document_id: The unique identifier of the document. Returns: A `DocumentStatusResponse` object containing the processing status of the document. Raises: HTTPException: 404 if the document is not found in the collection\'s queue.
323
- * Get Document Status
385
+ * Creates request options for getDocumentStatus without sending the request
324
386
  */
325
- async getDocumentStatusRaw(requestParameters, initOverrides) {
387
+ async getDocumentStatusRequestOpts(requestParameters) {
326
388
  if (requestParameters['collectionName'] == null) {
327
389
  throw new runtime.RequiredError('collectionName', 'Required parameter "collectionName" was null or undefined when calling getDocumentStatus().');
328
390
  }
@@ -334,12 +396,20 @@ class AmgixApi extends runtime.BaseAPI {
334
396
  let urlPath = `/v1/collections/{collection_name}/documents/{document_id}/status`;
335
397
  urlPath = urlPath.replace(`{${"collection_name"}}`, encodeURIComponent(String(requestParameters['collectionName'])));
336
398
  urlPath = urlPath.replace(`{${"document_id"}}`, encodeURIComponent(String(requestParameters['documentId'])));
337
- const response = await this.request({
399
+ return {
338
400
  path: urlPath,
339
401
  method: 'GET',
340
402
  headers: headerParameters,
341
403
  query: queryParameters,
342
- }, initOverrides);
404
+ };
405
+ }
406
+ /**
407
+ * Get document processing status. Retrieves the processing status of a document, including its current state in the queue and any associated messages. Args: collection_name: The name of the collection. document_id: The unique identifier of the document. Returns: A `DocumentStatusResponse` object containing the processing status of the document. Raises: HTTPException: 404 if the document is not found in the collection\'s queue.
408
+ * Get Document Status
409
+ */
410
+ async getDocumentStatusRaw(requestParameters, initOverrides) {
411
+ const requestOptions = await this.getDocumentStatusRequestOpts(requestParameters);
412
+ const response = await this.request(requestOptions, initOverrides);
343
413
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.DocumentStatusResponseFromJSON)(jsonValue));
344
414
  }
345
415
  /**
@@ -351,19 +421,26 @@ class AmgixApi extends runtime.BaseAPI {
351
421
  return await response.value();
352
422
  }
353
423
  /**
354
- * Check API service responsiveness. This endpoint returns a simple \'ok\' status to indicate that the API service is running and able to respond to requests. Returns: An `OkResponse` object with the \'ok\' field set to True, confirming the service\'s responsiveness.
355
- * Health
424
+ * Creates request options for healthCheck without sending the request
356
425
  */
357
- async healthCheckRaw(initOverrides) {
426
+ async healthCheckRequestOpts() {
358
427
  const queryParameters = {};
359
428
  const headerParameters = {};
360
429
  let urlPath = `/v1/health/check`;
361
- const response = await this.request({
430
+ return {
362
431
  path: urlPath,
363
432
  method: 'GET',
364
433
  headers: headerParameters,
365
434
  query: queryParameters,
366
- }, initOverrides);
435
+ };
436
+ }
437
+ /**
438
+ * Check API service responsiveness. This endpoint returns a simple \'ok\' status to indicate that the API service is running and able to respond to requests. Returns: An `OkResponse` object with the \'ok\' field set to True, confirming the service\'s responsiveness.
439
+ * Health
440
+ */
441
+ async healthCheckRaw(initOverrides) {
442
+ const requestOptions = await this.healthCheckRequestOpts();
443
+ const response = await this.request(requestOptions, initOverrides);
367
444
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.OkResponseFromJSON)(jsonValue));
368
445
  }
369
446
  /**
@@ -375,19 +452,26 @@ class AmgixApi extends runtime.BaseAPI {
375
452
  return await response.value();
376
453
  }
377
454
  /**
378
- * Check if service is ready to handle requests. Runs four probes: database, rabbitmq, encoder (ping-encoder), rpc (ping-rpc). Returns 200 if all pass (fully ready), 218 if some fail (partial ready). Response body always includes all four probe results and a ready flag.
379
- * Readiness Check
455
+ * Creates request options for healthReady without sending the request
380
456
  */
381
- async healthReadyRaw(initOverrides) {
457
+ async healthReadyRequestOpts() {
382
458
  const queryParameters = {};
383
459
  const headerParameters = {};
384
460
  let urlPath = `/v1/health/ready`;
385
- const response = await this.request({
461
+ return {
386
462
  path: urlPath,
387
463
  method: 'GET',
388
464
  headers: headerParameters,
389
465
  query: queryParameters,
390
- }, initOverrides);
466
+ };
467
+ }
468
+ /**
469
+ * Check if service is ready to handle requests. Runs four probes: database, rabbitmq, encoder (ping-encoder), rpc (ping-rpc). Returns 200 if all pass (fully ready), 218 if some fail (partial ready). Response body always includes all four probe results and a ready flag.
470
+ * Readiness Check
471
+ */
472
+ async healthReadyRaw(initOverrides) {
473
+ const requestOptions = await this.healthReadyRequestOpts();
474
+ const response = await this.request(requestOptions, initOverrides);
391
475
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.ReadyResponseFromJSON)(jsonValue));
392
476
  }
393
477
  /**
@@ -399,19 +483,26 @@ class AmgixApi extends runtime.BaseAPI {
399
483
  return await response.value();
400
484
  }
401
485
  /**
402
- * List all available collections. Retrieves a list of all collections managed by the application. Returns: A list of strings, where each string is the name of an available collection.
403
- * List Collections
486
+ * Creates request options for listCollections without sending the request
404
487
  */
405
- async listCollectionsRaw(initOverrides) {
488
+ async listCollectionsRequestOpts() {
406
489
  const queryParameters = {};
407
490
  const headerParameters = {};
408
491
  let urlPath = `/v1/collections`;
409
- const response = await this.request({
492
+ return {
410
493
  path: urlPath,
411
494
  method: 'GET',
412
495
  headers: headerParameters,
413
496
  query: queryParameters,
414
- }, initOverrides);
497
+ };
498
+ }
499
+ /**
500
+ * List all available collections. Retrieves a list of all collections managed by the application. Returns: A list of strings, where each string is the name of an available collection.
501
+ * List Collections
502
+ */
503
+ async listCollectionsRaw(initOverrides) {
504
+ const requestOptions = await this.listCollectionsRequestOpts();
505
+ const response = await this.request(requestOptions, initOverrides);
415
506
  return new runtime.JSONApiResponse(response);
416
507
  }
417
508
  /**
@@ -423,10 +514,9 @@ class AmgixApi extends runtime.BaseAPI {
423
514
  return await response.value();
424
515
  }
425
516
  /**
426
- * Perform a search query on a collection. Executes a search query against the specified collection. Args: collection_name: The name of the collection to search. query: The `SearchQuery` object containing the search text, filters, and other parameters. Returns: A list of `SearchResult` objects, where each object represents a search result.
427
- * Search
517
+ * Creates request options for search without sending the request
428
518
  */
429
- async searchRaw(requestParameters, initOverrides) {
519
+ async searchRequestOpts(requestParameters) {
430
520
  if (requestParameters['collectionName'] == null) {
431
521
  throw new runtime.RequiredError('collectionName', 'Required parameter "collectionName" was null or undefined when calling search().');
432
522
  }
@@ -438,13 +528,21 @@ class AmgixApi extends runtime.BaseAPI {
438
528
  headerParameters['Content-Type'] = 'application/json';
439
529
  let urlPath = `/v1/collections/{collection_name}/search`;
440
530
  urlPath = urlPath.replace(`{${"collection_name"}}`, encodeURIComponent(String(requestParameters['collectionName'])));
441
- const response = await this.request({
531
+ return {
442
532
  path: urlPath,
443
533
  method: 'POST',
444
534
  headers: headerParameters,
445
535
  query: queryParameters,
446
536
  body: (0, index_1.SearchQueryToJSON)(requestParameters['searchQuery']),
447
- }, initOverrides);
537
+ };
538
+ }
539
+ /**
540
+ * Perform a search query on a collection. Executes a search query against the specified collection. Args: collection_name: The name of the collection to search. query: The `SearchQuery` object containing the search text, filters, and other parameters. Returns: A list of `SearchResult` objects, where each object represents a search result.
541
+ * Search
542
+ */
543
+ async searchRaw(requestParameters, initOverrides) {
544
+ const requestOptions = await this.searchRequestOpts(requestParameters);
545
+ const response = await this.request(requestOptions, initOverrides);
448
546
  return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(index_1.SearchResultFromJSON));
449
547
  }
450
548
  /**
@@ -456,10 +554,9 @@ class AmgixApi extends runtime.BaseAPI {
456
554
  return await response.value();
457
555
  }
458
556
  /**
459
- * Upsert a single document asynchronously. Adds or updates a single document in the specified collection by placing it into a processing queue. The document will be vectorized and indexed asynchronously. Args: collection_name: The name of the collection to upsert the document into. document: The document object to be upserted. Returns: An `OkResponse` object indicating that the document has been accepted for processing. Raises: HTTPException: 500 if publishing the event to the internal queue fails.
460
- * Upsert Document
557
+ * Creates request options for upsertDocument without sending the request
461
558
  */
462
- async upsertDocumentRaw(requestParameters, initOverrides) {
559
+ async upsertDocumentRequestOpts(requestParameters) {
463
560
  if (requestParameters['collectionName'] == null) {
464
561
  throw new runtime.RequiredError('collectionName', 'Required parameter "collectionName" was null or undefined when calling upsertDocument().');
465
562
  }
@@ -471,13 +568,21 @@ class AmgixApi extends runtime.BaseAPI {
471
568
  headerParameters['Content-Type'] = 'application/json';
472
569
  let urlPath = `/v1/collections/{collection_name}/documents`;
473
570
  urlPath = urlPath.replace(`{${"collection_name"}}`, encodeURIComponent(String(requestParameters['collectionName'])));
474
- const response = await this.request({
571
+ return {
475
572
  path: urlPath,
476
573
  method: 'POST',
477
574
  headers: headerParameters,
478
575
  query: queryParameters,
479
576
  body: (0, index_1.DocumentToJSON)(requestParameters['document']),
480
- }, initOverrides);
577
+ };
578
+ }
579
+ /**
580
+ * Upsert a single document asynchronously. Adds or updates a single document in the specified collection by placing it into a processing queue. The document will be vectorized and indexed asynchronously. Args: collection_name: The name of the collection to upsert the document into. document: The document object to be upserted. Returns: An `OkResponse` object indicating that the document has been accepted for processing. Raises: HTTPException: 500 if publishing the event to the internal queue fails.
581
+ * Upsert Document
582
+ */
583
+ async upsertDocumentRaw(requestParameters, initOverrides) {
584
+ const requestOptions = await this.upsertDocumentRequestOpts(requestParameters);
585
+ const response = await this.request(requestOptions, initOverrides);
481
586
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.OkResponseFromJSON)(jsonValue));
482
587
  }
483
588
  /**
@@ -489,10 +594,9 @@ class AmgixApi extends runtime.BaseAPI {
489
594
  return await response.value();
490
595
  }
491
596
  /**
492
- * Upsert a single document synchronously. Adds or updates a single document in the specified collection and waits for the operation to complete, including vectorization and indexing. Args: collection_name: The name of the collection to upsert the document into. document: The document object to be upserted. Returns: An `OkResponse` object indicating the success of the operation. Raises: HTTPException: - 409 if a document with the same ID and newer timestamp already exists (conflict). - 500 for other internal server errors during processing.
493
- * Upsert Document Sync
597
+ * Creates request options for upsertDocumentSync without sending the request
494
598
  */
495
- async upsertDocumentSyncRaw(requestParameters, initOverrides) {
599
+ async upsertDocumentSyncRequestOpts(requestParameters) {
496
600
  if (requestParameters['collectionName'] == null) {
497
601
  throw new runtime.RequiredError('collectionName', 'Required parameter "collectionName" was null or undefined when calling upsertDocumentSync().');
498
602
  }
@@ -504,13 +608,21 @@ class AmgixApi extends runtime.BaseAPI {
504
608
  headerParameters['Content-Type'] = 'application/json';
505
609
  let urlPath = `/v1/collections/{collection_name}/documents/sync`;
506
610
  urlPath = urlPath.replace(`{${"collection_name"}}`, encodeURIComponent(String(requestParameters['collectionName'])));
507
- const response = await this.request({
611
+ return {
508
612
  path: urlPath,
509
613
  method: 'POST',
510
614
  headers: headerParameters,
511
615
  query: queryParameters,
512
616
  body: (0, index_1.DocumentToJSON)(requestParameters['document']),
513
- }, initOverrides);
617
+ };
618
+ }
619
+ /**
620
+ * Upsert a single document synchronously. Adds or updates a single document in the specified collection and waits for the operation to complete, including vectorization and indexing. Args: collection_name: The name of the collection to upsert the document into. document: The document object to be upserted. Returns: An `OkResponse` object indicating the success of the operation. Raises: HTTPException: - 409 if a document with the same ID and newer timestamp already exists (conflict). - 500 for other internal server errors during processing.
621
+ * Upsert Document Sync
622
+ */
623
+ async upsertDocumentSyncRaw(requestParameters, initOverrides) {
624
+ const requestOptions = await this.upsertDocumentSyncRequestOpts(requestParameters);
625
+ const response = await this.request(requestOptions, initOverrides);
514
626
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.OkResponseFromJSON)(jsonValue));
515
627
  }
516
628
  /**
@@ -522,10 +634,9 @@ class AmgixApi extends runtime.BaseAPI {
522
634
  return await response.value();
523
635
  }
524
636
  /**
525
- * Upsert multiple documents in bulk asynchronously. Adds or updates multiple documents in the specified collection by placing them into a processing queue. Documents will be vectorized and indexed asynchronously. This method is optimized for bulk operations. Args: collection_name: The name of the collection to upsert the documents into. request: A `BulkUploadRequest` object containing a list of `Document` objects to be upserted. Returns: An `OkResponse` object indicating that the documents have been accepted for processing. Raises: HTTPException: 500 if publishing events to the internal queue fails for any document.
526
- * Upsert Documents Bulk
637
+ * Creates request options for upsertDocumentsBulk without sending the request
527
638
  */
528
- async upsertDocumentsBulkRaw(requestParameters, initOverrides) {
639
+ async upsertDocumentsBulkRequestOpts(requestParameters) {
529
640
  if (requestParameters['collectionName'] == null) {
530
641
  throw new runtime.RequiredError('collectionName', 'Required parameter "collectionName" was null or undefined when calling upsertDocumentsBulk().');
531
642
  }
@@ -537,13 +648,21 @@ class AmgixApi extends runtime.BaseAPI {
537
648
  headerParameters['Content-Type'] = 'application/json';
538
649
  let urlPath = `/v1/collections/{collection_name}/documents/bulk`;
539
650
  urlPath = urlPath.replace(`{${"collection_name"}}`, encodeURIComponent(String(requestParameters['collectionName'])));
540
- const response = await this.request({
651
+ return {
541
652
  path: urlPath,
542
653
  method: 'POST',
543
654
  headers: headerParameters,
544
655
  query: queryParameters,
545
656
  body: (0, index_1.BulkUploadRequestToJSON)(requestParameters['bulkUploadRequest']),
546
- }, initOverrides);
657
+ };
658
+ }
659
+ /**
660
+ * Upsert multiple documents in bulk asynchronously. Adds or updates multiple documents in the specified collection by placing them into a processing queue. Documents will be vectorized and indexed asynchronously. This method is optimized for bulk operations. Args: collection_name: The name of the collection to upsert the documents into. request: A `BulkUploadRequest` object containing a list of `Document` objects to be upserted. Returns: An `OkResponse` object indicating that the documents have been accepted for processing. Raises: HTTPException: 500 if publishing events to the internal queue fails for any document.
661
+ * Upsert Documents Bulk
662
+ */
663
+ async upsertDocumentsBulkRaw(requestParameters, initOverrides) {
664
+ const requestOptions = await this.upsertDocumentsBulkRequestOpts(requestParameters);
665
+ const response = await this.request(requestOptions, initOverrides);
547
666
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.OkResponseFromJSON)(jsonValue));
548
667
  }
549
668
  /**
@@ -555,19 +674,26 @@ class AmgixApi extends runtime.BaseAPI {
555
674
  return await response.value();
556
675
  }
557
676
  /**
558
- * Return the system version. Returns: A `VersionResponse` object with the system version.
559
- * Version
677
+ * Creates request options for version without sending the request
560
678
  */
561
- async versionRaw(initOverrides) {
679
+ async versionRequestOpts() {
562
680
  const queryParameters = {};
563
681
  const headerParameters = {};
564
682
  let urlPath = `/v1/version`;
565
- const response = await this.request({
683
+ return {
566
684
  path: urlPath,
567
685
  method: 'GET',
568
686
  headers: headerParameters,
569
687
  query: queryParameters,
570
- }, initOverrides);
688
+ };
689
+ }
690
+ /**
691
+ * Return the system version. Returns: A `VersionResponse` object with the system version.
692
+ * Version
693
+ */
694
+ async versionRaw(initOverrides) {
695
+ const requestOptions = await this.versionRequestOpts();
696
+ const response = await this.request(requestOptions, initOverrides);
571
697
  return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.VersionResponseFromJSON)(jsonValue));
572
698
  }
573
699
  /**