@lcdp/api-react-rest-client 2.0.4-develop.4173211776 → 2.0.4-develop.4175536114
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/package.json
CHANGED
|
@@ -10,7 +10,10 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import { BaseAPI, ApiResponse, BlobWithMeta } from '../runtime';
|
|
13
|
-
import { PaginatedSaleOfferStatistics } from '../models';
|
|
13
|
+
import { PaginatedSaleOfferStatistics, SaleOfferStatistic } from '../models';
|
|
14
|
+
export interface GetSaleOfferStatisticRequest {
|
|
15
|
+
saleOfferStatisticId: string;
|
|
16
|
+
}
|
|
14
17
|
export interface GetSaleOfferStatisticsRequest {
|
|
15
18
|
refEq?: Array<string>;
|
|
16
19
|
oEq?: Array<number>;
|
|
@@ -22,6 +25,14 @@ export interface GetSaleOfferStatisticsRequest {
|
|
|
22
25
|
* no description
|
|
23
26
|
*/
|
|
24
27
|
export declare class SearchSaleOfferStatisticsApi extends BaseAPI {
|
|
28
|
+
/**
|
|
29
|
+
* Get a sale offer statistic
|
|
30
|
+
*/
|
|
31
|
+
getSaleOfferStatisticRaw(requestParameters: GetSaleOfferStatisticRequest): Promise<ApiResponse<SaleOfferStatistic | BlobWithMeta>>;
|
|
32
|
+
/**
|
|
33
|
+
* Get a sale offer statistic
|
|
34
|
+
*/
|
|
35
|
+
getSaleOfferStatistic(requestParameters: GetSaleOfferStatisticRequest): Promise<SaleOfferStatistic | BlobWithMeta>;
|
|
25
36
|
/**
|
|
26
37
|
* Search sale offers statistics
|
|
27
38
|
*/
|
|
@@ -75,12 +75,85 @@ var SearchSaleOfferStatisticsApi = /** @class */ (function (_super) {
|
|
|
75
75
|
function SearchSaleOfferStatisticsApi() {
|
|
76
76
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
77
77
|
}
|
|
78
|
+
/**
|
|
79
|
+
* Get a sale offer statistic
|
|
80
|
+
*/
|
|
81
|
+
SearchSaleOfferStatisticsApi.prototype.getSaleOfferStatisticRaw = function (requestParameters) {
|
|
82
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
83
|
+
var queryParameters, headerParameters, token, tokenString, response, contentType, response_1;
|
|
84
|
+
return __generator(this, function (_a) {
|
|
85
|
+
switch (_a.label) {
|
|
86
|
+
case 0:
|
|
87
|
+
if (requestParameters.saleOfferStatisticId === null || requestParameters.saleOfferStatisticId === undefined) {
|
|
88
|
+
throw new runtime_1.RequiredError('saleOfferStatisticId', 'Required parameter requestParameters.saleOfferStatisticId was null or undefined when calling getSaleOfferStatistic.');
|
|
89
|
+
}
|
|
90
|
+
queryParameters = {};
|
|
91
|
+
headerParameters = {};
|
|
92
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
93
|
+
headerParameters["x-api-key"] = this.configuration.apiKey("x-api-key"); // apiKeyAuth authentication
|
|
94
|
+
}
|
|
95
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
96
|
+
token = this.configuration.accessToken;
|
|
97
|
+
tokenString = typeof token === 'function' ? token("bearerAuth", []) : token;
|
|
98
|
+
if (tokenString) {
|
|
99
|
+
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
_a.label = 1;
|
|
103
|
+
case 1:
|
|
104
|
+
_a.trys.push([1, 3, , 4]);
|
|
105
|
+
return [4 /*yield*/, this.request({
|
|
106
|
+
path: "/sale-offer-statistics/{saleOfferStatisticId}".replace("{".concat("saleOfferStatisticId", "}"), encodeURIComponent(String(requestParameters.saleOfferStatisticId))),
|
|
107
|
+
method: 'GET',
|
|
108
|
+
headers: headerParameters,
|
|
109
|
+
query: queryParameters,
|
|
110
|
+
})];
|
|
111
|
+
case 2:
|
|
112
|
+
response = _a.sent();
|
|
113
|
+
contentType = response.headers.get("content-type");
|
|
114
|
+
if (contentType && contentType.indexOf("application/json") !== -1) {
|
|
115
|
+
return [2 /*return*/, new runtime_1.JSONApiResponse(response, function (jsonValue) { return (0, models_1.SaleOfferStatisticFromJSON)(jsonValue); })];
|
|
116
|
+
}
|
|
117
|
+
else if (contentType && contentType.indexOf("text/plain") !== -1) {
|
|
118
|
+
return [2 /*return*/, new runtime_1.TextApiResponse(response)];
|
|
119
|
+
}
|
|
120
|
+
else {
|
|
121
|
+
// TODO : Better handling of others application types
|
|
122
|
+
return [2 /*return*/, new runtime_1.BlobWithMetaApiResponse(response)];
|
|
123
|
+
}
|
|
124
|
+
return [3 /*break*/, 4];
|
|
125
|
+
case 3:
|
|
126
|
+
response_1 = _a.sent();
|
|
127
|
+
console.debug(response_1);
|
|
128
|
+
throw response_1;
|
|
129
|
+
case 4: return [2 /*return*/];
|
|
130
|
+
}
|
|
131
|
+
});
|
|
132
|
+
});
|
|
133
|
+
};
|
|
134
|
+
/**
|
|
135
|
+
* Get a sale offer statistic
|
|
136
|
+
*/
|
|
137
|
+
SearchSaleOfferStatisticsApi.prototype.getSaleOfferStatistic = function (requestParameters) {
|
|
138
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
139
|
+
var response;
|
|
140
|
+
return __generator(this, function (_a) {
|
|
141
|
+
switch (_a.label) {
|
|
142
|
+
case 0: return [4 /*yield*/, this.getSaleOfferStatisticRaw(requestParameters)];
|
|
143
|
+
case 1:
|
|
144
|
+
response = _a.sent();
|
|
145
|
+
return [4 /*yield*/, response.value()];
|
|
146
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
147
|
+
}
|
|
148
|
+
});
|
|
149
|
+
});
|
|
150
|
+
};
|
|
78
151
|
/**
|
|
79
152
|
* Search sale offers statistics
|
|
80
153
|
*/
|
|
81
154
|
SearchSaleOfferStatisticsApi.prototype.getSaleOfferStatisticsRaw = function (requestParameters) {
|
|
82
155
|
return __awaiter(this, void 0, void 0, function () {
|
|
83
|
-
var queryParameters, headerParameters, token, tokenString, response, contentType,
|
|
156
|
+
var queryParameters, headerParameters, token, tokenString, response, contentType, response_2;
|
|
84
157
|
return __generator(this, function (_a) {
|
|
85
158
|
switch (_a.label) {
|
|
86
159
|
case 0:
|
|
@@ -135,9 +208,9 @@ var SearchSaleOfferStatisticsApi = /** @class */ (function (_super) {
|
|
|
135
208
|
}
|
|
136
209
|
return [3 /*break*/, 4];
|
|
137
210
|
case 3:
|
|
138
|
-
|
|
139
|
-
console.debug(
|
|
140
|
-
throw
|
|
211
|
+
response_2 = _a.sent();
|
|
212
|
+
console.debug(response_2);
|
|
213
|
+
throw response_2;
|
|
141
214
|
case 4: return [2 /*return*/];
|
|
142
215
|
}
|
|
143
216
|
});
|