@revengai/sdk 3.89.0 → 3.92.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 (58) hide show
  1. package/README.md +17 -4
  2. package/dist/apis/AnalysesCoreApi.d.ts +4 -7
  3. package/dist/apis/AnalysesCoreApi.js +243 -345
  4. package/dist/apis/AnalysesCoreApi.js.map +1 -1
  5. package/dist/apis/CollectionsApi.d.ts +18 -0
  6. package/dist/apis/CollectionsApi.js +526 -0
  7. package/dist/apis/CollectionsApi.js.map +1 -1
  8. package/dist/apis/SearchApi.d.ts +1 -1
  9. package/dist/apis/SearchApi.js +4 -1
  10. package/dist/apis/SearchApi.js.map +1 -1
  11. package/dist/models/Binary.d.ts +26 -0
  12. package/dist/models/Binary.js +59 -0
  13. package/dist/models/Binary.js.map +1 -0
  14. package/dist/models/CollectionListItemBody.d.ts +30 -0
  15. package/dist/models/CollectionListItemBody.js +83 -0
  16. package/dist/models/CollectionListItemBody.js.map +1 -0
  17. package/dist/models/CreateCollectionInputBody.d.ts +32 -0
  18. package/dist/models/CreateCollectionInputBody.js +61 -0
  19. package/dist/models/CreateCollectionInputBody.js.map +1 -0
  20. package/dist/models/CreateCollectionOutputBody.d.ts +31 -0
  21. package/dist/models/CreateCollectionOutputBody.js +83 -0
  22. package/dist/models/CreateCollectionOutputBody.js.map +1 -0
  23. package/dist/models/GetCollectionOutputBody.d.ts +34 -0
  24. package/dist/models/GetCollectionOutputBody.js +101 -0
  25. package/dist/models/GetCollectionOutputBody.js.map +1 -0
  26. package/dist/models/ListCollectionsOutputBody.d.ts +24 -0
  27. package/dist/models/ListCollectionsOutputBody.js +41 -0
  28. package/dist/models/ListCollectionsOutputBody.js.map +1 -0
  29. package/dist/models/ObjectSerializer.d.ts +10 -1
  30. package/dist/models/ObjectSerializer.js +31 -3
  31. package/dist/models/ObjectSerializer.js.map +1 -1
  32. package/dist/models/PatchCollectionBinariesInputBody.d.ts +20 -0
  33. package/dist/models/PatchCollectionBinariesInputBody.js +23 -0
  34. package/dist/models/PatchCollectionBinariesInputBody.js.map +1 -0
  35. package/dist/models/PatchCollectionBinariesOutputBody.d.ts +21 -0
  36. package/dist/models/PatchCollectionBinariesOutputBody.js +23 -0
  37. package/dist/models/PatchCollectionBinariesOutputBody.js.map +1 -0
  38. package/dist/models/{QueuePositionResponse.d.ts → PatchCollectionTagsInputBody.d.ts} +2 -2
  39. package/dist/models/PatchCollectionTagsInputBody.js +23 -0
  40. package/dist/models/PatchCollectionTagsInputBody.js.map +1 -0
  41. package/dist/models/PatchCollectionTagsOutputBody.d.ts +20 -0
  42. package/dist/models/PatchCollectionTagsOutputBody.js +23 -0
  43. package/dist/models/PatchCollectionTagsOutputBody.js.map +1 -0
  44. package/dist/models/all.d.ts +10 -1
  45. package/dist/models/all.js +10 -1
  46. package/dist/models/all.js.map +1 -1
  47. package/dist/types/ObjectParamAPI.d.ts +62 -22
  48. package/dist/types/ObjectParamAPI.js +46 -20
  49. package/dist/types/ObjectParamAPI.js.map +1 -1
  50. package/dist/types/ObservableAPI.d.ts +24 -9
  51. package/dist/types/ObservableAPI.js +606 -494
  52. package/dist/types/ObservableAPI.js.map +1 -1
  53. package/dist/types/PromiseAPI.d.ts +24 -9
  54. package/dist/types/PromiseAPI.js +74 -34
  55. package/dist/types/PromiseAPI.js.map +1 -1
  56. package/package.json +1 -1
  57. package/dist/models/QueuePositionResponse.js +0 -23
  58. package/dist/models/QueuePositionResponse.js.map +0 -1
@@ -358,6 +358,223 @@ var CollectionsApiRequestFactory = (function (_super) {
358
358
  });
359
359
  });
360
360
  };
361
+ CollectionsApiRequestFactory.prototype.v3CreateCollection = function (createCollectionInputBody, _options) {
362
+ var _a;
363
+ return __awaiter(this, void 0, void 0, function () {
364
+ var _config, localVarPath, requestContext, contentType, serializedBody, authMethod, defaultAuth;
365
+ return __generator(this, function (_b) {
366
+ switch (_b.label) {
367
+ case 0:
368
+ _config = _options || this.configuration;
369
+ if (createCollectionInputBody === null || createCollectionInputBody === undefined) {
370
+ throw new baseapi_1.RequiredError("CollectionsApi", "v3CreateCollection", "createCollectionInputBody");
371
+ }
372
+ localVarPath = '/v3/collections';
373
+ requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.POST);
374
+ requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
375
+ contentType = ObjectSerializer_1.ObjectSerializer.getPreferredMediaType([
376
+ "application/json"
377
+ ]);
378
+ requestContext.setHeaderParam("Content-Type", contentType);
379
+ serializedBody = ObjectSerializer_1.ObjectSerializer.stringify(ObjectSerializer_1.ObjectSerializer.serialize(createCollectionInputBody, "CreateCollectionInputBody", ""), contentType);
380
+ requestContext.setBody(serializedBody);
381
+ authMethod = _config.authMethods["APIKey"];
382
+ if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
383
+ return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
384
+ case 1:
385
+ _b.sent();
386
+ _b.label = 2;
387
+ case 2:
388
+ defaultAuth = (_a = _config === null || _config === void 0 ? void 0 : _config.authMethods) === null || _a === void 0 ? void 0 : _a.default;
389
+ if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
390
+ return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
391
+ case 3:
392
+ _b.sent();
393
+ _b.label = 4;
394
+ case 4: return [2, requestContext];
395
+ }
396
+ });
397
+ });
398
+ };
399
+ CollectionsApiRequestFactory.prototype.v3GetCollection = function (collectionId, includeTags, includeBinaries, pageSize, pageNumber, binarySearchStr, _options) {
400
+ var _a;
401
+ return __awaiter(this, void 0, void 0, function () {
402
+ var _config, localVarPath, requestContext, authMethod, defaultAuth;
403
+ return __generator(this, function (_b) {
404
+ switch (_b.label) {
405
+ case 0:
406
+ _config = _options || this.configuration;
407
+ if (collectionId === null || collectionId === undefined) {
408
+ throw new baseapi_1.RequiredError("CollectionsApi", "v3GetCollection", "collectionId");
409
+ }
410
+ localVarPath = '/v3/collections/{collection_id}'
411
+ .replace('{' + 'collection_id' + '}', encodeURIComponent(String(collectionId)));
412
+ requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.GET);
413
+ requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
414
+ if (includeTags !== undefined) {
415
+ requestContext.setQueryParam("include_tags", ObjectSerializer_1.ObjectSerializer.serialize(includeTags, "boolean", ""));
416
+ }
417
+ if (includeBinaries !== undefined) {
418
+ requestContext.setQueryParam("include_binaries", ObjectSerializer_1.ObjectSerializer.serialize(includeBinaries, "boolean", ""));
419
+ }
420
+ if (pageSize !== undefined) {
421
+ requestContext.setQueryParam("page_size", ObjectSerializer_1.ObjectSerializer.serialize(pageSize, "number", "int64"));
422
+ }
423
+ if (pageNumber !== undefined) {
424
+ requestContext.setQueryParam("page_number", ObjectSerializer_1.ObjectSerializer.serialize(pageNumber, "number", "int64"));
425
+ }
426
+ if (binarySearchStr !== undefined) {
427
+ requestContext.setQueryParam("binary_search_str", ObjectSerializer_1.ObjectSerializer.serialize(binarySearchStr, "string", ""));
428
+ }
429
+ authMethod = _config.authMethods["APIKey"];
430
+ if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
431
+ return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
432
+ case 1:
433
+ _b.sent();
434
+ _b.label = 2;
435
+ case 2:
436
+ defaultAuth = (_a = _config === null || _config === void 0 ? void 0 : _config.authMethods) === null || _a === void 0 ? void 0 : _a.default;
437
+ if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
438
+ return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
439
+ case 3:
440
+ _b.sent();
441
+ _b.label = 4;
442
+ case 4: return [2, requestContext];
443
+ }
444
+ });
445
+ });
446
+ };
447
+ CollectionsApiRequestFactory.prototype.v3ListCollections = function (searchTerm, filters, limit, offset, orderBy, order, _options) {
448
+ var _a;
449
+ return __awaiter(this, void 0, void 0, function () {
450
+ var _config, localVarPath, requestContext, authMethod, defaultAuth;
451
+ return __generator(this, function (_b) {
452
+ switch (_b.label) {
453
+ case 0:
454
+ _config = _options || this.configuration;
455
+ localVarPath = '/v3/collections';
456
+ requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.GET);
457
+ requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
458
+ if (searchTerm !== undefined) {
459
+ requestContext.setQueryParam("search_term", ObjectSerializer_1.ObjectSerializer.serialize(searchTerm, "string", ""));
460
+ }
461
+ if (filters !== undefined) {
462
+ requestContext.setQueryParam("filters", ObjectSerializer_1.ObjectSerializer.serialize(filters, "Array<'official_only' | 'user_only' | 'team_only' | 'public_only' | 'hide_empty'>", ""));
463
+ }
464
+ if (limit !== undefined) {
465
+ requestContext.setQueryParam("limit", ObjectSerializer_1.ObjectSerializer.serialize(limit, "number", "int64"));
466
+ }
467
+ if (offset !== undefined) {
468
+ requestContext.setQueryParam("offset", ObjectSerializer_1.ObjectSerializer.serialize(offset, "number", "int64"));
469
+ }
470
+ if (orderBy !== undefined) {
471
+ requestContext.setQueryParam("order_by", ObjectSerializer_1.ObjectSerializer.serialize(orderBy, "'created' | 'collection' | 'model' | 'collection_size' | 'updated'", ""));
472
+ }
473
+ if (order !== undefined) {
474
+ requestContext.setQueryParam("order", ObjectSerializer_1.ObjectSerializer.serialize(order, "'ASC' | 'DESC'", ""));
475
+ }
476
+ authMethod = _config.authMethods["APIKey"];
477
+ if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
478
+ return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
479
+ case 1:
480
+ _b.sent();
481
+ _b.label = 2;
482
+ case 2:
483
+ defaultAuth = (_a = _config === null || _config === void 0 ? void 0 : _config.authMethods) === null || _a === void 0 ? void 0 : _a.default;
484
+ if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
485
+ return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
486
+ case 3:
487
+ _b.sent();
488
+ _b.label = 4;
489
+ case 4: return [2, requestContext];
490
+ }
491
+ });
492
+ });
493
+ };
494
+ CollectionsApiRequestFactory.prototype.v3PatchCollectionBinaries = function (collectionId, patchCollectionBinariesInputBody, _options) {
495
+ var _a;
496
+ return __awaiter(this, void 0, void 0, function () {
497
+ var _config, localVarPath, requestContext, contentType, serializedBody, authMethod, defaultAuth;
498
+ return __generator(this, function (_b) {
499
+ switch (_b.label) {
500
+ case 0:
501
+ _config = _options || this.configuration;
502
+ if (collectionId === null || collectionId === undefined) {
503
+ throw new baseapi_1.RequiredError("CollectionsApi", "v3PatchCollectionBinaries", "collectionId");
504
+ }
505
+ if (patchCollectionBinariesInputBody === null || patchCollectionBinariesInputBody === undefined) {
506
+ throw new baseapi_1.RequiredError("CollectionsApi", "v3PatchCollectionBinaries", "patchCollectionBinariesInputBody");
507
+ }
508
+ localVarPath = '/v3/collections/{collection_id}/binaries'
509
+ .replace('{' + 'collection_id' + '}', encodeURIComponent(String(collectionId)));
510
+ requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.PATCH);
511
+ requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
512
+ contentType = ObjectSerializer_1.ObjectSerializer.getPreferredMediaType([
513
+ "application/json"
514
+ ]);
515
+ requestContext.setHeaderParam("Content-Type", contentType);
516
+ serializedBody = ObjectSerializer_1.ObjectSerializer.stringify(ObjectSerializer_1.ObjectSerializer.serialize(patchCollectionBinariesInputBody, "PatchCollectionBinariesInputBody", ""), contentType);
517
+ requestContext.setBody(serializedBody);
518
+ authMethod = _config.authMethods["APIKey"];
519
+ if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
520
+ return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
521
+ case 1:
522
+ _b.sent();
523
+ _b.label = 2;
524
+ case 2:
525
+ defaultAuth = (_a = _config === null || _config === void 0 ? void 0 : _config.authMethods) === null || _a === void 0 ? void 0 : _a.default;
526
+ if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
527
+ return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
528
+ case 3:
529
+ _b.sent();
530
+ _b.label = 4;
531
+ case 4: return [2, requestContext];
532
+ }
533
+ });
534
+ });
535
+ };
536
+ CollectionsApiRequestFactory.prototype.v3PatchCollectionTags = function (collectionId, patchCollectionTagsInputBody, _options) {
537
+ var _a;
538
+ return __awaiter(this, void 0, void 0, function () {
539
+ var _config, localVarPath, requestContext, contentType, serializedBody, authMethod, defaultAuth;
540
+ return __generator(this, function (_b) {
541
+ switch (_b.label) {
542
+ case 0:
543
+ _config = _options || this.configuration;
544
+ if (collectionId === null || collectionId === undefined) {
545
+ throw new baseapi_1.RequiredError("CollectionsApi", "v3PatchCollectionTags", "collectionId");
546
+ }
547
+ if (patchCollectionTagsInputBody === null || patchCollectionTagsInputBody === undefined) {
548
+ throw new baseapi_1.RequiredError("CollectionsApi", "v3PatchCollectionTags", "patchCollectionTagsInputBody");
549
+ }
550
+ localVarPath = '/v3/collections/{collection_id}/tags'
551
+ .replace('{' + 'collection_id' + '}', encodeURIComponent(String(collectionId)));
552
+ requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.PATCH);
553
+ requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
554
+ contentType = ObjectSerializer_1.ObjectSerializer.getPreferredMediaType([
555
+ "application/json"
556
+ ]);
557
+ requestContext.setHeaderParam("Content-Type", contentType);
558
+ serializedBody = ObjectSerializer_1.ObjectSerializer.stringify(ObjectSerializer_1.ObjectSerializer.serialize(patchCollectionTagsInputBody, "PatchCollectionTagsInputBody", ""), contentType);
559
+ requestContext.setBody(serializedBody);
560
+ authMethod = _config.authMethods["APIKey"];
561
+ if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
562
+ return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
563
+ case 1:
564
+ _b.sent();
565
+ _b.label = 2;
566
+ case 2:
567
+ defaultAuth = (_a = _config === null || _config === void 0 ? void 0 : _config.authMethods) === null || _a === void 0 ? void 0 : _a.default;
568
+ if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
569
+ return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
570
+ case 3:
571
+ _b.sent();
572
+ _b.label = 4;
573
+ case 4: return [2, requestContext];
574
+ }
575
+ });
576
+ });
577
+ };
361
578
  return CollectionsApiRequestFactory;
362
579
  }(baseapi_1.BaseAPIRequestFactory));
363
580
  exports.CollectionsApiRequestFactory = CollectionsApiRequestFactory;
@@ -658,6 +875,315 @@ var CollectionsApiResponseProcessor = (function () {
658
875
  });
659
876
  });
660
877
  };
878
+ CollectionsApiResponseProcessor.prototype.v3CreateCollectionWithHttpInfo = function (response) {
879
+ return __awaiter(this, void 0, void 0, function () {
880
+ var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, body, _j, _k, _l, _m, body, _o, _p, _q, _r, body, _s, _t, _u, _v, _w, _x;
881
+ return __generator(this, function (_y) {
882
+ switch (_y.label) {
883
+ case 0:
884
+ contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
885
+ if (!(0, util_1.isCodeInRange)("201", response.httpStatusCode)) return [3, 2];
886
+ _b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
887
+ _d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
888
+ return [4, response.body.text()];
889
+ case 1:
890
+ body = _b.apply(_a, [_d.apply(_c, [_y.sent(), contentType]),
891
+ "CreateCollectionOutputBody", ""]);
892
+ return [2, new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body)];
893
+ case 2:
894
+ if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3, 4];
895
+ _f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
896
+ _h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
897
+ return [4, response.body.text()];
898
+ case 3:
899
+ body = _f.apply(_e, [_h.apply(_g, [_y.sent(), contentType]),
900
+ "APIError", ""]);
901
+ throw new exception_1.ApiException(response.httpStatusCode, "Not Found", body, response.headers);
902
+ case 4:
903
+ if (!(0, util_1.isCodeInRange)("422", response.httpStatusCode)) return [3, 6];
904
+ _k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
905
+ _m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
906
+ return [4, response.body.text()];
907
+ case 5:
908
+ body = _k.apply(_j, [_m.apply(_l, [_y.sent(), contentType]),
909
+ "APIError", ""]);
910
+ throw new exception_1.ApiException(response.httpStatusCode, "Unprocessable Entity", body, response.headers);
911
+ case 6:
912
+ if (!(0, util_1.isCodeInRange)("500", response.httpStatusCode)) return [3, 8];
913
+ _p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
914
+ _r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
915
+ return [4, response.body.text()];
916
+ case 7:
917
+ body = _p.apply(_o, [_r.apply(_q, [_y.sent(), contentType]),
918
+ "APIError", ""]);
919
+ throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
920
+ case 8:
921
+ if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 10];
922
+ _t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
923
+ _v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
924
+ return [4, response.body.text()];
925
+ case 9:
926
+ body = _t.apply(_s, [_v.apply(_u, [_y.sent(), contentType]),
927
+ "CreateCollectionOutputBody", ""]);
928
+ return [2, new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body)];
929
+ case 10:
930
+ _w = exception_1.ApiException.bind;
931
+ _x = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
932
+ return [4, response.getBodyAsAny()];
933
+ case 11: throw new (_w.apply(exception_1.ApiException, _x.concat([_y.sent(), response.headers])))();
934
+ }
935
+ });
936
+ });
937
+ };
938
+ CollectionsApiResponseProcessor.prototype.v3GetCollectionWithHttpInfo = function (response) {
939
+ return __awaiter(this, void 0, void 0, function () {
940
+ var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, body, _j, _k, _l, _m, body, _o, _p, _q, _r, body, _s, _t, _u, _v, _w, _x;
941
+ return __generator(this, function (_y) {
942
+ switch (_y.label) {
943
+ case 0:
944
+ contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
945
+ if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
946
+ _b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
947
+ _d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
948
+ return [4, response.body.text()];
949
+ case 1:
950
+ body = _b.apply(_a, [_d.apply(_c, [_y.sent(), contentType]),
951
+ "GetCollectionOutputBody", ""]);
952
+ return [2, new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body)];
953
+ case 2:
954
+ if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3, 4];
955
+ _f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
956
+ _h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
957
+ return [4, response.body.text()];
958
+ case 3:
959
+ body = _f.apply(_e, [_h.apply(_g, [_y.sent(), contentType]),
960
+ "APIError", ""]);
961
+ throw new exception_1.ApiException(response.httpStatusCode, "Not Found", body, response.headers);
962
+ case 4:
963
+ if (!(0, util_1.isCodeInRange)("422", response.httpStatusCode)) return [3, 6];
964
+ _k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
965
+ _m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
966
+ return [4, response.body.text()];
967
+ case 5:
968
+ body = _k.apply(_j, [_m.apply(_l, [_y.sent(), contentType]),
969
+ "APIError", ""]);
970
+ throw new exception_1.ApiException(response.httpStatusCode, "Unprocessable Entity", body, response.headers);
971
+ case 6:
972
+ if (!(0, util_1.isCodeInRange)("500", response.httpStatusCode)) return [3, 8];
973
+ _p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
974
+ _r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
975
+ return [4, response.body.text()];
976
+ case 7:
977
+ body = _p.apply(_o, [_r.apply(_q, [_y.sent(), contentType]),
978
+ "APIError", ""]);
979
+ throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
980
+ case 8:
981
+ if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 10];
982
+ _t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
983
+ _v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
984
+ return [4, response.body.text()];
985
+ case 9:
986
+ body = _t.apply(_s, [_v.apply(_u, [_y.sent(), contentType]),
987
+ "GetCollectionOutputBody", ""]);
988
+ return [2, new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body)];
989
+ case 10:
990
+ _w = exception_1.ApiException.bind;
991
+ _x = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
992
+ return [4, response.getBodyAsAny()];
993
+ case 11: throw new (_w.apply(exception_1.ApiException, _x.concat([_y.sent(), response.headers])))();
994
+ }
995
+ });
996
+ });
997
+ };
998
+ CollectionsApiResponseProcessor.prototype.v3ListCollectionsWithHttpInfo = function (response) {
999
+ return __awaiter(this, void 0, void 0, function () {
1000
+ var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, body, _j, _k, _l, _m, body, _o, _p, _q, _r, _s, _t;
1001
+ return __generator(this, function (_u) {
1002
+ switch (_u.label) {
1003
+ case 0:
1004
+ contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
1005
+ if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
1006
+ _b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
1007
+ _d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
1008
+ return [4, response.body.text()];
1009
+ case 1:
1010
+ body = _b.apply(_a, [_d.apply(_c, [_u.sent(), contentType]),
1011
+ "ListCollectionsOutputBody", ""]);
1012
+ return [2, new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body)];
1013
+ case 2:
1014
+ if (!(0, util_1.isCodeInRange)("422", response.httpStatusCode)) return [3, 4];
1015
+ _f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
1016
+ _h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
1017
+ return [4, response.body.text()];
1018
+ case 3:
1019
+ body = _f.apply(_e, [_h.apply(_g, [_u.sent(), contentType]),
1020
+ "APIError", ""]);
1021
+ throw new exception_1.ApiException(response.httpStatusCode, "Unprocessable Entity", body, response.headers);
1022
+ case 4:
1023
+ if (!(0, util_1.isCodeInRange)("500", response.httpStatusCode)) return [3, 6];
1024
+ _k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
1025
+ _m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
1026
+ return [4, response.body.text()];
1027
+ case 5:
1028
+ body = _k.apply(_j, [_m.apply(_l, [_u.sent(), contentType]),
1029
+ "APIError", ""]);
1030
+ throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
1031
+ case 6:
1032
+ if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 8];
1033
+ _p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
1034
+ _r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
1035
+ return [4, response.body.text()];
1036
+ case 7:
1037
+ body = _p.apply(_o, [_r.apply(_q, [_u.sent(), contentType]),
1038
+ "ListCollectionsOutputBody", ""]);
1039
+ return [2, new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body)];
1040
+ case 8:
1041
+ _s = exception_1.ApiException.bind;
1042
+ _t = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
1043
+ return [4, response.getBodyAsAny()];
1044
+ case 9: throw new (_s.apply(exception_1.ApiException, _t.concat([_u.sent(), response.headers])))();
1045
+ }
1046
+ });
1047
+ });
1048
+ };
1049
+ CollectionsApiResponseProcessor.prototype.v3PatchCollectionBinariesWithHttpInfo = function (response) {
1050
+ return __awaiter(this, void 0, void 0, function () {
1051
+ var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, body, _j, _k, _l, _m, body, _o, _p, _q, _r, body, _s, _t, _u, _v, body, _w, _x, _y, _z, _0, _1;
1052
+ return __generator(this, function (_2) {
1053
+ switch (_2.label) {
1054
+ case 0:
1055
+ contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
1056
+ if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
1057
+ _b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
1058
+ _d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
1059
+ return [4, response.body.text()];
1060
+ case 1:
1061
+ body = _b.apply(_a, [_d.apply(_c, [_2.sent(), contentType]),
1062
+ "PatchCollectionBinariesOutputBody", ""]);
1063
+ return [2, new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body)];
1064
+ case 2:
1065
+ if (!(0, util_1.isCodeInRange)("403", response.httpStatusCode)) return [3, 4];
1066
+ _f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
1067
+ _h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
1068
+ return [4, response.body.text()];
1069
+ case 3:
1070
+ body = _f.apply(_e, [_h.apply(_g, [_2.sent(), contentType]),
1071
+ "APIError", ""]);
1072
+ throw new exception_1.ApiException(response.httpStatusCode, "Forbidden", body, response.headers);
1073
+ case 4:
1074
+ if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3, 6];
1075
+ _k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
1076
+ _m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
1077
+ return [4, response.body.text()];
1078
+ case 5:
1079
+ body = _k.apply(_j, [_m.apply(_l, [_2.sent(), contentType]),
1080
+ "APIError", ""]);
1081
+ throw new exception_1.ApiException(response.httpStatusCode, "Not Found", body, response.headers);
1082
+ case 6:
1083
+ if (!(0, util_1.isCodeInRange)("422", response.httpStatusCode)) return [3, 8];
1084
+ _p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
1085
+ _r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
1086
+ return [4, response.body.text()];
1087
+ case 7:
1088
+ body = _p.apply(_o, [_r.apply(_q, [_2.sent(), contentType]),
1089
+ "APIError", ""]);
1090
+ throw new exception_1.ApiException(response.httpStatusCode, "Unprocessable Entity", body, response.headers);
1091
+ case 8:
1092
+ if (!(0, util_1.isCodeInRange)("500", response.httpStatusCode)) return [3, 10];
1093
+ _t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
1094
+ _v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
1095
+ return [4, response.body.text()];
1096
+ case 9:
1097
+ body = _t.apply(_s, [_v.apply(_u, [_2.sent(), contentType]),
1098
+ "APIError", ""]);
1099
+ throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
1100
+ case 10:
1101
+ if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 12];
1102
+ _x = (_w = ObjectSerializer_1.ObjectSerializer).deserialize;
1103
+ _z = (_y = ObjectSerializer_1.ObjectSerializer).parse;
1104
+ return [4, response.body.text()];
1105
+ case 11:
1106
+ body = _x.apply(_w, [_z.apply(_y, [_2.sent(), contentType]),
1107
+ "PatchCollectionBinariesOutputBody", ""]);
1108
+ return [2, new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body)];
1109
+ case 12:
1110
+ _0 = exception_1.ApiException.bind;
1111
+ _1 = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
1112
+ return [4, response.getBodyAsAny()];
1113
+ case 13: throw new (_0.apply(exception_1.ApiException, _1.concat([_2.sent(), response.headers])))();
1114
+ }
1115
+ });
1116
+ });
1117
+ };
1118
+ CollectionsApiResponseProcessor.prototype.v3PatchCollectionTagsWithHttpInfo = function (response) {
1119
+ return __awaiter(this, void 0, void 0, function () {
1120
+ var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, body, _j, _k, _l, _m, body, _o, _p, _q, _r, body, _s, _t, _u, _v, body, _w, _x, _y, _z, _0, _1;
1121
+ return __generator(this, function (_2) {
1122
+ switch (_2.label) {
1123
+ case 0:
1124
+ contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
1125
+ if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
1126
+ _b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
1127
+ _d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
1128
+ return [4, response.body.text()];
1129
+ case 1:
1130
+ body = _b.apply(_a, [_d.apply(_c, [_2.sent(), contentType]),
1131
+ "PatchCollectionTagsOutputBody", ""]);
1132
+ return [2, new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body)];
1133
+ case 2:
1134
+ if (!(0, util_1.isCodeInRange)("403", response.httpStatusCode)) return [3, 4];
1135
+ _f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
1136
+ _h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
1137
+ return [4, response.body.text()];
1138
+ case 3:
1139
+ body = _f.apply(_e, [_h.apply(_g, [_2.sent(), contentType]),
1140
+ "APIError", ""]);
1141
+ throw new exception_1.ApiException(response.httpStatusCode, "Forbidden", body, response.headers);
1142
+ case 4:
1143
+ if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3, 6];
1144
+ _k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
1145
+ _m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
1146
+ return [4, response.body.text()];
1147
+ case 5:
1148
+ body = _k.apply(_j, [_m.apply(_l, [_2.sent(), contentType]),
1149
+ "APIError", ""]);
1150
+ throw new exception_1.ApiException(response.httpStatusCode, "Not Found", body, response.headers);
1151
+ case 6:
1152
+ if (!(0, util_1.isCodeInRange)("422", response.httpStatusCode)) return [3, 8];
1153
+ _p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
1154
+ _r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
1155
+ return [4, response.body.text()];
1156
+ case 7:
1157
+ body = _p.apply(_o, [_r.apply(_q, [_2.sent(), contentType]),
1158
+ "APIError", ""]);
1159
+ throw new exception_1.ApiException(response.httpStatusCode, "Unprocessable Entity", body, response.headers);
1160
+ case 8:
1161
+ if (!(0, util_1.isCodeInRange)("500", response.httpStatusCode)) return [3, 10];
1162
+ _t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
1163
+ _v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
1164
+ return [4, response.body.text()];
1165
+ case 9:
1166
+ body = _t.apply(_s, [_v.apply(_u, [_2.sent(), contentType]),
1167
+ "APIError", ""]);
1168
+ throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
1169
+ case 10:
1170
+ if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 12];
1171
+ _x = (_w = ObjectSerializer_1.ObjectSerializer).deserialize;
1172
+ _z = (_y = ObjectSerializer_1.ObjectSerializer).parse;
1173
+ return [4, response.body.text()];
1174
+ case 11:
1175
+ body = _x.apply(_w, [_z.apply(_y, [_2.sent(), contentType]),
1176
+ "PatchCollectionTagsOutputBody", ""]);
1177
+ return [2, new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body)];
1178
+ case 12:
1179
+ _0 = exception_1.ApiException.bind;
1180
+ _1 = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
1181
+ return [4, response.getBodyAsAny()];
1182
+ case 13: throw new (_0.apply(exception_1.ApiException, _1.concat([_2.sent(), response.headers])))();
1183
+ }
1184
+ });
1185
+ });
1186
+ };
661
1187
  return CollectionsApiResponseProcessor;
662
1188
  }());
663
1189
  exports.CollectionsApiResponseProcessor = CollectionsApiResponseProcessor;