@randock/nameshift-api-client 0.0.528 → 0.0.529

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.
@@ -0,0 +1,38 @@
1
+ /**
2
+ * Nameshift
3
+ * Nameshift domain marketplace and management API. ## Authentication - **Bearer JWT** — Seller and buyer sessions obtained via login endpoints. - **API key** — Pass the `apikey` header for programmatic seller access. ## Audiences - **(public)** tags — Unauthenticated or buyer-facing endpoints. - **Accounts / Domains / Leads / Buyers** — Seller or buyer resources. - **Partner** — Partner integrations.
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 SalesStatsDto
16
+ */
17
+ export interface SalesStatsDto {
18
+ /**
19
+ * Number of paid buyer invoices
20
+ * @type {number}
21
+ * @memberof SalesStatsDto
22
+ */
23
+ totalSalesNumber: number;
24
+ /**
25
+ * Average sale price in EUR of the paid buyer invoices
26
+ * @type {number}
27
+ * @memberof SalesStatsDto
28
+ */
29
+ averageSalePriceEur: number;
30
+ }
31
+ /**
32
+ * Check if a given object implements the SalesStatsDto interface.
33
+ */
34
+ export declare function instanceOfSalesStatsDto(value: object): value is SalesStatsDto;
35
+ export declare function SalesStatsDtoFromJSON(json: any): SalesStatsDto;
36
+ export declare function SalesStatsDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): SalesStatsDto;
37
+ export declare function SalesStatsDtoToJSON(json: any): SalesStatsDto;
38
+ export declare function SalesStatsDtoToJSONTyped(value?: SalesStatsDto | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,55 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Nameshift
6
+ * Nameshift domain marketplace and management API. ## Authentication - **Bearer JWT** — Seller and buyer sessions obtained via login endpoints. - **API key** — Pass the `apikey` header for programmatic seller access. ## Audiences - **(public)** tags — Unauthenticated or buyer-facing endpoints. - **Accounts / Domains / Leads / Buyers** — Seller or buyer resources. - **Partner** — Partner integrations.
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.instanceOfSalesStatsDto = instanceOfSalesStatsDto;
17
+ exports.SalesStatsDtoFromJSON = SalesStatsDtoFromJSON;
18
+ exports.SalesStatsDtoFromJSONTyped = SalesStatsDtoFromJSONTyped;
19
+ exports.SalesStatsDtoToJSON = SalesStatsDtoToJSON;
20
+ exports.SalesStatsDtoToJSONTyped = SalesStatsDtoToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the SalesStatsDto interface.
23
+ */
24
+ function instanceOfSalesStatsDto(value) {
25
+ if (!('totalSalesNumber' in value) || value['totalSalesNumber'] === undefined)
26
+ return false;
27
+ if (!('averageSalePriceEur' in value) || value['averageSalePriceEur'] === undefined)
28
+ return false;
29
+ return true;
30
+ }
31
+ function SalesStatsDtoFromJSON(json) {
32
+ return SalesStatsDtoFromJSONTyped(json, false);
33
+ }
34
+ function SalesStatsDtoFromJSONTyped(json, ignoreDiscriminator) {
35
+ if (json == null) {
36
+ return json;
37
+ }
38
+ return {
39
+ 'totalSalesNumber': json['totalSalesNumber'],
40
+ 'averageSalePriceEur': json['averageSalePriceEur'],
41
+ };
42
+ }
43
+ function SalesStatsDtoToJSON(json) {
44
+ return SalesStatsDtoToJSONTyped(json, false);
45
+ }
46
+ function SalesStatsDtoToJSONTyped(value, ignoreDiscriminator) {
47
+ if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
48
+ if (value == null) {
49
+ return value;
50
+ }
51
+ return {
52
+ 'totalSalesNumber': value['totalSalesNumber'],
53
+ 'averageSalePriceEur': value['averageSalePriceEur'],
54
+ };
55
+ }
@@ -65,7 +65,6 @@ export * from './AdminChallengeListDto';
65
65
  export * from './AdminChallengeListItemDto';
66
66
  export * from './AdminCompanyStatsDto';
67
67
  export * from './AdminCompanyStatsLedger';
68
- export * from './AdminDashboardStatsDto';
69
68
  export * from './AdminDomainAppraisalRequestListItemDto';
70
69
  export * from './AdminDomainListItemDto';
71
70
  export * from './AdminGetAllDomainTransfers200Response';
@@ -517,6 +516,7 @@ export * from './SalesCountCommissionPayloadDto';
517
516
  export * from './SalesCountCommissionPayloadInput';
518
517
  export * from './SalesCountCommissionPayloadSimulationInput';
519
518
  export * from './SalesCountCommissionReasonPayloadDto';
519
+ export * from './SalesStatsDto';
520
520
  export * from './SearchBankAccountInstitutionsInput';
521
521
  export * from './SecondFactorMethod';
522
522
  export * from './SellerAccountReferralListItemDto';
@@ -83,7 +83,6 @@ __exportStar(require("./AdminChallengeListDto"), exports);
83
83
  __exportStar(require("./AdminChallengeListItemDto"), exports);
84
84
  __exportStar(require("./AdminCompanyStatsDto"), exports);
85
85
  __exportStar(require("./AdminCompanyStatsLedger"), exports);
86
- __exportStar(require("./AdminDashboardStatsDto"), exports);
87
86
  __exportStar(require("./AdminDomainAppraisalRequestListItemDto"), exports);
88
87
  __exportStar(require("./AdminDomainListItemDto"), exports);
89
88
  __exportStar(require("./AdminGetAllDomainTransfers200Response"), exports);
@@ -535,6 +534,7 @@ __exportStar(require("./SalesCountCommissionPayloadDto"), exports);
535
534
  __exportStar(require("./SalesCountCommissionPayloadInput"), exports);
536
535
  __exportStar(require("./SalesCountCommissionPayloadSimulationInput"), exports);
537
536
  __exportStar(require("./SalesCountCommissionReasonPayloadDto"), exports);
537
+ __exportStar(require("./SalesStatsDto"), exports);
538
538
  __exportStar(require("./SearchBankAccountInstitutionsInput"), exports);
539
539
  __exportStar(require("./SecondFactorMethod"), exports);
540
540
  __exportStar(require("./SellerAccountReferralListItemDto"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@randock/nameshift-api-client",
3
- "version": "0.0.528",
3
+ "version": "0.0.529",
4
4
  "description": "OpenAPI client for @randock/nameshift-api-client",
5
5
  "author": "OpenAPI-Generator",
6
6
  "repository": {
@@ -19,17 +19,19 @@ import type {
19
19
  AccountNoteListDto,
20
20
  AccountPaymentMethodProfileDto,
21
21
  AccountSettingsDto,
22
+ AccountsStatsDto,
22
23
  AdminAccountLoginDto,
23
24
  AdminAccountSettingsInput,
24
25
  AdminBuyerLoginDto,
25
26
  AdminChallengeListDto,
26
27
  AdminCompanyStatsDto,
27
- AdminDashboardStatsDto,
28
28
  AdminGetAllDomainTransfers200Response,
29
29
  AdminLandingDesignStatsDto,
30
30
  AdminMarketplaceDto,
31
31
  AdminUserNewsletterInput,
32
32
  AdminUserSecurityDto,
33
+ AffiliatesStatsDto,
34
+ AuctionsStatsDto,
33
35
  BadRequestException,
34
36
  BulkCommissionActionsInput,
35
37
  ChangeInvoiceStatusInput,
@@ -37,6 +39,7 @@ import type {
37
39
  ChangeSubscriptionStatusInput,
38
40
  CommissionListDto,
39
41
  CommissionSimulationResultDto,
42
+ CommissionsStatsDto,
40
43
  ConflictException,
41
44
  CreateAccountNoteInput,
42
45
  CreateChallengeInput,
@@ -74,6 +77,8 @@ import type {
74
77
  NewsletterPreviewDto,
75
78
  ObjectId,
76
79
  PaySellerInvoicesInput,
80
+ PaymentMethodsStatsDto,
81
+ SalesStatsDto,
77
82
  SellerLeadDetails,
78
83
  SellerPayoutPreviewDto,
79
84
  SellerSalesByTldStatsItemDto,
@@ -103,6 +108,8 @@ import {
103
108
  AccountPaymentMethodProfileDtoToJSON,
104
109
  AccountSettingsDtoFromJSON,
105
110
  AccountSettingsDtoToJSON,
111
+ AccountsStatsDtoFromJSON,
112
+ AccountsStatsDtoToJSON,
106
113
  AdminAccountLoginDtoFromJSON,
107
114
  AdminAccountLoginDtoToJSON,
108
115
  AdminAccountSettingsInputFromJSON,
@@ -113,8 +120,6 @@ import {
113
120
  AdminChallengeListDtoToJSON,
114
121
  AdminCompanyStatsDtoFromJSON,
115
122
  AdminCompanyStatsDtoToJSON,
116
- AdminDashboardStatsDtoFromJSON,
117
- AdminDashboardStatsDtoToJSON,
118
123
  AdminGetAllDomainTransfers200ResponseFromJSON,
119
124
  AdminGetAllDomainTransfers200ResponseToJSON,
120
125
  AdminLandingDesignStatsDtoFromJSON,
@@ -125,6 +130,10 @@ import {
125
130
  AdminUserNewsletterInputToJSON,
126
131
  AdminUserSecurityDtoFromJSON,
127
132
  AdminUserSecurityDtoToJSON,
133
+ AffiliatesStatsDtoFromJSON,
134
+ AffiliatesStatsDtoToJSON,
135
+ AuctionsStatsDtoFromJSON,
136
+ AuctionsStatsDtoToJSON,
128
137
  BadRequestExceptionFromJSON,
129
138
  BadRequestExceptionToJSON,
130
139
  BulkCommissionActionsInputFromJSON,
@@ -139,6 +148,8 @@ import {
139
148
  CommissionListDtoToJSON,
140
149
  CommissionSimulationResultDtoFromJSON,
141
150
  CommissionSimulationResultDtoToJSON,
151
+ CommissionsStatsDtoFromJSON,
152
+ CommissionsStatsDtoToJSON,
142
153
  ConflictExceptionFromJSON,
143
154
  ConflictExceptionToJSON,
144
155
  CreateAccountNoteInputFromJSON,
@@ -213,6 +224,10 @@ import {
213
224
  ObjectIdToJSON,
214
225
  PaySellerInvoicesInputFromJSON,
215
226
  PaySellerInvoicesInputToJSON,
227
+ PaymentMethodsStatsDtoFromJSON,
228
+ PaymentMethodsStatsDtoToJSON,
229
+ SalesStatsDtoFromJSON,
230
+ SalesStatsDtoToJSON,
216
231
  SellerLeadDetailsFromJSON,
217
232
  SellerLeadDetailsToJSON,
218
233
  SellerPayoutPreviewDtoFromJSON,
@@ -366,7 +381,27 @@ export interface AdminApiGetAccountSettingsRequest {
366
381
  accountId: string;
367
382
  }
368
383
 
369
- export interface AdminApiGetAdminDashboardStatsRequest {
384
+ export interface AdminApiGetAdminDashboardAccountsStatsRequest {
385
+ dateRange?: StatsFilterInputDateRange | null;
386
+ }
387
+
388
+ export interface AdminApiGetAdminDashboardAffiliatesStatsRequest {
389
+ dateRange?: StatsFilterInputDateRange | null;
390
+ }
391
+
392
+ export interface AdminApiGetAdminDashboardAuctionsStatsRequest {
393
+ dateRange?: StatsFilterInputDateRange | null;
394
+ }
395
+
396
+ export interface AdminApiGetAdminDashboardCommissionsStatsRequest {
397
+ dateRange?: StatsFilterInputDateRange | null;
398
+ }
399
+
400
+ export interface AdminApiGetAdminDashboardPaymentMethodsStatsRequest {
401
+ dateRange?: StatsFilterInputDateRange | null;
402
+ }
403
+
404
+ export interface AdminApiGetAdminDashboardSalesStatsRequest {
370
405
  dateRange?: StatsFilterInputDateRange | null;
371
406
  }
372
407
 
@@ -1918,10 +1953,210 @@ export class AdminApi extends runtime.BaseAPI {
1918
1953
  }
1919
1954
 
1920
1955
  /**
1921
- * Returns aggregated statistics for the admin dashboard, optionally filtered by date range.
1922
- * Get admin dashboard stats
1956
+ * Returns the accounts statistics of the admin dashboard, with the top sellers, top affiliate sellers and accounts per country, optionally filtered by date range.
1957
+ * Get admin dashboard accounts stats
1958
+ */
1959
+ async getAdminDashboardAccountsStatsRaw(requestParameters: AdminApiGetAdminDashboardAccountsStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AccountsStatsDto>> {
1960
+ const queryParameters: any = {};
1961
+
1962
+ if (requestParameters['dateRange'] != null) {
1963
+ queryParameters['dateRange'] = requestParameters['dateRange'];
1964
+ }
1965
+
1966
+ const headerParameters: runtime.HTTPHeaders = {};
1967
+
1968
+ if (this.configuration && this.configuration.accessToken) {
1969
+ const token = this.configuration.accessToken;
1970
+ const tokenString = await token("bearer", []);
1971
+
1972
+ if (tokenString) {
1973
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
1974
+ }
1975
+ }
1976
+ const response = await this.request({
1977
+ path: `/admin/stats/dashboard/accounts`,
1978
+ method: 'GET',
1979
+ headers: headerParameters,
1980
+ query: queryParameters,
1981
+ }, initOverrides);
1982
+
1983
+ return new runtime.JSONApiResponse(response, (jsonValue) => AccountsStatsDtoFromJSON(jsonValue));
1984
+ }
1985
+
1986
+ /**
1987
+ * Returns the accounts statistics of the admin dashboard, with the top sellers, top affiliate sellers and accounts per country, optionally filtered by date range.
1988
+ * Get admin dashboard accounts stats
1989
+ */
1990
+ async getAdminDashboardAccountsStats(requestParameters: AdminApiGetAdminDashboardAccountsStatsRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AccountsStatsDto> {
1991
+ const response = await this.getAdminDashboardAccountsStatsRaw(requestParameters, initOverrides);
1992
+ return await response.value();
1993
+ }
1994
+
1995
+ /**
1996
+ * Returns the affiliates statistics of the admin dashboard, optionally filtered by date range.
1997
+ * Get admin dashboard affiliates stats
1998
+ */
1999
+ async getAdminDashboardAffiliatesStatsRaw(requestParameters: AdminApiGetAdminDashboardAffiliatesStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AffiliatesStatsDto>> {
2000
+ const queryParameters: any = {};
2001
+
2002
+ if (requestParameters['dateRange'] != null) {
2003
+ queryParameters['dateRange'] = requestParameters['dateRange'];
2004
+ }
2005
+
2006
+ const headerParameters: runtime.HTTPHeaders = {};
2007
+
2008
+ if (this.configuration && this.configuration.accessToken) {
2009
+ const token = this.configuration.accessToken;
2010
+ const tokenString = await token("bearer", []);
2011
+
2012
+ if (tokenString) {
2013
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
2014
+ }
2015
+ }
2016
+ const response = await this.request({
2017
+ path: `/admin/stats/dashboard/affiliates`,
2018
+ method: 'GET',
2019
+ headers: headerParameters,
2020
+ query: queryParameters,
2021
+ }, initOverrides);
2022
+
2023
+ return new runtime.JSONApiResponse(response, (jsonValue) => AffiliatesStatsDtoFromJSON(jsonValue));
2024
+ }
2025
+
2026
+ /**
2027
+ * Returns the affiliates statistics of the admin dashboard, optionally filtered by date range.
2028
+ * Get admin dashboard affiliates stats
2029
+ */
2030
+ async getAdminDashboardAffiliatesStats(requestParameters: AdminApiGetAdminDashboardAffiliatesStatsRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AffiliatesStatsDto> {
2031
+ const response = await this.getAdminDashboardAffiliatesStatsRaw(requestParameters, initOverrides);
2032
+ return await response.value();
2033
+ }
2034
+
2035
+ /**
2036
+ * Returns the auctions statistics of the admin dashboard, optionally filtered by date range.
2037
+ * Get admin dashboard auctions stats
2038
+ */
2039
+ async getAdminDashboardAuctionsStatsRaw(requestParameters: AdminApiGetAdminDashboardAuctionsStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AuctionsStatsDto>> {
2040
+ const queryParameters: any = {};
2041
+
2042
+ if (requestParameters['dateRange'] != null) {
2043
+ queryParameters['dateRange'] = requestParameters['dateRange'];
2044
+ }
2045
+
2046
+ const headerParameters: runtime.HTTPHeaders = {};
2047
+
2048
+ if (this.configuration && this.configuration.accessToken) {
2049
+ const token = this.configuration.accessToken;
2050
+ const tokenString = await token("bearer", []);
2051
+
2052
+ if (tokenString) {
2053
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
2054
+ }
2055
+ }
2056
+ const response = await this.request({
2057
+ path: `/admin/stats/dashboard/auctions`,
2058
+ method: 'GET',
2059
+ headers: headerParameters,
2060
+ query: queryParameters,
2061
+ }, initOverrides);
2062
+
2063
+ return new runtime.JSONApiResponse(response, (jsonValue) => AuctionsStatsDtoFromJSON(jsonValue));
2064
+ }
2065
+
2066
+ /**
2067
+ * Returns the auctions statistics of the admin dashboard, optionally filtered by date range.
2068
+ * Get admin dashboard auctions stats
2069
+ */
2070
+ async getAdminDashboardAuctionsStats(requestParameters: AdminApiGetAdminDashboardAuctionsStatsRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AuctionsStatsDto> {
2071
+ const response = await this.getAdminDashboardAuctionsStatsRaw(requestParameters, initOverrides);
2072
+ return await response.value();
2073
+ }
2074
+
2075
+ /**
2076
+ * Returns the commissions statistics of the admin dashboard, optionally filtered by date range.
2077
+ * Get admin dashboard commissions stats
2078
+ */
2079
+ async getAdminDashboardCommissionsStatsRaw(requestParameters: AdminApiGetAdminDashboardCommissionsStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CommissionsStatsDto>> {
2080
+ const queryParameters: any = {};
2081
+
2082
+ if (requestParameters['dateRange'] != null) {
2083
+ queryParameters['dateRange'] = requestParameters['dateRange'];
2084
+ }
2085
+
2086
+ const headerParameters: runtime.HTTPHeaders = {};
2087
+
2088
+ if (this.configuration && this.configuration.accessToken) {
2089
+ const token = this.configuration.accessToken;
2090
+ const tokenString = await token("bearer", []);
2091
+
2092
+ if (tokenString) {
2093
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
2094
+ }
2095
+ }
2096
+ const response = await this.request({
2097
+ path: `/admin/stats/dashboard/commissions`,
2098
+ method: 'GET',
2099
+ headers: headerParameters,
2100
+ query: queryParameters,
2101
+ }, initOverrides);
2102
+
2103
+ return new runtime.JSONApiResponse(response, (jsonValue) => CommissionsStatsDtoFromJSON(jsonValue));
2104
+ }
2105
+
2106
+ /**
2107
+ * Returns the commissions statistics of the admin dashboard, optionally filtered by date range.
2108
+ * Get admin dashboard commissions stats
2109
+ */
2110
+ async getAdminDashboardCommissionsStats(requestParameters: AdminApiGetAdminDashboardCommissionsStatsRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CommissionsStatsDto> {
2111
+ const response = await this.getAdminDashboardCommissionsStatsRaw(requestParameters, initOverrides);
2112
+ return await response.value();
2113
+ }
2114
+
2115
+ /**
2116
+ * Returns the number of sales by payment method of the admin dashboard, optionally filtered by date range.
2117
+ * Get admin dashboard payment methods stats
2118
+ */
2119
+ async getAdminDashboardPaymentMethodsStatsRaw(requestParameters: AdminApiGetAdminDashboardPaymentMethodsStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaymentMethodsStatsDto>> {
2120
+ const queryParameters: any = {};
2121
+
2122
+ if (requestParameters['dateRange'] != null) {
2123
+ queryParameters['dateRange'] = requestParameters['dateRange'];
2124
+ }
2125
+
2126
+ const headerParameters: runtime.HTTPHeaders = {};
2127
+
2128
+ if (this.configuration && this.configuration.accessToken) {
2129
+ const token = this.configuration.accessToken;
2130
+ const tokenString = await token("bearer", []);
2131
+
2132
+ if (tokenString) {
2133
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
2134
+ }
2135
+ }
2136
+ const response = await this.request({
2137
+ path: `/admin/stats/dashboard/payment-methods`,
2138
+ method: 'GET',
2139
+ headers: headerParameters,
2140
+ query: queryParameters,
2141
+ }, initOverrides);
2142
+
2143
+ return new runtime.JSONApiResponse(response, (jsonValue) => PaymentMethodsStatsDtoFromJSON(jsonValue));
2144
+ }
2145
+
2146
+ /**
2147
+ * Returns the number of sales by payment method of the admin dashboard, optionally filtered by date range.
2148
+ * Get admin dashboard payment methods stats
2149
+ */
2150
+ async getAdminDashboardPaymentMethodsStats(requestParameters: AdminApiGetAdminDashboardPaymentMethodsStatsRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaymentMethodsStatsDto> {
2151
+ const response = await this.getAdminDashboardPaymentMethodsStatsRaw(requestParameters, initOverrides);
2152
+ return await response.value();
2153
+ }
2154
+
2155
+ /**
2156
+ * Returns the sales statistics of the admin dashboard, optionally filtered by date range.
2157
+ * Get admin dashboard sales stats
1923
2158
  */
1924
- async getAdminDashboardStatsRaw(requestParameters: AdminApiGetAdminDashboardStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminDashboardStatsDto>> {
2159
+ async getAdminDashboardSalesStatsRaw(requestParameters: AdminApiGetAdminDashboardSalesStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SalesStatsDto>> {
1925
2160
  const queryParameters: any = {};
1926
2161
 
1927
2162
  if (requestParameters['dateRange'] != null) {
@@ -1939,21 +2174,21 @@ export class AdminApi extends runtime.BaseAPI {
1939
2174
  }
1940
2175
  }
1941
2176
  const response = await this.request({
1942
- path: `/admin/stats/dashboard`,
2177
+ path: `/admin/stats/dashboard/sales`,
1943
2178
  method: 'GET',
1944
2179
  headers: headerParameters,
1945
2180
  query: queryParameters,
1946
2181
  }, initOverrides);
1947
2182
 
1948
- return new runtime.JSONApiResponse(response, (jsonValue) => AdminDashboardStatsDtoFromJSON(jsonValue));
2183
+ return new runtime.JSONApiResponse(response, (jsonValue) => SalesStatsDtoFromJSON(jsonValue));
1949
2184
  }
1950
2185
 
1951
2186
  /**
1952
- * Returns aggregated statistics for the admin dashboard, optionally filtered by date range.
1953
- * Get admin dashboard stats
2187
+ * Returns the sales statistics of the admin dashboard, optionally filtered by date range.
2188
+ * Get admin dashboard sales stats
1954
2189
  */
1955
- async getAdminDashboardStats(requestParameters: AdminApiGetAdminDashboardStatsRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminDashboardStatsDto> {
1956
- const response = await this.getAdminDashboardStatsRaw(requestParameters, initOverrides);
2190
+ async getAdminDashboardSalesStats(requestParameters: AdminApiGetAdminDashboardSalesStatsRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SalesStatsDto> {
2191
+ const response = await this.getAdminDashboardSalesStatsRaw(requestParameters, initOverrides);
1957
2192
  return await response.value();
1958
2193
  }
1959
2194
 
@@ -13,6 +13,28 @@
13
13
  */
14
14
 
15
15
  import { mapValues } from '../runtime';
16
+ import type { TopAffiliateSellerDto } from './TopAffiliateSellerDto';
17
+ import {
18
+ TopAffiliateSellerDtoFromJSON,
19
+ TopAffiliateSellerDtoFromJSONTyped,
20
+ TopAffiliateSellerDtoToJSON,
21
+ TopAffiliateSellerDtoToJSONTyped,
22
+ } from './TopAffiliateSellerDto';
23
+ import type { AccountCountryStatsDto } from './AccountCountryStatsDto';
24
+ import {
25
+ AccountCountryStatsDtoFromJSON,
26
+ AccountCountryStatsDtoFromJSONTyped,
27
+ AccountCountryStatsDtoToJSON,
28
+ AccountCountryStatsDtoToJSONTyped,
29
+ } from './AccountCountryStatsDto';
30
+ import type { TopSellerAccountDto } from './TopSellerAccountDto';
31
+ import {
32
+ TopSellerAccountDtoFromJSON,
33
+ TopSellerAccountDtoFromJSONTyped,
34
+ TopSellerAccountDtoToJSON,
35
+ TopSellerAccountDtoToJSONTyped,
36
+ } from './TopSellerAccountDto';
37
+
16
38
  /**
17
39
  *
18
40
  * @export
@@ -49,6 +71,24 @@ export interface AccountsStatsDto {
49
71
  * @memberof AccountsStatsDto
50
72
  */
51
73
  withDomainsVerified: number;
74
+ /**
75
+ * Number of accounts per billing country
76
+ * @type {Array<AccountCountryStatsDto>}
77
+ * @memberof AccountsStatsDto
78
+ */
79
+ countries: Array<AccountCountryStatsDto>;
80
+ /**
81
+ * Accounts with the most sold domains
82
+ * @type {Array<TopSellerAccountDto>}
83
+ * @memberof AccountsStatsDto
84
+ */
85
+ topSellers: Array<TopSellerAccountDto>;
86
+ /**
87
+ * Accounts with the most paid buyer sales that used their affiliate code
88
+ * @type {Array<TopAffiliateSellerDto>}
89
+ * @memberof AccountsStatsDto
90
+ */
91
+ topAffiliateSellers: Array<TopAffiliateSellerDto>;
52
92
  }
53
93
 
54
94
  /**
@@ -60,6 +100,9 @@ export function instanceOfAccountsStatsDto(value: object): value is AccountsStat
60
100
  if (!('withDomains' in value) || value['withDomains'] === undefined) return false;
61
101
  if (!('withDomainsPointingDns' in value) || value['withDomainsPointingDns'] === undefined) return false;
62
102
  if (!('withDomainsVerified' in value) || value['withDomainsVerified'] === undefined) return false;
103
+ if (!('countries' in value) || value['countries'] === undefined) return false;
104
+ if (!('topSellers' in value) || value['topSellers'] === undefined) return false;
105
+ if (!('topAffiliateSellers' in value) || value['topAffiliateSellers'] === undefined) return false;
63
106
  return true;
64
107
  }
65
108
 
@@ -78,6 +121,9 @@ export function AccountsStatsDtoFromJSONTyped(json: any, ignoreDiscriminator: bo
78
121
  'withDomains': json['withDomains'],
79
122
  'withDomainsPointingDns': json['withDomainsPointingDns'],
80
123
  'withDomainsVerified': json['withDomainsVerified'],
124
+ 'countries': ((json['countries'] as Array<any>).map(AccountCountryStatsDtoFromJSON)),
125
+ 'topSellers': ((json['topSellers'] as Array<any>).map(TopSellerAccountDtoFromJSON)),
126
+ 'topAffiliateSellers': ((json['topAffiliateSellers'] as Array<any>).map(TopAffiliateSellerDtoFromJSON)),
81
127
  };
82
128
  }
83
129
 
@@ -97,6 +143,9 @@ export function AccountsStatsDtoToJSONTyped(value?: AccountsStatsDto | null, ign
97
143
  'withDomains': value['withDomains'],
98
144
  'withDomainsPointingDns': value['withDomainsPointingDns'],
99
145
  'withDomainsVerified': value['withDomainsVerified'],
146
+ 'countries': ((value['countries'] as Array<any>).map(AccountCountryStatsDtoToJSON)),
147
+ 'topSellers': ((value['topSellers'] as Array<any>).map(TopSellerAccountDtoToJSON)),
148
+ 'topAffiliateSellers': ((value['topAffiliateSellers'] as Array<any>).map(TopAffiliateSellerDtoToJSON)),
100
149
  };
101
150
  }
102
151
 
@@ -25,6 +25,12 @@ export interface AffiliatesStatsDto {
25
25
  * @memberof AffiliatesStatsDto
26
26
  */
27
27
  accountsWithAffiliates: number;
28
+ /**
29
+ * Total number of accounts
30
+ * @type {number}
31
+ * @memberof AffiliatesStatsDto
32
+ */
33
+ totalAccounts: number;
28
34
  }
29
35
 
30
36
  /**
@@ -32,6 +38,7 @@ export interface AffiliatesStatsDto {
32
38
  */
33
39
  export function instanceOfAffiliatesStatsDto(value: object): value is AffiliatesStatsDto {
34
40
  if (!('accountsWithAffiliates' in value) || value['accountsWithAffiliates'] === undefined) return false;
41
+ if (!('totalAccounts' in value) || value['totalAccounts'] === undefined) return false;
35
42
  return true;
36
43
  }
37
44
 
@@ -46,6 +53,7 @@ export function AffiliatesStatsDtoFromJSONTyped(json: any, ignoreDiscriminator:
46
53
  return {
47
54
 
48
55
  'accountsWithAffiliates': json['accountsWithAffiliates'],
56
+ 'totalAccounts': json['totalAccounts'],
49
57
  };
50
58
  }
51
59
 
@@ -61,6 +69,7 @@ export function AffiliatesStatsDtoToJSONTyped(value?: AffiliatesStatsDto | null,
61
69
  return {
62
70
 
63
71
  'accountsWithAffiliates': value['accountsWithAffiliates'],
72
+ 'totalAccounts': value['totalAccounts'],
64
73
  };
65
74
  }
66
75
 
@@ -37,6 +37,12 @@ export interface AuctionsStatsDto {
37
37
  * @memberof AuctionsStatsDto
38
38
  */
39
39
  accountsUsingPaidAuctionsCount: number;
40
+ /**
41
+ * Total number of accounts
42
+ * @type {number}
43
+ * @memberof AuctionsStatsDto
44
+ */
45
+ totalAccounts: number;
40
46
  }
41
47
 
42
48
  /**
@@ -46,6 +52,7 @@ export function instanceOfAuctionsStatsDto(value: object): value is AuctionsStat
46
52
  if (!('paidAuctionsCount' in value) || value['paidAuctionsCount'] === undefined) return false;
47
53
  if (!('totalAuctionsCount' in value) || value['totalAuctionsCount'] === undefined) return false;
48
54
  if (!('accountsUsingPaidAuctionsCount' in value) || value['accountsUsingPaidAuctionsCount'] === undefined) return false;
55
+ if (!('totalAccounts' in value) || value['totalAccounts'] === undefined) return false;
49
56
  return true;
50
57
  }
51
58
 
@@ -62,6 +69,7 @@ export function AuctionsStatsDtoFromJSONTyped(json: any, ignoreDiscriminator: bo
62
69
  'paidAuctionsCount': json['paidAuctionsCount'],
63
70
  'totalAuctionsCount': json['totalAuctionsCount'],
64
71
  'accountsUsingPaidAuctionsCount': json['accountsUsingPaidAuctionsCount'],
72
+ 'totalAccounts': json['totalAccounts'],
65
73
  };
66
74
  }
67
75
 
@@ -79,6 +87,7 @@ export function AuctionsStatsDtoToJSONTyped(value?: AuctionsStatsDto | null, ign
79
87
  'paidAuctionsCount': value['paidAuctionsCount'],
80
88
  'totalAuctionsCount': value['totalAuctionsCount'],
81
89
  'accountsUsingPaidAuctionsCount': value['accountsUsingPaidAuctionsCount'],
90
+ 'totalAccounts': value['totalAccounts'],
82
91
  };
83
92
  }
84
93