@randock/nameshift-api-client 0.0.559 → 0.0.560

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.
@@ -341,6 +341,7 @@ src/models/DomainLockConfigurationDto.ts
341
341
  src/models/DomainLockDto.ts
342
342
  src/models/DomainMinimalLandingPageDesignDto.ts
343
343
  src/models/DomainModernLandingPageDesignDto.ts
344
+ src/models/DomainNameListDto.ts
344
345
  src/models/DomainOriginalLandingPageDesignDto.ts
345
346
  src/models/DomainPricesChangeDto.ts
346
347
  src/models/DomainSalesInformationDto.ts
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- ## @randock/nameshift-api-client@0.0.559
1
+ ## @randock/nameshift-api-client@0.0.560
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.559 --save
39
+ npm install @randock/nameshift-api-client@0.0.560 --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
- ca523b0a5d912fb34e6622beccd78557f7ced09fe0199a47579274ea8b2d64ae4f1acfd5ecc34d974175c8cf677d3922
47
+ 8ba23d671bce08d7b4bb18010a01fba7f92c1c2e8cfdbabbfdd786dacabea17b91059fff2c6f04d47491d576f015bb7d
@@ -10,10 +10,11 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { ApplyDomainEditInput, BatchImportPreviewDto, BatchUpdateDomainsInput, BulkUpdateDomainsWithFiltersInput, CheckDomainsNsInput, DeleteDomainsInput, DomainEditPreviewDto, DomainExchangeRateDto, DomainFiltersDto, DomainSearchTranslationDto, DomainUrlDto, DomainVerificationStatusDto, GetAllDomainTransfers200Response, ImportDomainsResponseDto, IntersectionDomainDtoWithHijackerDtoWithAccountDto, JobDto, List200Response2, PreviewDomainEditInput, SellerDomainAffiliateCommissionDto, SellerDomainTransferDto, StartAuctionInput, TranslateDomainSearchInput, UpdateDomainInput, UpdateDomainTransferAuthCodeInput, UpdateDomainTransferIpsTagInput } from '../models/index';
13
+ import type { ApplyDomainEditInput, BatchImportPreviewDto, BatchUpdateDomainsInput, BulkUpdateDomainsWithFiltersInput, CheckDomainsNsInput, DeleteDomainsInput, DomainEditPreviewDto, DomainExchangeRateDto, DomainFiltersDto, DomainNameListDto, DomainSearchTranslationDto, DomainUrlDto, DomainVerificationStatusDto, GetAllDomainTransfers200Response, ImportDomainsResponseDto, IntersectionDomainDtoWithHijackerDtoWithAccountDto, JobDto, List200Response2, PreviewDomainEditInput, SellerDomainAffiliateCommissionDto, SellerDomainTransferDto, StartAuctionInput, TranslateDomainSearchInput, UpdateDomainInput, UpdateDomainTransferAuthCodeInput, UpdateDomainTransferIpsTagInput } from '../models/index';
14
14
  export interface DomainsApiApplyDomainEditRequest {
15
15
  applyDomainEditInput: ApplyDomainEditInput;
16
16
  searchFilter?: string;
17
+ nameListId?: string;
17
18
  filter?: {
18
19
  [key: string]: string;
19
20
  };
@@ -32,6 +33,7 @@ export interface DomainsApiBatchUpdateRequest {
32
33
  export interface DomainsApiBulkUpdateDomainsWithFiltersRequest {
33
34
  bulkUpdateDomainsWithFiltersInput: BulkUpdateDomainsWithFiltersInput;
34
35
  searchFilter?: string;
36
+ nameListId?: string;
35
37
  filter?: object;
36
38
  }
37
39
  export interface DomainsApiCheckDnsRequest {
@@ -43,11 +45,15 @@ export interface DomainsApiCheckDnsBatchRequest {
43
45
  export interface DomainsApiCheckDomainVerificationRequest {
44
46
  domainId: string;
45
47
  }
48
+ export interface DomainsApiCreateDomainNameListRequest {
49
+ file: Blob;
50
+ }
46
51
  export interface DomainsApiDeleteDomainsRequest {
47
52
  deleteDomainsInput: DeleteDomainsInput;
48
53
  }
49
54
  export interface DomainsApiExportDomainsRequest {
50
55
  searchFilter?: string;
56
+ nameListId?: string;
51
57
  filter?: object;
52
58
  }
53
59
  export interface DomainsApiGetAffiliateCommissionRequest {
@@ -71,8 +77,12 @@ export interface DomainsApiGetDomainExchangeRateRequest {
71
77
  }
72
78
  export interface DomainsApiGetDomainFiltersCurrenciesRequest {
73
79
  searchFilter?: string;
80
+ nameListId?: string;
74
81
  filter?: object;
75
82
  }
83
+ export interface DomainsApiGetDomainNameListRequest {
84
+ nameListId: string;
85
+ }
76
86
  export interface DomainsApiGetDomainTransferRequest {
77
87
  transferId: string;
78
88
  }
@@ -81,6 +91,7 @@ export interface DomainsApiGetDomainUrlRequest {
81
91
  }
82
92
  export interface DomainsApiListRequest {
83
93
  searchFilter?: string;
94
+ nameListId?: string;
84
95
  filter?: {
85
96
  [key: string]: string;
86
97
  };
@@ -98,6 +109,7 @@ export interface DomainsApiListRequest {
98
109
  export interface DomainsApiPreviewDomainEditRequest {
99
110
  previewDomainEditInput: PreviewDomainEditInput;
100
111
  searchFilter?: string;
112
+ nameListId?: string;
101
113
  filter?: {
102
114
  [key: string]: string;
103
115
  };
@@ -205,6 +217,16 @@ export declare class DomainsApi extends runtime.BaseAPI {
205
217
  * Check domain verification
206
218
  */
207
219
  checkDomainVerification(requestParameters: DomainsApiCheckDomainVerificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DomainVerificationStatusDto>;
220
+ /**
221
+ * Takes a text file of domain names and answers with the id of the list. Pass that id as `nameListId` to the domains list, its currencies, its export and the bulk edits, to narrow them to the domains named in the file. The names may each be on a line of their own, or be separated by commas, semicolons or spaces. Letter case does not matter, and an internationalised name may be written in Unicode or in punycode. A name listed more than once counts once. A name the account has no domain for narrows nothing. The first 100 of those are returned as `unmatched`. A list can be filtered on for 7 days, and is deleted after that. **API key scope required:** `DOMAINS_READ`. Requests authenticated with a seller session do not need any scope.
222
+ * Upload a list of domain names to filter on
223
+ */
224
+ createDomainNameListRaw(requestParameters: DomainsApiCreateDomainNameListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DomainNameListDto>>;
225
+ /**
226
+ * Takes a text file of domain names and answers with the id of the list. Pass that id as `nameListId` to the domains list, its currencies, its export and the bulk edits, to narrow them to the domains named in the file. The names may each be on a line of their own, or be separated by commas, semicolons or spaces. Letter case does not matter, and an internationalised name may be written in Unicode or in punycode. A name listed more than once counts once. A name the account has no domain for narrows nothing. The first 100 of those are returned as `unmatched`. A list can be filtered on for 7 days, and is deleted after that. **API key scope required:** `DOMAINS_READ`. Requests authenticated with a seller session do not need any scope.
227
+ * Upload a list of domain names to filter on
228
+ */
229
+ createDomainNameList(requestParameters: DomainsApiCreateDomainNameListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DomainNameListDto>;
208
230
  /**
209
231
  * Deletes multiple domains by ID. Domains with open leads or active auctions cannot be deleted. **API key scope required:** `DOMAINS_WRITE`. Requests authenticated with a seller session do not need any scope.
210
232
  * Delete domains
@@ -285,6 +307,16 @@ export declare class DomainsApi extends runtime.BaseAPI {
285
307
  * Get domain filter currencies
286
308
  */
287
309
  getDomainFiltersCurrencies(requestParameters?: DomainsApiGetDomainFiltersCurrenciesRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<string>>;
310
+ /**
311
+ * Returns a list uploaded to POST /private/domains/name-lists as it stands now: how many of its names the account has a domain for, and the first 100 it has none for. **API key scope required:** `DOMAINS_READ`. Requests authenticated with a seller session do not need any scope.
312
+ * Get an uploaded list of domain names
313
+ */
314
+ getDomainNameListRaw(requestParameters: DomainsApiGetDomainNameListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DomainNameListDto>>;
315
+ /**
316
+ * Returns a list uploaded to POST /private/domains/name-lists as it stands now: how many of its names the account has a domain for, and the first 100 it has none for. **API key scope required:** `DOMAINS_READ`. Requests authenticated with a seller session do not need any scope.
317
+ * Get an uploaded list of domain names
318
+ */
319
+ getDomainNameList(requestParameters: DomainsApiGetDomainNameListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DomainNameListDto>;
288
320
  /**
289
321
  * Returns domain transfer information. **API key scope required:** `TRANSFERS_READ`. Requests authenticated with a seller session do not need any scope.
290
322
  * Get domain transfer
@@ -92,6 +92,9 @@ var DomainsApi = /** @class */ (function (_super) {
92
92
  if (requestParameters['searchFilter'] != null) {
93
93
  queryParameters['searchFilter'] = requestParameters['searchFilter'];
94
94
  }
95
+ if (requestParameters['nameListId'] != null) {
96
+ queryParameters['nameListId'] = requestParameters['nameListId'];
97
+ }
95
98
  if (requestParameters['filter'] != null) {
96
99
  queryParameters['filter'] = requestParameters['filter'];
97
100
  }
@@ -392,6 +395,9 @@ var DomainsApi = /** @class */ (function (_super) {
392
395
  if (requestParameters['searchFilter'] != null) {
393
396
  queryParameters['searchFilter'] = requestParameters['searchFilter'];
394
397
  }
398
+ if (requestParameters['nameListId'] != null) {
399
+ queryParameters['nameListId'] = requestParameters['nameListId'];
400
+ }
395
401
  if (requestParameters['filter'] != null) {
396
402
  queryParameters['filter'] = requestParameters['filter'];
397
403
  }
@@ -633,6 +639,87 @@ var DomainsApi = /** @class */ (function (_super) {
633
639
  });
634
640
  });
635
641
  };
642
+ /**
643
+ * Takes a text file of domain names and answers with the id of the list. Pass that id as `nameListId` to the domains list, its currencies, its export and the bulk edits, to narrow them to the domains named in the file. The names may each be on a line of their own, or be separated by commas, semicolons or spaces. Letter case does not matter, and an internationalised name may be written in Unicode or in punycode. A name listed more than once counts once. A name the account has no domain for narrows nothing. The first 100 of those are returned as `unmatched`. A list can be filtered on for 7 days, and is deleted after that. **API key scope required:** `DOMAINS_READ`. Requests authenticated with a seller session do not need any scope.
644
+ * Upload a list of domain names to filter on
645
+ */
646
+ DomainsApi.prototype.createDomainNameListRaw = function (requestParameters, initOverrides) {
647
+ return __awaiter(this, void 0, void 0, function () {
648
+ var queryParameters, headerParameters, _a, _b, token, tokenString, consumes, canConsumeForm, formParams, useForm, response;
649
+ return __generator(this, function (_c) {
650
+ switch (_c.label) {
651
+ case 0:
652
+ if (requestParameters['file'] == null) {
653
+ throw new runtime.RequiredError('file', 'Required parameter "file" was null or undefined when calling createDomainNameList().');
654
+ }
655
+ queryParameters = {};
656
+ headerParameters = {};
657
+ if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 2];
658
+ _a = headerParameters;
659
+ _b = "apikey";
660
+ return [4 /*yield*/, this.configuration.apiKey("apikey")];
661
+ case 1:
662
+ _a[_b] = _c.sent(); // api_key authentication
663
+ _c.label = 2;
664
+ case 2:
665
+ if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 4];
666
+ token = this.configuration.accessToken;
667
+ return [4 /*yield*/, token("bearer", [])];
668
+ case 3:
669
+ tokenString = _c.sent();
670
+ if (tokenString) {
671
+ headerParameters["Authorization"] = "Bearer ".concat(tokenString);
672
+ }
673
+ _c.label = 4;
674
+ case 4:
675
+ consumes = [
676
+ { contentType: 'multipart/form-data' },
677
+ ];
678
+ canConsumeForm = runtime.canConsumeForm(consumes);
679
+ useForm = false;
680
+ // use FormData to transmit files using content-type "multipart/form-data"
681
+ useForm = canConsumeForm;
682
+ if (useForm) {
683
+ formParams = new FormData();
684
+ }
685
+ else {
686
+ formParams = new URLSearchParams();
687
+ }
688
+ if (requestParameters['file'] != null) {
689
+ formParams.append('file', requestParameters['file']);
690
+ }
691
+ return [4 /*yield*/, this.request({
692
+ path: "/private/domains/name-lists",
693
+ method: 'POST',
694
+ headers: headerParameters,
695
+ query: queryParameters,
696
+ body: formParams,
697
+ }, initOverrides)];
698
+ case 5:
699
+ response = _c.sent();
700
+ return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.DomainNameListDtoFromJSON)(jsonValue); })];
701
+ }
702
+ });
703
+ });
704
+ };
705
+ /**
706
+ * Takes a text file of domain names and answers with the id of the list. Pass that id as `nameListId` to the domains list, its currencies, its export and the bulk edits, to narrow them to the domains named in the file. The names may each be on a line of their own, or be separated by commas, semicolons or spaces. Letter case does not matter, and an internationalised name may be written in Unicode or in punycode. A name listed more than once counts once. A name the account has no domain for narrows nothing. The first 100 of those are returned as `unmatched`. A list can be filtered on for 7 days, and is deleted after that. **API key scope required:** `DOMAINS_READ`. Requests authenticated with a seller session do not need any scope.
707
+ * Upload a list of domain names to filter on
708
+ */
709
+ DomainsApi.prototype.createDomainNameList = function (requestParameters, initOverrides) {
710
+ return __awaiter(this, void 0, void 0, function () {
711
+ var response;
712
+ return __generator(this, function (_a) {
713
+ switch (_a.label) {
714
+ case 0: return [4 /*yield*/, this.createDomainNameListRaw(requestParameters, initOverrides)];
715
+ case 1:
716
+ response = _a.sent();
717
+ return [4 /*yield*/, response.value()];
718
+ case 2: return [2 /*return*/, _a.sent()];
719
+ }
720
+ });
721
+ });
722
+ };
636
723
  /**
637
724
  * Deletes multiple domains by ID. Domains with open leads or active auctions cannot be deleted. **API key scope required:** `DOMAINS_WRITE`. Requests authenticated with a seller session do not need any scope.
638
725
  * Delete domains
@@ -710,6 +797,9 @@ var DomainsApi = /** @class */ (function (_super) {
710
797
  if (requestParameters['searchFilter'] != null) {
711
798
  queryParameters['searchFilter'] = requestParameters['searchFilter'];
712
799
  }
800
+ if (requestParameters['nameListId'] != null) {
801
+ queryParameters['nameListId'] = requestParameters['nameListId'];
802
+ }
713
803
  if (requestParameters['filter'] != null) {
714
804
  queryParameters['filter'] = requestParameters['filter'];
715
805
  }
@@ -1106,6 +1196,9 @@ var DomainsApi = /** @class */ (function (_super) {
1106
1196
  if (requestParameters['searchFilter'] != null) {
1107
1197
  queryParameters['searchFilter'] = requestParameters['searchFilter'];
1108
1198
  }
1199
+ if (requestParameters['nameListId'] != null) {
1200
+ queryParameters['nameListId'] = requestParameters['nameListId'];
1201
+ }
1109
1202
  if (requestParameters['filter'] != null) {
1110
1203
  queryParameters['filter'] = requestParameters['filter'];
1111
1204
  }
@@ -1159,6 +1252,69 @@ var DomainsApi = /** @class */ (function (_super) {
1159
1252
  });
1160
1253
  });
1161
1254
  };
1255
+ /**
1256
+ * Returns a list uploaded to POST /private/domains/name-lists as it stands now: how many of its names the account has a domain for, and the first 100 it has none for. **API key scope required:** `DOMAINS_READ`. Requests authenticated with a seller session do not need any scope.
1257
+ * Get an uploaded list of domain names
1258
+ */
1259
+ DomainsApi.prototype.getDomainNameListRaw = function (requestParameters, initOverrides) {
1260
+ return __awaiter(this, void 0, void 0, function () {
1261
+ var queryParameters, headerParameters, _a, _b, token, tokenString, response;
1262
+ return __generator(this, function (_c) {
1263
+ switch (_c.label) {
1264
+ case 0:
1265
+ if (requestParameters['nameListId'] == null) {
1266
+ throw new runtime.RequiredError('nameListId', 'Required parameter "nameListId" was null or undefined when calling getDomainNameList().');
1267
+ }
1268
+ queryParameters = {};
1269
+ headerParameters = {};
1270
+ if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 2];
1271
+ _a = headerParameters;
1272
+ _b = "apikey";
1273
+ return [4 /*yield*/, this.configuration.apiKey("apikey")];
1274
+ case 1:
1275
+ _a[_b] = _c.sent(); // api_key authentication
1276
+ _c.label = 2;
1277
+ case 2:
1278
+ if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 4];
1279
+ token = this.configuration.accessToken;
1280
+ return [4 /*yield*/, token("bearer", [])];
1281
+ case 3:
1282
+ tokenString = _c.sent();
1283
+ if (tokenString) {
1284
+ headerParameters["Authorization"] = "Bearer ".concat(tokenString);
1285
+ }
1286
+ _c.label = 4;
1287
+ case 4: return [4 /*yield*/, this.request({
1288
+ path: "/private/domains/name-lists/{nameListId}".replace("{".concat("nameListId", "}"), encodeURIComponent(String(requestParameters['nameListId']))),
1289
+ method: 'GET',
1290
+ headers: headerParameters,
1291
+ query: queryParameters,
1292
+ }, initOverrides)];
1293
+ case 5:
1294
+ response = _c.sent();
1295
+ return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.DomainNameListDtoFromJSON)(jsonValue); })];
1296
+ }
1297
+ });
1298
+ });
1299
+ };
1300
+ /**
1301
+ * Returns a list uploaded to POST /private/domains/name-lists as it stands now: how many of its names the account has a domain for, and the first 100 it has none for. **API key scope required:** `DOMAINS_READ`. Requests authenticated with a seller session do not need any scope.
1302
+ * Get an uploaded list of domain names
1303
+ */
1304
+ DomainsApi.prototype.getDomainNameList = function (requestParameters, initOverrides) {
1305
+ return __awaiter(this, void 0, void 0, function () {
1306
+ var response;
1307
+ return __generator(this, function (_a) {
1308
+ switch (_a.label) {
1309
+ case 0: return [4 /*yield*/, this.getDomainNameListRaw(requestParameters, initOverrides)];
1310
+ case 1:
1311
+ response = _a.sent();
1312
+ return [4 /*yield*/, response.value()];
1313
+ case 2: return [2 /*return*/, _a.sent()];
1314
+ }
1315
+ });
1316
+ });
1317
+ };
1162
1318
  /**
1163
1319
  * Returns domain transfer information. **API key scope required:** `TRANSFERS_READ`. Requests authenticated with a seller session do not need any scope.
1164
1320
  * Get domain transfer
@@ -1299,6 +1455,9 @@ var DomainsApi = /** @class */ (function (_super) {
1299
1455
  if (requestParameters['searchFilter'] != null) {
1300
1456
  queryParameters['searchFilter'] = requestParameters['searchFilter'];
1301
1457
  }
1458
+ if (requestParameters['nameListId'] != null) {
1459
+ queryParameters['nameListId'] = requestParameters['nameListId'];
1460
+ }
1302
1461
  if (requestParameters['filter'] != null) {
1303
1462
  queryParameters['filter'] = requestParameters['filter'];
1304
1463
  }
@@ -1399,6 +1558,9 @@ var DomainsApi = /** @class */ (function (_super) {
1399
1558
  if (requestParameters['searchFilter'] != null) {
1400
1559
  queryParameters['searchFilter'] = requestParameters['searchFilter'];
1401
1560
  }
1561
+ if (requestParameters['nameListId'] != null) {
1562
+ queryParameters['nameListId'] = requestParameters['nameListId'];
1563
+ }
1402
1564
  if (requestParameters['filter'] != null) {
1403
1565
  queryParameters['filter'] = requestParameters['filter'];
1404
1566
  }
@@ -0,0 +1,56 @@
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 DomainNameListDto
16
+ */
17
+ export interface DomainNameListDto {
18
+ /**
19
+ * Pass it as `nameListId` to the domains list, its export and the bulk edits, to narrow them to the domains of the list.
20
+ * @type {string}
21
+ * @memberof DomainNameListDto
22
+ */
23
+ id: string;
24
+ /**
25
+ * The distinct domain names the list held.
26
+ * @type {number}
27
+ * @memberof DomainNameListDto
28
+ */
29
+ total: number;
30
+ /**
31
+ * How many of them are a domain of the account.
32
+ * @type {number}
33
+ * @memberof DomainNameListDto
34
+ */
35
+ matched: number;
36
+ /**
37
+ * The names that are not a domain of the account, in the order of the list. At most the first 100; `total` minus `matched` is how many there are.
38
+ * @type {Array<string>}
39
+ * @memberof DomainNameListDto
40
+ */
41
+ unmatched: Array<string>;
42
+ /**
43
+ * Until when the list can be filtered on.
44
+ * @type {Date}
45
+ * @memberof DomainNameListDto
46
+ */
47
+ expiresAt: Date;
48
+ }
49
+ /**
50
+ * Check if a given object implements the DomainNameListDto interface.
51
+ */
52
+ export declare function instanceOfDomainNameListDto(value: object): value is DomainNameListDto;
53
+ export declare function DomainNameListDtoFromJSON(json: any): DomainNameListDto;
54
+ export declare function DomainNameListDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): DomainNameListDto;
55
+ export declare function DomainNameListDtoToJSON(json: any): DomainNameListDto;
56
+ export declare function DomainNameListDtoToJSONTyped(value?: DomainNameListDto | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,67 @@
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.instanceOfDomainNameListDto = instanceOfDomainNameListDto;
17
+ exports.DomainNameListDtoFromJSON = DomainNameListDtoFromJSON;
18
+ exports.DomainNameListDtoFromJSONTyped = DomainNameListDtoFromJSONTyped;
19
+ exports.DomainNameListDtoToJSON = DomainNameListDtoToJSON;
20
+ exports.DomainNameListDtoToJSONTyped = DomainNameListDtoToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the DomainNameListDto interface.
23
+ */
24
+ function instanceOfDomainNameListDto(value) {
25
+ if (!('id' in value) || value['id'] === undefined)
26
+ return false;
27
+ if (!('total' in value) || value['total'] === undefined)
28
+ return false;
29
+ if (!('matched' in value) || value['matched'] === undefined)
30
+ return false;
31
+ if (!('unmatched' in value) || value['unmatched'] === undefined)
32
+ return false;
33
+ if (!('expiresAt' in value) || value['expiresAt'] === undefined)
34
+ return false;
35
+ return true;
36
+ }
37
+ function DomainNameListDtoFromJSON(json) {
38
+ return DomainNameListDtoFromJSONTyped(json, false);
39
+ }
40
+ function DomainNameListDtoFromJSONTyped(json, ignoreDiscriminator) {
41
+ if (json == null) {
42
+ return json;
43
+ }
44
+ return {
45
+ 'id': json['id'],
46
+ 'total': json['total'],
47
+ 'matched': json['matched'],
48
+ 'unmatched': json['unmatched'],
49
+ 'expiresAt': (new Date(json['expiresAt'])),
50
+ };
51
+ }
52
+ function DomainNameListDtoToJSON(json) {
53
+ return DomainNameListDtoToJSONTyped(json, false);
54
+ }
55
+ function DomainNameListDtoToJSONTyped(value, ignoreDiscriminator) {
56
+ if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
57
+ if (value == null) {
58
+ return value;
59
+ }
60
+ return {
61
+ 'id': value['id'],
62
+ 'total': value['total'],
63
+ 'matched': value['matched'],
64
+ 'unmatched': value['unmatched'],
65
+ 'expiresAt': ((value['expiresAt']).toISOString()),
66
+ };
67
+ }
@@ -292,6 +292,7 @@ export * from './DomainLockConfigurationDto';
292
292
  export * from './DomainLockDto';
293
293
  export * from './DomainMinimalLandingPageDesignDto';
294
294
  export * from './DomainModernLandingPageDesignDto';
295
+ export * from './DomainNameListDto';
295
296
  export * from './DomainOriginalLandingPageDesignDto';
296
297
  export * from './DomainPricesChangeDto';
297
298
  export * from './DomainSalesInformationDto';
@@ -310,6 +310,7 @@ __exportStar(require("./DomainLockConfigurationDto"), exports);
310
310
  __exportStar(require("./DomainLockDto"), exports);
311
311
  __exportStar(require("./DomainMinimalLandingPageDesignDto"), exports);
312
312
  __exportStar(require("./DomainModernLandingPageDesignDto"), exports);
313
+ __exportStar(require("./DomainNameListDto"), exports);
313
314
  __exportStar(require("./DomainOriginalLandingPageDesignDto"), exports);
314
315
  __exportStar(require("./DomainPricesChangeDto"), exports);
315
316
  __exportStar(require("./DomainSalesInformationDto"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@randock/nameshift-api-client",
3
- "version": "0.0.559",
3
+ "version": "0.0.560",
4
4
  "description": "OpenAPI client for @randock/nameshift-api-client",
5
5
  "author": "OpenAPI-Generator",
6
6
  "repository": {
@@ -25,6 +25,7 @@ import type {
25
25
  DomainEditPreviewDto,
26
26
  DomainExchangeRateDto,
27
27
  DomainFiltersDto,
28
+ DomainNameListDto,
28
29
  DomainSearchTranslationDto,
29
30
  DomainUrlDto,
30
31
  DomainVerificationStatusDto,
@@ -64,6 +65,8 @@ import {
64
65
  DomainExchangeRateDtoToJSON,
65
66
  DomainFiltersDtoFromJSON,
66
67
  DomainFiltersDtoToJSON,
68
+ DomainNameListDtoFromJSON,
69
+ DomainNameListDtoToJSON,
67
70
  DomainSearchTranslationDtoFromJSON,
68
71
  DomainSearchTranslationDtoToJSON,
69
72
  DomainUrlDtoFromJSON,
@@ -103,6 +106,7 @@ import {
103
106
  export interface DomainsApiApplyDomainEditRequest {
104
107
  applyDomainEditInput: ApplyDomainEditInput;
105
108
  searchFilter?: string;
109
+ nameListId?: string;
106
110
  filter?: { [key: string]: string; };
107
111
  }
108
112
 
@@ -123,6 +127,7 @@ export interface DomainsApiBatchUpdateRequest {
123
127
  export interface DomainsApiBulkUpdateDomainsWithFiltersRequest {
124
128
  bulkUpdateDomainsWithFiltersInput: BulkUpdateDomainsWithFiltersInput;
125
129
  searchFilter?: string;
130
+ nameListId?: string;
126
131
  filter?: object;
127
132
  }
128
133
 
@@ -138,12 +143,17 @@ export interface DomainsApiCheckDomainVerificationRequest {
138
143
  domainId: string;
139
144
  }
140
145
 
146
+ export interface DomainsApiCreateDomainNameListRequest {
147
+ file: Blob;
148
+ }
149
+
141
150
  export interface DomainsApiDeleteDomainsRequest {
142
151
  deleteDomainsInput: DeleteDomainsInput;
143
152
  }
144
153
 
145
154
  export interface DomainsApiExportDomainsRequest {
146
155
  searchFilter?: string;
156
+ nameListId?: string;
147
157
  filter?: object;
148
158
  }
149
159
 
@@ -170,9 +180,14 @@ export interface DomainsApiGetDomainExchangeRateRequest {
170
180
 
171
181
  export interface DomainsApiGetDomainFiltersCurrenciesRequest {
172
182
  searchFilter?: string;
183
+ nameListId?: string;
173
184
  filter?: object;
174
185
  }
175
186
 
187
+ export interface DomainsApiGetDomainNameListRequest {
188
+ nameListId: string;
189
+ }
190
+
176
191
  export interface DomainsApiGetDomainTransferRequest {
177
192
  transferId: string;
178
193
  }
@@ -183,6 +198,7 @@ export interface DomainsApiGetDomainUrlRequest {
183
198
 
184
199
  export interface DomainsApiListRequest {
185
200
  searchFilter?: string;
201
+ nameListId?: string;
186
202
  filter?: { [key: string]: string; };
187
203
  page?: number;
188
204
  limit?: number;
@@ -199,6 +215,7 @@ export interface DomainsApiListRequest {
199
215
  export interface DomainsApiPreviewDomainEditRequest {
200
216
  previewDomainEditInput: PreviewDomainEditInput;
201
217
  searchFilter?: string;
218
+ nameListId?: string;
202
219
  filter?: { [key: string]: string; };
203
220
  }
204
221
 
@@ -249,6 +266,10 @@ export class DomainsApi extends runtime.BaseAPI {
249
266
  queryParameters['searchFilter'] = requestParameters['searchFilter'];
250
267
  }
251
268
 
269
+ if (requestParameters['nameListId'] != null) {
270
+ queryParameters['nameListId'] = requestParameters['nameListId'];
271
+ }
272
+
252
273
  if (requestParameters['filter'] != null) {
253
274
  queryParameters['filter'] = requestParameters['filter'];
254
275
  }
@@ -487,6 +508,10 @@ export class DomainsApi extends runtime.BaseAPI {
487
508
  queryParameters['searchFilter'] = requestParameters['searchFilter'];
488
509
  }
489
510
 
511
+ if (requestParameters['nameListId'] != null) {
512
+ queryParameters['nameListId'] = requestParameters['nameListId'];
513
+ }
514
+
490
515
  if (requestParameters['filter'] != null) {
491
516
  queryParameters['filter'] = requestParameters['filter'];
492
517
  }
@@ -669,6 +694,74 @@ export class DomainsApi extends runtime.BaseAPI {
669
694
  return await response.value();
670
695
  }
671
696
 
697
+ /**
698
+ * Takes a text file of domain names and answers with the id of the list. Pass that id as `nameListId` to the domains list, its currencies, its export and the bulk edits, to narrow them to the domains named in the file. The names may each be on a line of their own, or be separated by commas, semicolons or spaces. Letter case does not matter, and an internationalised name may be written in Unicode or in punycode. A name listed more than once counts once. A name the account has no domain for narrows nothing. The first 100 of those are returned as `unmatched`. A list can be filtered on for 7 days, and is deleted after that. **API key scope required:** `DOMAINS_READ`. Requests authenticated with a seller session do not need any scope.
699
+ * Upload a list of domain names to filter on
700
+ */
701
+ async createDomainNameListRaw(requestParameters: DomainsApiCreateDomainNameListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DomainNameListDto>> {
702
+ if (requestParameters['file'] == null) {
703
+ throw new runtime.RequiredError(
704
+ 'file',
705
+ 'Required parameter "file" was null or undefined when calling createDomainNameList().'
706
+ );
707
+ }
708
+
709
+ const queryParameters: any = {};
710
+
711
+ const headerParameters: runtime.HTTPHeaders = {};
712
+
713
+ if (this.configuration && this.configuration.apiKey) {
714
+ headerParameters["apikey"] = await this.configuration.apiKey("apikey"); // api_key authentication
715
+ }
716
+
717
+ if (this.configuration && this.configuration.accessToken) {
718
+ const token = this.configuration.accessToken;
719
+ const tokenString = await token("bearer", []);
720
+
721
+ if (tokenString) {
722
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
723
+ }
724
+ }
725
+ const consumes: runtime.Consume[] = [
726
+ { contentType: 'multipart/form-data' },
727
+ ];
728
+ // @ts-ignore: canConsumeForm may be unused
729
+ const canConsumeForm = runtime.canConsumeForm(consumes);
730
+
731
+ let formParams: { append(param: string, value: any): any };
732
+ let useForm = false;
733
+ // use FormData to transmit files using content-type "multipart/form-data"
734
+ useForm = canConsumeForm;
735
+ if (useForm) {
736
+ formParams = new FormData();
737
+ } else {
738
+ formParams = new URLSearchParams();
739
+ }
740
+
741
+ if (requestParameters['file'] != null) {
742
+ formParams.append('file', requestParameters['file'] as any);
743
+ }
744
+
745
+ const response = await this.request({
746
+ path: `/private/domains/name-lists`,
747
+ method: 'POST',
748
+ headers: headerParameters,
749
+ query: queryParameters,
750
+ body: formParams,
751
+ }, initOverrides);
752
+
753
+ return new runtime.JSONApiResponse(response, (jsonValue) => DomainNameListDtoFromJSON(jsonValue));
754
+ }
755
+
756
+ /**
757
+ * Takes a text file of domain names and answers with the id of the list. Pass that id as `nameListId` to the domains list, its currencies, its export and the bulk edits, to narrow them to the domains named in the file. The names may each be on a line of their own, or be separated by commas, semicolons or spaces. Letter case does not matter, and an internationalised name may be written in Unicode or in punycode. A name listed more than once counts once. A name the account has no domain for narrows nothing. The first 100 of those are returned as `unmatched`. A list can be filtered on for 7 days, and is deleted after that. **API key scope required:** `DOMAINS_READ`. Requests authenticated with a seller session do not need any scope.
758
+ * Upload a list of domain names to filter on
759
+ */
760
+ async createDomainNameList(requestParameters: DomainsApiCreateDomainNameListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DomainNameListDto> {
761
+ const response = await this.createDomainNameListRaw(requestParameters, initOverrides);
762
+ return await response.value();
763
+ }
764
+
672
765
  /**
673
766
  * Deletes multiple domains by ID. Domains with open leads or active auctions cannot be deleted. **API key scope required:** `DOMAINS_WRITE`. Requests authenticated with a seller session do not need any scope.
674
767
  * Delete domains
@@ -729,6 +822,10 @@ export class DomainsApi extends runtime.BaseAPI {
729
822
  queryParameters['searchFilter'] = requestParameters['searchFilter'];
730
823
  }
731
824
 
825
+ if (requestParameters['nameListId'] != null) {
826
+ queryParameters['nameListId'] = requestParameters['nameListId'];
827
+ }
828
+
732
829
  if (requestParameters['filter'] != null) {
733
830
  queryParameters['filter'] = requestParameters['filter'];
734
831
  }
@@ -1025,6 +1122,10 @@ export class DomainsApi extends runtime.BaseAPI {
1025
1122
  queryParameters['searchFilter'] = requestParameters['searchFilter'];
1026
1123
  }
1027
1124
 
1125
+ if (requestParameters['nameListId'] != null) {
1126
+ queryParameters['nameListId'] = requestParameters['nameListId'];
1127
+ }
1128
+
1028
1129
  if (requestParameters['filter'] != null) {
1029
1130
  queryParameters['filter'] = requestParameters['filter'];
1030
1131
  }
@@ -1062,6 +1163,53 @@ export class DomainsApi extends runtime.BaseAPI {
1062
1163
  return await response.value();
1063
1164
  }
1064
1165
 
1166
+ /**
1167
+ * Returns a list uploaded to POST /private/domains/name-lists as it stands now: how many of its names the account has a domain for, and the first 100 it has none for. **API key scope required:** `DOMAINS_READ`. Requests authenticated with a seller session do not need any scope.
1168
+ * Get an uploaded list of domain names
1169
+ */
1170
+ async getDomainNameListRaw(requestParameters: DomainsApiGetDomainNameListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DomainNameListDto>> {
1171
+ if (requestParameters['nameListId'] == null) {
1172
+ throw new runtime.RequiredError(
1173
+ 'nameListId',
1174
+ 'Required parameter "nameListId" was null or undefined when calling getDomainNameList().'
1175
+ );
1176
+ }
1177
+
1178
+ const queryParameters: any = {};
1179
+
1180
+ const headerParameters: runtime.HTTPHeaders = {};
1181
+
1182
+ if (this.configuration && this.configuration.apiKey) {
1183
+ headerParameters["apikey"] = await this.configuration.apiKey("apikey"); // api_key authentication
1184
+ }
1185
+
1186
+ if (this.configuration && this.configuration.accessToken) {
1187
+ const token = this.configuration.accessToken;
1188
+ const tokenString = await token("bearer", []);
1189
+
1190
+ if (tokenString) {
1191
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
1192
+ }
1193
+ }
1194
+ const response = await this.request({
1195
+ path: `/private/domains/name-lists/{nameListId}`.replace(`{${"nameListId"}}`, encodeURIComponent(String(requestParameters['nameListId']))),
1196
+ method: 'GET',
1197
+ headers: headerParameters,
1198
+ query: queryParameters,
1199
+ }, initOverrides);
1200
+
1201
+ return new runtime.JSONApiResponse(response, (jsonValue) => DomainNameListDtoFromJSON(jsonValue));
1202
+ }
1203
+
1204
+ /**
1205
+ * Returns a list uploaded to POST /private/domains/name-lists as it stands now: how many of its names the account has a domain for, and the first 100 it has none for. **API key scope required:** `DOMAINS_READ`. Requests authenticated with a seller session do not need any scope.
1206
+ * Get an uploaded list of domain names
1207
+ */
1208
+ async getDomainNameList(requestParameters: DomainsApiGetDomainNameListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DomainNameListDto> {
1209
+ const response = await this.getDomainNameListRaw(requestParameters, initOverrides);
1210
+ return await response.value();
1211
+ }
1212
+
1065
1213
  /**
1066
1214
  * Returns domain transfer information. **API key scope required:** `TRANSFERS_READ`. Requests authenticated with a seller session do not need any scope.
1067
1215
  * Get domain transfer
@@ -1167,6 +1315,10 @@ export class DomainsApi extends runtime.BaseAPI {
1167
1315
  queryParameters['searchFilter'] = requestParameters['searchFilter'];
1168
1316
  }
1169
1317
 
1318
+ if (requestParameters['nameListId'] != null) {
1319
+ queryParameters['nameListId'] = requestParameters['nameListId'];
1320
+ }
1321
+
1170
1322
  if (requestParameters['filter'] != null) {
1171
1323
  queryParameters['filter'] = requestParameters['filter'];
1172
1324
  }
@@ -1262,6 +1414,10 @@ export class DomainsApi extends runtime.BaseAPI {
1262
1414
  queryParameters['searchFilter'] = requestParameters['searchFilter'];
1263
1415
  }
1264
1416
 
1417
+ if (requestParameters['nameListId'] != null) {
1418
+ queryParameters['nameListId'] = requestParameters['nameListId'];
1419
+ }
1420
+
1265
1421
  if (requestParameters['filter'] != null) {
1266
1422
  queryParameters['filter'] = requestParameters['filter'];
1267
1423
  }
@@ -0,0 +1,102 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Nameshift
5
+ * 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.
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 DomainNameListDto
20
+ */
21
+ export interface DomainNameListDto {
22
+ /**
23
+ * Pass it as `nameListId` to the domains list, its export and the bulk edits, to narrow them to the domains of the list.
24
+ * @type {string}
25
+ * @memberof DomainNameListDto
26
+ */
27
+ id: string;
28
+ /**
29
+ * The distinct domain names the list held.
30
+ * @type {number}
31
+ * @memberof DomainNameListDto
32
+ */
33
+ total: number;
34
+ /**
35
+ * How many of them are a domain of the account.
36
+ * @type {number}
37
+ * @memberof DomainNameListDto
38
+ */
39
+ matched: number;
40
+ /**
41
+ * The names that are not a domain of the account, in the order of the list. At most the first 100; `total` minus `matched` is how many there are.
42
+ * @type {Array<string>}
43
+ * @memberof DomainNameListDto
44
+ */
45
+ unmatched: Array<string>;
46
+ /**
47
+ * Until when the list can be filtered on.
48
+ * @type {Date}
49
+ * @memberof DomainNameListDto
50
+ */
51
+ expiresAt: Date;
52
+ }
53
+
54
+ /**
55
+ * Check if a given object implements the DomainNameListDto interface.
56
+ */
57
+ export function instanceOfDomainNameListDto(value: object): value is DomainNameListDto {
58
+ if (!('id' in value) || value['id'] === undefined) return false;
59
+ if (!('total' in value) || value['total'] === undefined) return false;
60
+ if (!('matched' in value) || value['matched'] === undefined) return false;
61
+ if (!('unmatched' in value) || value['unmatched'] === undefined) return false;
62
+ if (!('expiresAt' in value) || value['expiresAt'] === undefined) return false;
63
+ return true;
64
+ }
65
+
66
+ export function DomainNameListDtoFromJSON(json: any): DomainNameListDto {
67
+ return DomainNameListDtoFromJSONTyped(json, false);
68
+ }
69
+
70
+ export function DomainNameListDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): DomainNameListDto {
71
+ if (json == null) {
72
+ return json;
73
+ }
74
+ return {
75
+
76
+ 'id': json['id'],
77
+ 'total': json['total'],
78
+ 'matched': json['matched'],
79
+ 'unmatched': json['unmatched'],
80
+ 'expiresAt': (new Date(json['expiresAt'])),
81
+ };
82
+ }
83
+
84
+ export function DomainNameListDtoToJSON(json: any): DomainNameListDto {
85
+ return DomainNameListDtoToJSONTyped(json, false);
86
+ }
87
+
88
+ export function DomainNameListDtoToJSONTyped(value?: DomainNameListDto | null, ignoreDiscriminator: boolean = false): any {
89
+ if (value == null) {
90
+ return value;
91
+ }
92
+
93
+ return {
94
+
95
+ 'id': value['id'],
96
+ 'total': value['total'],
97
+ 'matched': value['matched'],
98
+ 'unmatched': value['unmatched'],
99
+ 'expiresAt': ((value['expiresAt']).toISOString()),
100
+ };
101
+ }
102
+
@@ -294,6 +294,7 @@ export * from './DomainLockConfigurationDto';
294
294
  export * from './DomainLockDto';
295
295
  export * from './DomainMinimalLandingPageDesignDto';
296
296
  export * from './DomainModernLandingPageDesignDto';
297
+ export * from './DomainNameListDto';
297
298
  export * from './DomainOriginalLandingPageDesignDto';
298
299
  export * from './DomainPricesChangeDto';
299
300
  export * from './DomainSalesInformationDto';