edge-impulse-api 1.72.20 → 1.72.22
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/build/library/sdk/api/rawDataApi.d.ts +79 -0
- package/build/library/sdk/api/rawDataApi.js +211 -0
- package/build/library/sdk/api/rawDataApi.js.map +1 -1
- package/build/library/sdk/model/getSampleMetadataFilterOptionsResponse.d.ts +39 -0
- package/build/library/sdk/model/getSampleMetadataFilterOptionsResponse.js +49 -0
- package/build/library/sdk/model/getSampleMetadataFilterOptionsResponse.js.map +1 -0
- package/build/library/sdk/model/metadataFilterOptions.d.ts +31 -0
- package/build/library/sdk/model/metadataFilterOptions.js +39 -0
- package/build/library/sdk/model/metadataFilterOptions.js.map +1 -0
- package/build/library/sdk/model/metadataFilterOptionsOptionsList.d.ts +26 -0
- package/build/library/sdk/model/metadataFilterOptionsOptionsList.js +34 -0
- package/build/library/sdk/model/metadataFilterOptionsOptionsList.js.map +1 -0
- package/build/library/sdk/model/models.d.ts +3 -0
- package/build/library/sdk/model/models.js +9 -0
- package/build/library/sdk/model/models.js.map +1 -1
- package/package.json +1 -1
|
@@ -30,6 +30,7 @@ import { GetDataExplorerSettingsResponse } from '../model/getDataExplorerSetting
|
|
|
30
30
|
import { GetDatasetRatioResponse } from '../model/getDatasetRatioResponse';
|
|
31
31
|
import { GetDiversityDataResponse } from '../model/getDiversityDataResponse';
|
|
32
32
|
import { GetLabelNoiseDataResponse } from '../model/getLabelNoiseDataResponse';
|
|
33
|
+
import { GetSampleMetadataFilterOptionsResponse } from '../model/getSampleMetadataFilterOptionsResponse';
|
|
33
34
|
import { GetSampleMetadataResponse } from '../model/getSampleMetadataResponse';
|
|
34
35
|
import { GetSampleResponse } from '../model/getSampleResponse';
|
|
35
36
|
import { HasDataExplorerFeaturesResponse } from '../model/hasDataExplorerFeaturesResponse';
|
|
@@ -78,6 +79,9 @@ type batchAddMetadataQueryParams = {
|
|
|
78
79
|
dataType?: 'audio' | 'image';
|
|
79
80
|
minId?: number;
|
|
80
81
|
maxId?: number;
|
|
82
|
+
metadata?: string;
|
|
83
|
+
minDate?: Date;
|
|
84
|
+
maxDate?: Date;
|
|
81
85
|
};
|
|
82
86
|
type batchClearMetadataQueryParams = {
|
|
83
87
|
category: RawDataCategory;
|
|
@@ -97,6 +101,9 @@ type batchClearMetadataQueryParams = {
|
|
|
97
101
|
dataType?: 'audio' | 'image';
|
|
98
102
|
minId?: number;
|
|
99
103
|
maxId?: number;
|
|
104
|
+
metadata?: string;
|
|
105
|
+
minDate?: Date;
|
|
106
|
+
maxDate?: Date;
|
|
100
107
|
};
|
|
101
108
|
type batchClearMetadataByKeyQueryParams = {
|
|
102
109
|
category: RawDataCategory;
|
|
@@ -116,6 +123,9 @@ type batchClearMetadataByKeyQueryParams = {
|
|
|
116
123
|
dataType?: 'audio' | 'image';
|
|
117
124
|
minId?: number;
|
|
118
125
|
maxId?: number;
|
|
126
|
+
metadata?: string;
|
|
127
|
+
minDate?: Date;
|
|
128
|
+
maxDate?: Date;
|
|
119
129
|
};
|
|
120
130
|
type batchDeleteQueryParams = {
|
|
121
131
|
category: RawDataCategory;
|
|
@@ -135,6 +145,9 @@ type batchDeleteQueryParams = {
|
|
|
135
145
|
dataType?: 'audio' | 'image';
|
|
136
146
|
minId?: number;
|
|
137
147
|
maxId?: number;
|
|
148
|
+
metadata?: string;
|
|
149
|
+
minDate?: Date;
|
|
150
|
+
maxDate?: Date;
|
|
138
151
|
};
|
|
139
152
|
type batchDisableQueryParams = {
|
|
140
153
|
category: RawDataCategory;
|
|
@@ -154,6 +167,9 @@ type batchDisableQueryParams = {
|
|
|
154
167
|
dataType?: 'audio' | 'image';
|
|
155
168
|
minId?: number;
|
|
156
169
|
maxId?: number;
|
|
170
|
+
metadata?: string;
|
|
171
|
+
minDate?: Date;
|
|
172
|
+
maxDate?: Date;
|
|
157
173
|
};
|
|
158
174
|
type batchEditLabelsQueryParams = {
|
|
159
175
|
category: RawDataCategory;
|
|
@@ -173,6 +189,9 @@ type batchEditLabelsQueryParams = {
|
|
|
173
189
|
dataType?: 'audio' | 'image';
|
|
174
190
|
minId?: number;
|
|
175
191
|
maxId?: number;
|
|
192
|
+
metadata?: string;
|
|
193
|
+
minDate?: Date;
|
|
194
|
+
maxDate?: Date;
|
|
176
195
|
};
|
|
177
196
|
type batchEnableQueryParams = {
|
|
178
197
|
category: RawDataCategory;
|
|
@@ -192,6 +211,9 @@ type batchEnableQueryParams = {
|
|
|
192
211
|
dataType?: 'audio' | 'image';
|
|
193
212
|
minId?: number;
|
|
194
213
|
maxId?: number;
|
|
214
|
+
metadata?: string;
|
|
215
|
+
minDate?: Date;
|
|
216
|
+
maxDate?: Date;
|
|
195
217
|
};
|
|
196
218
|
type batchMoveQueryParams = {
|
|
197
219
|
category: RawDataCategory;
|
|
@@ -211,6 +233,9 @@ type batchMoveQueryParams = {
|
|
|
211
233
|
dataType?: 'audio' | 'image';
|
|
212
234
|
minId?: number;
|
|
213
235
|
maxId?: number;
|
|
236
|
+
metadata?: string;
|
|
237
|
+
minDate?: Date;
|
|
238
|
+
maxDate?: Date;
|
|
214
239
|
};
|
|
215
240
|
type countSamplesQueryParams = {
|
|
216
241
|
category: RawDataCategory;
|
|
@@ -228,6 +253,9 @@ type countSamplesQueryParams = {
|
|
|
228
253
|
dataType?: 'audio' | 'image';
|
|
229
254
|
minId?: number;
|
|
230
255
|
maxId?: number;
|
|
256
|
+
metadata?: string;
|
|
257
|
+
minDate?: Date;
|
|
258
|
+
maxDate?: Date;
|
|
231
259
|
};
|
|
232
260
|
type getAllImportedFromQueryParams = {
|
|
233
261
|
limit?: number;
|
|
@@ -259,6 +287,11 @@ type getSampleAsVideoQueryParams = {
|
|
|
259
287
|
type getSampleMetadataQueryParams = {
|
|
260
288
|
category: RawDataCategory;
|
|
261
289
|
};
|
|
290
|
+
type getSampleMetadataFilterOptionsQueryParams = {
|
|
291
|
+
category: RawDataCategory;
|
|
292
|
+
limit?: number;
|
|
293
|
+
offset?: number;
|
|
294
|
+
};
|
|
262
295
|
type getSampleSliceQueryParams = {
|
|
263
296
|
sliceStart: number;
|
|
264
297
|
sliceEnd?: number;
|
|
@@ -294,6 +327,9 @@ type listSamplesQueryParams = {
|
|
|
294
327
|
dataType?: 'audio' | 'image';
|
|
295
328
|
minId?: number;
|
|
296
329
|
maxId?: number;
|
|
330
|
+
metadata?: string;
|
|
331
|
+
minDate?: Date;
|
|
332
|
+
maxDate?: Date;
|
|
297
333
|
};
|
|
298
334
|
export type uploadDataExplorerScreenshotFormParams = {
|
|
299
335
|
image: RequestFile;
|
|
@@ -346,6 +382,9 @@ export declare class RawDataApi {
|
|
|
346
382
|
* @param dataType Include only samples with a particular data type
|
|
347
383
|
* @param minId Include only samples with an ID >= this value
|
|
348
384
|
* @param maxId Include only samples with an ID < this value
|
|
385
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
386
|
+
* @param minDate Only include samples that where added after the date given
|
|
387
|
+
* @param maxDate Only include samples that were added before the date given
|
|
349
388
|
*/
|
|
350
389
|
batchAddMetadata(projectId: number, batchAddMetadataRequest: BatchAddMetadataRequest, queryParams: batchAddMetadataQueryParams, options?: {
|
|
351
390
|
headers: {
|
|
@@ -373,6 +412,9 @@ export declare class RawDataApi {
|
|
|
373
412
|
* @param dataType Include only samples with a particular data type
|
|
374
413
|
* @param minId Include only samples with an ID >= this value
|
|
375
414
|
* @param maxId Include only samples with an ID < this value
|
|
415
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
416
|
+
* @param minDate Only include samples that where added after the date given
|
|
417
|
+
* @param maxDate Only include samples that were added before the date given
|
|
376
418
|
*/
|
|
377
419
|
batchClearMetadata(projectId: number, queryParams: batchClearMetadataQueryParams, options?: {
|
|
378
420
|
headers: {
|
|
@@ -401,6 +443,9 @@ export declare class RawDataApi {
|
|
|
401
443
|
* @param dataType Include only samples with a particular data type
|
|
402
444
|
* @param minId Include only samples with an ID >= this value
|
|
403
445
|
* @param maxId Include only samples with an ID < this value
|
|
446
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
447
|
+
* @param minDate Only include samples that where added after the date given
|
|
448
|
+
* @param maxDate Only include samples that were added before the date given
|
|
404
449
|
*/
|
|
405
450
|
batchClearMetadataByKey(projectId: number, batchClearMetadataByKeyRequest: BatchClearMetadataByKeyRequest, queryParams: batchClearMetadataByKeyQueryParams, options?: {
|
|
406
451
|
headers: {
|
|
@@ -428,6 +473,9 @@ export declare class RawDataApi {
|
|
|
428
473
|
* @param dataType Include only samples with a particular data type
|
|
429
474
|
* @param minId Include only samples with an ID >= this value
|
|
430
475
|
* @param maxId Include only samples with an ID < this value
|
|
476
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
477
|
+
* @param minDate Only include samples that where added after the date given
|
|
478
|
+
* @param maxDate Only include samples that were added before the date given
|
|
431
479
|
*/
|
|
432
480
|
batchDelete(projectId: number, queryParams: batchDeleteQueryParams, options?: {
|
|
433
481
|
headers: {
|
|
@@ -455,6 +503,9 @@ export declare class RawDataApi {
|
|
|
455
503
|
* @param dataType Include only samples with a particular data type
|
|
456
504
|
* @param minId Include only samples with an ID >= this value
|
|
457
505
|
* @param maxId Include only samples with an ID < this value
|
|
506
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
507
|
+
* @param minDate Only include samples that where added after the date given
|
|
508
|
+
* @param maxDate Only include samples that were added before the date given
|
|
458
509
|
*/
|
|
459
510
|
batchDisable(projectId: number, queryParams: batchDisableQueryParams, options?: {
|
|
460
511
|
headers: {
|
|
@@ -483,6 +534,9 @@ export declare class RawDataApi {
|
|
|
483
534
|
* @param dataType Include only samples with a particular data type
|
|
484
535
|
* @param minId Include only samples with an ID >= this value
|
|
485
536
|
* @param maxId Include only samples with an ID < this value
|
|
537
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
538
|
+
* @param minDate Only include samples that where added after the date given
|
|
539
|
+
* @param maxDate Only include samples that were added before the date given
|
|
486
540
|
*/
|
|
487
541
|
batchEditLabels(projectId: number, editSampleLabelRequest: EditSampleLabelRequest, queryParams: batchEditLabelsQueryParams, options?: {
|
|
488
542
|
headers: {
|
|
@@ -510,6 +564,9 @@ export declare class RawDataApi {
|
|
|
510
564
|
* @param dataType Include only samples with a particular data type
|
|
511
565
|
* @param minId Include only samples with an ID >= this value
|
|
512
566
|
* @param maxId Include only samples with an ID < this value
|
|
567
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
568
|
+
* @param minDate Only include samples that where added after the date given
|
|
569
|
+
* @param maxDate Only include samples that were added before the date given
|
|
513
570
|
*/
|
|
514
571
|
batchEnable(projectId: number, queryParams: batchEnableQueryParams, options?: {
|
|
515
572
|
headers: {
|
|
@@ -538,6 +595,9 @@ export declare class RawDataApi {
|
|
|
538
595
|
* @param dataType Include only samples with a particular data type
|
|
539
596
|
* @param minId Include only samples with an ID >= this value
|
|
540
597
|
* @param maxId Include only samples with an ID < this value
|
|
598
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
599
|
+
* @param minDate Only include samples that where added after the date given
|
|
600
|
+
* @param maxDate Only include samples that were added before the date given
|
|
541
601
|
*/
|
|
542
602
|
batchMove(projectId: number, moveRawDataRequest: MoveRawDataRequest, queryParams: batchMoveQueryParams, options?: {
|
|
543
603
|
headers: {
|
|
@@ -595,6 +655,9 @@ export declare class RawDataApi {
|
|
|
595
655
|
* @param dataType Include only samples with a particular data type
|
|
596
656
|
* @param minId Include only samples with an ID >= this value
|
|
597
657
|
* @param maxId Include only samples with an ID < this value
|
|
658
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
659
|
+
* @param minDate Only include samples that where added after the date given
|
|
660
|
+
* @param maxDate Only include samples that were added before the date given
|
|
598
661
|
*/
|
|
599
662
|
countSamples(projectId: number, queryParams: countSamplesQueryParams, options?: {
|
|
600
663
|
headers: {
|
|
@@ -875,6 +938,19 @@ export declare class RawDataApi {
|
|
|
875
938
|
[name: string]: string;
|
|
876
939
|
};
|
|
877
940
|
}): Promise<GetSampleMetadataResponse>;
|
|
941
|
+
/**
|
|
942
|
+
* Get a list of unique key value pairs across all samples in a project that can be applied as filters to the /api/{projectId}/raw-data endpoint
|
|
943
|
+
* @summary Get project sample metadata filter options
|
|
944
|
+
* @param projectId Project ID
|
|
945
|
+
* @param category Which of the three acquisition categories to retrieve data from
|
|
946
|
+
* @param limit Maximum number of results
|
|
947
|
+
* @param offset Offset in results, can be used in conjunction with LimitResultsParameter to implement paging.
|
|
948
|
+
*/
|
|
949
|
+
getSampleMetadataFilterOptions(projectId: number, queryParams: getSampleMetadataFilterOptionsQueryParams, options?: {
|
|
950
|
+
headers: {
|
|
951
|
+
[name: string]: string;
|
|
952
|
+
};
|
|
953
|
+
}): Promise<GetSampleMetadataFilterOptionsResponse>;
|
|
878
954
|
/**
|
|
879
955
|
* Get a slice of a sample.
|
|
880
956
|
* @summary Get sample slice
|
|
@@ -961,6 +1037,9 @@ export declare class RawDataApi {
|
|
|
961
1037
|
* @param dataType Include only samples with a particular data type
|
|
962
1038
|
* @param minId Include only samples with an ID >= this value
|
|
963
1039
|
* @param maxId Include only samples with an ID < this value
|
|
1040
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
1041
|
+
* @param minDate Only include samples that where added after the date given
|
|
1042
|
+
* @param maxDate Only include samples that were added before the date given
|
|
964
1043
|
*/
|
|
965
1044
|
listSamples(projectId: number, queryParams: listSamplesQueryParams, options?: {
|
|
966
1045
|
headers: {
|
|
@@ -100,6 +100,9 @@ class RawDataApi {
|
|
|
100
100
|
* @param dataType Include only samples with a particular data type
|
|
101
101
|
* @param minId Include only samples with an ID >= this value
|
|
102
102
|
* @param maxId Include only samples with an ID < this value
|
|
103
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
104
|
+
* @param minDate Only include samples that where added after the date given
|
|
105
|
+
* @param maxDate Only include samples that were added before the date given
|
|
103
106
|
*/
|
|
104
107
|
async batchAddMetadata(projectId, batchAddMetadataRequest, queryParams, options = { headers: {} }) {
|
|
105
108
|
const localVarPath = this.basePath + '/api/{projectId}/raw-data/batch/add-metadata'
|
|
@@ -180,6 +183,15 @@ class RawDataApi {
|
|
|
180
183
|
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxId) !== undefined) {
|
|
181
184
|
localVarQueryParameters['maxId'] = models_1.ObjectSerializer.serialize(queryParams.maxId, "number");
|
|
182
185
|
}
|
|
186
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.metadata) !== undefined) {
|
|
187
|
+
localVarQueryParameters['metadata'] = models_1.ObjectSerializer.serialize(queryParams.metadata, "string");
|
|
188
|
+
}
|
|
189
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.minDate) !== undefined) {
|
|
190
|
+
localVarQueryParameters['minDate'] = models_1.ObjectSerializer.serialize(queryParams.minDate, "Date");
|
|
191
|
+
}
|
|
192
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxDate) !== undefined) {
|
|
193
|
+
localVarQueryParameters['maxDate'] = models_1.ObjectSerializer.serialize(queryParams.maxDate, "Date");
|
|
194
|
+
}
|
|
183
195
|
Object.assign(localVarHeaderParams, options.headers);
|
|
184
196
|
Object.assign(localVarHeaderParams, this.opts.extraHeaders);
|
|
185
197
|
let localVarUseFormData = false;
|
|
@@ -252,6 +264,9 @@ class RawDataApi {
|
|
|
252
264
|
* @param dataType Include only samples with a particular data type
|
|
253
265
|
* @param minId Include only samples with an ID >= this value
|
|
254
266
|
* @param maxId Include only samples with an ID < this value
|
|
267
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
268
|
+
* @param minDate Only include samples that where added after the date given
|
|
269
|
+
* @param maxDate Only include samples that were added before the date given
|
|
255
270
|
*/
|
|
256
271
|
async batchClearMetadata(projectId, queryParams, options = { headers: {} }) {
|
|
257
272
|
const localVarPath = this.basePath + '/api/{projectId}/raw-data/batch/clear-metadata'
|
|
@@ -328,6 +343,15 @@ class RawDataApi {
|
|
|
328
343
|
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxId) !== undefined) {
|
|
329
344
|
localVarQueryParameters['maxId'] = models_1.ObjectSerializer.serialize(queryParams.maxId, "number");
|
|
330
345
|
}
|
|
346
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.metadata) !== undefined) {
|
|
347
|
+
localVarQueryParameters['metadata'] = models_1.ObjectSerializer.serialize(queryParams.metadata, "string");
|
|
348
|
+
}
|
|
349
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.minDate) !== undefined) {
|
|
350
|
+
localVarQueryParameters['minDate'] = models_1.ObjectSerializer.serialize(queryParams.minDate, "Date");
|
|
351
|
+
}
|
|
352
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxDate) !== undefined) {
|
|
353
|
+
localVarQueryParameters['maxDate'] = models_1.ObjectSerializer.serialize(queryParams.maxDate, "Date");
|
|
354
|
+
}
|
|
331
355
|
Object.assign(localVarHeaderParams, options.headers);
|
|
332
356
|
Object.assign(localVarHeaderParams, this.opts.extraHeaders);
|
|
333
357
|
let localVarUseFormData = false;
|
|
@@ -400,6 +424,9 @@ class RawDataApi {
|
|
|
400
424
|
* @param dataType Include only samples with a particular data type
|
|
401
425
|
* @param minId Include only samples with an ID >= this value
|
|
402
426
|
* @param maxId Include only samples with an ID < this value
|
|
427
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
428
|
+
* @param minDate Only include samples that where added after the date given
|
|
429
|
+
* @param maxDate Only include samples that were added before the date given
|
|
403
430
|
*/
|
|
404
431
|
async batchClearMetadataByKey(projectId, batchClearMetadataByKeyRequest, queryParams, options = { headers: {} }) {
|
|
405
432
|
const localVarPath = this.basePath + '/api/{projectId}/raw-data/batch/clear-metadata-by-key'
|
|
@@ -480,6 +507,15 @@ class RawDataApi {
|
|
|
480
507
|
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxId) !== undefined) {
|
|
481
508
|
localVarQueryParameters['maxId'] = models_1.ObjectSerializer.serialize(queryParams.maxId, "number");
|
|
482
509
|
}
|
|
510
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.metadata) !== undefined) {
|
|
511
|
+
localVarQueryParameters['metadata'] = models_1.ObjectSerializer.serialize(queryParams.metadata, "string");
|
|
512
|
+
}
|
|
513
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.minDate) !== undefined) {
|
|
514
|
+
localVarQueryParameters['minDate'] = models_1.ObjectSerializer.serialize(queryParams.minDate, "Date");
|
|
515
|
+
}
|
|
516
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxDate) !== undefined) {
|
|
517
|
+
localVarQueryParameters['maxDate'] = models_1.ObjectSerializer.serialize(queryParams.maxDate, "Date");
|
|
518
|
+
}
|
|
483
519
|
Object.assign(localVarHeaderParams, options.headers);
|
|
484
520
|
Object.assign(localVarHeaderParams, this.opts.extraHeaders);
|
|
485
521
|
let localVarUseFormData = false;
|
|
@@ -552,6 +588,9 @@ class RawDataApi {
|
|
|
552
588
|
* @param dataType Include only samples with a particular data type
|
|
553
589
|
* @param minId Include only samples with an ID >= this value
|
|
554
590
|
* @param maxId Include only samples with an ID < this value
|
|
591
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
592
|
+
* @param minDate Only include samples that where added after the date given
|
|
593
|
+
* @param maxDate Only include samples that were added before the date given
|
|
555
594
|
*/
|
|
556
595
|
async batchDelete(projectId, queryParams, options = { headers: {} }) {
|
|
557
596
|
const localVarPath = this.basePath + '/api/{projectId}/raw-data/batch/delete'
|
|
@@ -628,6 +667,15 @@ class RawDataApi {
|
|
|
628
667
|
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxId) !== undefined) {
|
|
629
668
|
localVarQueryParameters['maxId'] = models_1.ObjectSerializer.serialize(queryParams.maxId, "number");
|
|
630
669
|
}
|
|
670
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.metadata) !== undefined) {
|
|
671
|
+
localVarQueryParameters['metadata'] = models_1.ObjectSerializer.serialize(queryParams.metadata, "string");
|
|
672
|
+
}
|
|
673
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.minDate) !== undefined) {
|
|
674
|
+
localVarQueryParameters['minDate'] = models_1.ObjectSerializer.serialize(queryParams.minDate, "Date");
|
|
675
|
+
}
|
|
676
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxDate) !== undefined) {
|
|
677
|
+
localVarQueryParameters['maxDate'] = models_1.ObjectSerializer.serialize(queryParams.maxDate, "Date");
|
|
678
|
+
}
|
|
631
679
|
Object.assign(localVarHeaderParams, options.headers);
|
|
632
680
|
Object.assign(localVarHeaderParams, this.opts.extraHeaders);
|
|
633
681
|
let localVarUseFormData = false;
|
|
@@ -699,6 +747,9 @@ class RawDataApi {
|
|
|
699
747
|
* @param dataType Include only samples with a particular data type
|
|
700
748
|
* @param minId Include only samples with an ID >= this value
|
|
701
749
|
* @param maxId Include only samples with an ID < this value
|
|
750
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
751
|
+
* @param minDate Only include samples that where added after the date given
|
|
752
|
+
* @param maxDate Only include samples that were added before the date given
|
|
702
753
|
*/
|
|
703
754
|
async batchDisable(projectId, queryParams, options = { headers: {} }) {
|
|
704
755
|
const localVarPath = this.basePath + '/api/{projectId}/raw-data/batch/disable-samples'
|
|
@@ -775,6 +826,15 @@ class RawDataApi {
|
|
|
775
826
|
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxId) !== undefined) {
|
|
776
827
|
localVarQueryParameters['maxId'] = models_1.ObjectSerializer.serialize(queryParams.maxId, "number");
|
|
777
828
|
}
|
|
829
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.metadata) !== undefined) {
|
|
830
|
+
localVarQueryParameters['metadata'] = models_1.ObjectSerializer.serialize(queryParams.metadata, "string");
|
|
831
|
+
}
|
|
832
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.minDate) !== undefined) {
|
|
833
|
+
localVarQueryParameters['minDate'] = models_1.ObjectSerializer.serialize(queryParams.minDate, "Date");
|
|
834
|
+
}
|
|
835
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxDate) !== undefined) {
|
|
836
|
+
localVarQueryParameters['maxDate'] = models_1.ObjectSerializer.serialize(queryParams.maxDate, "Date");
|
|
837
|
+
}
|
|
778
838
|
Object.assign(localVarHeaderParams, options.headers);
|
|
779
839
|
Object.assign(localVarHeaderParams, this.opts.extraHeaders);
|
|
780
840
|
let localVarUseFormData = false;
|
|
@@ -847,6 +907,9 @@ class RawDataApi {
|
|
|
847
907
|
* @param dataType Include only samples with a particular data type
|
|
848
908
|
* @param minId Include only samples with an ID >= this value
|
|
849
909
|
* @param maxId Include only samples with an ID < this value
|
|
910
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
911
|
+
* @param minDate Only include samples that where added after the date given
|
|
912
|
+
* @param maxDate Only include samples that were added before the date given
|
|
850
913
|
*/
|
|
851
914
|
async batchEditLabels(projectId, editSampleLabelRequest, queryParams, options = { headers: {} }) {
|
|
852
915
|
const localVarPath = this.basePath + '/api/{projectId}/raw-data/batch/edit-labels'
|
|
@@ -927,6 +990,15 @@ class RawDataApi {
|
|
|
927
990
|
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxId) !== undefined) {
|
|
928
991
|
localVarQueryParameters['maxId'] = models_1.ObjectSerializer.serialize(queryParams.maxId, "number");
|
|
929
992
|
}
|
|
993
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.metadata) !== undefined) {
|
|
994
|
+
localVarQueryParameters['metadata'] = models_1.ObjectSerializer.serialize(queryParams.metadata, "string");
|
|
995
|
+
}
|
|
996
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.minDate) !== undefined) {
|
|
997
|
+
localVarQueryParameters['minDate'] = models_1.ObjectSerializer.serialize(queryParams.minDate, "Date");
|
|
998
|
+
}
|
|
999
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxDate) !== undefined) {
|
|
1000
|
+
localVarQueryParameters['maxDate'] = models_1.ObjectSerializer.serialize(queryParams.maxDate, "Date");
|
|
1001
|
+
}
|
|
930
1002
|
Object.assign(localVarHeaderParams, options.headers);
|
|
931
1003
|
Object.assign(localVarHeaderParams, this.opts.extraHeaders);
|
|
932
1004
|
let localVarUseFormData = false;
|
|
@@ -999,6 +1071,9 @@ class RawDataApi {
|
|
|
999
1071
|
* @param dataType Include only samples with a particular data type
|
|
1000
1072
|
* @param minId Include only samples with an ID >= this value
|
|
1001
1073
|
* @param maxId Include only samples with an ID < this value
|
|
1074
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
1075
|
+
* @param minDate Only include samples that where added after the date given
|
|
1076
|
+
* @param maxDate Only include samples that were added before the date given
|
|
1002
1077
|
*/
|
|
1003
1078
|
async batchEnable(projectId, queryParams, options = { headers: {} }) {
|
|
1004
1079
|
const localVarPath = this.basePath + '/api/{projectId}/raw-data/batch/enable-samples'
|
|
@@ -1075,6 +1150,15 @@ class RawDataApi {
|
|
|
1075
1150
|
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxId) !== undefined) {
|
|
1076
1151
|
localVarQueryParameters['maxId'] = models_1.ObjectSerializer.serialize(queryParams.maxId, "number");
|
|
1077
1152
|
}
|
|
1153
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.metadata) !== undefined) {
|
|
1154
|
+
localVarQueryParameters['metadata'] = models_1.ObjectSerializer.serialize(queryParams.metadata, "string");
|
|
1155
|
+
}
|
|
1156
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.minDate) !== undefined) {
|
|
1157
|
+
localVarQueryParameters['minDate'] = models_1.ObjectSerializer.serialize(queryParams.minDate, "Date");
|
|
1158
|
+
}
|
|
1159
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxDate) !== undefined) {
|
|
1160
|
+
localVarQueryParameters['maxDate'] = models_1.ObjectSerializer.serialize(queryParams.maxDate, "Date");
|
|
1161
|
+
}
|
|
1078
1162
|
Object.assign(localVarHeaderParams, options.headers);
|
|
1079
1163
|
Object.assign(localVarHeaderParams, this.opts.extraHeaders);
|
|
1080
1164
|
let localVarUseFormData = false;
|
|
@@ -1147,6 +1231,9 @@ class RawDataApi {
|
|
|
1147
1231
|
* @param dataType Include only samples with a particular data type
|
|
1148
1232
|
* @param minId Include only samples with an ID >= this value
|
|
1149
1233
|
* @param maxId Include only samples with an ID < this value
|
|
1234
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
1235
|
+
* @param minDate Only include samples that where added after the date given
|
|
1236
|
+
* @param maxDate Only include samples that were added before the date given
|
|
1150
1237
|
*/
|
|
1151
1238
|
async batchMove(projectId, moveRawDataRequest, queryParams, options = { headers: {} }) {
|
|
1152
1239
|
const localVarPath = this.basePath + '/api/{projectId}/raw-data/batch/moveSamples'
|
|
@@ -1227,6 +1314,15 @@ class RawDataApi {
|
|
|
1227
1314
|
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxId) !== undefined) {
|
|
1228
1315
|
localVarQueryParameters['maxId'] = models_1.ObjectSerializer.serialize(queryParams.maxId, "number");
|
|
1229
1316
|
}
|
|
1317
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.metadata) !== undefined) {
|
|
1318
|
+
localVarQueryParameters['metadata'] = models_1.ObjectSerializer.serialize(queryParams.metadata, "string");
|
|
1319
|
+
}
|
|
1320
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.minDate) !== undefined) {
|
|
1321
|
+
localVarQueryParameters['minDate'] = models_1.ObjectSerializer.serialize(queryParams.minDate, "Date");
|
|
1322
|
+
}
|
|
1323
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxDate) !== undefined) {
|
|
1324
|
+
localVarQueryParameters['maxDate'] = models_1.ObjectSerializer.serialize(queryParams.maxDate, "Date");
|
|
1325
|
+
}
|
|
1230
1326
|
Object.assign(localVarHeaderParams, options.headers);
|
|
1231
1327
|
Object.assign(localVarHeaderParams, this.opts.extraHeaders);
|
|
1232
1328
|
let localVarUseFormData = false;
|
|
@@ -1534,6 +1630,9 @@ class RawDataApi {
|
|
|
1534
1630
|
* @param dataType Include only samples with a particular data type
|
|
1535
1631
|
* @param minId Include only samples with an ID >= this value
|
|
1536
1632
|
* @param maxId Include only samples with an ID < this value
|
|
1633
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
1634
|
+
* @param minDate Only include samples that where added after the date given
|
|
1635
|
+
* @param maxDate Only include samples that were added before the date given
|
|
1537
1636
|
*/
|
|
1538
1637
|
async countSamples(projectId, queryParams, options = { headers: {} }) {
|
|
1539
1638
|
const localVarPath = this.basePath + '/api/{projectId}/raw-data/count'
|
|
@@ -1604,6 +1703,15 @@ class RawDataApi {
|
|
|
1604
1703
|
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxId) !== undefined) {
|
|
1605
1704
|
localVarQueryParameters['maxId'] = models_1.ObjectSerializer.serialize(queryParams.maxId, "number");
|
|
1606
1705
|
}
|
|
1706
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.metadata) !== undefined) {
|
|
1707
|
+
localVarQueryParameters['metadata'] = models_1.ObjectSerializer.serialize(queryParams.metadata, "string");
|
|
1708
|
+
}
|
|
1709
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.minDate) !== undefined) {
|
|
1710
|
+
localVarQueryParameters['minDate'] = models_1.ObjectSerializer.serialize(queryParams.minDate, "Date");
|
|
1711
|
+
}
|
|
1712
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxDate) !== undefined) {
|
|
1713
|
+
localVarQueryParameters['maxDate'] = models_1.ObjectSerializer.serialize(queryParams.maxDate, "Date");
|
|
1714
|
+
}
|
|
1607
1715
|
Object.assign(localVarHeaderParams, options.headers);
|
|
1608
1716
|
Object.assign(localVarHeaderParams, this.opts.extraHeaders);
|
|
1609
1717
|
let localVarUseFormData = false;
|
|
@@ -3630,6 +3738,97 @@ class RawDataApi {
|
|
|
3630
3738
|
});
|
|
3631
3739
|
});
|
|
3632
3740
|
}
|
|
3741
|
+
/**
|
|
3742
|
+
* Get a list of unique key value pairs across all samples in a project that can be applied as filters to the /api/{projectId}/raw-data endpoint
|
|
3743
|
+
* @summary Get project sample metadata filter options
|
|
3744
|
+
* @param projectId Project ID
|
|
3745
|
+
* @param category Which of the three acquisition categories to retrieve data from
|
|
3746
|
+
* @param limit Maximum number of results
|
|
3747
|
+
* @param offset Offset in results, can be used in conjunction with LimitResultsParameter to implement paging.
|
|
3748
|
+
*/
|
|
3749
|
+
async getSampleMetadataFilterOptions(projectId, queryParams, options = { headers: {} }) {
|
|
3750
|
+
const localVarPath = this.basePath + '/api/{projectId}/raw-data/metadata-filter-options'
|
|
3751
|
+
.replace('{' + 'projectId' + '}', encodeURIComponent(String(projectId)));
|
|
3752
|
+
let localVarQueryParameters = {};
|
|
3753
|
+
let localVarHeaderParams = Object.assign({
|
|
3754
|
+
'User-Agent': 'edgeimpulse-api nodejs'
|
|
3755
|
+
}, this.defaultHeaders);
|
|
3756
|
+
const produces = ['application/json'];
|
|
3757
|
+
// give precedence to 'application/json'
|
|
3758
|
+
if (produces.indexOf('application/json') >= 0) {
|
|
3759
|
+
localVarHeaderParams.Accept = 'application/json';
|
|
3760
|
+
}
|
|
3761
|
+
else {
|
|
3762
|
+
localVarHeaderParams.Accept = produces.join(',');
|
|
3763
|
+
}
|
|
3764
|
+
let localVarFormParams = {};
|
|
3765
|
+
// verify required parameter 'projectId' is not null or undefined
|
|
3766
|
+
if (projectId === null || projectId === undefined) {
|
|
3767
|
+
throw new Error('Required parameter projectId was null or undefined when calling getSampleMetadataFilterOptions.');
|
|
3768
|
+
}
|
|
3769
|
+
// verify required parameter 'category' is not null or undefined
|
|
3770
|
+
if (queryParams.category === null || queryParams.category === undefined) {
|
|
3771
|
+
throw new Error('Required parameter queryParams.category was null or undefined when calling getSampleMetadataFilterOptions.');
|
|
3772
|
+
}
|
|
3773
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.category) !== undefined) {
|
|
3774
|
+
localVarQueryParameters['category'] = models_1.ObjectSerializer.serialize(queryParams.category, "RawDataCategory");
|
|
3775
|
+
}
|
|
3776
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.limit) !== undefined) {
|
|
3777
|
+
localVarQueryParameters['limit'] = models_1.ObjectSerializer.serialize(queryParams.limit, "number");
|
|
3778
|
+
}
|
|
3779
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.offset) !== undefined) {
|
|
3780
|
+
localVarQueryParameters['offset'] = models_1.ObjectSerializer.serialize(queryParams.offset, "number");
|
|
3781
|
+
}
|
|
3782
|
+
Object.assign(localVarHeaderParams, options.headers);
|
|
3783
|
+
Object.assign(localVarHeaderParams, this.opts.extraHeaders);
|
|
3784
|
+
let localVarUseFormData = false;
|
|
3785
|
+
let localVarRequestOptions = {
|
|
3786
|
+
method: 'GET',
|
|
3787
|
+
qs: localVarQueryParameters,
|
|
3788
|
+
headers: localVarHeaderParams,
|
|
3789
|
+
uri: localVarPath,
|
|
3790
|
+
useQuerystring: this._useQuerystring,
|
|
3791
|
+
agentOptions: { keepAlive: false },
|
|
3792
|
+
json: true,
|
|
3793
|
+
};
|
|
3794
|
+
let authenticationPromise = Promise.resolve();
|
|
3795
|
+
authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
|
|
3796
|
+
authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
|
|
3797
|
+
authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
|
|
3798
|
+
authenticationPromise = authenticationPromise.then(() => this.authentications.OAuth2.applyToRequest(localVarRequestOptions));
|
|
3799
|
+
authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
|
|
3800
|
+
return authenticationPromise.then(() => {
|
|
3801
|
+
if (Object.keys(localVarFormParams).length) {
|
|
3802
|
+
if (localVarUseFormData) {
|
|
3803
|
+
localVarRequestOptions.formData = localVarFormParams;
|
|
3804
|
+
}
|
|
3805
|
+
else {
|
|
3806
|
+
localVarRequestOptions.form = localVarFormParams;
|
|
3807
|
+
}
|
|
3808
|
+
}
|
|
3809
|
+
return new Promise((resolve, reject) => {
|
|
3810
|
+
localVarRequest(localVarRequestOptions, (error, response, body) => {
|
|
3811
|
+
if (error) {
|
|
3812
|
+
reject(error);
|
|
3813
|
+
}
|
|
3814
|
+
else {
|
|
3815
|
+
body = models_1.ObjectSerializer.deserialize(body, "GetSampleMetadataFilterOptionsResponse");
|
|
3816
|
+
if (typeof body.success === 'boolean' && !body.success) {
|
|
3817
|
+
const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
|
|
3818
|
+
reject(new Error(body.error || errString));
|
|
3819
|
+
}
|
|
3820
|
+
else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
|
|
3821
|
+
resolve(body);
|
|
3822
|
+
}
|
|
3823
|
+
else {
|
|
3824
|
+
const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
|
|
3825
|
+
reject(errString);
|
|
3826
|
+
}
|
|
3827
|
+
}
|
|
3828
|
+
});
|
|
3829
|
+
});
|
|
3830
|
+
});
|
|
3831
|
+
}
|
|
3633
3832
|
/**
|
|
3634
3833
|
* Get a slice of a sample.
|
|
3635
3834
|
* @summary Get sample slice
|
|
@@ -4082,6 +4281,9 @@ class RawDataApi {
|
|
|
4082
4281
|
* @param dataType Include only samples with a particular data type
|
|
4083
4282
|
* @param minId Include only samples with an ID >= this value
|
|
4084
4283
|
* @param maxId Include only samples with an ID < this value
|
|
4284
|
+
* @param metadata Filter samples by metadata key-value pairs, provided as a JSON string. Each filter item in the list is combined using a logical OR. To include samples without any metadata, use: { \"no_metadata\": true }.
|
|
4285
|
+
* @param minDate Only include samples that where added after the date given
|
|
4286
|
+
* @param maxDate Only include samples that were added before the date given
|
|
4085
4287
|
*/
|
|
4086
4288
|
async listSamples(projectId, queryParams, options = { headers: {} }) {
|
|
4087
4289
|
const localVarPath = this.basePath + '/api/{projectId}/raw-data'
|
|
@@ -4170,6 +4372,15 @@ class RawDataApi {
|
|
|
4170
4372
|
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxId) !== undefined) {
|
|
4171
4373
|
localVarQueryParameters['maxId'] = models_1.ObjectSerializer.serialize(queryParams.maxId, "number");
|
|
4172
4374
|
}
|
|
4375
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.metadata) !== undefined) {
|
|
4376
|
+
localVarQueryParameters['metadata'] = models_1.ObjectSerializer.serialize(queryParams.metadata, "string");
|
|
4377
|
+
}
|
|
4378
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.minDate) !== undefined) {
|
|
4379
|
+
localVarQueryParameters['minDate'] = models_1.ObjectSerializer.serialize(queryParams.minDate, "Date");
|
|
4380
|
+
}
|
|
4381
|
+
if ((queryParams === null || queryParams === void 0 ? void 0 : queryParams.maxDate) !== undefined) {
|
|
4382
|
+
localVarQueryParameters['maxDate'] = models_1.ObjectSerializer.serialize(queryParams.maxDate, "Date");
|
|
4383
|
+
}
|
|
4173
4384
|
Object.assign(localVarHeaderParams, options.headers);
|
|
4174
4385
|
Object.assign(localVarHeaderParams, this.opts.extraHeaders);
|
|
4175
4386
|
let localVarUseFormData = false;
|