@lcdp/api-react-rest-client 2.1.4-test-order-by.4883611692 → 2.1.5

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 (95) hide show
  1. package/package.json +1 -1
  2. package/sale-offer/index.d.ts +1 -0
  3. package/sale-offer/index.js +17 -0
  4. package/sale-offer/src/apis/ManageSaleOfferApi.d.ts +74 -0
  5. package/sale-offer/src/apis/ManageSaleOfferApi.js +371 -0
  6. package/sale-offer/src/apis/ManageSaleOfferStatusApi.d.ts +32 -0
  7. package/sale-offer/src/apis/ManageSaleOfferStatusApi.js +160 -0
  8. package/sale-offer/src/apis/SearchSaleOfferApi.d.ts +105 -0
  9. package/sale-offer/src/apis/SearchSaleOfferApi.js +333 -0
  10. package/sale-offer/src/apis/index.d.ts +3 -0
  11. package/sale-offer/src/apis/index.js +19 -0
  12. package/sale-offer/src/index.d.ts +3 -0
  13. package/sale-offer/src/index.js +19 -0
  14. package/sale-offer/src/models/AnyDistributionMode.d.ts +28 -0
  15. package/sale-offer/src/models/AnyDistributionMode.js +69 -0
  16. package/sale-offer/src/models/AnyIdentifiedDistributionMode.d.ts +28 -0
  17. package/sale-offer/src/models/AnyIdentifiedDistributionMode.js +69 -0
  18. package/sale-offer/src/models/Barcodes.d.ts +45 -0
  19. package/sale-offer/src/models/Barcodes.js +48 -0
  20. package/sale-offer/src/models/DistributionMode.d.ts +39 -0
  21. package/sale-offer/src/models/DistributionMode.js +45 -0
  22. package/sale-offer/src/models/DistributionRange.d.ts +39 -0
  23. package/sale-offer/src/models/DistributionRange.js +45 -0
  24. package/sale-offer/src/models/HttpLink.d.ts +27 -0
  25. package/sale-offer/src/models/HttpLink.js +41 -0
  26. package/sale-offer/src/models/IdentifiedDistributionRange.d.ts +34 -0
  27. package/sale-offer/src/models/IdentifiedDistributionRange.js +49 -0
  28. package/sale-offer/src/models/IdentifiedDistributionRangeAllOf.d.ts +33 -0
  29. package/sale-offer/src/models/IdentifiedDistributionRangeAllOf.js +43 -0
  30. package/sale-offer/src/models/IdentifiedRangeDistributionMode.d.ts +29 -0
  31. package/sale-offer/src/models/IdentifiedRangeDistributionMode.js +50 -0
  32. package/sale-offer/src/models/IdentifiedRangeDistributionModeAllOf.d.ts +28 -0
  33. package/sale-offer/src/models/IdentifiedRangeDistributionModeAllOf.js +42 -0
  34. package/sale-offer/src/models/ImageVersions.d.ts +57 -0
  35. package/sale-offer/src/models/ImageVersions.js +52 -0
  36. package/sale-offer/src/models/Images.d.ts +40 -0
  37. package/sale-offer/src/models/Images.js +47 -0
  38. package/sale-offer/src/models/OwnerLink.d.ts +41 -0
  39. package/sale-offer/src/models/OwnerLink.js +51 -0
  40. package/sale-offer/src/models/OwnerLinkAllOf.d.ts +40 -0
  41. package/sale-offer/src/models/OwnerLinkAllOf.js +47 -0
  42. package/sale-offer/src/models/OwnerLinkAllOfCompany.d.ts +27 -0
  43. package/sale-offer/src/models/OwnerLinkAllOfCompany.js +42 -0
  44. package/sale-offer/src/models/PaginatedObject.d.ts +28 -0
  45. package/sale-offer/src/models/PaginatedObject.js +42 -0
  46. package/sale-offer/src/models/PaginatedSaleOffers.d.ts +29 -0
  47. package/sale-offer/src/models/PaginatedSaleOffers.js +50 -0
  48. package/sale-offer/src/models/PaginatedSaleOffersAllOf.d.ts +28 -0
  49. package/sale-offer/src/models/PaginatedSaleOffersAllOf.js +42 -0
  50. package/sale-offer/src/models/PagingMetadata.d.ts +45 -0
  51. package/sale-offer/src/models/PagingMetadata.js +47 -0
  52. package/sale-offer/src/models/ProductImageLink.d.ts +35 -0
  53. package/sale-offer/src/models/ProductImageLink.js +51 -0
  54. package/sale-offer/src/models/ProductImageLinkAllOf.d.ts +34 -0
  55. package/sale-offer/src/models/ProductImageLinkAllOf.js +45 -0
  56. package/sale-offer/src/models/ProductLink.d.ts +41 -0
  57. package/sale-offer/src/models/ProductLink.js +51 -0
  58. package/sale-offer/src/models/ProductLinkAllOf.d.ts +40 -0
  59. package/sale-offer/src/models/ProductLinkAllOf.js +47 -0
  60. package/sale-offer/src/models/QuotationDistributionMode.d.ts +28 -0
  61. package/sale-offer/src/models/QuotationDistributionMode.js +49 -0
  62. package/sale-offer/src/models/QuotationDistributionModeAllOf.d.ts +27 -0
  63. package/sale-offer/src/models/QuotationDistributionModeAllOf.js +41 -0
  64. package/sale-offer/src/models/RangeDistributionMode.d.ts +29 -0
  65. package/sale-offer/src/models/RangeDistributionMode.js +50 -0
  66. package/sale-offer/src/models/RangeDistributionModeAllOf.d.ts +28 -0
  67. package/sale-offer/src/models/RangeDistributionModeAllOf.js +42 -0
  68. package/sale-offer/src/models/RestError.d.ts +85 -0
  69. package/sale-offer/src/models/RestError.js +97 -0
  70. package/sale-offer/src/models/SaleOffer.d.ts +125 -0
  71. package/sale-offer/src/models/SaleOffer.js +80 -0
  72. package/sale-offer/src/models/SaleOfferCreationImagesParameters.d.ts +39 -0
  73. package/sale-offer/src/models/SaleOfferCreationImagesParameters.js +46 -0
  74. package/sale-offer/src/models/SaleOfferCreationParameters.d.ts +72 -0
  75. package/sale-offer/src/models/SaleOfferCreationParameters.js +59 -0
  76. package/sale-offer/src/models/SaleOfferJournal.d.ts +27 -0
  77. package/sale-offer/src/models/SaleOfferJournal.js +42 -0
  78. package/sale-offer/src/models/SaleOfferNewVersionParameters.d.ts +54 -0
  79. package/sale-offer/src/models/SaleOfferNewVersionParameters.js +53 -0
  80. package/sale-offer/src/models/SaleOfferStatisticLink.d.ts +34 -0
  81. package/sale-offer/src/models/SaleOfferStatisticLink.js +50 -0
  82. package/sale-offer/src/models/SaleOfferStatisticLinkAllOf.d.ts +33 -0
  83. package/sale-offer/src/models/SaleOfferStatisticLinkAllOf.js +44 -0
  84. package/sale-offer/src/models/SaleOfferStatus.d.ts +28 -0
  85. package/sale-offer/src/models/SaleOfferStatus.js +43 -0
  86. package/sale-offer/src/models/Stock.d.ts +39 -0
  87. package/sale-offer/src/models/Stock.js +46 -0
  88. package/sale-offer/src/models/UnitaryDistributionMode.d.ts +34 -0
  89. package/sale-offer/src/models/UnitaryDistributionMode.js +49 -0
  90. package/sale-offer/src/models/UnitaryDistributionModeAllOf.d.ts +33 -0
  91. package/sale-offer/src/models/UnitaryDistributionModeAllOf.js +43 -0
  92. package/sale-offer/src/models/index.d.ts +39 -0
  93. package/sale-offer/src/models/index.js +55 -0
  94. package/sale-offer/src/runtime.d.ts +149 -0
  95. package/sale-offer/src/runtime.js +480 -0
@@ -0,0 +1,46 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * lcdp-monolith-service
6
+ * This is the REST API of LCDP products
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ * Contact: contact@lecomptoirdespharmacies.fr
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.StockToJSON = exports.StockFromJSONTyped = exports.StockFromJSON = void 0;
17
+ var runtime_1 = require("../runtime");
18
+ function StockFromJSON(json) {
19
+ return StockFromJSONTyped(json, false);
20
+ }
21
+ exports.StockFromJSON = StockFromJSON;
22
+ function StockFromJSONTyped(json, ignoreDiscriminator) {
23
+ if ((json === undefined) || (json === null)) {
24
+ return json;
25
+ }
26
+ return {
27
+ 'remainingQuantity': !(0, runtime_1.exists)(json, 'remainingQuantity') ? json['remainingQuantity'] : json['remainingQuantity'],
28
+ 'lapsingDate': !(0, runtime_1.exists)(json, 'lapsingDate') ? json['lapsingDate'] : (new Date(json['lapsingDate'])),
29
+ 'batch': !(0, runtime_1.exists)(json, 'batch') ? json['batch'] : json['batch'],
30
+ };
31
+ }
32
+ exports.StockFromJSONTyped = StockFromJSONTyped;
33
+ function StockToJSON(value) {
34
+ if (value === undefined) {
35
+ return undefined;
36
+ }
37
+ if (value === null) {
38
+ return null;
39
+ }
40
+ return {
41
+ 'remainingQuantity': value.remainingQuantity,
42
+ 'lapsingDate': value.lapsingDate === undefined ? undefined : (value.lapsingDate === null ? null : (0, runtime_1.toDateISOString)(value.lapsingDate)),
43
+ 'batch': value.batch,
44
+ };
45
+ }
46
+ exports.StockToJSON = StockToJSON;
@@ -0,0 +1,34 @@
1
+ /**
2
+ * lcdp-monolith-service
3
+ * This is the REST API of LCDP products
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ * Contact: contact@lecomptoirdespharmacies.fr
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import { DistributionMode } from './DistributionMode';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface UnitaryDistributionMode
17
+ */
18
+ export interface UnitaryDistributionMode extends DistributionMode {
19
+ /**
20
+ * The unit price as a decimal.
21
+ * @type {number}
22
+ * @memberof UnitaryDistributionMode
23
+ */
24
+ unitPrice: number;
25
+ /**
26
+ * Sold by this step value
27
+ * @type {number}
28
+ * @memberof UnitaryDistributionMode
29
+ */
30
+ soldBy: number;
31
+ }
32
+ export declare function UnitaryDistributionModeFromJSON(json: any): UnitaryDistributionMode;
33
+ export declare function UnitaryDistributionModeFromJSONTyped(json: any, ignoreDiscriminator: boolean): UnitaryDistributionMode;
34
+ export declare function UnitaryDistributionModeToJSON(value?: UnitaryDistributionMode | null): any;
@@ -0,0 +1,49 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * lcdp-monolith-service
6
+ * This is the REST API of LCDP products
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ * Contact: contact@lecomptoirdespharmacies.fr
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ var __assign = (this && this.__assign) || function () {
16
+ __assign = Object.assign || function(t) {
17
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
18
+ s = arguments[i];
19
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
20
+ t[p] = s[p];
21
+ }
22
+ return t;
23
+ };
24
+ return __assign.apply(this, arguments);
25
+ };
26
+ Object.defineProperty(exports, "__esModule", { value: true });
27
+ exports.UnitaryDistributionModeToJSON = exports.UnitaryDistributionModeFromJSONTyped = exports.UnitaryDistributionModeFromJSON = void 0;
28
+ var DistributionMode_1 = require("./DistributionMode");
29
+ function UnitaryDistributionModeFromJSON(json) {
30
+ return UnitaryDistributionModeFromJSONTyped(json, false);
31
+ }
32
+ exports.UnitaryDistributionModeFromJSON = UnitaryDistributionModeFromJSON;
33
+ function UnitaryDistributionModeFromJSONTyped(json, ignoreDiscriminator) {
34
+ if ((json === undefined) || (json === null)) {
35
+ return json;
36
+ }
37
+ return __assign(__assign({}, (0, DistributionMode_1.DistributionModeFromJSONTyped)(json, ignoreDiscriminator)), { 'unitPrice': json['unitPrice'], 'soldBy': json['soldBy'] });
38
+ }
39
+ exports.UnitaryDistributionModeFromJSONTyped = UnitaryDistributionModeFromJSONTyped;
40
+ function UnitaryDistributionModeToJSON(value) {
41
+ if (value === undefined) {
42
+ return undefined;
43
+ }
44
+ if (value === null) {
45
+ return null;
46
+ }
47
+ return __assign(__assign({}, (0, DistributionMode_1.DistributionModeToJSON)(value)), { 'unitPrice': value.unitPrice, 'soldBy': value.soldBy });
48
+ }
49
+ exports.UnitaryDistributionModeToJSON = UnitaryDistributionModeToJSON;
@@ -0,0 +1,33 @@
1
+ /**
2
+ * lcdp-monolith-service
3
+ * This is the REST API of LCDP products
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ * Contact: contact@lecomptoirdespharmacies.fr
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface UnitaryDistributionModeAllOf
16
+ */
17
+ export interface UnitaryDistributionModeAllOf {
18
+ /**
19
+ * The unit price as a decimal.
20
+ * @type {number}
21
+ * @memberof UnitaryDistributionModeAllOf
22
+ */
23
+ unitPrice: number;
24
+ /**
25
+ * Sold by this step value
26
+ * @type {number}
27
+ * @memberof UnitaryDistributionModeAllOf
28
+ */
29
+ soldBy: number;
30
+ }
31
+ export declare function UnitaryDistributionModeAllOfFromJSON(json: any): UnitaryDistributionModeAllOf;
32
+ export declare function UnitaryDistributionModeAllOfFromJSONTyped(json: any, ignoreDiscriminator: boolean): UnitaryDistributionModeAllOf;
33
+ export declare function UnitaryDistributionModeAllOfToJSON(value?: UnitaryDistributionModeAllOf | null): any;
@@ -0,0 +1,43 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * lcdp-monolith-service
6
+ * This is the REST API of LCDP products
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ * Contact: contact@lecomptoirdespharmacies.fr
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.UnitaryDistributionModeAllOfToJSON = exports.UnitaryDistributionModeAllOfFromJSONTyped = exports.UnitaryDistributionModeAllOfFromJSON = void 0;
17
+ function UnitaryDistributionModeAllOfFromJSON(json) {
18
+ return UnitaryDistributionModeAllOfFromJSONTyped(json, false);
19
+ }
20
+ exports.UnitaryDistributionModeAllOfFromJSON = UnitaryDistributionModeAllOfFromJSON;
21
+ function UnitaryDistributionModeAllOfFromJSONTyped(json, ignoreDiscriminator) {
22
+ if ((json === undefined) || (json === null)) {
23
+ return json;
24
+ }
25
+ return {
26
+ 'unitPrice': json['unitPrice'],
27
+ 'soldBy': json['soldBy'],
28
+ };
29
+ }
30
+ exports.UnitaryDistributionModeAllOfFromJSONTyped = UnitaryDistributionModeAllOfFromJSONTyped;
31
+ function UnitaryDistributionModeAllOfToJSON(value) {
32
+ if (value === undefined) {
33
+ return undefined;
34
+ }
35
+ if (value === null) {
36
+ return null;
37
+ }
38
+ return {
39
+ 'unitPrice': value.unitPrice,
40
+ 'soldBy': value.soldBy,
41
+ };
42
+ }
43
+ exports.UnitaryDistributionModeAllOfToJSON = UnitaryDistributionModeAllOfToJSON;
@@ -0,0 +1,39 @@
1
+ export * from './AnyDistributionMode';
2
+ export * from './AnyIdentifiedDistributionMode';
3
+ export * from './Barcodes';
4
+ export * from './DistributionMode';
5
+ export * from './DistributionRange';
6
+ export * from './HttpLink';
7
+ export * from './IdentifiedDistributionRange';
8
+ export * from './IdentifiedDistributionRangeAllOf';
9
+ export * from './IdentifiedRangeDistributionMode';
10
+ export * from './IdentifiedRangeDistributionModeAllOf';
11
+ export * from './ImageVersions';
12
+ export * from './Images';
13
+ export * from './OwnerLink';
14
+ export * from './OwnerLinkAllOf';
15
+ export * from './OwnerLinkAllOfCompany';
16
+ export * from './PaginatedObject';
17
+ export * from './PaginatedSaleOffers';
18
+ export * from './PaginatedSaleOffersAllOf';
19
+ export * from './PagingMetadata';
20
+ export * from './ProductImageLink';
21
+ export * from './ProductImageLinkAllOf';
22
+ export * from './ProductLink';
23
+ export * from './ProductLinkAllOf';
24
+ export * from './QuotationDistributionMode';
25
+ export * from './QuotationDistributionModeAllOf';
26
+ export * from './RangeDistributionMode';
27
+ export * from './RangeDistributionModeAllOf';
28
+ export * from './RestError';
29
+ export * from './SaleOffer';
30
+ export * from './SaleOfferCreationImagesParameters';
31
+ export * from './SaleOfferCreationParameters';
32
+ export * from './SaleOfferJournal';
33
+ export * from './SaleOfferNewVersionParameters';
34
+ export * from './SaleOfferStatisticLink';
35
+ export * from './SaleOfferStatisticLinkAllOf';
36
+ export * from './SaleOfferStatus';
37
+ export * from './Stock';
38
+ export * from './UnitaryDistributionMode';
39
+ export * from './UnitaryDistributionModeAllOf';
@@ -0,0 +1,55 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./AnyDistributionMode"), exports);
18
+ __exportStar(require("./AnyIdentifiedDistributionMode"), exports);
19
+ __exportStar(require("./Barcodes"), exports);
20
+ __exportStar(require("./DistributionMode"), exports);
21
+ __exportStar(require("./DistributionRange"), exports);
22
+ __exportStar(require("./HttpLink"), exports);
23
+ __exportStar(require("./IdentifiedDistributionRange"), exports);
24
+ __exportStar(require("./IdentifiedDistributionRangeAllOf"), exports);
25
+ __exportStar(require("./IdentifiedRangeDistributionMode"), exports);
26
+ __exportStar(require("./IdentifiedRangeDistributionModeAllOf"), exports);
27
+ __exportStar(require("./ImageVersions"), exports);
28
+ __exportStar(require("./Images"), exports);
29
+ __exportStar(require("./OwnerLink"), exports);
30
+ __exportStar(require("./OwnerLinkAllOf"), exports);
31
+ __exportStar(require("./OwnerLinkAllOfCompany"), exports);
32
+ __exportStar(require("./PaginatedObject"), exports);
33
+ __exportStar(require("./PaginatedSaleOffers"), exports);
34
+ __exportStar(require("./PaginatedSaleOffersAllOf"), exports);
35
+ __exportStar(require("./PagingMetadata"), exports);
36
+ __exportStar(require("./ProductImageLink"), exports);
37
+ __exportStar(require("./ProductImageLinkAllOf"), exports);
38
+ __exportStar(require("./ProductLink"), exports);
39
+ __exportStar(require("./ProductLinkAllOf"), exports);
40
+ __exportStar(require("./QuotationDistributionMode"), exports);
41
+ __exportStar(require("./QuotationDistributionModeAllOf"), exports);
42
+ __exportStar(require("./RangeDistributionMode"), exports);
43
+ __exportStar(require("./RangeDistributionModeAllOf"), exports);
44
+ __exportStar(require("./RestError"), exports);
45
+ __exportStar(require("./SaleOffer"), exports);
46
+ __exportStar(require("./SaleOfferCreationImagesParameters"), exports);
47
+ __exportStar(require("./SaleOfferCreationParameters"), exports);
48
+ __exportStar(require("./SaleOfferJournal"), exports);
49
+ __exportStar(require("./SaleOfferNewVersionParameters"), exports);
50
+ __exportStar(require("./SaleOfferStatisticLink"), exports);
51
+ __exportStar(require("./SaleOfferStatisticLinkAllOf"), exports);
52
+ __exportStar(require("./SaleOfferStatus"), exports);
53
+ __exportStar(require("./Stock"), exports);
54
+ __exportStar(require("./UnitaryDistributionMode"), exports);
55
+ __exportStar(require("./UnitaryDistributionModeAllOf"), exports);
@@ -0,0 +1,149 @@
1
+ /**
2
+ * lcdp-monolith-service
3
+ * This is the REST API of LCDP products
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ * Contact: contact@lecomptoirdespharmacies.fr
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ export declare const BASE_PATH = "/api/v1";
13
+ /**
14
+ * This is the base class for all generated API classes.
15
+ */
16
+ export declare class BaseAPI {
17
+ protected configuration: Configuration;
18
+ private middleware;
19
+ constructor(configuration?: Configuration);
20
+ withMiddleware<T extends BaseAPI>(this: T, ...middlewares: Middleware[]): T;
21
+ withPreMiddleware<T extends BaseAPI>(this: T, ...preMiddlewares: Array<Middleware['pre']>): T;
22
+ withPostMiddleware<T extends BaseAPI>(this: T, ...postMiddlewares: Array<Middleware['post']>): T;
23
+ protected request(context: RequestOpts): Promise<Response>;
24
+ private createFetchParams;
25
+ private fetchApi;
26
+ /**
27
+ * Create a shallow clone of `this` by constructing a new instance
28
+ * and then shallow cloning data members.
29
+ */
30
+ private clone;
31
+ }
32
+ export declare class RequiredError extends Error {
33
+ field: string;
34
+ name: "RequiredError";
35
+ constructor(field: string, msg?: string);
36
+ }
37
+ export declare const COLLECTION_FORMATS: {
38
+ csv: string;
39
+ ssv: string;
40
+ tsv: string;
41
+ pipes: string;
42
+ };
43
+ export declare type FetchAPI = WindowOrWorkerGlobalScope['fetch'];
44
+ export interface ConfigurationParameters {
45
+ basePath?: string;
46
+ fetchApi?: FetchAPI;
47
+ middleware?: Middleware[];
48
+ queryParamsStringify?: (params: HTTPQuery) => string;
49
+ username?: string;
50
+ password?: string;
51
+ apiKey?: string | ((name: string) => string);
52
+ accessToken?: string | ((name?: string, scopes?: string[]) => string);
53
+ headers?: HTTPHeaders;
54
+ credentials?: RequestCredentials;
55
+ referrerPolicy?: ReferrerPolicy;
56
+ }
57
+ export declare class Configuration {
58
+ private configuration;
59
+ constructor(configuration?: ConfigurationParameters);
60
+ get basePath(): string;
61
+ get fetchApi(): FetchAPI;
62
+ get middleware(): Middleware[];
63
+ get queryParamsStringify(): (params: HTTPQuery) => string;
64
+ get username(): string | undefined;
65
+ get password(): string | undefined;
66
+ get apiKey(): ((name: string) => string) | undefined;
67
+ get accessToken(): ((name: string, scopes?: string[]) => string) | undefined;
68
+ get headers(): HTTPHeaders | undefined;
69
+ get credentials(): RequestCredentials | undefined;
70
+ get referrerPolicy(): ReferrerPolicy | undefined;
71
+ }
72
+ export declare type Json = any;
73
+ export declare type HTTPMethod = 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE' | 'OPTIONS' | 'HEAD';
74
+ export declare type HTTPHeaders = {
75
+ [key: string]: string;
76
+ };
77
+ export declare type HTTPQuery = {
78
+ [key: string]: string | number | null | boolean | Array<string | number | null | boolean> | HTTPQuery;
79
+ };
80
+ export declare type HTTPBody = Json | FormData | URLSearchParams;
81
+ export declare type ModelPropertyNaming = 'camelCase' | 'snake_case' | 'PascalCase' | 'original';
82
+ export interface FetchParams {
83
+ url: string;
84
+ init: RequestInit;
85
+ }
86
+ export interface RequestOpts {
87
+ path: string;
88
+ method: HTTPMethod;
89
+ headers: HTTPHeaders;
90
+ query?: HTTPQuery;
91
+ body?: HTTPBody;
92
+ }
93
+ export declare function exists(json: any, key: string): boolean;
94
+ export declare function querystring(params: HTTPQuery, prefix?: string): string;
95
+ export declare function mapValues(data: any, fn: (item: any) => any): {};
96
+ export declare function canConsumeForm(consumes: Consume[]): boolean;
97
+ export declare function toDateISOString(date: Date): string;
98
+ export interface Consume {
99
+ contentType: string;
100
+ }
101
+ export interface RequestContext {
102
+ fetch: FetchAPI;
103
+ url: string;
104
+ init: RequestInit;
105
+ }
106
+ export interface ResponseContext {
107
+ fetch: FetchAPI;
108
+ url: string;
109
+ init: RequestInit;
110
+ response: Response;
111
+ }
112
+ export interface Middleware {
113
+ pre?(context: RequestContext): Promise<FetchParams | void>;
114
+ post?(context: ResponseContext): Promise<Response | void>;
115
+ }
116
+ export interface ApiResponse<T> {
117
+ raw: Response;
118
+ value(): Promise<T>;
119
+ }
120
+ export interface ResponseTransformer<T> {
121
+ (json: any): T;
122
+ }
123
+ export declare class JSONApiResponse<T> {
124
+ raw: Response;
125
+ private transformer;
126
+ constructor(raw: Response, transformer?: ResponseTransformer<T>);
127
+ value(): Promise<T>;
128
+ }
129
+ export declare class VoidApiResponse {
130
+ raw: Response;
131
+ constructor(raw: Response);
132
+ value(): Promise<void>;
133
+ }
134
+ export interface BlobWithMeta {
135
+ blob: Blob;
136
+ filename: string;
137
+ }
138
+ export declare function instanceOfBlobWithMeta(object: any): object is BlobWithMeta;
139
+ export declare class BlobWithMetaApiResponse {
140
+ raw: Response;
141
+ constructor(raw: Response);
142
+ value(): Promise<BlobWithMeta>;
143
+ private extractFilename;
144
+ }
145
+ export declare class TextApiResponse {
146
+ raw: Response;
147
+ constructor(raw: Response);
148
+ value(): Promise<string>;
149
+ }