@randock/nameshift-api-client 0.0.210 → 0.0.211
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.
- package/.openapi-generator/FILES +7 -2
- package/README.md +3 -3
- package/dist/apis/AccountsApi.d.ts +3 -3
- package/dist/apis/AccountsApi.js +1 -1
- package/dist/apis/AdminApi.d.ts +12 -1
- package/dist/apis/AdminApi.js +53 -0
- package/dist/apis/BankAccountsApi.d.ts +78 -0
- package/dist/apis/BankAccountsApi.js +356 -0
- package/dist/apis/index.d.ts +1 -0
- package/dist/apis/index.js +1 -0
- package/dist/models/AccountBankAccountDto.d.ts +68 -0
- package/dist/models/AccountBankAccountDto.js +75 -0
- package/dist/models/AccountDto.d.ts +10 -3
- package/dist/models/AccountDto.js +9 -4
- package/dist/models/AccountOnboardingDto.d.ts +65 -0
- package/dist/models/AccountOnboardingDto.js +77 -0
- package/dist/models/AccountOnboardingSessionDto.d.ts +32 -0
- package/dist/models/AccountOnboardingSessionDto.js +51 -0
- package/dist/models/AccountPayoutDto.d.ts +46 -0
- package/dist/models/AccountPayoutDto.js +63 -0
- package/dist/models/AccountSettingsDto.d.ts +0 -6
- package/dist/models/AccountSettingsDto.js +0 -4
- package/dist/models/CreateBankAccountInput.d.ts +56 -0
- package/dist/models/CreateBankAccountInput.js +63 -0
- package/dist/models/IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto.d.ts +11 -3
- package/dist/models/IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto.js +11 -5
- package/dist/models/UpdateBankAccountInput.d.ts +56 -0
- package/dist/models/UpdateBankAccountInput.js +63 -0
- package/dist/models/index.d.ts +6 -2
- package/dist/models/index.js +6 -2
- package/package.json +1 -1
- package/src/apis/AccountsApi.ts +6 -6
- package/src/apis/AdminApi.ts +48 -0
- package/src/apis/BankAccountsApi.ts +309 -0
- package/src/apis/index.ts +1 -0
- package/src/models/AccountBankAccountDto.ts +120 -0
- package/src/models/AccountDto.ts +27 -11
- package/src/models/AccountOnboardingDto.ts +112 -0
- package/src/models/AccountOnboardingSessionDto.ts +66 -0
- package/src/models/AccountPayoutDto.ts +86 -0
- package/src/models/AccountSettingsDto.ts +0 -9
- package/src/models/CreateBankAccountInput.ts +100 -0
- package/src/models/IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto.ts +29 -12
- package/src/models/UpdateBankAccountInput.ts +100 -0
- package/src/models/index.ts +6 -2
- package/dist/models/AccountPaymentProviderSessionDto.d.ts +0 -32
- package/dist/models/AccountPaymentProviderSessionDto.js +0 -51
- package/dist/models/PaymentProviderDto.d.ts +0 -52
- package/dist/models/PaymentProviderDto.js +0 -67
- package/src/models/AccountPaymentProviderSessionDto.ts +0 -66
- package/src/models/PaymentProviderDto.ts +0 -95
package/.openapi-generator/FILES
CHANGED
|
@@ -6,6 +6,7 @@ package.json
|
|
|
6
6
|
src/apis/AccountsApi.ts
|
|
7
7
|
src/apis/AccountsPublicApi.ts
|
|
8
8
|
src/apis/AdminApi.ts
|
|
9
|
+
src/apis/BankAccountsApi.ts
|
|
9
10
|
src/apis/BuyersApi.ts
|
|
10
11
|
src/apis/BuyersPublicApi.ts
|
|
11
12
|
src/apis/DefaultApi.ts
|
|
@@ -23,11 +24,14 @@ src/apis/UsersApi.ts
|
|
|
23
24
|
src/apis/UsersPublicApi.ts
|
|
24
25
|
src/apis/index.ts
|
|
25
26
|
src/index.ts
|
|
27
|
+
src/models/AccountBankAccountDto.ts
|
|
26
28
|
src/models/AccountDto.ts
|
|
27
29
|
src/models/AccountMetricsDto.ts
|
|
28
30
|
src/models/AccountNotificationDto.ts
|
|
29
31
|
src/models/AccountNotificationReadStatusDto.ts
|
|
30
|
-
src/models/
|
|
32
|
+
src/models/AccountOnboardingDto.ts
|
|
33
|
+
src/models/AccountOnboardingSessionDto.ts
|
|
34
|
+
src/models/AccountPayoutDto.ts
|
|
31
35
|
src/models/AccountSettingsDto.ts
|
|
32
36
|
src/models/AccountSettingsInput.ts
|
|
33
37
|
src/models/AccountSettingsLeaseToOwnConfigurationDto.ts
|
|
@@ -61,6 +65,7 @@ src/models/CompanyInformationDto.ts
|
|
|
61
65
|
src/models/CompanyTaxIdDto.ts
|
|
62
66
|
src/models/ConcreteDomainTransferTaskData.ts
|
|
63
67
|
src/models/ConflictException.ts
|
|
68
|
+
src/models/CreateBankAccountInput.ts
|
|
64
69
|
src/models/CreateBuyerLeadMessageInput.ts
|
|
65
70
|
src/models/CreateLeadInput.ts
|
|
66
71
|
src/models/CreateLeadMessageInput.ts
|
|
@@ -160,7 +165,6 @@ src/models/PaginateResponse.ts
|
|
|
160
165
|
src/models/PaginateResponseLinks.ts
|
|
161
166
|
src/models/PaginateResponseMeta.ts
|
|
162
167
|
src/models/ParsedDomainDto.ts
|
|
163
|
-
src/models/PaymentProviderDto.ts
|
|
164
168
|
src/models/PublicDomainDto.ts
|
|
165
169
|
src/models/PublicDomainDtoSeo.ts
|
|
166
170
|
src/models/PublicDomainDtoSeoMoz.ts
|
|
@@ -204,6 +208,7 @@ src/models/TaskListDomainTransferDto.ts
|
|
|
204
208
|
src/models/TaskListLeadDto.ts
|
|
205
209
|
src/models/ThrottlerException.ts
|
|
206
210
|
src/models/UpdateAccountBillingInformationInput.ts
|
|
211
|
+
src/models/UpdateBankAccountInput.ts
|
|
207
212
|
src/models/UpdateDomainInput.ts
|
|
208
213
|
src/models/UpdateDomainTransferAuthCodeInput.ts
|
|
209
214
|
src/models/UpdateLeadInput.ts
|
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
## @randock/nameshift-api-client@0.0.
|
|
1
|
+
## @randock/nameshift-api-client@0.0.211
|
|
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.
|
|
39
|
+
npm install @randock/nameshift-api-client@0.0.211 --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
|
-
|
|
47
|
+
9d7d771b5fbac612e4b509358213c72b602b34e715991e64c9efff091efbb48d7d8bc3639437e1d78a83f0fac98f6891
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type {
|
|
13
|
+
import type { AccountOnboardingSessionDto, AccountSettingsDto, AccountSettingsInput, IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto, UpdateAccountBillingInformationInput } from '../models/index';
|
|
14
14
|
export interface AccountsApiGetAccountPaymentProviderSessionRequest {
|
|
15
15
|
accountId: string;
|
|
16
16
|
}
|
|
@@ -37,11 +37,11 @@ export declare class AccountsApi extends runtime.BaseAPI {
|
|
|
37
37
|
/**
|
|
38
38
|
*
|
|
39
39
|
*/
|
|
40
|
-
getAccountPaymentProviderSessionRaw(requestParameters: AccountsApiGetAccountPaymentProviderSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<
|
|
40
|
+
getAccountPaymentProviderSessionRaw(requestParameters: AccountsApiGetAccountPaymentProviderSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AccountOnboardingSessionDto>>;
|
|
41
41
|
/**
|
|
42
42
|
*
|
|
43
43
|
*/
|
|
44
|
-
getAccountPaymentProviderSession(requestParameters: AccountsApiGetAccountPaymentProviderSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<
|
|
44
|
+
getAccountPaymentProviderSession(requestParameters: AccountsApiGetAccountPaymentProviderSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AccountOnboardingSessionDto>;
|
|
45
45
|
/**
|
|
46
46
|
*
|
|
47
47
|
*/
|
package/dist/apis/AccountsApi.js
CHANGED
|
@@ -106,7 +106,7 @@ var AccountsApi = /** @class */ (function (_super) {
|
|
|
106
106
|
}, initOverrides)];
|
|
107
107
|
case 3:
|
|
108
108
|
response = _a.sent();
|
|
109
|
-
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.
|
|
109
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.AccountOnboardingSessionDtoFromJSON)(jsonValue); })];
|
|
110
110
|
}
|
|
111
111
|
});
|
|
112
112
|
});
|
package/dist/apis/AdminApi.d.ts
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type { AccountSettingsDto, AdminAccountLoginDto, AdminAccountSettingsInput, AdminGetAllDomainTransfers200Response, ChangeOrderStatusInput, ChangeSubscriptionStatusInput, DomainTransferDetailsDto, GetAllInvoices200Response, GetAllOrders200Response, GetAllOwnedDomains200Response, GetAllSubscriptions200Response, ListAccounts200Response, ListDomains200Response, SubscriptionDetailsDto } from '../models/index';
|
|
13
|
+
import type { AccountSettingsDto, AdminAccountLoginDto, AdminAccountSettingsInput, AdminGetAllDomainTransfers200Response, ChangeOrderStatusInput, ChangeSubscriptionStatusInput, DomainTransferDetailsDto, GetAllInvoices200Response, GetAllOrders200Response, GetAllOwnedDomains200Response, GetAllSubscriptions200Response, IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto, ListAccounts200Response, ListDomains200Response, SubscriptionDetailsDto } from '../models/index';
|
|
14
14
|
export interface AdminApiAdminGetAllDomainTransfersRequest {
|
|
15
15
|
filter?: object;
|
|
16
16
|
page?: number;
|
|
@@ -28,6 +28,9 @@ export interface AdminApiChangeSubscriptionStatusRequest {
|
|
|
28
28
|
export interface AdminApiDownloadInvoiceRequest {
|
|
29
29
|
invoiceId: string;
|
|
30
30
|
}
|
|
31
|
+
export interface AdminApiGetAccountMeRequest {
|
|
32
|
+
accountId: string;
|
|
33
|
+
}
|
|
31
34
|
export interface AdminApiGetAccountSettingsRequest {
|
|
32
35
|
accountId: string;
|
|
33
36
|
}
|
|
@@ -131,6 +134,14 @@ export declare class AdminApi extends runtime.BaseAPI {
|
|
|
131
134
|
*
|
|
132
135
|
*/
|
|
133
136
|
downloadInvoice(requestParameters: AdminApiDownloadInvoiceRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Blob>;
|
|
137
|
+
/**
|
|
138
|
+
*
|
|
139
|
+
*/
|
|
140
|
+
getAccountMeRaw(requestParameters: AdminApiGetAccountMeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto>>;
|
|
141
|
+
/**
|
|
142
|
+
*
|
|
143
|
+
*/
|
|
144
|
+
getAccountMe(requestParameters: AdminApiGetAccountMeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto>;
|
|
134
145
|
/**
|
|
135
146
|
*
|
|
136
147
|
*/
|
package/dist/apis/AdminApi.js
CHANGED
|
@@ -303,6 +303,59 @@ var AdminApi = /** @class */ (function (_super) {
|
|
|
303
303
|
});
|
|
304
304
|
});
|
|
305
305
|
};
|
|
306
|
+
/**
|
|
307
|
+
*
|
|
308
|
+
*/
|
|
309
|
+
AdminApi.prototype.getAccountMeRaw = function (requestParameters, initOverrides) {
|
|
310
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
311
|
+
var queryParameters, headerParameters, token, tokenString, response;
|
|
312
|
+
return __generator(this, function (_a) {
|
|
313
|
+
switch (_a.label) {
|
|
314
|
+
case 0:
|
|
315
|
+
if (requestParameters['accountId'] == null) {
|
|
316
|
+
throw new runtime.RequiredError('accountId', 'Required parameter "accountId" was null or undefined when calling getAccountMe().');
|
|
317
|
+
}
|
|
318
|
+
queryParameters = {};
|
|
319
|
+
headerParameters = {};
|
|
320
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
321
|
+
token = this.configuration.accessToken;
|
|
322
|
+
return [4 /*yield*/, token("bearer", [])];
|
|
323
|
+
case 1:
|
|
324
|
+
tokenString = _a.sent();
|
|
325
|
+
if (tokenString) {
|
|
326
|
+
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
327
|
+
}
|
|
328
|
+
_a.label = 2;
|
|
329
|
+
case 2: return [4 /*yield*/, this.request({
|
|
330
|
+
path: "/admin/accounts/{accountId}/me".replace("{".concat("accountId", "}"), encodeURIComponent(String(requestParameters['accountId']))),
|
|
331
|
+
method: 'GET',
|
|
332
|
+
headers: headerParameters,
|
|
333
|
+
query: queryParameters,
|
|
334
|
+
}, initOverrides)];
|
|
335
|
+
case 3:
|
|
336
|
+
response = _a.sent();
|
|
337
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDtoFromJSON)(jsonValue); })];
|
|
338
|
+
}
|
|
339
|
+
});
|
|
340
|
+
});
|
|
341
|
+
};
|
|
342
|
+
/**
|
|
343
|
+
*
|
|
344
|
+
*/
|
|
345
|
+
AdminApi.prototype.getAccountMe = function (requestParameters, initOverrides) {
|
|
346
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
347
|
+
var response;
|
|
348
|
+
return __generator(this, function (_a) {
|
|
349
|
+
switch (_a.label) {
|
|
350
|
+
case 0: return [4 /*yield*/, this.getAccountMeRaw(requestParameters, initOverrides)];
|
|
351
|
+
case 1:
|
|
352
|
+
response = _a.sent();
|
|
353
|
+
return [4 /*yield*/, response.value()];
|
|
354
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
355
|
+
}
|
|
356
|
+
});
|
|
357
|
+
});
|
|
358
|
+
};
|
|
306
359
|
/**
|
|
307
360
|
*
|
|
308
361
|
*/
|
|
@@ -0,0 +1,78 @@
|
|
|
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 * as runtime from '../runtime';
|
|
13
|
+
import type { AccountBankAccountDto, CreateBankAccountInput, UpdateBankAccountInput } from '../models/index';
|
|
14
|
+
export interface BankAccountsApiCreateBankAccountRequest {
|
|
15
|
+
accountId: string;
|
|
16
|
+
createBankAccountInput: CreateBankAccountInput;
|
|
17
|
+
}
|
|
18
|
+
export interface BankAccountsApiDeleteBankAccountRequest {
|
|
19
|
+
accountId: string;
|
|
20
|
+
bankAccountId: string;
|
|
21
|
+
}
|
|
22
|
+
export interface BankAccountsApiListBankAccountsRequest {
|
|
23
|
+
accountId: string;
|
|
24
|
+
}
|
|
25
|
+
export interface BankAccountsApiMakeBankAccountPrimaryRequest {
|
|
26
|
+
accountId: string;
|
|
27
|
+
bankAccountId: string;
|
|
28
|
+
}
|
|
29
|
+
export interface BankAccountsApiUpdateBankAccountRequest {
|
|
30
|
+
accountId: string;
|
|
31
|
+
bankAccountId: string;
|
|
32
|
+
updateBankAccountInput: UpdateBankAccountInput;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
*/
|
|
37
|
+
export declare class BankAccountsApi extends runtime.BaseAPI {
|
|
38
|
+
/**
|
|
39
|
+
*
|
|
40
|
+
*/
|
|
41
|
+
createBankAccountRaw(requestParameters: BankAccountsApiCreateBankAccountRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
42
|
+
/**
|
|
43
|
+
*
|
|
44
|
+
*/
|
|
45
|
+
createBankAccount(requestParameters: BankAccountsApiCreateBankAccountRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
*/
|
|
49
|
+
deleteBankAccountRaw(requestParameters: BankAccountsApiDeleteBankAccountRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
50
|
+
/**
|
|
51
|
+
*
|
|
52
|
+
*/
|
|
53
|
+
deleteBankAccount(requestParameters: BankAccountsApiDeleteBankAccountRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
54
|
+
/**
|
|
55
|
+
*
|
|
56
|
+
*/
|
|
57
|
+
listBankAccountsRaw(requestParameters: BankAccountsApiListBankAccountsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<AccountBankAccountDto>>>;
|
|
58
|
+
/**
|
|
59
|
+
*
|
|
60
|
+
*/
|
|
61
|
+
listBankAccounts(requestParameters: BankAccountsApiListBankAccountsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<AccountBankAccountDto>>;
|
|
62
|
+
/**
|
|
63
|
+
*
|
|
64
|
+
*/
|
|
65
|
+
makeBankAccountPrimaryRaw(requestParameters: BankAccountsApiMakeBankAccountPrimaryRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
66
|
+
/**
|
|
67
|
+
*
|
|
68
|
+
*/
|
|
69
|
+
makeBankAccountPrimary(requestParameters: BankAccountsApiMakeBankAccountPrimaryRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
70
|
+
/**
|
|
71
|
+
*
|
|
72
|
+
*/
|
|
73
|
+
updateBankAccountRaw(requestParameters: BankAccountsApiUpdateBankAccountRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
74
|
+
/**
|
|
75
|
+
*
|
|
76
|
+
*/
|
|
77
|
+
updateBankAccount(requestParameters: BankAccountsApiUpdateBankAccountRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
78
|
+
}
|
|
@@ -0,0 +1,356 @@
|
|
|
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
|
+
var __extends = (this && this.__extends) || (function () {
|
|
16
|
+
var extendStatics = function (d, b) {
|
|
17
|
+
extendStatics = Object.setPrototypeOf ||
|
|
18
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
19
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
20
|
+
return extendStatics(d, b);
|
|
21
|
+
};
|
|
22
|
+
return function (d, b) {
|
|
23
|
+
if (typeof b !== "function" && b !== null)
|
|
24
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
25
|
+
extendStatics(d, b);
|
|
26
|
+
function __() { this.constructor = d; }
|
|
27
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
28
|
+
};
|
|
29
|
+
})();
|
|
30
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
31
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
32
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
33
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
34
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
35
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
36
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
37
|
+
});
|
|
38
|
+
};
|
|
39
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
40
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
|
|
41
|
+
return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
42
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
43
|
+
function step(op) {
|
|
44
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
45
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
46
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
47
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
48
|
+
switch (op[0]) {
|
|
49
|
+
case 0: case 1: t = op; break;
|
|
50
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
51
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
52
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
53
|
+
default:
|
|
54
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
55
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
56
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
57
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
58
|
+
if (t[2]) _.ops.pop();
|
|
59
|
+
_.trys.pop(); continue;
|
|
60
|
+
}
|
|
61
|
+
op = body.call(thisArg, _);
|
|
62
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
63
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
64
|
+
}
|
|
65
|
+
};
|
|
66
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
67
|
+
exports.BankAccountsApi = void 0;
|
|
68
|
+
var runtime = require("../runtime");
|
|
69
|
+
var index_1 = require("../models/index");
|
|
70
|
+
/**
|
|
71
|
+
*
|
|
72
|
+
*/
|
|
73
|
+
var BankAccountsApi = /** @class */ (function (_super) {
|
|
74
|
+
__extends(BankAccountsApi, _super);
|
|
75
|
+
function BankAccountsApi() {
|
|
76
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
*
|
|
80
|
+
*/
|
|
81
|
+
BankAccountsApi.prototype.createBankAccountRaw = function (requestParameters, initOverrides) {
|
|
82
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
83
|
+
var queryParameters, headerParameters, token, tokenString, response;
|
|
84
|
+
return __generator(this, function (_a) {
|
|
85
|
+
switch (_a.label) {
|
|
86
|
+
case 0:
|
|
87
|
+
if (requestParameters['accountId'] == null) {
|
|
88
|
+
throw new runtime.RequiredError('accountId', 'Required parameter "accountId" was null or undefined when calling createBankAccount().');
|
|
89
|
+
}
|
|
90
|
+
if (requestParameters['createBankAccountInput'] == null) {
|
|
91
|
+
throw new runtime.RequiredError('createBankAccountInput', 'Required parameter "createBankAccountInput" was null or undefined when calling createBankAccount().');
|
|
92
|
+
}
|
|
93
|
+
queryParameters = {};
|
|
94
|
+
headerParameters = {};
|
|
95
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
96
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
97
|
+
token = this.configuration.accessToken;
|
|
98
|
+
return [4 /*yield*/, token("bearer", [])];
|
|
99
|
+
case 1:
|
|
100
|
+
tokenString = _a.sent();
|
|
101
|
+
if (tokenString) {
|
|
102
|
+
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
103
|
+
}
|
|
104
|
+
_a.label = 2;
|
|
105
|
+
case 2: return [4 /*yield*/, this.request({
|
|
106
|
+
path: "/private/accounts/{accountId}/bank-accounts".replace("{".concat("accountId", "}"), encodeURIComponent(String(requestParameters['accountId']))),
|
|
107
|
+
method: 'POST',
|
|
108
|
+
headers: headerParameters,
|
|
109
|
+
query: queryParameters,
|
|
110
|
+
body: (0, index_1.CreateBankAccountInputToJSON)(requestParameters['createBankAccountInput']),
|
|
111
|
+
}, initOverrides)];
|
|
112
|
+
case 3:
|
|
113
|
+
response = _a.sent();
|
|
114
|
+
return [2 /*return*/, new runtime.VoidApiResponse(response)];
|
|
115
|
+
}
|
|
116
|
+
});
|
|
117
|
+
});
|
|
118
|
+
};
|
|
119
|
+
/**
|
|
120
|
+
*
|
|
121
|
+
*/
|
|
122
|
+
BankAccountsApi.prototype.createBankAccount = function (requestParameters, initOverrides) {
|
|
123
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
124
|
+
return __generator(this, function (_a) {
|
|
125
|
+
switch (_a.label) {
|
|
126
|
+
case 0: return [4 /*yield*/, this.createBankAccountRaw(requestParameters, initOverrides)];
|
|
127
|
+
case 1:
|
|
128
|
+
_a.sent();
|
|
129
|
+
return [2 /*return*/];
|
|
130
|
+
}
|
|
131
|
+
});
|
|
132
|
+
});
|
|
133
|
+
};
|
|
134
|
+
/**
|
|
135
|
+
*
|
|
136
|
+
*/
|
|
137
|
+
BankAccountsApi.prototype.deleteBankAccountRaw = function (requestParameters, initOverrides) {
|
|
138
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
139
|
+
var queryParameters, headerParameters, token, tokenString, response;
|
|
140
|
+
return __generator(this, function (_a) {
|
|
141
|
+
switch (_a.label) {
|
|
142
|
+
case 0:
|
|
143
|
+
if (requestParameters['accountId'] == null) {
|
|
144
|
+
throw new runtime.RequiredError('accountId', 'Required parameter "accountId" was null or undefined when calling deleteBankAccount().');
|
|
145
|
+
}
|
|
146
|
+
if (requestParameters['bankAccountId'] == null) {
|
|
147
|
+
throw new runtime.RequiredError('bankAccountId', 'Required parameter "bankAccountId" was null or undefined when calling deleteBankAccount().');
|
|
148
|
+
}
|
|
149
|
+
queryParameters = {};
|
|
150
|
+
headerParameters = {};
|
|
151
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
152
|
+
token = this.configuration.accessToken;
|
|
153
|
+
return [4 /*yield*/, token("bearer", [])];
|
|
154
|
+
case 1:
|
|
155
|
+
tokenString = _a.sent();
|
|
156
|
+
if (tokenString) {
|
|
157
|
+
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
158
|
+
}
|
|
159
|
+
_a.label = 2;
|
|
160
|
+
case 2: return [4 /*yield*/, this.request({
|
|
161
|
+
path: "/private/accounts/{accountId}/bank-accounts/{bankAccountId}".replace("{".concat("accountId", "}"), encodeURIComponent(String(requestParameters['accountId']))).replace("{".concat("bankAccountId", "}"), encodeURIComponent(String(requestParameters['bankAccountId']))),
|
|
162
|
+
method: 'DELETE',
|
|
163
|
+
headers: headerParameters,
|
|
164
|
+
query: queryParameters,
|
|
165
|
+
}, initOverrides)];
|
|
166
|
+
case 3:
|
|
167
|
+
response = _a.sent();
|
|
168
|
+
return [2 /*return*/, new runtime.VoidApiResponse(response)];
|
|
169
|
+
}
|
|
170
|
+
});
|
|
171
|
+
});
|
|
172
|
+
};
|
|
173
|
+
/**
|
|
174
|
+
*
|
|
175
|
+
*/
|
|
176
|
+
BankAccountsApi.prototype.deleteBankAccount = function (requestParameters, initOverrides) {
|
|
177
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
178
|
+
return __generator(this, function (_a) {
|
|
179
|
+
switch (_a.label) {
|
|
180
|
+
case 0: return [4 /*yield*/, this.deleteBankAccountRaw(requestParameters, initOverrides)];
|
|
181
|
+
case 1:
|
|
182
|
+
_a.sent();
|
|
183
|
+
return [2 /*return*/];
|
|
184
|
+
}
|
|
185
|
+
});
|
|
186
|
+
});
|
|
187
|
+
};
|
|
188
|
+
/**
|
|
189
|
+
*
|
|
190
|
+
*/
|
|
191
|
+
BankAccountsApi.prototype.listBankAccountsRaw = function (requestParameters, initOverrides) {
|
|
192
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
193
|
+
var queryParameters, headerParameters, token, tokenString, response;
|
|
194
|
+
return __generator(this, function (_a) {
|
|
195
|
+
switch (_a.label) {
|
|
196
|
+
case 0:
|
|
197
|
+
if (requestParameters['accountId'] == null) {
|
|
198
|
+
throw new runtime.RequiredError('accountId', 'Required parameter "accountId" was null or undefined when calling listBankAccounts().');
|
|
199
|
+
}
|
|
200
|
+
queryParameters = {};
|
|
201
|
+
headerParameters = {};
|
|
202
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
203
|
+
token = this.configuration.accessToken;
|
|
204
|
+
return [4 /*yield*/, token("bearer", [])];
|
|
205
|
+
case 1:
|
|
206
|
+
tokenString = _a.sent();
|
|
207
|
+
if (tokenString) {
|
|
208
|
+
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
209
|
+
}
|
|
210
|
+
_a.label = 2;
|
|
211
|
+
case 2: return [4 /*yield*/, this.request({
|
|
212
|
+
path: "/private/accounts/{accountId}/bank-accounts".replace("{".concat("accountId", "}"), encodeURIComponent(String(requestParameters['accountId']))),
|
|
213
|
+
method: 'GET',
|
|
214
|
+
headers: headerParameters,
|
|
215
|
+
query: queryParameters,
|
|
216
|
+
}, initOverrides)];
|
|
217
|
+
case 3:
|
|
218
|
+
response = _a.sent();
|
|
219
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return jsonValue.map(index_1.AccountBankAccountDtoFromJSON); })];
|
|
220
|
+
}
|
|
221
|
+
});
|
|
222
|
+
});
|
|
223
|
+
};
|
|
224
|
+
/**
|
|
225
|
+
*
|
|
226
|
+
*/
|
|
227
|
+
BankAccountsApi.prototype.listBankAccounts = function (requestParameters, initOverrides) {
|
|
228
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
229
|
+
var response;
|
|
230
|
+
return __generator(this, function (_a) {
|
|
231
|
+
switch (_a.label) {
|
|
232
|
+
case 0: return [4 /*yield*/, this.listBankAccountsRaw(requestParameters, initOverrides)];
|
|
233
|
+
case 1:
|
|
234
|
+
response = _a.sent();
|
|
235
|
+
return [4 /*yield*/, response.value()];
|
|
236
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
237
|
+
}
|
|
238
|
+
});
|
|
239
|
+
});
|
|
240
|
+
};
|
|
241
|
+
/**
|
|
242
|
+
*
|
|
243
|
+
*/
|
|
244
|
+
BankAccountsApi.prototype.makeBankAccountPrimaryRaw = function (requestParameters, initOverrides) {
|
|
245
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
246
|
+
var queryParameters, headerParameters, token, tokenString, response;
|
|
247
|
+
return __generator(this, function (_a) {
|
|
248
|
+
switch (_a.label) {
|
|
249
|
+
case 0:
|
|
250
|
+
if (requestParameters['accountId'] == null) {
|
|
251
|
+
throw new runtime.RequiredError('accountId', 'Required parameter "accountId" was null or undefined when calling makeBankAccountPrimary().');
|
|
252
|
+
}
|
|
253
|
+
if (requestParameters['bankAccountId'] == null) {
|
|
254
|
+
throw new runtime.RequiredError('bankAccountId', 'Required parameter "bankAccountId" was null or undefined when calling makeBankAccountPrimary().');
|
|
255
|
+
}
|
|
256
|
+
queryParameters = {};
|
|
257
|
+
headerParameters = {};
|
|
258
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
259
|
+
token = this.configuration.accessToken;
|
|
260
|
+
return [4 /*yield*/, token("bearer", [])];
|
|
261
|
+
case 1:
|
|
262
|
+
tokenString = _a.sent();
|
|
263
|
+
if (tokenString) {
|
|
264
|
+
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
265
|
+
}
|
|
266
|
+
_a.label = 2;
|
|
267
|
+
case 2: return [4 /*yield*/, this.request({
|
|
268
|
+
path: "/private/accounts/{accountId}/bank-accounts/{bankAccountId}/make-primary".replace("{".concat("accountId", "}"), encodeURIComponent(String(requestParameters['accountId']))).replace("{".concat("bankAccountId", "}"), encodeURIComponent(String(requestParameters['bankAccountId']))),
|
|
269
|
+
method: 'POST',
|
|
270
|
+
headers: headerParameters,
|
|
271
|
+
query: queryParameters,
|
|
272
|
+
}, initOverrides)];
|
|
273
|
+
case 3:
|
|
274
|
+
response = _a.sent();
|
|
275
|
+
return [2 /*return*/, new runtime.VoidApiResponse(response)];
|
|
276
|
+
}
|
|
277
|
+
});
|
|
278
|
+
});
|
|
279
|
+
};
|
|
280
|
+
/**
|
|
281
|
+
*
|
|
282
|
+
*/
|
|
283
|
+
BankAccountsApi.prototype.makeBankAccountPrimary = function (requestParameters, initOverrides) {
|
|
284
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
285
|
+
return __generator(this, function (_a) {
|
|
286
|
+
switch (_a.label) {
|
|
287
|
+
case 0: return [4 /*yield*/, this.makeBankAccountPrimaryRaw(requestParameters, initOverrides)];
|
|
288
|
+
case 1:
|
|
289
|
+
_a.sent();
|
|
290
|
+
return [2 /*return*/];
|
|
291
|
+
}
|
|
292
|
+
});
|
|
293
|
+
});
|
|
294
|
+
};
|
|
295
|
+
/**
|
|
296
|
+
*
|
|
297
|
+
*/
|
|
298
|
+
BankAccountsApi.prototype.updateBankAccountRaw = function (requestParameters, initOverrides) {
|
|
299
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
300
|
+
var queryParameters, headerParameters, token, tokenString, response;
|
|
301
|
+
return __generator(this, function (_a) {
|
|
302
|
+
switch (_a.label) {
|
|
303
|
+
case 0:
|
|
304
|
+
if (requestParameters['accountId'] == null) {
|
|
305
|
+
throw new runtime.RequiredError('accountId', 'Required parameter "accountId" was null or undefined when calling updateBankAccount().');
|
|
306
|
+
}
|
|
307
|
+
if (requestParameters['bankAccountId'] == null) {
|
|
308
|
+
throw new runtime.RequiredError('bankAccountId', 'Required parameter "bankAccountId" was null or undefined when calling updateBankAccount().');
|
|
309
|
+
}
|
|
310
|
+
if (requestParameters['updateBankAccountInput'] == null) {
|
|
311
|
+
throw new runtime.RequiredError('updateBankAccountInput', 'Required parameter "updateBankAccountInput" was null or undefined when calling updateBankAccount().');
|
|
312
|
+
}
|
|
313
|
+
queryParameters = {};
|
|
314
|
+
headerParameters = {};
|
|
315
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
316
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
317
|
+
token = this.configuration.accessToken;
|
|
318
|
+
return [4 /*yield*/, token("bearer", [])];
|
|
319
|
+
case 1:
|
|
320
|
+
tokenString = _a.sent();
|
|
321
|
+
if (tokenString) {
|
|
322
|
+
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
323
|
+
}
|
|
324
|
+
_a.label = 2;
|
|
325
|
+
case 2: return [4 /*yield*/, this.request({
|
|
326
|
+
path: "/private/accounts/{accountId}/bank-accounts/{bankAccountId}".replace("{".concat("accountId", "}"), encodeURIComponent(String(requestParameters['accountId']))).replace("{".concat("bankAccountId", "}"), encodeURIComponent(String(requestParameters['bankAccountId']))),
|
|
327
|
+
method: 'PATCH',
|
|
328
|
+
headers: headerParameters,
|
|
329
|
+
query: queryParameters,
|
|
330
|
+
body: (0, index_1.UpdateBankAccountInputToJSON)(requestParameters['updateBankAccountInput']),
|
|
331
|
+
}, initOverrides)];
|
|
332
|
+
case 3:
|
|
333
|
+
response = _a.sent();
|
|
334
|
+
return [2 /*return*/, new runtime.VoidApiResponse(response)];
|
|
335
|
+
}
|
|
336
|
+
});
|
|
337
|
+
});
|
|
338
|
+
};
|
|
339
|
+
/**
|
|
340
|
+
*
|
|
341
|
+
*/
|
|
342
|
+
BankAccountsApi.prototype.updateBankAccount = function (requestParameters, initOverrides) {
|
|
343
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
344
|
+
return __generator(this, function (_a) {
|
|
345
|
+
switch (_a.label) {
|
|
346
|
+
case 0: return [4 /*yield*/, this.updateBankAccountRaw(requestParameters, initOverrides)];
|
|
347
|
+
case 1:
|
|
348
|
+
_a.sent();
|
|
349
|
+
return [2 /*return*/];
|
|
350
|
+
}
|
|
351
|
+
});
|
|
352
|
+
});
|
|
353
|
+
};
|
|
354
|
+
return BankAccountsApi;
|
|
355
|
+
}(runtime.BaseAPI));
|
|
356
|
+
exports.BankAccountsApi = BankAccountsApi;
|
package/dist/apis/index.d.ts
CHANGED
package/dist/apis/index.js
CHANGED
|
@@ -19,6 +19,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
19
19
|
__exportStar(require("./AccountsApi"), exports);
|
|
20
20
|
__exportStar(require("./AccountsPublicApi"), exports);
|
|
21
21
|
__exportStar(require("./AdminApi"), exports);
|
|
22
|
+
__exportStar(require("./BankAccountsApi"), exports);
|
|
22
23
|
__exportStar(require("./BuyersApi"), exports);
|
|
23
24
|
__exportStar(require("./BuyersPublicApi"), exports);
|
|
24
25
|
__exportStar(require("./DefaultApi"), exports);
|