@randock/nameshift-api-client 0.0.269 → 0.0.271

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 (36) hide show
  1. package/.openapi-generator/FILES +2 -0
  2. package/README.md +3 -3
  3. package/dist/apis/AdminApi.d.ts +13 -1
  4. package/dist/apis/AdminApi.js +62 -0
  5. package/dist/models/AdminCompanyStatsDto.d.ts +33 -0
  6. package/dist/models/AdminCompanyStatsDto.js +52 -0
  7. package/dist/models/AdminCompanyStatsLedger.d.ts +68 -0
  8. package/dist/models/AdminCompanyStatsLedger.js +75 -0
  9. package/dist/models/BuyerLeadListItemDto.d.ts +1 -0
  10. package/dist/models/BuyerLeadListItemDto.js +1 -0
  11. package/dist/models/CreateLeadInput.d.ts +1 -0
  12. package/dist/models/CreateLeadInput.js +1 -0
  13. package/dist/models/IntersectionLeadDtoWithLeadDetailsDtoWithBuyerDetailsDto.d.ts +1 -0
  14. package/dist/models/IntersectionLeadDtoWithLeadDetailsDtoWithBuyerDetailsDto.js +1 -0
  15. package/dist/models/IntersectionLeadDtoWithListFieldsDto.d.ts +2 -0
  16. package/dist/models/IntersectionLeadDtoWithListFieldsDto.js +2 -0
  17. package/dist/models/LeadDto.d.ts +1 -0
  18. package/dist/models/LeadDto.js +1 -0
  19. package/dist/models/LeadMessageDto.d.ts +1 -0
  20. package/dist/models/LeadMessageDto.js +1 -0
  21. package/dist/models/TaskListLeadDto.d.ts +1 -0
  22. package/dist/models/TaskListLeadDto.js +1 -0
  23. package/dist/models/index.d.ts +2 -0
  24. package/dist/models/index.js +2 -0
  25. package/package.json +1 -1
  26. package/src/apis/AdminApi.ts +64 -0
  27. package/src/models/AdminCompanyStatsDto.ts +74 -0
  28. package/src/models/AdminCompanyStatsLedger.ts +120 -0
  29. package/src/models/BuyerLeadListItemDto.ts +1 -0
  30. package/src/models/CreateLeadInput.ts +1 -0
  31. package/src/models/IntersectionLeadDtoWithLeadDetailsDtoWithBuyerDetailsDto.ts +1 -0
  32. package/src/models/IntersectionLeadDtoWithListFieldsDto.ts +2 -0
  33. package/src/models/LeadDto.ts +1 -0
  34. package/src/models/LeadMessageDto.ts +1 -0
  35. package/src/models/TaskListLeadDto.ts +1 -0
  36. package/src/models/index.ts +2 -0
@@ -46,6 +46,8 @@ src/models/AddressDto.ts
46
46
  src/models/AdminAccountLoginDto.ts
47
47
  src/models/AdminAccountSettingsInput.ts
48
48
  src/models/AdminBankAccountDto.ts
49
+ src/models/AdminCompanyStatsDto.ts
50
+ src/models/AdminCompanyStatsLedger.ts
49
51
  src/models/AdminGetAllDomainTransfers200Response.ts
50
52
  src/models/AdminVerificationDepositDto.ts
51
53
  src/models/AggregatedPaginationResponse.ts
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- ## @randock/nameshift-api-client@0.0.269
1
+ ## @randock/nameshift-api-client@0.0.271
2
2
 
3
3
  This generator creates TypeScript/JavaScript client that utilizes [Fetch API](https://fetch.spec.whatwg.org/). The generated Node module can be used in the following environments:
4
4
 
@@ -36,7 +36,7 @@ navigate to the folder of your consuming project and run one of the following co
36
36
  _published:_
37
37
 
38
38
  ```
39
- npm install @randock/nameshift-api-client@0.0.269 --save
39
+ npm install @randock/nameshift-api-client@0.0.271 --save
40
40
  ```
41
41
 
42
42
  _unPublished (not recommended):_
@@ -44,4 +44,4 @@ _unPublished (not recommended):_
44
44
  ```
45
45
  npm install PATH_TO_GENERATED_PACKAGE --save
46
46
  ```
47
- 10d805d9bd774d99e3f727a8007426277e1b4e0e3f24e0bff861150d2f0bbffbdfa452177c9ea25279e721d51e968e4e
47
+ 38d4f138b4f09b85ad1ce10a5fb49310e1e261e9f06a4c15cd30a1fb68dd1805a6e81f728af70ad7538ce6c2e0cf05df
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { AccountSettingsDto, AdminAccountLoginDto, AdminAccountSettingsInput, AdminGetAllDomainTransfers200Response, ChangeOrderStatusInput, ChangeSubscriptionStatusInput, DomainTransferDetailsDto, GetAllInvoices200Response, GetAllOrders200Response, GetAllOwnedDomains200Response, GetAllSubscriptions200Response, IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto, LeadMessageDto, ListAccounts200Response, ListBankAccounts200Response, ListDomains200Response, SendAdminLeadAiPriceNegotiatorAgentChatMessageInput, SubscriptionDetailsDto } from '../models/index';
13
+ import type { AccountSettingsDto, AdminAccountLoginDto, AdminAccountSettingsInput, AdminCompanyStatsDto, AdminGetAllDomainTransfers200Response, ChangeOrderStatusInput, ChangeSubscriptionStatusInput, DomainTransferDetailsDto, GetAllInvoices200Response, GetAllOrders200Response, GetAllOwnedDomains200Response, GetAllSubscriptions200Response, IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto, LeadMessageDto, ListAccounts200Response, ListBankAccounts200Response, ListDomains200Response, SendAdminLeadAiPriceNegotiatorAgentChatMessageInput, SubscriptionDetailsDto } from '../models/index';
14
14
  export interface AdminApiAdminGetAllDomainTransfersRequest {
15
15
  filter?: object;
16
16
  page?: number;
@@ -61,6 +61,10 @@ export interface AdminApiGetAllSubscriptionsRequest {
61
61
  limit?: number;
62
62
  sortBy?: Array<string>;
63
63
  }
64
+ export interface AdminApiGetCompanyStatsRequest {
65
+ startDate: Date;
66
+ endDate: Date;
67
+ }
64
68
  export interface AdminApiGetSubscriptionDetailsRequest {
65
69
  subscriptionId: string;
66
70
  }
@@ -205,6 +209,14 @@ export declare class AdminApi extends runtime.BaseAPI {
205
209
  *
206
210
  */
207
211
  getAllSubscriptions(requestParameters?: AdminApiGetAllSubscriptionsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetAllSubscriptions200Response>;
212
+ /**
213
+ *
214
+ */
215
+ getCompanyStatsRaw(requestParameters: AdminApiGetCompanyStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminCompanyStatsDto>>;
216
+ /**
217
+ *
218
+ */
219
+ getCompanyStats(requestParameters: AdminApiGetCompanyStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminCompanyStatsDto>;
208
220
  /**
209
221
  *
210
222
  */
@@ -714,6 +714,68 @@ var AdminApi = /** @class */ (function (_super) {
714
714
  });
715
715
  });
716
716
  };
717
+ /**
718
+ *
719
+ */
720
+ AdminApi.prototype.getCompanyStatsRaw = function (requestParameters, initOverrides) {
721
+ return __awaiter(this, void 0, void 0, function () {
722
+ var queryParameters, headerParameters, token, tokenString, response;
723
+ return __generator(this, function (_a) {
724
+ switch (_a.label) {
725
+ case 0:
726
+ if (requestParameters['startDate'] == null) {
727
+ throw new runtime.RequiredError('startDate', 'Required parameter "startDate" was null or undefined when calling getCompanyStats().');
728
+ }
729
+ if (requestParameters['endDate'] == null) {
730
+ throw new runtime.RequiredError('endDate', 'Required parameter "endDate" was null or undefined when calling getCompanyStats().');
731
+ }
732
+ queryParameters = {};
733
+ if (requestParameters['startDate'] != null) {
734
+ queryParameters['startDate'] = requestParameters['startDate'].toISOString();
735
+ }
736
+ if (requestParameters['endDate'] != null) {
737
+ queryParameters['endDate'] = requestParameters['endDate'].toISOString();
738
+ }
739
+ headerParameters = {};
740
+ if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
741
+ token = this.configuration.accessToken;
742
+ return [4 /*yield*/, token("bearer", [])];
743
+ case 1:
744
+ tokenString = _a.sent();
745
+ if (tokenString) {
746
+ headerParameters["Authorization"] = "Bearer ".concat(tokenString);
747
+ }
748
+ _a.label = 2;
749
+ case 2: return [4 /*yield*/, this.request({
750
+ path: "/admin/stats",
751
+ method: 'GET',
752
+ headers: headerParameters,
753
+ query: queryParameters,
754
+ }, initOverrides)];
755
+ case 3:
756
+ response = _a.sent();
757
+ return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.AdminCompanyStatsDtoFromJSON)(jsonValue); })];
758
+ }
759
+ });
760
+ });
761
+ };
762
+ /**
763
+ *
764
+ */
765
+ AdminApi.prototype.getCompanyStats = function (requestParameters, initOverrides) {
766
+ return __awaiter(this, void 0, void 0, function () {
767
+ var response;
768
+ return __generator(this, function (_a) {
769
+ switch (_a.label) {
770
+ case 0: return [4 /*yield*/, this.getCompanyStatsRaw(requestParameters, initOverrides)];
771
+ case 1:
772
+ response = _a.sent();
773
+ return [4 /*yield*/, response.value()];
774
+ case 2: return [2 /*return*/, _a.sent()];
775
+ }
776
+ });
777
+ });
778
+ };
717
779
  /**
718
780
  *
719
781
  */
@@ -0,0 +1,33 @@
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
+ import type { AdminCompanyStatsLedger } from './AdminCompanyStatsLedger';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface AdminCompanyStatsDto
17
+ */
18
+ export interface AdminCompanyStatsDto {
19
+ /**
20
+ *
21
+ * @type {Array<AdminCompanyStatsLedger>}
22
+ * @memberof AdminCompanyStatsDto
23
+ */
24
+ ledgers: Array<AdminCompanyStatsLedger>;
25
+ }
26
+ /**
27
+ * Check if a given object implements the AdminCompanyStatsDto interface.
28
+ */
29
+ export declare function instanceOfAdminCompanyStatsDto(value: object): value is AdminCompanyStatsDto;
30
+ export declare function AdminCompanyStatsDtoFromJSON(json: any): AdminCompanyStatsDto;
31
+ export declare function AdminCompanyStatsDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): AdminCompanyStatsDto;
32
+ export declare function AdminCompanyStatsDtoToJSON(json: any): AdminCompanyStatsDto;
33
+ export declare function AdminCompanyStatsDtoToJSONTyped(value?: AdminCompanyStatsDto | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,52 @@
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.instanceOfAdminCompanyStatsDto = instanceOfAdminCompanyStatsDto;
17
+ exports.AdminCompanyStatsDtoFromJSON = AdminCompanyStatsDtoFromJSON;
18
+ exports.AdminCompanyStatsDtoFromJSONTyped = AdminCompanyStatsDtoFromJSONTyped;
19
+ exports.AdminCompanyStatsDtoToJSON = AdminCompanyStatsDtoToJSON;
20
+ exports.AdminCompanyStatsDtoToJSONTyped = AdminCompanyStatsDtoToJSONTyped;
21
+ var AdminCompanyStatsLedger_1 = require("./AdminCompanyStatsLedger");
22
+ /**
23
+ * Check if a given object implements the AdminCompanyStatsDto interface.
24
+ */
25
+ function instanceOfAdminCompanyStatsDto(value) {
26
+ if (!('ledgers' in value) || value['ledgers'] === undefined)
27
+ return false;
28
+ return true;
29
+ }
30
+ function AdminCompanyStatsDtoFromJSON(json) {
31
+ return AdminCompanyStatsDtoFromJSONTyped(json, false);
32
+ }
33
+ function AdminCompanyStatsDtoFromJSONTyped(json, ignoreDiscriminator) {
34
+ if (json == null) {
35
+ return json;
36
+ }
37
+ return {
38
+ 'ledgers': (json['ledgers'].map(AdminCompanyStatsLedger_1.AdminCompanyStatsLedgerFromJSON)),
39
+ };
40
+ }
41
+ function AdminCompanyStatsDtoToJSON(json) {
42
+ return AdminCompanyStatsDtoToJSONTyped(json, false);
43
+ }
44
+ function AdminCompanyStatsDtoToJSONTyped(value, ignoreDiscriminator) {
45
+ if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
46
+ if (value == null) {
47
+ return value;
48
+ }
49
+ return {
50
+ 'ledgers': (value['ledgers'].map(AdminCompanyStatsLedger_1.AdminCompanyStatsLedgerToJSON)),
51
+ };
52
+ }
@@ -0,0 +1,68 @@
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 AdminCompanyStatsLedger
16
+ */
17
+ export interface AdminCompanyStatsLedger {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof AdminCompanyStatsLedger
22
+ */
23
+ id: string;
24
+ /**
25
+ *
26
+ * @type {string}
27
+ * @memberof AdminCompanyStatsLedger
28
+ */
29
+ description: string;
30
+ /**
31
+ *
32
+ * @type {number}
33
+ * @memberof AdminCompanyStatsLedger
34
+ */
35
+ number: number;
36
+ /**
37
+ *
38
+ * @type {number}
39
+ * @memberof AdminCompanyStatsLedger
40
+ */
41
+ debet: number;
42
+ /**
43
+ *
44
+ * @type {number}
45
+ * @memberof AdminCompanyStatsLedger
46
+ */
47
+ credit: number;
48
+ /**
49
+ *
50
+ * @type {number}
51
+ * @memberof AdminCompanyStatsLedger
52
+ */
53
+ balanceDebet: number;
54
+ /**
55
+ *
56
+ * @type {number}
57
+ * @memberof AdminCompanyStatsLedger
58
+ */
59
+ balanceCredit: number;
60
+ }
61
+ /**
62
+ * Check if a given object implements the AdminCompanyStatsLedger interface.
63
+ */
64
+ export declare function instanceOfAdminCompanyStatsLedger(value: object): value is AdminCompanyStatsLedger;
65
+ export declare function AdminCompanyStatsLedgerFromJSON(json: any): AdminCompanyStatsLedger;
66
+ export declare function AdminCompanyStatsLedgerFromJSONTyped(json: any, ignoreDiscriminator: boolean): AdminCompanyStatsLedger;
67
+ export declare function AdminCompanyStatsLedgerToJSON(json: any): AdminCompanyStatsLedger;
68
+ export declare function AdminCompanyStatsLedgerToJSONTyped(value?: AdminCompanyStatsLedger | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,75 @@
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.instanceOfAdminCompanyStatsLedger = instanceOfAdminCompanyStatsLedger;
17
+ exports.AdminCompanyStatsLedgerFromJSON = AdminCompanyStatsLedgerFromJSON;
18
+ exports.AdminCompanyStatsLedgerFromJSONTyped = AdminCompanyStatsLedgerFromJSONTyped;
19
+ exports.AdminCompanyStatsLedgerToJSON = AdminCompanyStatsLedgerToJSON;
20
+ exports.AdminCompanyStatsLedgerToJSONTyped = AdminCompanyStatsLedgerToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the AdminCompanyStatsLedger interface.
23
+ */
24
+ function instanceOfAdminCompanyStatsLedger(value) {
25
+ if (!('id' in value) || value['id'] === undefined)
26
+ return false;
27
+ if (!('description' in value) || value['description'] === undefined)
28
+ return false;
29
+ if (!('number' in value) || value['number'] === undefined)
30
+ return false;
31
+ if (!('debet' in value) || value['debet'] === undefined)
32
+ return false;
33
+ if (!('credit' in value) || value['credit'] === undefined)
34
+ return false;
35
+ if (!('balanceDebet' in value) || value['balanceDebet'] === undefined)
36
+ return false;
37
+ if (!('balanceCredit' in value) || value['balanceCredit'] === undefined)
38
+ return false;
39
+ return true;
40
+ }
41
+ function AdminCompanyStatsLedgerFromJSON(json) {
42
+ return AdminCompanyStatsLedgerFromJSONTyped(json, false);
43
+ }
44
+ function AdminCompanyStatsLedgerFromJSONTyped(json, ignoreDiscriminator) {
45
+ if (json == null) {
46
+ return json;
47
+ }
48
+ return {
49
+ 'id': json['id'],
50
+ 'description': json['description'],
51
+ 'number': json['number'],
52
+ 'debet': json['debet'],
53
+ 'credit': json['credit'],
54
+ 'balanceDebet': json['balanceDebet'],
55
+ 'balanceCredit': json['balanceCredit'],
56
+ };
57
+ }
58
+ function AdminCompanyStatsLedgerToJSON(json) {
59
+ return AdminCompanyStatsLedgerToJSONTyped(json, false);
60
+ }
61
+ function AdminCompanyStatsLedgerToJSONTyped(value, ignoreDiscriminator) {
62
+ if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
63
+ if (value == null) {
64
+ return value;
65
+ }
66
+ return {
67
+ 'id': value['id'],
68
+ 'description': value['description'],
69
+ 'number': value['number'],
70
+ 'debet': value['debet'],
71
+ 'credit': value['credit'],
72
+ 'balanceDebet': value['balanceDebet'],
73
+ 'balanceCredit': value['balanceCredit'],
74
+ };
75
+ }
@@ -83,6 +83,7 @@ export type BuyerLeadListItemDtoStatusEnum = typeof BuyerLeadListItemDtoStatusEn
83
83
  export declare const BuyerLeadListItemDtoLastOfferByEnum: {
84
84
  readonly BUYER: "buyer";
85
85
  readonly SELLER: "seller";
86
+ readonly AI: "ai";
86
87
  readonly ADMIN: "admin";
87
88
  };
88
89
  export type BuyerLeadListItemDtoLastOfferByEnum = typeof BuyerLeadListItemDtoLastOfferByEnum[keyof typeof BuyerLeadListItemDtoLastOfferByEnum];
@@ -37,6 +37,7 @@ exports.BuyerLeadListItemDtoStatusEnum = {
37
37
  exports.BuyerLeadListItemDtoLastOfferByEnum = {
38
38
  BUYER: 'buyer',
39
39
  SELLER: 'seller',
40
+ AI: 'ai',
40
41
  ADMIN: 'admin'
41
42
  };
42
43
  /**
@@ -65,6 +65,7 @@ export interface CreateLeadInput {
65
65
  export declare const CreateLeadInputOfferedByEnum: {
66
66
  readonly BUYER: "buyer";
67
67
  readonly SELLER: "seller";
68
+ readonly AI: "ai";
68
69
  readonly ADMIN: "admin";
69
70
  };
70
71
  export type CreateLeadInputOfferedByEnum = typeof CreateLeadInputOfferedByEnum[keyof typeof CreateLeadInputOfferedByEnum];
@@ -26,6 +26,7 @@ var MoneyDto_1 = require("./MoneyDto");
26
26
  exports.CreateLeadInputOfferedByEnum = {
27
27
  BUYER: 'buyer',
28
28
  SELLER: 'seller',
29
+ AI: 'ai',
29
30
  ADMIN: 'admin'
30
31
  };
31
32
  /**
@@ -114,6 +114,7 @@ export type IntersectionLeadDtoWithLeadDetailsDtoWithBuyerDetailsDtoStatusEnum =
114
114
  export declare const IntersectionLeadDtoWithLeadDetailsDtoWithBuyerDetailsDtoLastOfferByEnum: {
115
115
  readonly BUYER: "buyer";
116
116
  readonly SELLER: "seller";
117
+ readonly AI: "ai";
117
118
  readonly ADMIN: "admin";
118
119
  };
119
120
  export type IntersectionLeadDtoWithLeadDetailsDtoWithBuyerDetailsDtoLastOfferByEnum = typeof IntersectionLeadDtoWithLeadDetailsDtoWithBuyerDetailsDtoLastOfferByEnum[keyof typeof IntersectionLeadDtoWithLeadDetailsDtoWithBuyerDetailsDtoLastOfferByEnum];
@@ -38,6 +38,7 @@ exports.IntersectionLeadDtoWithLeadDetailsDtoWithBuyerDetailsDtoStatusEnum = {
38
38
  exports.IntersectionLeadDtoWithLeadDetailsDtoWithBuyerDetailsDtoLastOfferByEnum = {
39
39
  BUYER: 'buyer',
40
40
  SELLER: 'seller',
41
+ AI: 'ai',
41
42
  ADMIN: 'admin'
42
43
  };
43
44
  /**
@@ -150,6 +150,7 @@ export type IntersectionLeadDtoWithListFieldsDtoStatusEnum = typeof Intersection
150
150
  export declare const IntersectionLeadDtoWithListFieldsDtoLastOfferByEnum: {
151
151
  readonly BUYER: "buyer";
152
152
  readonly SELLER: "seller";
153
+ readonly AI: "ai";
153
154
  readonly ADMIN: "admin";
154
155
  };
155
156
  export type IntersectionLeadDtoWithListFieldsDtoLastOfferByEnum = typeof IntersectionLeadDtoWithListFieldsDtoLastOfferByEnum[keyof typeof IntersectionLeadDtoWithListFieldsDtoLastOfferByEnum];
@@ -159,6 +160,7 @@ export type IntersectionLeadDtoWithListFieldsDtoLastOfferByEnum = typeof Interse
159
160
  export declare const IntersectionLeadDtoWithListFieldsDtoLastMessageFromEnum: {
160
161
  readonly BUYER: "buyer";
161
162
  readonly SELLER: "seller";
163
+ readonly AI: "ai";
162
164
  readonly ADMIN: "admin";
163
165
  };
164
166
  export type IntersectionLeadDtoWithListFieldsDtoLastMessageFromEnum = typeof IntersectionLeadDtoWithListFieldsDtoLastMessageFromEnum[keyof typeof IntersectionLeadDtoWithListFieldsDtoLastMessageFromEnum];
@@ -38,6 +38,7 @@ exports.IntersectionLeadDtoWithListFieldsDtoStatusEnum = {
38
38
  exports.IntersectionLeadDtoWithListFieldsDtoLastOfferByEnum = {
39
39
  BUYER: 'buyer',
40
40
  SELLER: 'seller',
41
+ AI: 'ai',
41
42
  ADMIN: 'admin'
42
43
  };
43
44
  /**
@@ -46,6 +47,7 @@ exports.IntersectionLeadDtoWithListFieldsDtoLastOfferByEnum = {
46
47
  exports.IntersectionLeadDtoWithListFieldsDtoLastMessageFromEnum = {
47
48
  BUYER: 'buyer',
48
49
  SELLER: 'seller',
50
+ AI: 'ai',
49
51
  ADMIN: 'admin'
50
52
  };
51
53
  /**
@@ -107,6 +107,7 @@ export type LeadDtoStatusEnum = typeof LeadDtoStatusEnum[keyof typeof LeadDtoSta
107
107
  export declare const LeadDtoLastOfferByEnum: {
108
108
  readonly BUYER: "buyer";
109
109
  readonly SELLER: "seller";
110
+ readonly AI: "ai";
110
111
  readonly ADMIN: "admin";
111
112
  };
112
113
  export type LeadDtoLastOfferByEnum = typeof LeadDtoLastOfferByEnum[keyof typeof LeadDtoLastOfferByEnum];
@@ -37,6 +37,7 @@ exports.LeadDtoStatusEnum = {
37
37
  exports.LeadDtoLastOfferByEnum = {
38
38
  BUYER: 'buyer',
39
39
  SELLER: 'seller',
40
+ AI: 'ai',
40
41
  ADMIN: 'admin'
41
42
  };
42
43
  /**
@@ -82,6 +82,7 @@ export type LeadMessageDtoTypeEnum = typeof LeadMessageDtoTypeEnum[keyof typeof
82
82
  export declare const LeadMessageDtoOriginEnum: {
83
83
  readonly BUYER: "buyer";
84
84
  readonly SELLER: "seller";
85
+ readonly AI: "ai";
85
86
  readonly ADMIN: "admin";
86
87
  };
87
88
  export type LeadMessageDtoOriginEnum = typeof LeadMessageDtoOriginEnum[keyof typeof LeadMessageDtoOriginEnum];
@@ -36,6 +36,7 @@ exports.LeadMessageDtoTypeEnum = {
36
36
  exports.LeadMessageDtoOriginEnum = {
37
37
  BUYER: 'buyer',
38
38
  SELLER: 'seller',
39
+ AI: 'ai',
39
40
  ADMIN: 'admin'
40
41
  };
41
42
  /**
@@ -47,6 +47,7 @@ export interface TaskListLeadDto {
47
47
  export declare const TaskListLeadDtoLastOfferByEnum: {
48
48
  readonly BUYER: "buyer";
49
49
  readonly SELLER: "seller";
50
+ readonly AI: "ai";
50
51
  readonly ADMIN: "admin";
51
52
  };
52
53
  export type TaskListLeadDtoLastOfferByEnum = typeof TaskListLeadDtoLastOfferByEnum[keyof typeof TaskListLeadDtoLastOfferByEnum];
@@ -26,6 +26,7 @@ var MoneyDto_1 = require("./MoneyDto");
26
26
  exports.TaskListLeadDtoLastOfferByEnum = {
27
27
  BUYER: 'buyer',
28
28
  SELLER: 'seller',
29
+ AI: 'ai',
29
30
  ADMIN: 'admin'
30
31
  };
31
32
  /**
@@ -19,6 +19,8 @@ export * from './AddressDto';
19
19
  export * from './AdminAccountLoginDto';
20
20
  export * from './AdminAccountSettingsInput';
21
21
  export * from './AdminBankAccountDto';
22
+ export * from './AdminCompanyStatsDto';
23
+ export * from './AdminCompanyStatsLedger';
22
24
  export * from './AdminGetAllDomainTransfers200Response';
23
25
  export * from './AdminVerificationDepositDto';
24
26
  export * from './AggregatedPaginationResponse';
@@ -37,6 +37,8 @@ __exportStar(require("./AddressDto"), exports);
37
37
  __exportStar(require("./AdminAccountLoginDto"), exports);
38
38
  __exportStar(require("./AdminAccountSettingsInput"), exports);
39
39
  __exportStar(require("./AdminBankAccountDto"), exports);
40
+ __exportStar(require("./AdminCompanyStatsDto"), exports);
41
+ __exportStar(require("./AdminCompanyStatsLedger"), exports);
40
42
  __exportStar(require("./AdminGetAllDomainTransfers200Response"), exports);
41
43
  __exportStar(require("./AdminVerificationDepositDto"), exports);
42
44
  __exportStar(require("./AggregatedPaginationResponse"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@randock/nameshift-api-client",
3
- "version": "0.0.269",
3
+ "version": "0.0.271",
4
4
  "description": "OpenAPI client for @randock/nameshift-api-client",
5
5
  "author": "OpenAPI-Generator",
6
6
  "repository": {
@@ -18,6 +18,7 @@ import type {
18
18
  AccountSettingsDto,
19
19
  AdminAccountLoginDto,
20
20
  AdminAccountSettingsInput,
21
+ AdminCompanyStatsDto,
21
22
  AdminGetAllDomainTransfers200Response,
22
23
  BadRequestException,
23
24
  ChangeOrderStatusInput,
@@ -45,6 +46,8 @@ import {
45
46
  AdminAccountLoginDtoToJSON,
46
47
  AdminAccountSettingsInputFromJSON,
47
48
  AdminAccountSettingsInputToJSON,
49
+ AdminCompanyStatsDtoFromJSON,
50
+ AdminCompanyStatsDtoToJSON,
48
51
  AdminGetAllDomainTransfers200ResponseFromJSON,
49
52
  AdminGetAllDomainTransfers200ResponseToJSON,
50
53
  BadRequestExceptionFromJSON,
@@ -146,6 +149,11 @@ export interface AdminApiGetAllSubscriptionsRequest {
146
149
  sortBy?: Array<string>;
147
150
  }
148
151
 
152
+ export interface AdminApiGetCompanyStatsRequest {
153
+ startDate: Date;
154
+ endDate: Date;
155
+ }
156
+
149
157
  export interface AdminApiGetSubscriptionDetailsRequest {
150
158
  subscriptionId: string;
151
159
  }
@@ -730,6 +738,62 @@ export class AdminApi extends runtime.BaseAPI {
730
738
  return await response.value();
731
739
  }
732
740
 
741
+ /**
742
+ *
743
+ */
744
+ async getCompanyStatsRaw(requestParameters: AdminApiGetCompanyStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminCompanyStatsDto>> {
745
+ if (requestParameters['startDate'] == null) {
746
+ throw new runtime.RequiredError(
747
+ 'startDate',
748
+ 'Required parameter "startDate" was null or undefined when calling getCompanyStats().'
749
+ );
750
+ }
751
+
752
+ if (requestParameters['endDate'] == null) {
753
+ throw new runtime.RequiredError(
754
+ 'endDate',
755
+ 'Required parameter "endDate" was null or undefined when calling getCompanyStats().'
756
+ );
757
+ }
758
+
759
+ const queryParameters: any = {};
760
+
761
+ if (requestParameters['startDate'] != null) {
762
+ queryParameters['startDate'] = (requestParameters['startDate'] as any).toISOString();
763
+ }
764
+
765
+ if (requestParameters['endDate'] != null) {
766
+ queryParameters['endDate'] = (requestParameters['endDate'] as any).toISOString();
767
+ }
768
+
769
+ const headerParameters: runtime.HTTPHeaders = {};
770
+
771
+ if (this.configuration && this.configuration.accessToken) {
772
+ const token = this.configuration.accessToken;
773
+ const tokenString = await token("bearer", []);
774
+
775
+ if (tokenString) {
776
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
777
+ }
778
+ }
779
+ const response = await this.request({
780
+ path: `/admin/stats`,
781
+ method: 'GET',
782
+ headers: headerParameters,
783
+ query: queryParameters,
784
+ }, initOverrides);
785
+
786
+ return new runtime.JSONApiResponse(response, (jsonValue) => AdminCompanyStatsDtoFromJSON(jsonValue));
787
+ }
788
+
789
+ /**
790
+ *
791
+ */
792
+ async getCompanyStats(requestParameters: AdminApiGetCompanyStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminCompanyStatsDto> {
793
+ const response = await this.getCompanyStatsRaw(requestParameters, initOverrides);
794
+ return await response.value();
795
+ }
796
+
733
797
  /**
734
798
  *
735
799
  */
@@ -0,0 +1,74 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Nameshift
5
+ * Nameshift API
6
+ *
7
+ * The version of the OpenAPI document: 1.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime';
16
+ import type { AdminCompanyStatsLedger } from './AdminCompanyStatsLedger';
17
+ import {
18
+ AdminCompanyStatsLedgerFromJSON,
19
+ AdminCompanyStatsLedgerFromJSONTyped,
20
+ AdminCompanyStatsLedgerToJSON,
21
+ AdminCompanyStatsLedgerToJSONTyped,
22
+ } from './AdminCompanyStatsLedger';
23
+
24
+ /**
25
+ *
26
+ * @export
27
+ * @interface AdminCompanyStatsDto
28
+ */
29
+ export interface AdminCompanyStatsDto {
30
+ /**
31
+ *
32
+ * @type {Array<AdminCompanyStatsLedger>}
33
+ * @memberof AdminCompanyStatsDto
34
+ */
35
+ ledgers: Array<AdminCompanyStatsLedger>;
36
+ }
37
+
38
+ /**
39
+ * Check if a given object implements the AdminCompanyStatsDto interface.
40
+ */
41
+ export function instanceOfAdminCompanyStatsDto(value: object): value is AdminCompanyStatsDto {
42
+ if (!('ledgers' in value) || value['ledgers'] === undefined) return false;
43
+ return true;
44
+ }
45
+
46
+ export function AdminCompanyStatsDtoFromJSON(json: any): AdminCompanyStatsDto {
47
+ return AdminCompanyStatsDtoFromJSONTyped(json, false);
48
+ }
49
+
50
+ export function AdminCompanyStatsDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): AdminCompanyStatsDto {
51
+ if (json == null) {
52
+ return json;
53
+ }
54
+ return {
55
+
56
+ 'ledgers': ((json['ledgers'] as Array<any>).map(AdminCompanyStatsLedgerFromJSON)),
57
+ };
58
+ }
59
+
60
+ export function AdminCompanyStatsDtoToJSON(json: any): AdminCompanyStatsDto {
61
+ return AdminCompanyStatsDtoToJSONTyped(json, false);
62
+ }
63
+
64
+ export function AdminCompanyStatsDtoToJSONTyped(value?: AdminCompanyStatsDto | null, ignoreDiscriminator: boolean = false): any {
65
+ if (value == null) {
66
+ return value;
67
+ }
68
+
69
+ return {
70
+
71
+ 'ledgers': ((value['ledgers'] as Array<any>).map(AdminCompanyStatsLedgerToJSON)),
72
+ };
73
+ }
74
+
@@ -0,0 +1,120 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Nameshift
5
+ * Nameshift API
6
+ *
7
+ * The version of the OpenAPI document: 1.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface AdminCompanyStatsLedger
20
+ */
21
+ export interface AdminCompanyStatsLedger {
22
+ /**
23
+ *
24
+ * @type {string}
25
+ * @memberof AdminCompanyStatsLedger
26
+ */
27
+ id: string;
28
+ /**
29
+ *
30
+ * @type {string}
31
+ * @memberof AdminCompanyStatsLedger
32
+ */
33
+ description: string;
34
+ /**
35
+ *
36
+ * @type {number}
37
+ * @memberof AdminCompanyStatsLedger
38
+ */
39
+ number: number;
40
+ /**
41
+ *
42
+ * @type {number}
43
+ * @memberof AdminCompanyStatsLedger
44
+ */
45
+ debet: number;
46
+ /**
47
+ *
48
+ * @type {number}
49
+ * @memberof AdminCompanyStatsLedger
50
+ */
51
+ credit: number;
52
+ /**
53
+ *
54
+ * @type {number}
55
+ * @memberof AdminCompanyStatsLedger
56
+ */
57
+ balanceDebet: number;
58
+ /**
59
+ *
60
+ * @type {number}
61
+ * @memberof AdminCompanyStatsLedger
62
+ */
63
+ balanceCredit: number;
64
+ }
65
+
66
+ /**
67
+ * Check if a given object implements the AdminCompanyStatsLedger interface.
68
+ */
69
+ export function instanceOfAdminCompanyStatsLedger(value: object): value is AdminCompanyStatsLedger {
70
+ if (!('id' in value) || value['id'] === undefined) return false;
71
+ if (!('description' in value) || value['description'] === undefined) return false;
72
+ if (!('number' in value) || value['number'] === undefined) return false;
73
+ if (!('debet' in value) || value['debet'] === undefined) return false;
74
+ if (!('credit' in value) || value['credit'] === undefined) return false;
75
+ if (!('balanceDebet' in value) || value['balanceDebet'] === undefined) return false;
76
+ if (!('balanceCredit' in value) || value['balanceCredit'] === undefined) return false;
77
+ return true;
78
+ }
79
+
80
+ export function AdminCompanyStatsLedgerFromJSON(json: any): AdminCompanyStatsLedger {
81
+ return AdminCompanyStatsLedgerFromJSONTyped(json, false);
82
+ }
83
+
84
+ export function AdminCompanyStatsLedgerFromJSONTyped(json: any, ignoreDiscriminator: boolean): AdminCompanyStatsLedger {
85
+ if (json == null) {
86
+ return json;
87
+ }
88
+ return {
89
+
90
+ 'id': json['id'],
91
+ 'description': json['description'],
92
+ 'number': json['number'],
93
+ 'debet': json['debet'],
94
+ 'credit': json['credit'],
95
+ 'balanceDebet': json['balanceDebet'],
96
+ 'balanceCredit': json['balanceCredit'],
97
+ };
98
+ }
99
+
100
+ export function AdminCompanyStatsLedgerToJSON(json: any): AdminCompanyStatsLedger {
101
+ return AdminCompanyStatsLedgerToJSONTyped(json, false);
102
+ }
103
+
104
+ export function AdminCompanyStatsLedgerToJSONTyped(value?: AdminCompanyStatsLedger | null, ignoreDiscriminator: boolean = false): any {
105
+ if (value == null) {
106
+ return value;
107
+ }
108
+
109
+ return {
110
+
111
+ 'id': value['id'],
112
+ 'description': value['description'],
113
+ 'number': value['number'],
114
+ 'debet': value['debet'],
115
+ 'credit': value['credit'],
116
+ 'balanceDebet': value['balanceDebet'],
117
+ 'balanceCredit': value['balanceCredit'],
118
+ };
119
+ }
120
+
@@ -103,6 +103,7 @@ export type BuyerLeadListItemDtoStatusEnum = typeof BuyerLeadListItemDtoStatusEn
103
103
  export const BuyerLeadListItemDtoLastOfferByEnum = {
104
104
  BUYER: 'buyer',
105
105
  SELLER: 'seller',
106
+ AI: 'ai',
106
107
  ADMIN: 'admin'
107
108
  } as const;
108
109
  export type BuyerLeadListItemDtoLastOfferByEnum = typeof BuyerLeadListItemDtoLastOfferByEnum[keyof typeof BuyerLeadListItemDtoLastOfferByEnum];
@@ -78,6 +78,7 @@ export interface CreateLeadInput {
78
78
  export const CreateLeadInputOfferedByEnum = {
79
79
  BUYER: 'buyer',
80
80
  SELLER: 'seller',
81
+ AI: 'ai',
81
82
  ADMIN: 'admin'
82
83
  } as const;
83
84
  export type CreateLeadInputOfferedByEnum = typeof CreateLeadInputOfferedByEnum[keyof typeof CreateLeadInputOfferedByEnum];
@@ -140,6 +140,7 @@ export type IntersectionLeadDtoWithLeadDetailsDtoWithBuyerDetailsDtoStatusEnum =
140
140
  export const IntersectionLeadDtoWithLeadDetailsDtoWithBuyerDetailsDtoLastOfferByEnum = {
141
141
  BUYER: 'buyer',
142
142
  SELLER: 'seller',
143
+ AI: 'ai',
143
144
  ADMIN: 'admin'
144
145
  } as const;
145
146
  export type IntersectionLeadDtoWithLeadDetailsDtoWithBuyerDetailsDtoLastOfferByEnum = typeof IntersectionLeadDtoWithLeadDetailsDtoWithBuyerDetailsDtoLastOfferByEnum[keyof typeof IntersectionLeadDtoWithLeadDetailsDtoWithBuyerDetailsDtoLastOfferByEnum];
@@ -176,6 +176,7 @@ export type IntersectionLeadDtoWithListFieldsDtoStatusEnum = typeof Intersection
176
176
  export const IntersectionLeadDtoWithListFieldsDtoLastOfferByEnum = {
177
177
  BUYER: 'buyer',
178
178
  SELLER: 'seller',
179
+ AI: 'ai',
179
180
  ADMIN: 'admin'
180
181
  } as const;
181
182
  export type IntersectionLeadDtoWithListFieldsDtoLastOfferByEnum = typeof IntersectionLeadDtoWithListFieldsDtoLastOfferByEnum[keyof typeof IntersectionLeadDtoWithListFieldsDtoLastOfferByEnum];
@@ -186,6 +187,7 @@ export type IntersectionLeadDtoWithListFieldsDtoLastOfferByEnum = typeof Interse
186
187
  export const IntersectionLeadDtoWithListFieldsDtoLastMessageFromEnum = {
187
188
  BUYER: 'buyer',
188
189
  SELLER: 'seller',
190
+ AI: 'ai',
189
191
  ADMIN: 'admin'
190
192
  } as const;
191
193
  export type IntersectionLeadDtoWithListFieldsDtoLastMessageFromEnum = typeof IntersectionLeadDtoWithListFieldsDtoLastMessageFromEnum[keyof typeof IntersectionLeadDtoWithListFieldsDtoLastMessageFromEnum];
@@ -127,6 +127,7 @@ export type LeadDtoStatusEnum = typeof LeadDtoStatusEnum[keyof typeof LeadDtoSta
127
127
  export const LeadDtoLastOfferByEnum = {
128
128
  BUYER: 'buyer',
129
129
  SELLER: 'seller',
130
+ AI: 'ai',
130
131
  ADMIN: 'admin'
131
132
  } as const;
132
133
  export type LeadDtoLastOfferByEnum = typeof LeadDtoLastOfferByEnum[keyof typeof LeadDtoLastOfferByEnum];
@@ -96,6 +96,7 @@ export type LeadMessageDtoTypeEnum = typeof LeadMessageDtoTypeEnum[keyof typeof
96
96
  export const LeadMessageDtoOriginEnum = {
97
97
  BUYER: 'buyer',
98
98
  SELLER: 'seller',
99
+ AI: 'ai',
99
100
  ADMIN: 'admin'
100
101
  } as const;
101
102
  export type LeadMessageDtoOriginEnum = typeof LeadMessageDtoOriginEnum[keyof typeof LeadMessageDtoOriginEnum];
@@ -60,6 +60,7 @@ export interface TaskListLeadDto {
60
60
  export const TaskListLeadDtoLastOfferByEnum = {
61
61
  BUYER: 'buyer',
62
62
  SELLER: 'seller',
63
+ AI: 'ai',
63
64
  ADMIN: 'admin'
64
65
  } as const;
65
66
  export type TaskListLeadDtoLastOfferByEnum = typeof TaskListLeadDtoLastOfferByEnum[keyof typeof TaskListLeadDtoLastOfferByEnum];
@@ -21,6 +21,8 @@ export * from './AddressDto';
21
21
  export * from './AdminAccountLoginDto';
22
22
  export * from './AdminAccountSettingsInput';
23
23
  export * from './AdminBankAccountDto';
24
+ export * from './AdminCompanyStatsDto';
25
+ export * from './AdminCompanyStatsLedger';
24
26
  export * from './AdminGetAllDomainTransfers200Response';
25
27
  export * from './AdminVerificationDepositDto';
26
28
  export * from './AggregatedPaginationResponse';