@randock/nameshift-api-client 0.0.304 → 0.0.306
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/.openapi-generator/FILES +3 -0
- package/README.md +3 -3
- package/dist/apis/AdminApi.d.ts +15 -6
- package/dist/apis/AdminApi.js +62 -25
- package/dist/apis/StatsApi.d.ts +26 -9
- package/dist/apis/StatsApi.js +118 -30
- package/dist/models/SellerRemainingAndTotalLeaseToOwnByCurrencyStatsItemDto.d.ts +50 -0
- package/dist/models/SellerRemainingAndTotalLeaseToOwnByCurrencyStatsItemDto.js +63 -0
- package/dist/models/SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto.d.ts +44 -0
- package/dist/models/SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto.js +59 -0
- package/dist/models/StatsFilterInputDateRange.d.ts +38 -0
- package/dist/models/StatsFilterInputDateRange.js +55 -0
- package/dist/models/index.d.ts +3 -0
- package/dist/models/index.js +3 -0
- package/package.json +1 -1
- package/src/apis/AdminApi.ts +54 -47
- package/src/apis/StatsApi.ts +91 -47
- package/src/models/SellerRemainingAndTotalLeaseToOwnByCurrencyStatsItemDto.ts +93 -0
- package/src/models/SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto.ts +84 -0
- package/src/models/StatsFilterInputDateRange.ts +75 -0
- package/src/models/index.ts +3 -0
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Nameshift
|
|
3
|
+
* Nameshift API
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0
|
|
6
|
+
*
|
|
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 SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto
|
|
16
|
+
*/
|
|
17
|
+
export interface SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {number}
|
|
21
|
+
* @memberof SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto
|
|
22
|
+
*/
|
|
23
|
+
total: number;
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @type {string}
|
|
27
|
+
* @memberof SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto
|
|
28
|
+
*/
|
|
29
|
+
currency: string;
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {number}
|
|
33
|
+
* @memberof SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto
|
|
34
|
+
*/
|
|
35
|
+
count: number;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Check if a given object implements the SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto interface.
|
|
39
|
+
*/
|
|
40
|
+
export declare function instanceOfSellerTotalRentMonthlyIncomeByCurrencyStatsItemDto(value: object): value is SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto;
|
|
41
|
+
export declare function SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoFromJSON(json: any): SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto;
|
|
42
|
+
export declare function SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto;
|
|
43
|
+
export declare function SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoToJSON(json: any): SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto;
|
|
44
|
+
export declare function SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoToJSONTyped(value?: SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Nameshift
|
|
6
|
+
* Nameshift API
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0
|
|
9
|
+
*
|
|
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.instanceOfSellerTotalRentMonthlyIncomeByCurrencyStatsItemDto = instanceOfSellerTotalRentMonthlyIncomeByCurrencyStatsItemDto;
|
|
17
|
+
exports.SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoFromJSON = SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoFromJSON;
|
|
18
|
+
exports.SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoFromJSONTyped = SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoFromJSONTyped;
|
|
19
|
+
exports.SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoToJSON = SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoToJSON;
|
|
20
|
+
exports.SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoToJSONTyped = SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoToJSONTyped;
|
|
21
|
+
/**
|
|
22
|
+
* Check if a given object implements the SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto interface.
|
|
23
|
+
*/
|
|
24
|
+
function instanceOfSellerTotalRentMonthlyIncomeByCurrencyStatsItemDto(value) {
|
|
25
|
+
if (!('total' in value) || value['total'] === undefined)
|
|
26
|
+
return false;
|
|
27
|
+
if (!('currency' in value) || value['currency'] === undefined)
|
|
28
|
+
return false;
|
|
29
|
+
if (!('count' in value) || value['count'] === undefined)
|
|
30
|
+
return false;
|
|
31
|
+
return true;
|
|
32
|
+
}
|
|
33
|
+
function SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoFromJSON(json) {
|
|
34
|
+
return SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoFromJSONTyped(json, false);
|
|
35
|
+
}
|
|
36
|
+
function SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoFromJSONTyped(json, ignoreDiscriminator) {
|
|
37
|
+
if (json == null) {
|
|
38
|
+
return json;
|
|
39
|
+
}
|
|
40
|
+
return {
|
|
41
|
+
'total': json['total'],
|
|
42
|
+
'currency': json['currency'],
|
|
43
|
+
'count': json['count'],
|
|
44
|
+
};
|
|
45
|
+
}
|
|
46
|
+
function SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoToJSON(json) {
|
|
47
|
+
return SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoToJSONTyped(json, false);
|
|
48
|
+
}
|
|
49
|
+
function SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoToJSONTyped(value, ignoreDiscriminator) {
|
|
50
|
+
if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
|
|
51
|
+
if (value == null) {
|
|
52
|
+
return value;
|
|
53
|
+
}
|
|
54
|
+
return {
|
|
55
|
+
'total': value['total'],
|
|
56
|
+
'currency': value['currency'],
|
|
57
|
+
'count': value['count'],
|
|
58
|
+
};
|
|
59
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Nameshift
|
|
3
|
+
* Nameshift API
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0
|
|
6
|
+
*
|
|
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 StatsFilterInputDateRange
|
|
16
|
+
*/
|
|
17
|
+
export interface StatsFilterInputDateRange {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {Date}
|
|
21
|
+
* @memberof StatsFilterInputDateRange
|
|
22
|
+
*/
|
|
23
|
+
startDate: Date;
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @type {Date}
|
|
27
|
+
* @memberof StatsFilterInputDateRange
|
|
28
|
+
*/
|
|
29
|
+
endDate: Date;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Check if a given object implements the StatsFilterInputDateRange interface.
|
|
33
|
+
*/
|
|
34
|
+
export declare function instanceOfStatsFilterInputDateRange(value: object): value is StatsFilterInputDateRange;
|
|
35
|
+
export declare function StatsFilterInputDateRangeFromJSON(json: any): StatsFilterInputDateRange;
|
|
36
|
+
export declare function StatsFilterInputDateRangeFromJSONTyped(json: any, ignoreDiscriminator: boolean): StatsFilterInputDateRange;
|
|
37
|
+
export declare function StatsFilterInputDateRangeToJSON(json: any): StatsFilterInputDateRange;
|
|
38
|
+
export declare function StatsFilterInputDateRangeToJSONTyped(value?: StatsFilterInputDateRange | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Nameshift
|
|
6
|
+
* Nameshift API
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0
|
|
9
|
+
*
|
|
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.instanceOfStatsFilterInputDateRange = instanceOfStatsFilterInputDateRange;
|
|
17
|
+
exports.StatsFilterInputDateRangeFromJSON = StatsFilterInputDateRangeFromJSON;
|
|
18
|
+
exports.StatsFilterInputDateRangeFromJSONTyped = StatsFilterInputDateRangeFromJSONTyped;
|
|
19
|
+
exports.StatsFilterInputDateRangeToJSON = StatsFilterInputDateRangeToJSON;
|
|
20
|
+
exports.StatsFilterInputDateRangeToJSONTyped = StatsFilterInputDateRangeToJSONTyped;
|
|
21
|
+
/**
|
|
22
|
+
* Check if a given object implements the StatsFilterInputDateRange interface.
|
|
23
|
+
*/
|
|
24
|
+
function instanceOfStatsFilterInputDateRange(value) {
|
|
25
|
+
if (!('startDate' in value) || value['startDate'] === undefined)
|
|
26
|
+
return false;
|
|
27
|
+
if (!('endDate' in value) || value['endDate'] === undefined)
|
|
28
|
+
return false;
|
|
29
|
+
return true;
|
|
30
|
+
}
|
|
31
|
+
function StatsFilterInputDateRangeFromJSON(json) {
|
|
32
|
+
return StatsFilterInputDateRangeFromJSONTyped(json, false);
|
|
33
|
+
}
|
|
34
|
+
function StatsFilterInputDateRangeFromJSONTyped(json, ignoreDiscriminator) {
|
|
35
|
+
if (json == null) {
|
|
36
|
+
return json;
|
|
37
|
+
}
|
|
38
|
+
return {
|
|
39
|
+
'startDate': (new Date(json['startDate'])),
|
|
40
|
+
'endDate': (new Date(json['endDate'])),
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
function StatsFilterInputDateRangeToJSON(json) {
|
|
44
|
+
return StatsFilterInputDateRangeToJSONTyped(json, false);
|
|
45
|
+
}
|
|
46
|
+
function StatsFilterInputDateRangeToJSONTyped(value, ignoreDiscriminator) {
|
|
47
|
+
if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
|
|
48
|
+
if (value == null) {
|
|
49
|
+
return value;
|
|
50
|
+
}
|
|
51
|
+
return {
|
|
52
|
+
'startDate': ((value['startDate']).toISOString()),
|
|
53
|
+
'endDate': ((value['endDate']).toISOString()),
|
|
54
|
+
};
|
|
55
|
+
}
|
package/dist/models/index.d.ts
CHANGED
|
@@ -220,6 +220,7 @@ export * from './SellerInvoiceDomainDto';
|
|
|
220
220
|
export * from './SellerInvoiceDto';
|
|
221
221
|
export * from './SellerInvoiceSellerAccountDto';
|
|
222
222
|
export * from './SellerPendingPayoutsByCurrencyStatsItemDto';
|
|
223
|
+
export * from './SellerRemainingAndTotalLeaseToOwnByCurrencyStatsItemDto';
|
|
223
224
|
export * from './SellerSalesCountStatsItemDto';
|
|
224
225
|
export * from './SellerSecurityUserAccountDto';
|
|
225
226
|
export * from './SellerSecurityUserDto';
|
|
@@ -227,6 +228,7 @@ export * from './SellerSubscriptionListItemDto';
|
|
|
227
228
|
export * from './SellerSubscriptionListItemDtoDomainInformation';
|
|
228
229
|
export * from './SellerTotalEarningsByCurrencyOverTimeStatsItemDto';
|
|
229
230
|
export * from './SellerTotalEarningsByCurrencyStatsItemDto';
|
|
231
|
+
export * from './SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto';
|
|
230
232
|
export * from './SendAdminLeadAiPriceNegotiatorAgentChatMessageInput';
|
|
231
233
|
export * from './SendAdminLeadAiPriceNegotiatorAgentChatMessageInputAiModel';
|
|
232
234
|
export * from './SeoMetricsDto';
|
|
@@ -235,6 +237,7 @@ export * from './SetDomainTransferConfirmationInput';
|
|
|
235
237
|
export * from './SetNewPasswordInput';
|
|
236
238
|
export * from './SetPayoutProviderInput';
|
|
237
239
|
export * from './SortDto';
|
|
240
|
+
export * from './StatsFilterInputDateRange';
|
|
238
241
|
export * from './StoreBuyerLocaleInput';
|
|
239
242
|
export * from './StoreUserLocaleInput';
|
|
240
243
|
export * from './SubscriptionBillingPeriodicityDto';
|
package/dist/models/index.js
CHANGED
|
@@ -238,6 +238,7 @@ __exportStar(require("./SellerInvoiceDomainDto"), exports);
|
|
|
238
238
|
__exportStar(require("./SellerInvoiceDto"), exports);
|
|
239
239
|
__exportStar(require("./SellerInvoiceSellerAccountDto"), exports);
|
|
240
240
|
__exportStar(require("./SellerPendingPayoutsByCurrencyStatsItemDto"), exports);
|
|
241
|
+
__exportStar(require("./SellerRemainingAndTotalLeaseToOwnByCurrencyStatsItemDto"), exports);
|
|
241
242
|
__exportStar(require("./SellerSalesCountStatsItemDto"), exports);
|
|
242
243
|
__exportStar(require("./SellerSecurityUserAccountDto"), exports);
|
|
243
244
|
__exportStar(require("./SellerSecurityUserDto"), exports);
|
|
@@ -245,6 +246,7 @@ __exportStar(require("./SellerSubscriptionListItemDto"), exports);
|
|
|
245
246
|
__exportStar(require("./SellerSubscriptionListItemDtoDomainInformation"), exports);
|
|
246
247
|
__exportStar(require("./SellerTotalEarningsByCurrencyOverTimeStatsItemDto"), exports);
|
|
247
248
|
__exportStar(require("./SellerTotalEarningsByCurrencyStatsItemDto"), exports);
|
|
249
|
+
__exportStar(require("./SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto"), exports);
|
|
248
250
|
__exportStar(require("./SendAdminLeadAiPriceNegotiatorAgentChatMessageInput"), exports);
|
|
249
251
|
__exportStar(require("./SendAdminLeadAiPriceNegotiatorAgentChatMessageInputAiModel"), exports);
|
|
250
252
|
__exportStar(require("./SeoMetricsDto"), exports);
|
|
@@ -253,6 +255,7 @@ __exportStar(require("./SetDomainTransferConfirmationInput"), exports);
|
|
|
253
255
|
__exportStar(require("./SetNewPasswordInput"), exports);
|
|
254
256
|
__exportStar(require("./SetPayoutProviderInput"), exports);
|
|
255
257
|
__exportStar(require("./SortDto"), exports);
|
|
258
|
+
__exportStar(require("./StatsFilterInputDateRange"), exports);
|
|
256
259
|
__exportStar(require("./StoreBuyerLocaleInput"), exports);
|
|
257
260
|
__exportStar(require("./StoreUserLocaleInput"), exports);
|
|
258
261
|
__exportStar(require("./SubscriptionBillingPeriodicityDto"), exports);
|
package/package.json
CHANGED
package/src/apis/AdminApi.ts
CHANGED
|
@@ -36,6 +36,7 @@ import type {
|
|
|
36
36
|
ListDomains200Response,
|
|
37
37
|
NotFoundException,
|
|
38
38
|
ObjectId,
|
|
39
|
+
SellerSalesCountStatsItemDto,
|
|
39
40
|
SendAdminLeadAiPriceNegotiatorAgentChatMessageInput,
|
|
40
41
|
SubscriptionDetailsDto,
|
|
41
42
|
ThrottlerException,
|
|
@@ -84,6 +85,8 @@ import {
|
|
|
84
85
|
NotFoundExceptionToJSON,
|
|
85
86
|
ObjectIdFromJSON,
|
|
86
87
|
ObjectIdToJSON,
|
|
88
|
+
SellerSalesCountStatsItemDtoFromJSON,
|
|
89
|
+
SellerSalesCountStatsItemDtoToJSON,
|
|
87
90
|
SendAdminLeadAiPriceNegotiatorAgentChatMessageInputFromJSON,
|
|
88
91
|
SendAdminLeadAiPriceNegotiatorAgentChatMessageInputToJSON,
|
|
89
92
|
SubscriptionDetailsDtoFromJSON,
|
|
@@ -131,6 +134,10 @@ export interface AdminApiGetAdminDomainTransferDetailsRequest {
|
|
|
131
134
|
domainTransferId: string;
|
|
132
135
|
}
|
|
133
136
|
|
|
137
|
+
export interface AdminApiGetAllAccountsSalesCountRequest {
|
|
138
|
+
dateRange?: any | null;
|
|
139
|
+
}
|
|
140
|
+
|
|
134
141
|
export interface AdminApiGetAllInvoicesRequest {
|
|
135
142
|
filter?: object;
|
|
136
143
|
page?: number;
|
|
@@ -160,8 +167,7 @@ export interface AdminApiGetAllSubscriptionsRequest {
|
|
|
160
167
|
}
|
|
161
168
|
|
|
162
169
|
export interface AdminApiGetCompanyStatsRequest {
|
|
163
|
-
|
|
164
|
-
endDate: Date;
|
|
170
|
+
dateRange?: any | null;
|
|
165
171
|
}
|
|
166
172
|
|
|
167
173
|
export interface AdminApiGetSubscriptionDetailsRequest {
|
|
@@ -190,11 +196,10 @@ export interface AdminApiListDomainsRequest {
|
|
|
190
196
|
}
|
|
191
197
|
|
|
192
198
|
export interface AdminApiListLedgerMutationsRequest {
|
|
193
|
-
startDate: Date;
|
|
194
|
-
endDate: Date;
|
|
195
199
|
ledgerId: string;
|
|
196
200
|
page: number;
|
|
197
201
|
limit: number;
|
|
202
|
+
dateRange?: any | null;
|
|
198
203
|
}
|
|
199
204
|
|
|
200
205
|
export interface AdminApiLoginAsRequest {
|
|
@@ -597,6 +602,44 @@ export class AdminApi extends runtime.BaseAPI {
|
|
|
597
602
|
return await response.value();
|
|
598
603
|
}
|
|
599
604
|
|
|
605
|
+
/**
|
|
606
|
+
*
|
|
607
|
+
*/
|
|
608
|
+
async getAllAccountsSalesCountRaw(requestParameters: AdminApiGetAllAccountsSalesCountRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<SellerSalesCountStatsItemDto>>> {
|
|
609
|
+
const queryParameters: any = {};
|
|
610
|
+
|
|
611
|
+
if (requestParameters['dateRange'] != null) {
|
|
612
|
+
queryParameters['dateRange'] = requestParameters['dateRange'];
|
|
613
|
+
}
|
|
614
|
+
|
|
615
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
616
|
+
|
|
617
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
618
|
+
const token = this.configuration.accessToken;
|
|
619
|
+
const tokenString = await token("bearer", []);
|
|
620
|
+
|
|
621
|
+
if (tokenString) {
|
|
622
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
623
|
+
}
|
|
624
|
+
}
|
|
625
|
+
const response = await this.request({
|
|
626
|
+
path: `/admin/stats/sales-count`,
|
|
627
|
+
method: 'GET',
|
|
628
|
+
headers: headerParameters,
|
|
629
|
+
query: queryParameters,
|
|
630
|
+
}, initOverrides);
|
|
631
|
+
|
|
632
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(SellerSalesCountStatsItemDtoFromJSON));
|
|
633
|
+
}
|
|
634
|
+
|
|
635
|
+
/**
|
|
636
|
+
*
|
|
637
|
+
*/
|
|
638
|
+
async getAllAccountsSalesCount(requestParameters: AdminApiGetAllAccountsSalesCountRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<SellerSalesCountStatsItemDto>> {
|
|
639
|
+
const response = await this.getAllAccountsSalesCountRaw(requestParameters, initOverrides);
|
|
640
|
+
return await response.value();
|
|
641
|
+
}
|
|
642
|
+
|
|
600
643
|
/**
|
|
601
644
|
*
|
|
602
645
|
*/
|
|
@@ -801,28 +844,10 @@ export class AdminApi extends runtime.BaseAPI {
|
|
|
801
844
|
*
|
|
802
845
|
*/
|
|
803
846
|
async getCompanyStatsRaw(requestParameters: AdminApiGetCompanyStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminCompanyStatsDto>> {
|
|
804
|
-
if (requestParameters['startDate'] == null) {
|
|
805
|
-
throw new runtime.RequiredError(
|
|
806
|
-
'startDate',
|
|
807
|
-
'Required parameter "startDate" was null or undefined when calling getCompanyStats().'
|
|
808
|
-
);
|
|
809
|
-
}
|
|
810
|
-
|
|
811
|
-
if (requestParameters['endDate'] == null) {
|
|
812
|
-
throw new runtime.RequiredError(
|
|
813
|
-
'endDate',
|
|
814
|
-
'Required parameter "endDate" was null or undefined when calling getCompanyStats().'
|
|
815
|
-
);
|
|
816
|
-
}
|
|
817
|
-
|
|
818
847
|
const queryParameters: any = {};
|
|
819
848
|
|
|
820
|
-
if (requestParameters['
|
|
821
|
-
queryParameters['
|
|
822
|
-
}
|
|
823
|
-
|
|
824
|
-
if (requestParameters['endDate'] != null) {
|
|
825
|
-
queryParameters['endDate'] = (requestParameters['endDate'] as any).toISOString();
|
|
849
|
+
if (requestParameters['dateRange'] != null) {
|
|
850
|
+
queryParameters['dateRange'] = requestParameters['dateRange'];
|
|
826
851
|
}
|
|
827
852
|
|
|
828
853
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
@@ -848,7 +873,7 @@ export class AdminApi extends runtime.BaseAPI {
|
|
|
848
873
|
/**
|
|
849
874
|
*
|
|
850
875
|
*/
|
|
851
|
-
async getCompanyStats(requestParameters: AdminApiGetCompanyStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminCompanyStatsDto> {
|
|
876
|
+
async getCompanyStats(requestParameters: AdminApiGetCompanyStatsRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminCompanyStatsDto> {
|
|
852
877
|
const response = await this.getCompanyStatsRaw(requestParameters, initOverrides);
|
|
853
878
|
return await response.value();
|
|
854
879
|
}
|
|
@@ -1048,20 +1073,6 @@ export class AdminApi extends runtime.BaseAPI {
|
|
|
1048
1073
|
*
|
|
1049
1074
|
*/
|
|
1050
1075
|
async listLedgerMutationsRaw(requestParameters: AdminApiListLedgerMutationsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<LedgerMutationsDto>> {
|
|
1051
|
-
if (requestParameters['startDate'] == null) {
|
|
1052
|
-
throw new runtime.RequiredError(
|
|
1053
|
-
'startDate',
|
|
1054
|
-
'Required parameter "startDate" was null or undefined when calling listLedgerMutations().'
|
|
1055
|
-
);
|
|
1056
|
-
}
|
|
1057
|
-
|
|
1058
|
-
if (requestParameters['endDate'] == null) {
|
|
1059
|
-
throw new runtime.RequiredError(
|
|
1060
|
-
'endDate',
|
|
1061
|
-
'Required parameter "endDate" was null or undefined when calling listLedgerMutations().'
|
|
1062
|
-
);
|
|
1063
|
-
}
|
|
1064
|
-
|
|
1065
1076
|
if (requestParameters['ledgerId'] == null) {
|
|
1066
1077
|
throw new runtime.RequiredError(
|
|
1067
1078
|
'ledgerId',
|
|
@@ -1085,14 +1096,6 @@ export class AdminApi extends runtime.BaseAPI {
|
|
|
1085
1096
|
|
|
1086
1097
|
const queryParameters: any = {};
|
|
1087
1098
|
|
|
1088
|
-
if (requestParameters['startDate'] != null) {
|
|
1089
|
-
queryParameters['startDate'] = (requestParameters['startDate'] as any).toISOString();
|
|
1090
|
-
}
|
|
1091
|
-
|
|
1092
|
-
if (requestParameters['endDate'] != null) {
|
|
1093
|
-
queryParameters['endDate'] = (requestParameters['endDate'] as any).toISOString();
|
|
1094
|
-
}
|
|
1095
|
-
|
|
1096
1099
|
if (requestParameters['ledgerId'] != null) {
|
|
1097
1100
|
queryParameters['ledgerId'] = requestParameters['ledgerId'];
|
|
1098
1101
|
}
|
|
@@ -1105,6 +1108,10 @@ export class AdminApi extends runtime.BaseAPI {
|
|
|
1105
1108
|
queryParameters['limit'] = requestParameters['limit'];
|
|
1106
1109
|
}
|
|
1107
1110
|
|
|
1111
|
+
if (requestParameters['dateRange'] != null) {
|
|
1112
|
+
queryParameters['dateRange'] = requestParameters['dateRange'];
|
|
1113
|
+
}
|
|
1114
|
+
|
|
1108
1115
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
1109
1116
|
|
|
1110
1117
|
if (this.configuration && this.configuration.accessToken) {
|
package/src/apis/StatsApi.ts
CHANGED
|
@@ -16,21 +16,27 @@
|
|
|
16
16
|
import * as runtime from '../runtime';
|
|
17
17
|
import type {
|
|
18
18
|
SellerPendingPayoutsByCurrencyStatsItemDto,
|
|
19
|
+
SellerRemainingAndTotalLeaseToOwnByCurrencyStatsItemDto,
|
|
19
20
|
SellerSalesCountStatsItemDto,
|
|
20
21
|
SellerTotalEarningsByCurrencyOverTimeStatsItemDto,
|
|
21
22
|
SellerTotalEarningsByCurrencyStatsItemDto,
|
|
23
|
+
SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto,
|
|
22
24
|
ThrottlerException,
|
|
23
25
|
ValidationException,
|
|
24
26
|
} from '../models/index';
|
|
25
27
|
import {
|
|
26
28
|
SellerPendingPayoutsByCurrencyStatsItemDtoFromJSON,
|
|
27
29
|
SellerPendingPayoutsByCurrencyStatsItemDtoToJSON,
|
|
30
|
+
SellerRemainingAndTotalLeaseToOwnByCurrencyStatsItemDtoFromJSON,
|
|
31
|
+
SellerRemainingAndTotalLeaseToOwnByCurrencyStatsItemDtoToJSON,
|
|
28
32
|
SellerSalesCountStatsItemDtoFromJSON,
|
|
29
33
|
SellerSalesCountStatsItemDtoToJSON,
|
|
30
34
|
SellerTotalEarningsByCurrencyOverTimeStatsItemDtoFromJSON,
|
|
31
35
|
SellerTotalEarningsByCurrencyOverTimeStatsItemDtoToJSON,
|
|
32
36
|
SellerTotalEarningsByCurrencyStatsItemDtoFromJSON,
|
|
33
37
|
SellerTotalEarningsByCurrencyStatsItemDtoToJSON,
|
|
38
|
+
SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoFromJSON,
|
|
39
|
+
SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoToJSON,
|
|
34
40
|
ThrottlerExceptionFromJSON,
|
|
35
41
|
ThrottlerExceptionToJSON,
|
|
36
42
|
ValidationExceptionFromJSON,
|
|
@@ -38,13 +44,15 @@ import {
|
|
|
38
44
|
} from '../models/index';
|
|
39
45
|
|
|
40
46
|
export interface StatsApiGetSalesCountRequest {
|
|
41
|
-
|
|
42
|
-
|
|
47
|
+
dateRange?: any | null;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export interface StatsApiGetTotalEarningsByCurrencyRequest {
|
|
51
|
+
dateRange?: any | null;
|
|
43
52
|
}
|
|
44
53
|
|
|
45
54
|
export interface StatsApiGetTotalEarningsByCurrencyOverTimeRequest {
|
|
46
|
-
|
|
47
|
-
endDate: Date;
|
|
55
|
+
dateRange?: any | null;
|
|
48
56
|
}
|
|
49
57
|
|
|
50
58
|
/**
|
|
@@ -89,29 +97,45 @@ export class StatsApi extends runtime.BaseAPI {
|
|
|
89
97
|
/**
|
|
90
98
|
*
|
|
91
99
|
*/
|
|
92
|
-
async
|
|
93
|
-
|
|
94
|
-
throw new runtime.RequiredError(
|
|
95
|
-
'startDate',
|
|
96
|
-
'Required parameter "startDate" was null or undefined when calling getSalesCount().'
|
|
97
|
-
);
|
|
98
|
-
}
|
|
100
|
+
async getRemainingVsTotalLeaseToOwnByCurrencyRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<SellerRemainingAndTotalLeaseToOwnByCurrencyStatsItemDto>>> {
|
|
101
|
+
const queryParameters: any = {};
|
|
99
102
|
|
|
100
|
-
|
|
101
|
-
throw new runtime.RequiredError(
|
|
102
|
-
'endDate',
|
|
103
|
-
'Required parameter "endDate" was null or undefined when calling getSalesCount().'
|
|
104
|
-
);
|
|
105
|
-
}
|
|
103
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
106
104
|
|
|
107
|
-
|
|
105
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
106
|
+
const token = this.configuration.accessToken;
|
|
107
|
+
const tokenString = await token("bearer", []);
|
|
108
108
|
|
|
109
|
-
|
|
110
|
-
|
|
109
|
+
if (tokenString) {
|
|
110
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
111
|
+
}
|
|
111
112
|
}
|
|
113
|
+
const response = await this.request({
|
|
114
|
+
path: `/private/stats/remaining-vs-total-lease-to-own-by-currency`,
|
|
115
|
+
method: 'GET',
|
|
116
|
+
headers: headerParameters,
|
|
117
|
+
query: queryParameters,
|
|
118
|
+
}, initOverrides);
|
|
119
|
+
|
|
120
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(SellerRemainingAndTotalLeaseToOwnByCurrencyStatsItemDtoFromJSON));
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
/**
|
|
124
|
+
*
|
|
125
|
+
*/
|
|
126
|
+
async getRemainingVsTotalLeaseToOwnByCurrency(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<SellerRemainingAndTotalLeaseToOwnByCurrencyStatsItemDto>> {
|
|
127
|
+
const response = await this.getRemainingVsTotalLeaseToOwnByCurrencyRaw(initOverrides);
|
|
128
|
+
return await response.value();
|
|
129
|
+
}
|
|
112
130
|
|
|
113
|
-
|
|
114
|
-
|
|
131
|
+
/**
|
|
132
|
+
*
|
|
133
|
+
*/
|
|
134
|
+
async getSalesCountRaw(requestParameters: StatsApiGetSalesCountRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<SellerSalesCountStatsItemDto>>> {
|
|
135
|
+
const queryParameters: any = {};
|
|
136
|
+
|
|
137
|
+
if (requestParameters['dateRange'] != null) {
|
|
138
|
+
queryParameters['dateRange'] = requestParameters['dateRange'];
|
|
115
139
|
}
|
|
116
140
|
|
|
117
141
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
@@ -137,7 +161,7 @@ export class StatsApi extends runtime.BaseAPI {
|
|
|
137
161
|
/**
|
|
138
162
|
*
|
|
139
163
|
*/
|
|
140
|
-
async getSalesCount(requestParameters: StatsApiGetSalesCountRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<SellerSalesCountStatsItemDto>> {
|
|
164
|
+
async getSalesCount(requestParameters: StatsApiGetSalesCountRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<SellerSalesCountStatsItemDto>> {
|
|
141
165
|
const response = await this.getSalesCountRaw(requestParameters, initOverrides);
|
|
142
166
|
return await response.value();
|
|
143
167
|
}
|
|
@@ -145,9 +169,13 @@ export class StatsApi extends runtime.BaseAPI {
|
|
|
145
169
|
/**
|
|
146
170
|
*
|
|
147
171
|
*/
|
|
148
|
-
async getTotalEarningsByCurrencyRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<SellerTotalEarningsByCurrencyStatsItemDto>>> {
|
|
172
|
+
async getTotalEarningsByCurrencyRaw(requestParameters: StatsApiGetTotalEarningsByCurrencyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<SellerTotalEarningsByCurrencyStatsItemDto>>> {
|
|
149
173
|
const queryParameters: any = {};
|
|
150
174
|
|
|
175
|
+
if (requestParameters['dateRange'] != null) {
|
|
176
|
+
queryParameters['dateRange'] = requestParameters['dateRange'];
|
|
177
|
+
}
|
|
178
|
+
|
|
151
179
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
152
180
|
|
|
153
181
|
if (this.configuration && this.configuration.accessToken) {
|
|
@@ -171,8 +199,8 @@ export class StatsApi extends runtime.BaseAPI {
|
|
|
171
199
|
/**
|
|
172
200
|
*
|
|
173
201
|
*/
|
|
174
|
-
async getTotalEarningsByCurrency(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<SellerTotalEarningsByCurrencyStatsItemDto>> {
|
|
175
|
-
const response = await this.getTotalEarningsByCurrencyRaw(initOverrides);
|
|
202
|
+
async getTotalEarningsByCurrency(requestParameters: StatsApiGetTotalEarningsByCurrencyRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<SellerTotalEarningsByCurrencyStatsItemDto>> {
|
|
203
|
+
const response = await this.getTotalEarningsByCurrencyRaw(requestParameters, initOverrides);
|
|
176
204
|
return await response.value();
|
|
177
205
|
}
|
|
178
206
|
|
|
@@ -180,28 +208,10 @@ export class StatsApi extends runtime.BaseAPI {
|
|
|
180
208
|
*
|
|
181
209
|
*/
|
|
182
210
|
async getTotalEarningsByCurrencyOverTimeRaw(requestParameters: StatsApiGetTotalEarningsByCurrencyOverTimeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<SellerTotalEarningsByCurrencyOverTimeStatsItemDto>>> {
|
|
183
|
-
if (requestParameters['startDate'] == null) {
|
|
184
|
-
throw new runtime.RequiredError(
|
|
185
|
-
'startDate',
|
|
186
|
-
'Required parameter "startDate" was null or undefined when calling getTotalEarningsByCurrencyOverTime().'
|
|
187
|
-
);
|
|
188
|
-
}
|
|
189
|
-
|
|
190
|
-
if (requestParameters['endDate'] == null) {
|
|
191
|
-
throw new runtime.RequiredError(
|
|
192
|
-
'endDate',
|
|
193
|
-
'Required parameter "endDate" was null or undefined when calling getTotalEarningsByCurrencyOverTime().'
|
|
194
|
-
);
|
|
195
|
-
}
|
|
196
|
-
|
|
197
211
|
const queryParameters: any = {};
|
|
198
212
|
|
|
199
|
-
if (requestParameters['
|
|
200
|
-
queryParameters['
|
|
201
|
-
}
|
|
202
|
-
|
|
203
|
-
if (requestParameters['endDate'] != null) {
|
|
204
|
-
queryParameters['endDate'] = (requestParameters['endDate'] as any).toISOString();
|
|
213
|
+
if (requestParameters['dateRange'] != null) {
|
|
214
|
+
queryParameters['dateRange'] = requestParameters['dateRange'];
|
|
205
215
|
}
|
|
206
216
|
|
|
207
217
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
@@ -227,9 +237,43 @@ export class StatsApi extends runtime.BaseAPI {
|
|
|
227
237
|
/**
|
|
228
238
|
*
|
|
229
239
|
*/
|
|
230
|
-
async getTotalEarningsByCurrencyOverTime(requestParameters: StatsApiGetTotalEarningsByCurrencyOverTimeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<SellerTotalEarningsByCurrencyOverTimeStatsItemDto>> {
|
|
240
|
+
async getTotalEarningsByCurrencyOverTime(requestParameters: StatsApiGetTotalEarningsByCurrencyOverTimeRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<SellerTotalEarningsByCurrencyOverTimeStatsItemDto>> {
|
|
231
241
|
const response = await this.getTotalEarningsByCurrencyOverTimeRaw(requestParameters, initOverrides);
|
|
232
242
|
return await response.value();
|
|
233
243
|
}
|
|
234
244
|
|
|
245
|
+
/**
|
|
246
|
+
*
|
|
247
|
+
*/
|
|
248
|
+
async getTotalMonthlyRentIncomeByCurrencyRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto>>> {
|
|
249
|
+
const queryParameters: any = {};
|
|
250
|
+
|
|
251
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
252
|
+
|
|
253
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
254
|
+
const token = this.configuration.accessToken;
|
|
255
|
+
const tokenString = await token("bearer", []);
|
|
256
|
+
|
|
257
|
+
if (tokenString) {
|
|
258
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
259
|
+
}
|
|
260
|
+
}
|
|
261
|
+
const response = await this.request({
|
|
262
|
+
path: `/private/stats/total-monthly-rent-income-by-currency`,
|
|
263
|
+
method: 'GET',
|
|
264
|
+
headers: headerParameters,
|
|
265
|
+
query: queryParameters,
|
|
266
|
+
}, initOverrides);
|
|
267
|
+
|
|
268
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(SellerTotalRentMonthlyIncomeByCurrencyStatsItemDtoFromJSON));
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
/**
|
|
272
|
+
*
|
|
273
|
+
*/
|
|
274
|
+
async getTotalMonthlyRentIncomeByCurrency(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto>> {
|
|
275
|
+
const response = await this.getTotalMonthlyRentIncomeByCurrencyRaw(initOverrides);
|
|
276
|
+
return await response.value();
|
|
277
|
+
}
|
|
278
|
+
|
|
235
279
|
}
|