@randock/nameshift-api-client 0.0.313 → 0.0.315

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.
@@ -232,6 +232,7 @@ src/models/PublicSalesDto.ts
232
232
  src/models/PutBuyerLeadOfferInput.ts
233
233
  src/models/PutLeadOfferInput.ts
234
234
  src/models/RegisterAccountInput.ts
235
+ src/models/RelatedDomainsDto.ts
235
236
  src/models/RelatedSellerDomain.ts
236
237
  src/models/RentConfigurationDto.ts
237
238
  src/models/RentConfigurationInput.ts
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- ## @randock/nameshift-api-client@0.0.313
1
+ ## @randock/nameshift-api-client@0.0.315
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.313 --save
39
+ npm install @randock/nameshift-api-client@0.0.315 --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
- 841a77f51c233112561312bd670db2432fa4b6e790164db9862c0eab19c2fa447fe28b8b0098dbdd6da5e10854af73af
47
+ bebd9db2be101337a7f30e663485e4a20811c3fc9687f5fe20322309701902d23e145f6a1c8929c19588c1ffeb8488b7
@@ -10,16 +10,21 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { DomainSalesInformationDto, DomainTldsDto, List200Response3, SortDto } from '../models/index';
13
+ import type { DomainSalesInformationDto, DomainStatsDto, DomainTldsDto, List200Response3, RelatedDomainsDto, SortDto } from '../models/index';
14
14
  export interface DomainsPublicApiGetAllTldsRequest {
15
15
  seller?: string;
16
16
  }
17
+ export interface DomainsPublicApiGetDomainRelatedDomainsRequest {
18
+ domainName: string;
19
+ }
17
20
  export interface DomainsPublicApiGetDomainSalesInformationRequest {
18
21
  domainName: string;
19
- includeStats?: boolean;
20
22
  preview?: boolean;
21
23
  installments?: number;
22
24
  }
25
+ export interface DomainsPublicApiGetDomainStatsRequest {
26
+ domainName: string;
27
+ }
23
28
  export interface DomainsPublicApiListRequest {
24
29
  fuzzy: boolean;
25
30
  limit?: number;
@@ -40,6 +45,14 @@ export declare class DomainsPublicApi extends runtime.BaseAPI {
40
45
  *
41
46
  */
42
47
  getAllTlds(requestParameters?: DomainsPublicApiGetAllTldsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DomainTldsDto>;
48
+ /**
49
+ *
50
+ */
51
+ getDomainRelatedDomainsRaw(requestParameters: DomainsPublicApiGetDomainRelatedDomainsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<RelatedDomainsDto>>;
52
+ /**
53
+ *
54
+ */
55
+ getDomainRelatedDomains(requestParameters: DomainsPublicApiGetDomainRelatedDomainsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<RelatedDomainsDto>;
43
56
  /**
44
57
  *
45
58
  */
@@ -48,6 +61,14 @@ export declare class DomainsPublicApi extends runtime.BaseAPI {
48
61
  *
49
62
  */
50
63
  getDomainSalesInformation(requestParameters: DomainsPublicApiGetDomainSalesInformationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DomainSalesInformationDto>;
64
+ /**
65
+ *
66
+ */
67
+ getDomainStatsRaw(requestParameters: DomainsPublicApiGetDomainStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DomainStatsDto>>;
68
+ /**
69
+ *
70
+ */
71
+ getDomainStats(requestParameters: DomainsPublicApiGetDomainStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DomainStatsDto>;
51
72
  /**
52
73
  *
53
74
  */
@@ -120,6 +120,50 @@ var DomainsPublicApi = /** @class */ (function (_super) {
120
120
  });
121
121
  });
122
122
  };
123
+ /**
124
+ *
125
+ */
126
+ DomainsPublicApi.prototype.getDomainRelatedDomainsRaw = function (requestParameters, initOverrides) {
127
+ return __awaiter(this, void 0, void 0, function () {
128
+ var queryParameters, headerParameters, response;
129
+ return __generator(this, function (_a) {
130
+ switch (_a.label) {
131
+ case 0:
132
+ if (requestParameters['domainName'] == null) {
133
+ throw new runtime.RequiredError('domainName', 'Required parameter "domainName" was null or undefined when calling getDomainRelatedDomains().');
134
+ }
135
+ queryParameters = {};
136
+ headerParameters = {};
137
+ return [4 /*yield*/, this.request({
138
+ path: "/domains/by-name/{domainName}/related-domains".replace("{".concat("domainName", "}"), encodeURIComponent(String(requestParameters['domainName']))),
139
+ method: 'GET',
140
+ headers: headerParameters,
141
+ query: queryParameters,
142
+ }, initOverrides)];
143
+ case 1:
144
+ response = _a.sent();
145
+ return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.RelatedDomainsDtoFromJSON)(jsonValue); })];
146
+ }
147
+ });
148
+ });
149
+ };
150
+ /**
151
+ *
152
+ */
153
+ DomainsPublicApi.prototype.getDomainRelatedDomains = function (requestParameters, initOverrides) {
154
+ return __awaiter(this, void 0, void 0, function () {
155
+ var response;
156
+ return __generator(this, function (_a) {
157
+ switch (_a.label) {
158
+ case 0: return [4 /*yield*/, this.getDomainRelatedDomainsRaw(requestParameters, initOverrides)];
159
+ case 1:
160
+ response = _a.sent();
161
+ return [4 /*yield*/, response.value()];
162
+ case 2: return [2 /*return*/, _a.sent()];
163
+ }
164
+ });
165
+ });
166
+ };
123
167
  /**
124
168
  *
125
169
  */
@@ -133,9 +177,6 @@ var DomainsPublicApi = /** @class */ (function (_super) {
133
177
  throw new runtime.RequiredError('domainName', 'Required parameter "domainName" was null or undefined when calling getDomainSalesInformation().');
134
178
  }
135
179
  queryParameters = {};
136
- if (requestParameters['includeStats'] != null) {
137
- queryParameters['includeStats'] = requestParameters['includeStats'];
138
- }
139
180
  if (requestParameters['preview'] != null) {
140
181
  queryParameters['preview'] = requestParameters['preview'];
141
182
  }
@@ -173,6 +214,50 @@ var DomainsPublicApi = /** @class */ (function (_super) {
173
214
  });
174
215
  });
175
216
  };
217
+ /**
218
+ *
219
+ */
220
+ DomainsPublicApi.prototype.getDomainStatsRaw = function (requestParameters, initOverrides) {
221
+ return __awaiter(this, void 0, void 0, function () {
222
+ var queryParameters, headerParameters, response;
223
+ return __generator(this, function (_a) {
224
+ switch (_a.label) {
225
+ case 0:
226
+ if (requestParameters['domainName'] == null) {
227
+ throw new runtime.RequiredError('domainName', 'Required parameter "domainName" was null or undefined when calling getDomainStats().');
228
+ }
229
+ queryParameters = {};
230
+ headerParameters = {};
231
+ return [4 /*yield*/, this.request({
232
+ path: "/domains/by-name/{domainName}/stats".replace("{".concat("domainName", "}"), encodeURIComponent(String(requestParameters['domainName']))),
233
+ method: 'GET',
234
+ headers: headerParameters,
235
+ query: queryParameters,
236
+ }, initOverrides)];
237
+ case 1:
238
+ response = _a.sent();
239
+ return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.DomainStatsDtoFromJSON)(jsonValue); })];
240
+ }
241
+ });
242
+ });
243
+ };
244
+ /**
245
+ *
246
+ */
247
+ DomainsPublicApi.prototype.getDomainStats = function (requestParameters, initOverrides) {
248
+ return __awaiter(this, void 0, void 0, function () {
249
+ var response;
250
+ return __generator(this, function (_a) {
251
+ switch (_a.label) {
252
+ case 0: return [4 /*yield*/, this.getDomainStatsRaw(requestParameters, initOverrides)];
253
+ case 1:
254
+ response = _a.sent();
255
+ return [4 /*yield*/, response.value()];
256
+ case 2: return [2 /*return*/, _a.sent()];
257
+ }
258
+ });
259
+ });
260
+ };
176
261
  /**
177
262
  *
178
263
  */
@@ -13,7 +13,6 @@ import type { DomainSellerDto } from './DomainSellerDto';
13
13
  import type { LeadBuyerConfigDto } from './LeadBuyerConfigDto';
14
14
  import type { MoneyDto } from './MoneyDto';
15
15
  import type { DomainSalesInformationRentConfigurationDto } from './DomainSalesInformationRentConfigurationDto';
16
- import type { DomainStatsDto } from './DomainStatsDto';
17
16
  import type { DomainSalesInformationLeaseToOwnConfigurationDto } from './DomainSalesInformationLeaseToOwnConfigurationDto';
18
17
  import type { SeoMetricsDto } from './SeoMetricsDto';
19
18
  /**
@@ -83,11 +82,29 @@ export interface DomainSalesInformationDto {
83
82
  */
84
83
  seo: SeoMetricsDto | null;
85
84
  /**
86
- * SEO metrics
87
- * @type {DomainStatsDto}
85
+ * Stats enabled
86
+ * @type {boolean}
87
+ * @memberof DomainSalesInformationDto
88
+ */
89
+ statsEnabled: boolean;
90
+ /**
91
+ * Related domains enabled
92
+ * @type {boolean}
93
+ * @memberof DomainSalesInformationDto
94
+ */
95
+ relatedDomainsEnabled: boolean;
96
+ /**
97
+ * Trustpilot enabled
98
+ * @type {boolean}
99
+ * @memberof DomainSalesInformationDto
100
+ */
101
+ trustpilotEnabled: boolean;
102
+ /**
103
+ * SEO enabled
104
+ * @type {boolean}
88
105
  * @memberof DomainSalesInformationDto
89
106
  */
90
- stats: DomainStatsDto | null;
107
+ seoEnabled: boolean;
91
108
  /**
92
109
  * Lead buyer settings
93
110
  * @type {LeadBuyerConfigDto}
@@ -22,7 +22,6 @@ var DomainSellerDto_1 = require("./DomainSellerDto");
22
22
  var LeadBuyerConfigDto_1 = require("./LeadBuyerConfigDto");
23
23
  var MoneyDto_1 = require("./MoneyDto");
24
24
  var DomainSalesInformationRentConfigurationDto_1 = require("./DomainSalesInformationRentConfigurationDto");
25
- var DomainStatsDto_1 = require("./DomainStatsDto");
26
25
  var DomainSalesInformationLeaseToOwnConfigurationDto_1 = require("./DomainSalesInformationLeaseToOwnConfigurationDto");
27
26
  var SeoMetricsDto_1 = require("./SeoMetricsDto");
28
27
  /**
@@ -49,7 +48,13 @@ function instanceOfDomainSalesInformationDto(value) {
49
48
  return false;
50
49
  if (!('seo' in value) || value['seo'] === undefined)
51
50
  return false;
52
- if (!('stats' in value) || value['stats'] === undefined)
51
+ if (!('statsEnabled' in value) || value['statsEnabled'] === undefined)
52
+ return false;
53
+ if (!('relatedDomainsEnabled' in value) || value['relatedDomainsEnabled'] === undefined)
54
+ return false;
55
+ if (!('trustpilotEnabled' in value) || value['trustpilotEnabled'] === undefined)
56
+ return false;
57
+ if (!('seoEnabled' in value) || value['seoEnabled'] === undefined)
53
58
  return false;
54
59
  if (!('leadBuyerSettings' in value) || value['leadBuyerSettings'] === undefined)
55
60
  return false;
@@ -73,7 +78,10 @@ function DomainSalesInformationDtoFromJSONTyped(json, ignoreDiscriminator) {
73
78
  'sold': json['sold'],
74
79
  'isPurchaseable': json['isPurchaseable'],
75
80
  'seo': (0, SeoMetricsDto_1.SeoMetricsDtoFromJSON)(json['seo']),
76
- 'stats': (0, DomainStatsDto_1.DomainStatsDtoFromJSON)(json['stats']),
81
+ 'statsEnabled': json['statsEnabled'],
82
+ 'relatedDomainsEnabled': json['relatedDomainsEnabled'],
83
+ 'trustpilotEnabled': json['trustpilotEnabled'],
84
+ 'seoEnabled': json['seoEnabled'],
77
85
  'leadBuyerSettings': (0, LeadBuyerConfigDto_1.LeadBuyerConfigDtoFromJSON)(json['leadBuyerSettings']),
78
86
  };
79
87
  }
@@ -96,7 +104,10 @@ function DomainSalesInformationDtoToJSONTyped(value, ignoreDiscriminator) {
96
104
  'sold': value['sold'],
97
105
  'isPurchaseable': value['isPurchaseable'],
98
106
  'seo': (0, SeoMetricsDto_1.SeoMetricsDtoToJSON)(value['seo']),
99
- 'stats': (0, DomainStatsDto_1.DomainStatsDtoToJSON)(value['stats']),
107
+ 'statsEnabled': value['statsEnabled'],
108
+ 'relatedDomainsEnabled': value['relatedDomainsEnabled'],
109
+ 'trustpilotEnabled': value['trustpilotEnabled'],
110
+ 'seoEnabled': value['seoEnabled'],
100
111
  'leadBuyerSettings': (0, LeadBuyerConfigDto_1.LeadBuyerConfigDtoToJSON)(value['leadBuyerSettings']),
101
112
  };
102
113
  }
@@ -9,7 +9,6 @@
9
9
  * https://openapi-generator.tech
10
10
  * Do not edit the class manually.
11
11
  */
12
- import type { RelatedSellerDomain } from './RelatedSellerDomain';
13
12
  /**
14
13
  *
15
14
  * @export
@@ -34,12 +33,6 @@ export interface DomainSellerDto {
34
33
  * @memberof DomainSellerDto
35
34
  */
36
35
  anonymous: boolean;
37
- /**
38
- * Show trustpilot
39
- * @type {boolean}
40
- * @memberof DomainSellerDto
41
- */
42
- showTrustpilot: boolean;
43
36
  /**
44
37
  * Last online, formatted
45
38
  * @type {Date}
@@ -70,12 +63,6 @@ export interface DomainSellerDto {
70
63
  * @memberof DomainSellerDto
71
64
  */
72
65
  description: string | null;
73
- /**
74
- * The domain seller related domains
75
- * @type {Array<RelatedSellerDomain>}
76
- * @memberof DomainSellerDto
77
- */
78
- relatedDomains: Array<RelatedSellerDomain> | null;
79
66
  }
80
67
  /**
81
68
  * Check if a given object implements the DomainSellerDto interface.
@@ -18,7 +18,6 @@ exports.DomainSellerDtoFromJSON = DomainSellerDtoFromJSON;
18
18
  exports.DomainSellerDtoFromJSONTyped = DomainSellerDtoFromJSONTyped;
19
19
  exports.DomainSellerDtoToJSON = DomainSellerDtoToJSON;
20
20
  exports.DomainSellerDtoToJSONTyped = DomainSellerDtoToJSONTyped;
21
- var RelatedSellerDomain_1 = require("./RelatedSellerDomain");
22
21
  /**
23
22
  * Check if a given object implements the DomainSellerDto interface.
24
23
  */
@@ -29,8 +28,6 @@ function instanceOfDomainSellerDto(value) {
29
28
  return false;
30
29
  if (!('anonymous' in value) || value['anonymous'] === undefined)
31
30
  return false;
32
- if (!('showTrustpilot' in value) || value['showTrustpilot'] === undefined)
33
- return false;
34
31
  if (!('lastOnline' in value) || value['lastOnline'] === undefined)
35
32
  return false;
36
33
  if (!('deliversIn' in value) || value['deliversIn'] === undefined)
@@ -41,8 +38,6 @@ function instanceOfDomainSellerDto(value) {
41
38
  return false;
42
39
  if (!('description' in value) || value['description'] === undefined)
43
40
  return false;
44
- if (!('relatedDomains' in value) || value['relatedDomains'] === undefined)
45
- return false;
46
41
  return true;
47
42
  }
48
43
  function DomainSellerDtoFromJSON(json) {
@@ -56,13 +51,11 @@ function DomainSellerDtoFromJSONTyped(json, ignoreDiscriminator) {
56
51
  'id': json['id'],
57
52
  'createdAt': (new Date(json['createdAt'])),
58
53
  'anonymous': json['anonymous'],
59
- 'showTrustpilot': json['showTrustpilot'],
60
54
  'lastOnline': (json['lastOnline'] == null ? null : new Date(json['lastOnline'])),
61
55
  'deliversIn': json['deliversIn'],
62
56
  'name': json['name'],
63
57
  'avatar': json['avatar'],
64
58
  'description': json['description'],
65
- 'relatedDomains': (json['relatedDomains'] == null ? null : json['relatedDomains'].map(RelatedSellerDomain_1.RelatedSellerDomainFromJSON)),
66
59
  };
67
60
  }
68
61
  function DomainSellerDtoToJSON(json) {
@@ -77,12 +70,10 @@ function DomainSellerDtoToJSONTyped(value, ignoreDiscriminator) {
77
70
  'id': value['id'],
78
71
  'createdAt': ((value['createdAt']).toISOString()),
79
72
  'anonymous': value['anonymous'],
80
- 'showTrustpilot': value['showTrustpilot'],
81
73
  'lastOnline': (value['lastOnline'] == null ? null : value['lastOnline'].toISOString()),
82
74
  'deliversIn': value['deliversIn'],
83
75
  'name': value['name'],
84
76
  'avatar': value['avatar'],
85
77
  'description': value['description'],
86
- 'relatedDomains': (value['relatedDomains'] == null ? null : value['relatedDomains'].map(RelatedSellerDomain_1.RelatedSellerDomainToJSON)),
87
78
  };
88
79
  }
@@ -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 { RelatedSellerDomain } from './RelatedSellerDomain';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface RelatedDomainsDto
17
+ */
18
+ export interface RelatedDomainsDto {
19
+ /**
20
+ *
21
+ * @type {Array<RelatedSellerDomain>}
22
+ * @memberof RelatedDomainsDto
23
+ */
24
+ domains: Array<RelatedSellerDomain>;
25
+ }
26
+ /**
27
+ * Check if a given object implements the RelatedDomainsDto interface.
28
+ */
29
+ export declare function instanceOfRelatedDomainsDto(value: object): value is RelatedDomainsDto;
30
+ export declare function RelatedDomainsDtoFromJSON(json: any): RelatedDomainsDto;
31
+ export declare function RelatedDomainsDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): RelatedDomainsDto;
32
+ export declare function RelatedDomainsDtoToJSON(json: any): RelatedDomainsDto;
33
+ export declare function RelatedDomainsDtoToJSONTyped(value?: RelatedDomainsDto | 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.instanceOfRelatedDomainsDto = instanceOfRelatedDomainsDto;
17
+ exports.RelatedDomainsDtoFromJSON = RelatedDomainsDtoFromJSON;
18
+ exports.RelatedDomainsDtoFromJSONTyped = RelatedDomainsDtoFromJSONTyped;
19
+ exports.RelatedDomainsDtoToJSON = RelatedDomainsDtoToJSON;
20
+ exports.RelatedDomainsDtoToJSONTyped = RelatedDomainsDtoToJSONTyped;
21
+ var RelatedSellerDomain_1 = require("./RelatedSellerDomain");
22
+ /**
23
+ * Check if a given object implements the RelatedDomainsDto interface.
24
+ */
25
+ function instanceOfRelatedDomainsDto(value) {
26
+ if (!('domains' in value) || value['domains'] === undefined)
27
+ return false;
28
+ return true;
29
+ }
30
+ function RelatedDomainsDtoFromJSON(json) {
31
+ return RelatedDomainsDtoFromJSONTyped(json, false);
32
+ }
33
+ function RelatedDomainsDtoFromJSONTyped(json, ignoreDiscriminator) {
34
+ if (json == null) {
35
+ return json;
36
+ }
37
+ return {
38
+ 'domains': (json['domains'].map(RelatedSellerDomain_1.RelatedSellerDomainFromJSON)),
39
+ };
40
+ }
41
+ function RelatedDomainsDtoToJSON(json) {
42
+ return RelatedDomainsDtoToJSONTyped(json, false);
43
+ }
44
+ function RelatedDomainsDtoToJSONTyped(value, ignoreDiscriminator) {
45
+ if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
46
+ if (value == null) {
47
+ return value;
48
+ }
49
+ return {
50
+ 'domains': (value['domains'].map(RelatedSellerDomain_1.RelatedSellerDomainToJSON)),
51
+ };
52
+ }
@@ -203,6 +203,7 @@ export * from './PublicSalesDto';
203
203
  export * from './PutBuyerLeadOfferInput';
204
204
  export * from './PutLeadOfferInput';
205
205
  export * from './RegisterAccountInput';
206
+ export * from './RelatedDomainsDto';
206
207
  export * from './RelatedSellerDomain';
207
208
  export * from './RentConfigurationDto';
208
209
  export * from './RentConfigurationInput';
@@ -221,6 +221,7 @@ __exportStar(require("./PublicSalesDto"), exports);
221
221
  __exportStar(require("./PutBuyerLeadOfferInput"), exports);
222
222
  __exportStar(require("./PutLeadOfferInput"), exports);
223
223
  __exportStar(require("./RegisterAccountInput"), exports);
224
+ __exportStar(require("./RelatedDomainsDto"), exports);
224
225
  __exportStar(require("./RelatedSellerDomain"), exports);
225
226
  __exportStar(require("./RentConfigurationDto"), exports);
226
227
  __exportStar(require("./RentConfigurationInput"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@randock/nameshift-api-client",
3
- "version": "0.0.313",
3
+ "version": "0.0.315",
4
4
  "description": "OpenAPI client for @randock/nameshift-api-client",
5
5
  "author": "OpenAPI-Generator",
6
6
  "repository": {
@@ -16,9 +16,11 @@
16
16
  import * as runtime from '../runtime';
17
17
  import type {
18
18
  DomainSalesInformationDto,
19
+ DomainStatsDto,
19
20
  DomainTldsDto,
20
21
  List200Response3,
21
22
  NotFoundException,
23
+ RelatedDomainsDto,
22
24
  SortDto,
23
25
  ThrottlerException,
24
26
  ValidationException,
@@ -26,12 +28,16 @@ import type {
26
28
  import {
27
29
  DomainSalesInformationDtoFromJSON,
28
30
  DomainSalesInformationDtoToJSON,
31
+ DomainStatsDtoFromJSON,
32
+ DomainStatsDtoToJSON,
29
33
  DomainTldsDtoFromJSON,
30
34
  DomainTldsDtoToJSON,
31
35
  List200Response3FromJSON,
32
36
  List200Response3ToJSON,
33
37
  NotFoundExceptionFromJSON,
34
38
  NotFoundExceptionToJSON,
39
+ RelatedDomainsDtoFromJSON,
40
+ RelatedDomainsDtoToJSON,
35
41
  SortDtoFromJSON,
36
42
  SortDtoToJSON,
37
43
  ThrottlerExceptionFromJSON,
@@ -44,13 +50,20 @@ export interface DomainsPublicApiGetAllTldsRequest {
44
50
  seller?: string;
45
51
  }
46
52
 
53
+ export interface DomainsPublicApiGetDomainRelatedDomainsRequest {
54
+ domainName: string;
55
+ }
56
+
47
57
  export interface DomainsPublicApiGetDomainSalesInformationRequest {
48
58
  domainName: string;
49
- includeStats?: boolean;
50
59
  preview?: boolean;
51
60
  installments?: number;
52
61
  }
53
62
 
63
+ export interface DomainsPublicApiGetDomainStatsRequest {
64
+ domainName: string;
65
+ }
66
+
54
67
  export interface DomainsPublicApiListRequest {
55
68
  fuzzy: boolean;
56
69
  limit?: number;
@@ -98,20 +111,49 @@ export class DomainsPublicApi extends runtime.BaseAPI {
98
111
  /**
99
112
  *
100
113
  */
101
- async getDomainSalesInformationRaw(requestParameters: DomainsPublicApiGetDomainSalesInformationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DomainSalesInformationDto>> {
114
+ async getDomainRelatedDomainsRaw(requestParameters: DomainsPublicApiGetDomainRelatedDomainsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<RelatedDomainsDto>> {
102
115
  if (requestParameters['domainName'] == null) {
103
116
  throw new runtime.RequiredError(
104
117
  'domainName',
105
- 'Required parameter "domainName" was null or undefined when calling getDomainSalesInformation().'
118
+ 'Required parameter "domainName" was null or undefined when calling getDomainRelatedDomains().'
106
119
  );
107
120
  }
108
121
 
109
122
  const queryParameters: any = {};
110
123
 
111
- if (requestParameters['includeStats'] != null) {
112
- queryParameters['includeStats'] = requestParameters['includeStats'];
124
+ const headerParameters: runtime.HTTPHeaders = {};
125
+
126
+ const response = await this.request({
127
+ path: `/domains/by-name/{domainName}/related-domains`.replace(`{${"domainName"}}`, encodeURIComponent(String(requestParameters['domainName']))),
128
+ method: 'GET',
129
+ headers: headerParameters,
130
+ query: queryParameters,
131
+ }, initOverrides);
132
+
133
+ return new runtime.JSONApiResponse(response, (jsonValue) => RelatedDomainsDtoFromJSON(jsonValue));
134
+ }
135
+
136
+ /**
137
+ *
138
+ */
139
+ async getDomainRelatedDomains(requestParameters: DomainsPublicApiGetDomainRelatedDomainsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<RelatedDomainsDto> {
140
+ const response = await this.getDomainRelatedDomainsRaw(requestParameters, initOverrides);
141
+ return await response.value();
142
+ }
143
+
144
+ /**
145
+ *
146
+ */
147
+ async getDomainSalesInformationRaw(requestParameters: DomainsPublicApiGetDomainSalesInformationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DomainSalesInformationDto>> {
148
+ if (requestParameters['domainName'] == null) {
149
+ throw new runtime.RequiredError(
150
+ 'domainName',
151
+ 'Required parameter "domainName" was null or undefined when calling getDomainSalesInformation().'
152
+ );
113
153
  }
114
154
 
155
+ const queryParameters: any = {};
156
+
115
157
  if (requestParameters['preview'] != null) {
116
158
  queryParameters['preview'] = requestParameters['preview'];
117
159
  }
@@ -140,6 +182,39 @@ export class DomainsPublicApi extends runtime.BaseAPI {
140
182
  return await response.value();
141
183
  }
142
184
 
185
+ /**
186
+ *
187
+ */
188
+ async getDomainStatsRaw(requestParameters: DomainsPublicApiGetDomainStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DomainStatsDto>> {
189
+ if (requestParameters['domainName'] == null) {
190
+ throw new runtime.RequiredError(
191
+ 'domainName',
192
+ 'Required parameter "domainName" was null or undefined when calling getDomainStats().'
193
+ );
194
+ }
195
+
196
+ const queryParameters: any = {};
197
+
198
+ const headerParameters: runtime.HTTPHeaders = {};
199
+
200
+ const response = await this.request({
201
+ path: `/domains/by-name/{domainName}/stats`.replace(`{${"domainName"}}`, encodeURIComponent(String(requestParameters['domainName']))),
202
+ method: 'GET',
203
+ headers: headerParameters,
204
+ query: queryParameters,
205
+ }, initOverrides);
206
+
207
+ return new runtime.JSONApiResponse(response, (jsonValue) => DomainStatsDtoFromJSON(jsonValue));
208
+ }
209
+
210
+ /**
211
+ *
212
+ */
213
+ async getDomainStats(requestParameters: DomainsPublicApiGetDomainStatsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DomainStatsDto> {
214
+ const response = await this.getDomainStatsRaw(requestParameters, initOverrides);
215
+ return await response.value();
216
+ }
217
+
143
218
  /**
144
219
  *
145
220
  */
@@ -41,13 +41,6 @@ import {
41
41
  DomainSalesInformationRentConfigurationDtoToJSON,
42
42
  DomainSalesInformationRentConfigurationDtoToJSONTyped,
43
43
  } from './DomainSalesInformationRentConfigurationDto';
44
- import type { DomainStatsDto } from './DomainStatsDto';
45
- import {
46
- DomainStatsDtoFromJSON,
47
- DomainStatsDtoFromJSONTyped,
48
- DomainStatsDtoToJSON,
49
- DomainStatsDtoToJSONTyped,
50
- } from './DomainStatsDto';
51
44
  import type { DomainSalesInformationLeaseToOwnConfigurationDto } from './DomainSalesInformationLeaseToOwnConfigurationDto';
52
45
  import {
53
46
  DomainSalesInformationLeaseToOwnConfigurationDtoFromJSON,
@@ -130,11 +123,29 @@ export interface DomainSalesInformationDto {
130
123
  */
131
124
  seo: SeoMetricsDto | null;
132
125
  /**
133
- * SEO metrics
134
- * @type {DomainStatsDto}
126
+ * Stats enabled
127
+ * @type {boolean}
128
+ * @memberof DomainSalesInformationDto
129
+ */
130
+ statsEnabled: boolean;
131
+ /**
132
+ * Related domains enabled
133
+ * @type {boolean}
134
+ * @memberof DomainSalesInformationDto
135
+ */
136
+ relatedDomainsEnabled: boolean;
137
+ /**
138
+ * Trustpilot enabled
139
+ * @type {boolean}
140
+ * @memberof DomainSalesInformationDto
141
+ */
142
+ trustpilotEnabled: boolean;
143
+ /**
144
+ * SEO enabled
145
+ * @type {boolean}
135
146
  * @memberof DomainSalesInformationDto
136
147
  */
137
- stats: DomainStatsDto | null;
148
+ seoEnabled: boolean;
138
149
  /**
139
150
  * Lead buyer settings
140
151
  * @type {LeadBuyerConfigDto}
@@ -157,7 +168,10 @@ export function instanceOfDomainSalesInformationDto(value: object): value is Dom
157
168
  if (!('sold' in value) || value['sold'] === undefined) return false;
158
169
  if (!('isPurchaseable' in value) || value['isPurchaseable'] === undefined) return false;
159
170
  if (!('seo' in value) || value['seo'] === undefined) return false;
160
- if (!('stats' in value) || value['stats'] === undefined) return false;
171
+ if (!('statsEnabled' in value) || value['statsEnabled'] === undefined) return false;
172
+ if (!('relatedDomainsEnabled' in value) || value['relatedDomainsEnabled'] === undefined) return false;
173
+ if (!('trustpilotEnabled' in value) || value['trustpilotEnabled'] === undefined) return false;
174
+ if (!('seoEnabled' in value) || value['seoEnabled'] === undefined) return false;
161
175
  if (!('leadBuyerSettings' in value) || value['leadBuyerSettings'] === undefined) return false;
162
176
  return true;
163
177
  }
@@ -182,7 +196,10 @@ export function DomainSalesInformationDtoFromJSONTyped(json: any, ignoreDiscrimi
182
196
  'sold': json['sold'],
183
197
  'isPurchaseable': json['isPurchaseable'],
184
198
  'seo': SeoMetricsDtoFromJSON(json['seo']),
185
- 'stats': DomainStatsDtoFromJSON(json['stats']),
199
+ 'statsEnabled': json['statsEnabled'],
200
+ 'relatedDomainsEnabled': json['relatedDomainsEnabled'],
201
+ 'trustpilotEnabled': json['trustpilotEnabled'],
202
+ 'seoEnabled': json['seoEnabled'],
186
203
  'leadBuyerSettings': LeadBuyerConfigDtoFromJSON(json['leadBuyerSettings']),
187
204
  };
188
205
  }
@@ -208,7 +225,10 @@ export function DomainSalesInformationDtoToJSONTyped(value?: DomainSalesInformat
208
225
  'sold': value['sold'],
209
226
  'isPurchaseable': value['isPurchaseable'],
210
227
  'seo': SeoMetricsDtoToJSON(value['seo']),
211
- 'stats': DomainStatsDtoToJSON(value['stats']),
228
+ 'statsEnabled': value['statsEnabled'],
229
+ 'relatedDomainsEnabled': value['relatedDomainsEnabled'],
230
+ 'trustpilotEnabled': value['trustpilotEnabled'],
231
+ 'seoEnabled': value['seoEnabled'],
212
232
  'leadBuyerSettings': LeadBuyerConfigDtoToJSON(value['leadBuyerSettings']),
213
233
  };
214
234
  }
@@ -13,14 +13,6 @@
13
13
  */
14
14
 
15
15
  import { mapValues } from '../runtime';
16
- import type { RelatedSellerDomain } from './RelatedSellerDomain';
17
- import {
18
- RelatedSellerDomainFromJSON,
19
- RelatedSellerDomainFromJSONTyped,
20
- RelatedSellerDomainToJSON,
21
- RelatedSellerDomainToJSONTyped,
22
- } from './RelatedSellerDomain';
23
-
24
16
  /**
25
17
  *
26
18
  * @export
@@ -45,12 +37,6 @@ export interface DomainSellerDto {
45
37
  * @memberof DomainSellerDto
46
38
  */
47
39
  anonymous: boolean;
48
- /**
49
- * Show trustpilot
50
- * @type {boolean}
51
- * @memberof DomainSellerDto
52
- */
53
- showTrustpilot: boolean;
54
40
  /**
55
41
  * Last online, formatted
56
42
  * @type {Date}
@@ -81,12 +67,6 @@ export interface DomainSellerDto {
81
67
  * @memberof DomainSellerDto
82
68
  */
83
69
  description: string | null;
84
- /**
85
- * The domain seller related domains
86
- * @type {Array<RelatedSellerDomain>}
87
- * @memberof DomainSellerDto
88
- */
89
- relatedDomains: Array<RelatedSellerDomain> | null;
90
70
  }
91
71
 
92
72
  /**
@@ -96,13 +76,11 @@ export function instanceOfDomainSellerDto(value: object): value is DomainSellerD
96
76
  if (!('id' in value) || value['id'] === undefined) return false;
97
77
  if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
98
78
  if (!('anonymous' in value) || value['anonymous'] === undefined) return false;
99
- if (!('showTrustpilot' in value) || value['showTrustpilot'] === undefined) return false;
100
79
  if (!('lastOnline' in value) || value['lastOnline'] === undefined) return false;
101
80
  if (!('deliversIn' in value) || value['deliversIn'] === undefined) return false;
102
81
  if (!('name' in value) || value['name'] === undefined) return false;
103
82
  if (!('avatar' in value) || value['avatar'] === undefined) return false;
104
83
  if (!('description' in value) || value['description'] === undefined) return false;
105
- if (!('relatedDomains' in value) || value['relatedDomains'] === undefined) return false;
106
84
  return true;
107
85
  }
108
86
 
@@ -119,13 +97,11 @@ export function DomainSellerDtoFromJSONTyped(json: any, ignoreDiscriminator: boo
119
97
  'id': json['id'],
120
98
  'createdAt': (new Date(json['createdAt'])),
121
99
  'anonymous': json['anonymous'],
122
- 'showTrustpilot': json['showTrustpilot'],
123
100
  'lastOnline': (json['lastOnline'] == null ? null : new Date(json['lastOnline'])),
124
101
  'deliversIn': json['deliversIn'],
125
102
  'name': json['name'],
126
103
  'avatar': json['avatar'],
127
104
  'description': json['description'],
128
- 'relatedDomains': (json['relatedDomains'] == null ? null : (json['relatedDomains'] as Array<any>).map(RelatedSellerDomainFromJSON)),
129
105
  };
130
106
  }
131
107
 
@@ -143,13 +119,11 @@ export function DomainSellerDtoToJSONTyped(value?: DomainSellerDto | null, ignor
143
119
  'id': value['id'],
144
120
  'createdAt': ((value['createdAt']).toISOString()),
145
121
  'anonymous': value['anonymous'],
146
- 'showTrustpilot': value['showTrustpilot'],
147
122
  'lastOnline': (value['lastOnline'] == null ? null : (value['lastOnline'] as any).toISOString()),
148
123
  'deliversIn': value['deliversIn'],
149
124
  'name': value['name'],
150
125
  'avatar': value['avatar'],
151
126
  'description': value['description'],
152
- 'relatedDomains': (value['relatedDomains'] == null ? null : (value['relatedDomains'] as Array<any>).map(RelatedSellerDomainToJSON)),
153
127
  };
154
128
  }
155
129
 
@@ -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 { RelatedSellerDomain } from './RelatedSellerDomain';
17
+ import {
18
+ RelatedSellerDomainFromJSON,
19
+ RelatedSellerDomainFromJSONTyped,
20
+ RelatedSellerDomainToJSON,
21
+ RelatedSellerDomainToJSONTyped,
22
+ } from './RelatedSellerDomain';
23
+
24
+ /**
25
+ *
26
+ * @export
27
+ * @interface RelatedDomainsDto
28
+ */
29
+ export interface RelatedDomainsDto {
30
+ /**
31
+ *
32
+ * @type {Array<RelatedSellerDomain>}
33
+ * @memberof RelatedDomainsDto
34
+ */
35
+ domains: Array<RelatedSellerDomain>;
36
+ }
37
+
38
+ /**
39
+ * Check if a given object implements the RelatedDomainsDto interface.
40
+ */
41
+ export function instanceOfRelatedDomainsDto(value: object): value is RelatedDomainsDto {
42
+ if (!('domains' in value) || value['domains'] === undefined) return false;
43
+ return true;
44
+ }
45
+
46
+ export function RelatedDomainsDtoFromJSON(json: any): RelatedDomainsDto {
47
+ return RelatedDomainsDtoFromJSONTyped(json, false);
48
+ }
49
+
50
+ export function RelatedDomainsDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): RelatedDomainsDto {
51
+ if (json == null) {
52
+ return json;
53
+ }
54
+ return {
55
+
56
+ 'domains': ((json['domains'] as Array<any>).map(RelatedSellerDomainFromJSON)),
57
+ };
58
+ }
59
+
60
+ export function RelatedDomainsDtoToJSON(json: any): RelatedDomainsDto {
61
+ return RelatedDomainsDtoToJSONTyped(json, false);
62
+ }
63
+
64
+ export function RelatedDomainsDtoToJSONTyped(value?: RelatedDomainsDto | null, ignoreDiscriminator: boolean = false): any {
65
+ if (value == null) {
66
+ return value;
67
+ }
68
+
69
+ return {
70
+
71
+ 'domains': ((value['domains'] as Array<any>).map(RelatedSellerDomainToJSON)),
72
+ };
73
+ }
74
+
@@ -205,6 +205,7 @@ export * from './PublicSalesDto';
205
205
  export * from './PutBuyerLeadOfferInput';
206
206
  export * from './PutLeadOfferInput';
207
207
  export * from './RegisterAccountInput';
208
+ export * from './RelatedDomainsDto';
208
209
  export * from './RelatedSellerDomain';
209
210
  export * from './RentConfigurationDto';
210
211
  export * from './RentConfigurationInput';