@randock/nameshift-api-client 0.0.492 → 0.0.493

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 (66) hide show
  1. package/.openapi-generator/FILES +9 -8
  2. package/README.md +3 -3
  3. package/dist/apis/BankAccountsApi.d.ts +40 -1
  4. package/dist/apis/BankAccountsApi.js +197 -0
  5. package/dist/models/AccountBankAccountDetailsDto.d.ts +40 -0
  6. package/dist/models/AccountBankAccountDetailsDto.js +55 -0
  7. package/dist/models/AccountBankAccountDto.d.ts +10 -4
  8. package/dist/models/AccountBankAccountDto.js +7 -3
  9. package/dist/models/BankAccountFormatCountryDto.d.ts +38 -0
  10. package/dist/models/BankAccountFormatCountryDto.js +55 -0
  11. package/dist/models/BankAccountFormatDto.d.ts +45 -0
  12. package/dist/models/BankAccountFormatDto.js +60 -0
  13. package/dist/models/BankAccountFormatFieldDto.d.ts +76 -0
  14. package/dist/models/BankAccountFormatFieldDto.js +81 -0
  15. package/dist/models/BankAccountFormatFieldOptionDto.d.ts +38 -0
  16. package/dist/models/BankAccountFormatFieldOptionDto.js +55 -0
  17. package/dist/models/BankAccountFormatFieldType.d.ts +26 -0
  18. package/dist/models/BankAccountFormatFieldType.js +52 -0
  19. package/dist/models/BankAccountFormatsDto.d.ts +33 -0
  20. package/dist/models/BankAccountFormatsDto.js +52 -0
  21. package/dist/models/CreateBankAccountDetailsInput.d.ts +40 -0
  22. package/dist/models/CreateBankAccountDetailsInput.js +55 -0
  23. package/dist/models/CreateBankAccountInput.d.ts +5 -4
  24. package/dist/models/CreateBankAccountInput.js +3 -2
  25. package/dist/models/SearchBankAccountInstitutionsInput.d.ts +46 -0
  26. package/dist/models/SearchBankAccountInstitutionsInput.js +55 -0
  27. package/dist/models/index.d.ts +9 -8
  28. package/dist/models/index.js +9 -8
  29. package/package.json +1 -1
  30. package/src/apis/BankAccountsApi.ts +181 -0
  31. package/src/models/AccountBankAccountDetailsDto.ts +75 -0
  32. package/src/models/AccountBankAccountDto.ts +20 -11
  33. package/src/models/BankAccountFormatCountryDto.ts +75 -0
  34. package/src/models/BankAccountFormatDto.ts +92 -0
  35. package/src/models/BankAccountFormatFieldDto.ts +146 -0
  36. package/src/models/BankAccountFormatFieldOptionDto.ts +75 -0
  37. package/src/models/BankAccountFormatFieldType.ts +54 -0
  38. package/src/models/BankAccountFormatsDto.ts +74 -0
  39. package/src/models/CreateBankAccountDetailsInput.ts +75 -0
  40. package/src/models/CreateBankAccountInput.ts +14 -6
  41. package/src/models/SearchBankAccountInstitutionsInput.ts +82 -0
  42. package/src/models/index.ts +9 -8
  43. package/dist/models/AccountBankAccountDtoDetails.d.ts +0 -42
  44. package/dist/models/AccountBankAccountDtoDetails.js +0 -79
  45. package/dist/models/AuBankAccountDetails.d.ts +0 -63
  46. package/dist/models/AuBankAccountDetails.js +0 -76
  47. package/dist/models/CaBankAccountDetails.d.ts +0 -69
  48. package/dist/models/CaBankAccountDetails.js +0 -80
  49. package/dist/models/NzBankAccountDetails.d.ts +0 -57
  50. package/dist/models/NzBankAccountDetails.js +0 -72
  51. package/dist/models/SeBankAccountDetails.d.ts +0 -75
  52. package/dist/models/SeBankAccountDetails.js +0 -84
  53. package/dist/models/SepaBankAccountDetails.d.ts +0 -63
  54. package/dist/models/SepaBankAccountDetails.js +0 -76
  55. package/dist/models/UkBankAccountDetails.d.ts +0 -63
  56. package/dist/models/UkBankAccountDetails.js +0 -76
  57. package/dist/models/UsBankAccountDetails.d.ts +0 -63
  58. package/dist/models/UsBankAccountDetails.js +0 -76
  59. package/src/models/AccountBankAccountDtoDetails.ts +0 -128
  60. package/src/models/AuBankAccountDetails.ts +0 -109
  61. package/src/models/CaBankAccountDetails.ts +0 -118
  62. package/src/models/NzBankAccountDetails.ts +0 -100
  63. package/src/models/SeBankAccountDetails.ts +0 -127
  64. package/src/models/SepaBankAccountDetails.ts +0 -109
  65. package/src/models/UkBankAccountDetails.ts +0 -109
  66. package/src/models/UsBankAccountDetails.ts +0 -109
@@ -43,8 +43,8 @@ src/apis/index.ts
43
43
  src/index.ts
44
44
  src/models/AccountAliasDto.ts
45
45
  src/models/AccountAliasInput.ts
46
+ src/models/AccountBankAccountDetailsDto.ts
46
47
  src/models/AccountBankAccountDto.ts
47
- src/models/AccountBankAccountDtoDetails.ts
48
48
  src/models/AccountBankAccountSummaryDto.ts
49
49
  src/models/AccountChallengeRewardUsageListItemDto.ts
50
50
  src/models/AccountChallengeRewardUsageListItemDtoMetadata.ts
@@ -125,7 +125,6 @@ src/models/ApiKeyDto.ts
125
125
  src/models/ApiKeyScopeDto.ts
126
126
  src/models/ApplyDomainEditInput.ts
127
127
  src/models/AssociateVisitorInput.ts
128
- src/models/AuBankAccountDetails.ts
129
128
  src/models/AuctionBidDto.ts
130
129
  src/models/AuctionBidInput.ts
131
130
  src/models/AuctionBidMetricsDto.ts
@@ -140,6 +139,12 @@ src/models/AuctionListItemDtoDomainInformation.ts
140
139
  src/models/AuctionListItemDtoSellerAccount.ts
141
140
  src/models/AuctionsStatsDto.ts
142
141
  src/models/BadRequestException.ts
142
+ src/models/BankAccountFormatCountryDto.ts
143
+ src/models/BankAccountFormatDto.ts
144
+ src/models/BankAccountFormatFieldDto.ts
145
+ src/models/BankAccountFormatFieldOptionDto.ts
146
+ src/models/BankAccountFormatFieldType.ts
147
+ src/models/BankAccountFormatsDto.ts
143
148
  src/models/BatchDeleteBuyerLeadsInput.ts
144
149
  src/models/BatchImportPreviewDto.ts
145
150
  src/models/BatchReadBuyerLeadMessageInput.ts
@@ -184,7 +189,6 @@ src/models/BuyerSessionDto.ts
184
189
  src/models/BuyerSubscriptionListItemDto.ts
185
190
  src/models/BuyerSubscriptionListItemDtoDomainInformation.ts
186
191
  src/models/BuyerTaskDetailsDto.ts
187
- src/models/CaBankAccountDetails.ts
188
192
  src/models/ChallengeRewardBalanceDto.ts
189
193
  src/models/ChangeInvoiceStatusInput.ts
190
194
  src/models/ChangeOrderStatusInput.ts
@@ -221,6 +225,7 @@ src/models/CreateAccountNoteInput.ts
221
225
  src/models/CreateAccountPaymentInput.ts
222
226
  src/models/CreateAccountPaymentManualTransactionInput.ts
223
227
  src/models/CreateApiKeyInput.ts
228
+ src/models/CreateBankAccountDetailsInput.ts
224
229
  src/models/CreateBankAccountInput.ts
225
230
  src/models/CreateBuyerDomainAppraisalRequestInput.ts
226
231
  src/models/CreateBuyerLeadMessageInput.ts
@@ -439,7 +444,6 @@ src/models/MoneyInput.ts
439
444
  src/models/MozMetrics.ts
440
445
  src/models/NotFoundException.ts
441
446
  src/models/NotificationsUnsubscribeResultDto.ts
442
- src/models/NzBankAccountDetails.ts
443
447
  src/models/ObjectId.ts
444
448
  src/models/OrderCompanyInfoDto.ts
445
449
  src/models/OrderCompanyTaxIdDto.ts
@@ -499,7 +503,7 @@ src/models/SalesCountCommissionPayloadDto.ts
499
503
  src/models/SalesCountCommissionPayloadInput.ts
500
504
  src/models/SalesCountCommissionPayloadSimulationInput.ts
501
505
  src/models/SalesCountCommissionReasonPayloadDto.ts
502
- src/models/SeBankAccountDetails.ts
506
+ src/models/SearchBankAccountInstitutionsInput.ts
503
507
  src/models/SellerAccountReferralListItemDto.ts
504
508
  src/models/SellerAffiliateCommissionDto.ts
505
509
  src/models/SellerAuctionListItemDto.ts
@@ -533,7 +537,6 @@ src/models/SellerTotalRentMonthlyIncomeByCurrencyStatsItemDto.ts
533
537
  src/models/SendAdminLeadAiPriceNegotiatorAgentChatMessageInput.ts
534
538
  src/models/SendAdminLeadAiPriceNegotiatorAgentChatMessageInputAiModel.ts
535
539
  src/models/SeoMetricsDto.ts
536
- src/models/SepaBankAccountDetails.ts
537
540
  src/models/SetAccountMarketplaceInput.ts
538
541
  src/models/SetDomainTransferConfirmationInput.ts
539
542
  src/models/SetNewPasswordInput.ts
@@ -576,7 +579,6 @@ src/models/TimeTableConfigurationInput.ts
576
579
  src/models/TopAffiliateSellerDto.ts
577
580
  src/models/TopSellerAccountDto.ts
578
581
  src/models/TranslateDomainSearchInput.ts
579
- src/models/UkBankAccountDetails.ts
580
582
  src/models/UpdateAccountBillingInformationInput.ts
581
583
  src/models/UpdateAccountChallengeRewardBalanceInput.ts
582
584
  src/models/UpdateAccountNoteInput.ts
@@ -607,7 +609,6 @@ src/models/UpdateSubscriptionInput.ts
607
609
  src/models/UpdateTaskMuteStatusForBuyerInput.ts
608
610
  src/models/UpdateTaskMuteStatusInput.ts
609
611
  src/models/UpdateUserNotificationSettingsInput.ts
610
- src/models/UsBankAccountDetails.ts
611
612
  src/models/UserNotificationAttachmentDto.ts
612
613
  src/models/UserNotificationDto.ts
613
614
  src/models/UserNotificationListItemDto.ts
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- ## @randock/nameshift-api-client@0.0.492
1
+ ## @randock/nameshift-api-client@0.0.493
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.492 --save
39
+ npm install @randock/nameshift-api-client@0.0.493 --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
- 5b1e45bef11b94ee4ff2796fa861bdb05f3034baa67b8397fa64a227e1d50a4261aa772677e5aae23ccb94f81331a660
47
+ d54bc8e1a61a398c5ffd5872c454e73bc6b129c755257f711fc587b9939fd640fcc03d2d0ec4dd7db73198bb1430acac
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { AccountBankAccountDto, AirwallexBankAccountDetailsDto, CreateBankAccountInput } from '../models/index';
13
+ import type { AccountBankAccountDto, AirwallexBankAccountDetailsDto, BankAccountFormatDto, BankAccountFormatFieldOptionDto, BankAccountFormatsDto, CreateBankAccountInput, SearchBankAccountInstitutionsInput } from '../models/index';
14
14
  export interface BankAccountsApiCreateBankAccountRequest {
15
15
  accountId: string;
16
16
  createBankAccountInput: CreateBankAccountInput;
@@ -19,6 +19,10 @@ export interface BankAccountsApiDeleteBankAccountRequest {
19
19
  accountId: string;
20
20
  bankAccountId: string;
21
21
  }
22
+ export interface BankAccountsApiGetBankAccountFormatRequest {
23
+ countryCode: string;
24
+ currencyCode: string;
25
+ }
22
26
  export interface BankAccountsApiGetBankAccountToUseForMicrodepositRequest {
23
27
  bankAccountId: string;
24
28
  accountId: string;
@@ -30,6 +34,11 @@ export interface BankAccountsApiMakeBankAccountPrimaryRequest {
30
34
  accountId: string;
31
35
  bankAccountId: string;
32
36
  }
37
+ export interface BankAccountsApiSearchBankAccountInstitutionsRequest {
38
+ countryCode: string;
39
+ currencyCode: string;
40
+ searchBankAccountInstitutionsInput: SearchBankAccountInstitutionsInput;
41
+ }
33
42
  /**
34
43
  *
35
44
  */
@@ -54,6 +63,16 @@ export declare class BankAccountsApi extends runtime.BaseAPI {
54
63
  * Delete bank account
55
64
  */
56
65
  deleteBankAccount(requestParameters: BankAccountsApiDeleteBankAccountRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
66
+ /**
67
+ * Returns the fields a bank account in this country and currency needs, to render the form from and submit in `details.fields`. **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
68
+ * Get the bank details to ask for
69
+ */
70
+ getBankAccountFormatRaw(requestParameters: BankAccountsApiGetBankAccountFormatRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<BankAccountFormatDto>>;
71
+ /**
72
+ * Returns the fields a bank account in this country and currency needs, to render the form from and submit in `details.fields`. **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
73
+ * Get the bank details to ask for
74
+ */
75
+ getBankAccountFormat(requestParameters: BankAccountsApiGetBankAccountFormatRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<BankAccountFormatDto>;
57
76
  /**
58
77
  * Returns bank account details to use for microdeposit verification. **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
59
78
  * Get microdeposit bank account details
@@ -64,6 +83,16 @@ export declare class BankAccountsApi extends runtime.BaseAPI {
64
83
  * Get microdeposit bank account details
65
84
  */
66
85
  getBankAccountToUseForMicrodeposit(requestParameters: BankAccountsApiGetBankAccountToUseForMicrodepositRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AirwallexBankAccountDetailsDto>;
86
+ /**
87
+ * Returns the bank countries and currencies we pay out to, for the current seller\'s entity type (business or personal). **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
88
+ * List bank account countries and currencies
89
+ */
90
+ listBankAccountFormatsRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<BankAccountFormatsDto>>;
91
+ /**
92
+ * Returns the bank countries and currencies we pay out to, for the current seller\'s entity type (business or personal). **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
93
+ * List bank account countries and currencies
94
+ */
95
+ listBankAccountFormats(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<BankAccountFormatsDto>;
67
96
  /**
68
97
  * Returns all bank accounts configured for the current seller account. **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
69
98
  * List bank accounts
@@ -84,4 +113,14 @@ export declare class BankAccountsApi extends runtime.BaseAPI {
84
113
  * Set primary bank account
85
114
  */
86
115
  makeBankAccountPrimary(requestParameters: BankAccountsApiMakeBankAccountPrimaryRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
116
+ /**
117
+ * Returns the banks or branches matching what the seller typed in a LOOKUP field, e.g. an IFSC code or a Japanese branch. **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
118
+ * Search banks or branches
119
+ */
120
+ searchBankAccountInstitutionsRaw(requestParameters: BankAccountsApiSearchBankAccountInstitutionsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<BankAccountFormatFieldOptionDto>>>;
121
+ /**
122
+ * Returns the banks or branches matching what the seller typed in a LOOKUP field, e.g. an IFSC code or a Japanese branch. **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
123
+ * Search banks or branches
124
+ */
125
+ searchBankAccountInstitutions(requestParameters: BankAccountsApiSearchBankAccountInstitutionsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<BankAccountFormatFieldOptionDto>>;
87
126
  }
@@ -205,6 +205,72 @@ var BankAccountsApi = /** @class */ (function (_super) {
205
205
  });
206
206
  });
207
207
  };
208
+ /**
209
+ * Returns the fields a bank account in this country and currency needs, to render the form from and submit in `details.fields`. **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
210
+ * Get the bank details to ask for
211
+ */
212
+ BankAccountsApi.prototype.getBankAccountFormatRaw = function (requestParameters, initOverrides) {
213
+ return __awaiter(this, void 0, void 0, function () {
214
+ var queryParameters, headerParameters, _a, _b, token, tokenString, response;
215
+ return __generator(this, function (_c) {
216
+ switch (_c.label) {
217
+ case 0:
218
+ if (requestParameters['countryCode'] == null) {
219
+ throw new runtime.RequiredError('countryCode', 'Required parameter "countryCode" was null or undefined when calling getBankAccountFormat().');
220
+ }
221
+ if (requestParameters['currencyCode'] == null) {
222
+ throw new runtime.RequiredError('currencyCode', 'Required parameter "currencyCode" was null or undefined when calling getBankAccountFormat().');
223
+ }
224
+ queryParameters = {};
225
+ headerParameters = {};
226
+ if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 2];
227
+ _a = headerParameters;
228
+ _b = "apikey";
229
+ return [4 /*yield*/, this.configuration.apiKey("apikey")];
230
+ case 1:
231
+ _a[_b] = _c.sent(); // api_key authentication
232
+ _c.label = 2;
233
+ case 2:
234
+ if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 4];
235
+ token = this.configuration.accessToken;
236
+ return [4 /*yield*/, token("bearer", [])];
237
+ case 3:
238
+ tokenString = _c.sent();
239
+ if (tokenString) {
240
+ headerParameters["Authorization"] = "Bearer ".concat(tokenString);
241
+ }
242
+ _c.label = 4;
243
+ case 4: return [4 /*yield*/, this.request({
244
+ path: "/private/bank-account-formats/{countryCode}/{currencyCode}".replace("{".concat("countryCode", "}"), encodeURIComponent(String(requestParameters['countryCode']))).replace("{".concat("currencyCode", "}"), encodeURIComponent(String(requestParameters['currencyCode']))),
245
+ method: 'GET',
246
+ headers: headerParameters,
247
+ query: queryParameters,
248
+ }, initOverrides)];
249
+ case 5:
250
+ response = _c.sent();
251
+ return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.BankAccountFormatDtoFromJSON)(jsonValue); })];
252
+ }
253
+ });
254
+ });
255
+ };
256
+ /**
257
+ * Returns the fields a bank account in this country and currency needs, to render the form from and submit in `details.fields`. **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
258
+ * Get the bank details to ask for
259
+ */
260
+ BankAccountsApi.prototype.getBankAccountFormat = function (requestParameters, initOverrides) {
261
+ return __awaiter(this, void 0, void 0, function () {
262
+ var response;
263
+ return __generator(this, function (_a) {
264
+ switch (_a.label) {
265
+ case 0: return [4 /*yield*/, this.getBankAccountFormatRaw(requestParameters, initOverrides)];
266
+ case 1:
267
+ response = _a.sent();
268
+ return [4 /*yield*/, response.value()];
269
+ case 2: return [2 /*return*/, _a.sent()];
270
+ }
271
+ });
272
+ });
273
+ };
208
274
  /**
209
275
  * Returns bank account details to use for microdeposit verification. **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
210
276
  * Get microdeposit bank account details
@@ -271,6 +337,66 @@ var BankAccountsApi = /** @class */ (function (_super) {
271
337
  });
272
338
  });
273
339
  };
340
+ /**
341
+ * Returns the bank countries and currencies we pay out to, for the current seller\'s entity type (business or personal). **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
342
+ * List bank account countries and currencies
343
+ */
344
+ BankAccountsApi.prototype.listBankAccountFormatsRaw = function (initOverrides) {
345
+ return __awaiter(this, void 0, void 0, function () {
346
+ var queryParameters, headerParameters, _a, _b, token, tokenString, response;
347
+ return __generator(this, function (_c) {
348
+ switch (_c.label) {
349
+ case 0:
350
+ queryParameters = {};
351
+ headerParameters = {};
352
+ if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 2];
353
+ _a = headerParameters;
354
+ _b = "apikey";
355
+ return [4 /*yield*/, this.configuration.apiKey("apikey")];
356
+ case 1:
357
+ _a[_b] = _c.sent(); // api_key authentication
358
+ _c.label = 2;
359
+ case 2:
360
+ if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 4];
361
+ token = this.configuration.accessToken;
362
+ return [4 /*yield*/, token("bearer", [])];
363
+ case 3:
364
+ tokenString = _c.sent();
365
+ if (tokenString) {
366
+ headerParameters["Authorization"] = "Bearer ".concat(tokenString);
367
+ }
368
+ _c.label = 4;
369
+ case 4: return [4 /*yield*/, this.request({
370
+ path: "/private/bank-account-formats",
371
+ method: 'GET',
372
+ headers: headerParameters,
373
+ query: queryParameters,
374
+ }, initOverrides)];
375
+ case 5:
376
+ response = _c.sent();
377
+ return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.BankAccountFormatsDtoFromJSON)(jsonValue); })];
378
+ }
379
+ });
380
+ });
381
+ };
382
+ /**
383
+ * Returns the bank countries and currencies we pay out to, for the current seller\'s entity type (business or personal). **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
384
+ * List bank account countries and currencies
385
+ */
386
+ BankAccountsApi.prototype.listBankAccountFormats = function (initOverrides) {
387
+ return __awaiter(this, void 0, void 0, function () {
388
+ var response;
389
+ return __generator(this, function (_a) {
390
+ switch (_a.label) {
391
+ case 0: return [4 /*yield*/, this.listBankAccountFormatsRaw(initOverrides)];
392
+ case 1:
393
+ response = _a.sent();
394
+ return [4 /*yield*/, response.value()];
395
+ case 2: return [2 /*return*/, _a.sent()];
396
+ }
397
+ });
398
+ });
399
+ };
274
400
  /**
275
401
  * Returns all bank accounts configured for the current seller account. **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
276
402
  * List bank accounts
@@ -398,6 +524,77 @@ var BankAccountsApi = /** @class */ (function (_super) {
398
524
  });
399
525
  });
400
526
  };
527
+ /**
528
+ * Returns the banks or branches matching what the seller typed in a LOOKUP field, e.g. an IFSC code or a Japanese branch. **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
529
+ * Search banks or branches
530
+ */
531
+ BankAccountsApi.prototype.searchBankAccountInstitutionsRaw = function (requestParameters, initOverrides) {
532
+ return __awaiter(this, void 0, void 0, function () {
533
+ var queryParameters, headerParameters, _a, _b, token, tokenString, response;
534
+ return __generator(this, function (_c) {
535
+ switch (_c.label) {
536
+ case 0:
537
+ if (requestParameters['countryCode'] == null) {
538
+ throw new runtime.RequiredError('countryCode', 'Required parameter "countryCode" was null or undefined when calling searchBankAccountInstitutions().');
539
+ }
540
+ if (requestParameters['currencyCode'] == null) {
541
+ throw new runtime.RequiredError('currencyCode', 'Required parameter "currencyCode" was null or undefined when calling searchBankAccountInstitutions().');
542
+ }
543
+ if (requestParameters['searchBankAccountInstitutionsInput'] == null) {
544
+ throw new runtime.RequiredError('searchBankAccountInstitutionsInput', 'Required parameter "searchBankAccountInstitutionsInput" was null or undefined when calling searchBankAccountInstitutions().');
545
+ }
546
+ queryParameters = {};
547
+ headerParameters = {};
548
+ headerParameters['Content-Type'] = 'application/json';
549
+ if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 2];
550
+ _a = headerParameters;
551
+ _b = "apikey";
552
+ return [4 /*yield*/, this.configuration.apiKey("apikey")];
553
+ case 1:
554
+ _a[_b] = _c.sent(); // api_key authentication
555
+ _c.label = 2;
556
+ case 2:
557
+ if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 4];
558
+ token = this.configuration.accessToken;
559
+ return [4 /*yield*/, token("bearer", [])];
560
+ case 3:
561
+ tokenString = _c.sent();
562
+ if (tokenString) {
563
+ headerParameters["Authorization"] = "Bearer ".concat(tokenString);
564
+ }
565
+ _c.label = 4;
566
+ case 4: return [4 /*yield*/, this.request({
567
+ path: "/private/bank-account-formats/{countryCode}/{currencyCode}/institutions".replace("{".concat("countryCode", "}"), encodeURIComponent(String(requestParameters['countryCode']))).replace("{".concat("currencyCode", "}"), encodeURIComponent(String(requestParameters['currencyCode']))),
568
+ method: 'POST',
569
+ headers: headerParameters,
570
+ query: queryParameters,
571
+ body: (0, index_1.SearchBankAccountInstitutionsInputToJSON)(requestParameters['searchBankAccountInstitutionsInput']),
572
+ }, initOverrides)];
573
+ case 5:
574
+ response = _c.sent();
575
+ return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return jsonValue.map(index_1.BankAccountFormatFieldOptionDtoFromJSON); })];
576
+ }
577
+ });
578
+ });
579
+ };
580
+ /**
581
+ * Returns the banks or branches matching what the seller typed in a LOOKUP field, e.g. an IFSC code or a Japanese branch. **API key scope required:** `PAYOUTS_READ`. Requests authenticated with a seller session do not need any scope.
582
+ * Search banks or branches
583
+ */
584
+ BankAccountsApi.prototype.searchBankAccountInstitutions = function (requestParameters, initOverrides) {
585
+ return __awaiter(this, void 0, void 0, function () {
586
+ var response;
587
+ return __generator(this, function (_a) {
588
+ switch (_a.label) {
589
+ case 0: return [4 /*yield*/, this.searchBankAccountInstitutionsRaw(requestParameters, initOverrides)];
590
+ case 1:
591
+ response = _a.sent();
592
+ return [4 /*yield*/, response.value()];
593
+ case 2: return [2 /*return*/, _a.sent()];
594
+ }
595
+ });
596
+ });
597
+ };
401
598
  return BankAccountsApi;
402
599
  }(runtime.BaseAPI));
403
600
  exports.BankAccountsApi = BankAccountsApi;
@@ -0,0 +1,40 @@
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 AccountBankAccountDetailsDto
16
+ */
17
+ export interface AccountBankAccountDetailsDto {
18
+ /**
19
+ * ISO country code of the country the account is held in.
20
+ * @type {string}
21
+ * @memberof AccountBankAccountDetailsDto
22
+ */
23
+ countryCode: string;
24
+ /**
25
+ * The bank details by the key the bank account format lists after `bank_details.`, with routing types next to their values, e.g. `account_routing_type1: sort_code`.
26
+ * @type {{ [key: string]: string; }}
27
+ * @memberof AccountBankAccountDetailsDto
28
+ */
29
+ bankDetails: {
30
+ [key: string]: string;
31
+ };
32
+ }
33
+ /**
34
+ * Check if a given object implements the AccountBankAccountDetailsDto interface.
35
+ */
36
+ export declare function instanceOfAccountBankAccountDetailsDto(value: object): value is AccountBankAccountDetailsDto;
37
+ export declare function AccountBankAccountDetailsDtoFromJSON(json: any): AccountBankAccountDetailsDto;
38
+ export declare function AccountBankAccountDetailsDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): AccountBankAccountDetailsDto;
39
+ export declare function AccountBankAccountDetailsDtoToJSON(json: any): AccountBankAccountDetailsDto;
40
+ export declare function AccountBankAccountDetailsDtoToJSONTyped(value?: AccountBankAccountDetailsDto | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,55 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Nameshift
6
+ * Nameshift domain marketplace and management API. ## Authentication - **Bearer JWT** — Seller and buyer sessions obtained via login endpoints. - **API key** — Pass the `apikey` header for programmatic seller access. ## Audiences - **(public)** tags — Unauthenticated or buyer-facing endpoints. - **Accounts / Domains / Leads / Buyers** — Seller or buyer resources. - **Partner** — Partner integrations.
7
+ *
8
+ * The version of the OpenAPI document: 1.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.instanceOfAccountBankAccountDetailsDto = instanceOfAccountBankAccountDetailsDto;
17
+ exports.AccountBankAccountDetailsDtoFromJSON = AccountBankAccountDetailsDtoFromJSON;
18
+ exports.AccountBankAccountDetailsDtoFromJSONTyped = AccountBankAccountDetailsDtoFromJSONTyped;
19
+ exports.AccountBankAccountDetailsDtoToJSON = AccountBankAccountDetailsDtoToJSON;
20
+ exports.AccountBankAccountDetailsDtoToJSONTyped = AccountBankAccountDetailsDtoToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the AccountBankAccountDetailsDto interface.
23
+ */
24
+ function instanceOfAccountBankAccountDetailsDto(value) {
25
+ if (!('countryCode' in value) || value['countryCode'] === undefined)
26
+ return false;
27
+ if (!('bankDetails' in value) || value['bankDetails'] === undefined)
28
+ return false;
29
+ return true;
30
+ }
31
+ function AccountBankAccountDetailsDtoFromJSON(json) {
32
+ return AccountBankAccountDetailsDtoFromJSONTyped(json, false);
33
+ }
34
+ function AccountBankAccountDetailsDtoFromJSONTyped(json, ignoreDiscriminator) {
35
+ if (json == null) {
36
+ return json;
37
+ }
38
+ return {
39
+ 'countryCode': json['countryCode'],
40
+ 'bankDetails': json['bankDetails'],
41
+ };
42
+ }
43
+ function AccountBankAccountDetailsDtoToJSON(json) {
44
+ return AccountBankAccountDetailsDtoToJSONTyped(json, false);
45
+ }
46
+ function AccountBankAccountDetailsDtoToJSONTyped(value, ignoreDiscriminator) {
47
+ if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
48
+ if (value == null) {
49
+ return value;
50
+ }
51
+ return {
52
+ 'countryCode': value['countryCode'],
53
+ 'bankDetails': value['bankDetails'],
54
+ };
55
+ }
@@ -9,7 +9,7 @@
9
9
  * https://openapi-generator.tech
10
10
  * Do not edit the class manually.
11
11
  */
12
- import type { AccountBankAccountDtoDetails } from './AccountBankAccountDtoDetails';
12
+ import type { AccountBankAccountDetailsDto } from './AccountBankAccountDetailsDto';
13
13
  /**
14
14
  *
15
15
  * @export
@@ -47,11 +47,17 @@ export interface AccountBankAccountDto {
47
47
  */
48
48
  nameCheckStatus: AccountBankAccountDtoNameCheckStatusEnum | null;
49
49
  /**
50
- *
51
- * @type {AccountBankAccountDtoDetails}
50
+ * The bank details. Extra details such as tax IDs are never returned.
51
+ * @type {AccountBankAccountDetailsDto}
52
52
  * @memberof AccountBankAccountDto
53
53
  */
54
- details: AccountBankAccountDtoDetails;
54
+ details: AccountBankAccountDetailsDto;
55
+ /**
56
+ * Whether we can pay out to this bank account: false when we don't pay out to its country and currency, or its details are incomplete.
57
+ * @type {boolean}
58
+ * @memberof AccountBankAccountDto
59
+ */
60
+ payable: boolean;
55
61
  }
56
62
  /**
57
63
  * @export
@@ -19,7 +19,7 @@ exports.AccountBankAccountDtoFromJSON = AccountBankAccountDtoFromJSON;
19
19
  exports.AccountBankAccountDtoFromJSONTyped = AccountBankAccountDtoFromJSONTyped;
20
20
  exports.AccountBankAccountDtoToJSON = AccountBankAccountDtoToJSON;
21
21
  exports.AccountBankAccountDtoToJSONTyped = AccountBankAccountDtoToJSONTyped;
22
- var AccountBankAccountDtoDetails_1 = require("./AccountBankAccountDtoDetails");
22
+ var AccountBankAccountDetailsDto_1 = require("./AccountBankAccountDetailsDto");
23
23
  /**
24
24
  * @export
25
25
  */
@@ -54,6 +54,8 @@ function instanceOfAccountBankAccountDto(value) {
54
54
  return false;
55
55
  if (!('details' in value) || value['details'] === undefined)
56
56
  return false;
57
+ if (!('payable' in value) || value['payable'] === undefined)
58
+ return false;
57
59
  return true;
58
60
  }
59
61
  function AccountBankAccountDtoFromJSON(json) {
@@ -69,7 +71,8 @@ function AccountBankAccountDtoFromJSONTyped(json, ignoreDiscriminator) {
69
71
  'currencyCode': json['currencyCode'],
70
72
  'verificationStatus': json['verificationStatus'],
71
73
  'nameCheckStatus': json['nameCheckStatus'],
72
- 'details': (0, AccountBankAccountDtoDetails_1.AccountBankAccountDtoDetailsFromJSON)(json['details']),
74
+ 'details': (0, AccountBankAccountDetailsDto_1.AccountBankAccountDetailsDtoFromJSON)(json['details']),
75
+ 'payable': json['payable'],
73
76
  };
74
77
  }
75
78
  function AccountBankAccountDtoToJSON(json) {
@@ -86,6 +89,7 @@ function AccountBankAccountDtoToJSONTyped(value, ignoreDiscriminator) {
86
89
  'currencyCode': value['currencyCode'],
87
90
  'verificationStatus': value['verificationStatus'],
88
91
  'nameCheckStatus': value['nameCheckStatus'],
89
- 'details': (0, AccountBankAccountDtoDetails_1.AccountBankAccountDtoDetailsToJSON)(value['details']),
92
+ 'details': (0, AccountBankAccountDetailsDto_1.AccountBankAccountDetailsDtoToJSON)(value['details']),
93
+ 'payable': value['payable'],
90
94
  };
91
95
  }
@@ -0,0 +1,38 @@
1
+ /**
2
+ * Nameshift
3
+ * Nameshift domain marketplace and management API. ## Authentication - **Bearer JWT** — Seller and buyer sessions obtained via login endpoints. - **API key** — Pass the `apikey` header for programmatic seller access. ## Audiences - **(public)** tags — Unauthenticated or buyer-facing endpoints. - **Accounts / Domains / Leads / Buyers** — Seller or buyer resources. - **Partner** — Partner integrations.
4
+ *
5
+ * The version of the OpenAPI document: 1.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface BankAccountFormatCountryDto
16
+ */
17
+ export interface BankAccountFormatCountryDto {
18
+ /**
19
+ * ISO 3166-1 alpha-2 code of the bank country.
20
+ * @type {string}
21
+ * @memberof BankAccountFormatCountryDto
22
+ */
23
+ countryCode: string;
24
+ /**
25
+ * ISO 4217 codes of the currencies we pay out to in this country, the country's own currency first.
26
+ * @type {Array<string>}
27
+ * @memberof BankAccountFormatCountryDto
28
+ */
29
+ currencyCodes: Array<string>;
30
+ }
31
+ /**
32
+ * Check if a given object implements the BankAccountFormatCountryDto interface.
33
+ */
34
+ export declare function instanceOfBankAccountFormatCountryDto(value: object): value is BankAccountFormatCountryDto;
35
+ export declare function BankAccountFormatCountryDtoFromJSON(json: any): BankAccountFormatCountryDto;
36
+ export declare function BankAccountFormatCountryDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): BankAccountFormatCountryDto;
37
+ export declare function BankAccountFormatCountryDtoToJSON(json: any): BankAccountFormatCountryDto;
38
+ export declare function BankAccountFormatCountryDtoToJSONTyped(value?: BankAccountFormatCountryDto | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,55 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Nameshift
6
+ * Nameshift domain marketplace and management API. ## Authentication - **Bearer JWT** — Seller and buyer sessions obtained via login endpoints. - **API key** — Pass the `apikey` header for programmatic seller access. ## Audiences - **(public)** tags — Unauthenticated or buyer-facing endpoints. - **Accounts / Domains / Leads / Buyers** — Seller or buyer resources. - **Partner** — Partner integrations.
7
+ *
8
+ * The version of the OpenAPI document: 1.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.instanceOfBankAccountFormatCountryDto = instanceOfBankAccountFormatCountryDto;
17
+ exports.BankAccountFormatCountryDtoFromJSON = BankAccountFormatCountryDtoFromJSON;
18
+ exports.BankAccountFormatCountryDtoFromJSONTyped = BankAccountFormatCountryDtoFromJSONTyped;
19
+ exports.BankAccountFormatCountryDtoToJSON = BankAccountFormatCountryDtoToJSON;
20
+ exports.BankAccountFormatCountryDtoToJSONTyped = BankAccountFormatCountryDtoToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the BankAccountFormatCountryDto interface.
23
+ */
24
+ function instanceOfBankAccountFormatCountryDto(value) {
25
+ if (!('countryCode' in value) || value['countryCode'] === undefined)
26
+ return false;
27
+ if (!('currencyCodes' in value) || value['currencyCodes'] === undefined)
28
+ return false;
29
+ return true;
30
+ }
31
+ function BankAccountFormatCountryDtoFromJSON(json) {
32
+ return BankAccountFormatCountryDtoFromJSONTyped(json, false);
33
+ }
34
+ function BankAccountFormatCountryDtoFromJSONTyped(json, ignoreDiscriminator) {
35
+ if (json == null) {
36
+ return json;
37
+ }
38
+ return {
39
+ 'countryCode': json['countryCode'],
40
+ 'currencyCodes': json['currencyCodes'],
41
+ };
42
+ }
43
+ function BankAccountFormatCountryDtoToJSON(json) {
44
+ return BankAccountFormatCountryDtoToJSONTyped(json, false);
45
+ }
46
+ function BankAccountFormatCountryDtoToJSONTyped(value, ignoreDiscriminator) {
47
+ if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
48
+ if (value == null) {
49
+ return value;
50
+ }
51
+ return {
52
+ 'countryCode': value['countryCode'],
53
+ 'currencyCodes': value['currencyCodes'],
54
+ };
55
+ }