@northstake/northstakeapi 1.0.13 → 1.0.14
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 +13 -16
- package/api/depositAddressesApi.ts +4 -4
- package/api/linkedWalletsApi.ts +2 -2
- package/api/managedUsersApi.ts +28 -28
- package/api/managedUsersDepositAddressesApi.ts +5 -5
- package/api/managedUsersLinkedWalletsApi.ts +15 -15
- package/api/managedUsersOrdersApi.ts +16 -16
- package/api/managedUsersPortfolioApi.ts +2 -2
- package/api/managedUsersTransactionsApi.ts +11 -11
- package/api/managedUsersValidatorsApi.ts +2 -2
- package/api/ordersApi.ts +7 -7
- package/api/transactionsApi.ts +6 -6
- package/api/validatorMarketplaceBuyersApi.ts +3 -3
- package/api/validatorMarketplaceSellersApi.ts +3 -3
- package/api/validatorsApi.ts +5 -5
- package/api.ts +13 -16
- package/dist/api/depositAddressesApi.d.ts +3 -3
- package/dist/api/depositAddressesApi.js +1 -1
- package/dist/api/linkedWalletsApi.d.ts +2 -2
- package/dist/api/managedUsersApi.d.ts +11 -11
- package/dist/api/managedUsersApi.js +24 -24
- package/dist/api/managedUsersDepositAddressesApi.d.ts +3 -3
- package/dist/api/managedUsersDepositAddressesApi.js +3 -3
- package/dist/api/managedUsersLinkedWalletsApi.d.ts +6 -6
- package/dist/api/managedUsersLinkedWalletsApi.js +13 -13
- package/dist/api/managedUsersOrdersApi.d.ts +6 -6
- package/dist/api/managedUsersOrdersApi.js +15 -15
- package/dist/api/managedUsersPortfolioApi.d.ts +1 -1
- package/dist/api/managedUsersPortfolioApi.js +2 -2
- package/dist/api/managedUsersTransactionsApi.d.ts +7 -7
- package/dist/api/managedUsersTransactionsApi.js +5 -5
- package/dist/api/managedUsersValidatorsApi.d.ts +1 -1
- package/dist/api/managedUsersValidatorsApi.js +2 -2
- package/dist/api/ordersApi.d.ts +3 -3
- package/dist/api/ordersApi.js +6 -6
- package/dist/api/transactionsApi.d.ts +4 -4
- package/dist/api/transactionsApi.js +2 -2
- package/dist/api/validatorMarketplaceBuyersApi.d.ts +2 -2
- package/dist/api/validatorMarketplaceBuyersApi.js +1 -1
- package/dist/api/validatorMarketplaceSellersApi.d.ts +2 -2
- package/dist/api/validatorMarketplaceSellersApi.js +1 -1
- package/dist/api/validatorsApi.d.ts +3 -3
- package/dist/api/validatorsApi.js +2 -2
- package/dist/api.d.ts +13 -16
- package/dist/api.js +13 -16
- package/dist/model/accountEntity.d.ts +2 -0
- package/dist/model/accountEntity.js +5 -0
- package/dist/model/{addLinkedWalletForManagedUserRequest.d.ts → addLinkedWalletForUserRequest.d.ts} +4 -4
- package/dist/model/{addLinkedWalletForManagedUserRequest.js → addLinkedWalletForUserRequest.js} +7 -7
- package/dist/model/addLinkedWalletRequest.d.ts +2 -2
- package/dist/model/addLinkedWalletRequest.js +1 -1
- package/dist/model/{tokenEnum.d.ts → asset.d.ts} +1 -1
- package/dist/model/depositAccount.d.ts +2 -2
- package/dist/model/depositAccount.js +1 -1
- package/dist/model/{depositAddressesForManagedUserResponse.d.ts → depositAddressesForUserResponse.d.ts} +1 -1
- package/dist/model/{depositAddressesForManagedUserResponse.js → depositAddressesForUserResponse.js} +6 -6
- package/dist/model/models.d.ts +13 -16
- package/dist/model/models.js +23 -40
- package/dist/model/{newOrderRequest.d.ts → order.d.ts} +8 -14
- package/dist/model/{newOrderRequest.js → order.js} +7 -7
- package/dist/model/orderDocument.d.ts +2 -2
- package/dist/model/orderDocument.js +1 -1
- package/dist/model/{rFQDocumentStatusEnum.d.ts → orderType.d.ts} +4 -1
- package/dist/model/portfolioEntity.d.ts +2 -2
- package/dist/model/portfolioEntity.js +1 -1
- package/dist/model/rFQDocumentBase.d.ts +2 -2
- package/dist/model/rFQDocumentBase.js +1 -1
- package/dist/model/rFQDocumentBuyer.d.ts +2 -2
- package/dist/model/rFQDocumentBuyer.js +1 -1
- package/dist/model/rFQDocumentBuyerStatusFilter.d.ts +12 -0
- package/dist/model/rFQDocumentSeller.d.ts +2 -2
- package/dist/model/rFQDocumentSeller.js +1 -1
- package/dist/model/{rFQDocumentBuyerStatusFilterEnum.d.ts → rFQDocumentSellerStatusFilter.d.ts} +1 -1
- package/dist/model/rFQDocumentStatus.d.ts +12 -0
- package/dist/model/{baseOrder.d.ts → smartContract.d.ts} +12 -18
- package/dist/model/smartContract.js +56 -0
- package/dist/model/transaction.d.ts +4 -4
- package/dist/model/transaction.js +2 -2
- package/dist/model/{transactionEventTypeEnum.d.ts → transactionEventType.d.ts} +1 -1
- package/dist/model/{transactionsForManagedUser.d.ts → transactionsforUser.d.ts} +1 -1
- package/dist/model/{transactionsForManagedUser.js → transactionsforUser.js} +6 -6
- package/dist/model/validatorContractType.d.ts +12 -0
- package/dist/model/validatorInfoValidatorType.d.ts +2 -2
- package/dist/model/validatorInfoValidatorType.js +1 -1
- package/dist/model/validatorInfoValidatorTypeContract.d.ts +2 -2
- package/dist/model/validatorInfoValidatorTypeContract.js +1 -1
- package/dist/model/{validatorKeyHolderEnum.d.ts → validatorKeyHolder.d.ts} +1 -1
- package/dist/model/validatorKeyHolder.js +13 -0
- package/model/accountEntity.ts +7 -0
- package/model/{addLinkedWalletForManagedUserRequest.ts → addLinkedWalletForUserRequest.ts} +6 -6
- package/model/addLinkedWalletRequest.ts +3 -3
- package/model/{tokenEnum.ts → asset.ts} +1 -1
- package/model/depositAccount.ts +3 -3
- package/model/{depositAddressesForManagedUserResponse.ts → depositAddressesForUserResponse.ts} +2 -2
- package/model/models.ts +33 -55
- package/model/{stakeOrder.ts → order.ts} +19 -19
- package/model/orderDocument.ts +3 -3
- package/model/orderType.ts +21 -0
- package/model/portfolioEntity.ts +3 -3
- package/model/rFQDocumentBase.ts +3 -3
- package/model/rFQDocumentBuyer.ts +3 -3
- package/model/{rFQDocumentBuyerStatusFilterEnum.ts → rFQDocumentBuyerStatusFilter.ts} +1 -1
- package/model/rFQDocumentSeller.ts +3 -3
- package/model/{rFQDocumentSellerStatusFilterEnum.ts → rFQDocumentSellerStatusFilter.ts} +1 -1
- package/model/{rFQDocumentStatusEnum.ts → rFQDocumentStatus.ts} +1 -1
- package/model/smartContract.ts +67 -0
- package/model/transaction.ts +6 -6
- package/model/{transactionEventTypeEnum.ts → transactionEventType.ts} +1 -1
- package/model/{transactionsForManagedUser.ts → transactionsforUser.ts} +2 -2
- package/model/{validatorContractTypeEnum.ts → validatorContractType.ts} +1 -1
- package/model/validatorInfoValidatorType.ts +3 -3
- package/model/validatorInfoValidatorTypeContract.ts +3 -3
- package/model/{validatorKeyHolderEnum.ts → validatorKeyHolder.ts} +1 -1
- package/package.json +2 -2
- package/dist/model/baseOrder.js +0 -38
- package/dist/model/createOrderForManagedUserRequest.d.ts +0 -48
- package/dist/model/createOrderForManagedUserRequest.js +0 -48
- package/dist/model/rFQDocumentSellerStatusFilterEnum.d.ts +0 -12
- package/dist/model/stakeOrder.d.ts +0 -44
- package/dist/model/stakeOrder.js +0 -46
- package/dist/model/unstakeOrder.d.ts +0 -42
- package/dist/model/unstakeOrder.js +0 -38
- package/dist/model/validatorContractTypeEnum.d.ts +0 -12
- package/dist/model/withdrawalOrder.d.ts +0 -46
- package/dist/model/withdrawalOrder.js +0 -43
- package/model/baseOrder.ts +0 -61
- package/model/createOrderForManagedUserRequest.ts +0 -80
- package/model/newOrderRequest.ts +0 -80
- package/model/unstakeOrder.ts +0 -61
- package/model/withdrawalOrder.ts +0 -70
- /package/dist/model/{rFQDocumentBuyerStatusFilterEnum.js → asset.js} +0 -0
- /package/dist/model/{rFQDocumentSellerStatusFilterEnum.js → orderType.js} +0 -0
- /package/dist/model/{rFQDocumentStatusEnum.js → rFQDocumentBuyerStatusFilter.js} +0 -0
- /package/dist/model/{tokenEnum.js → rFQDocumentSellerStatusFilter.js} +0 -0
- /package/dist/model/{transactionEventTypeEnum.js → rFQDocumentStatus.js} +0 -0
- /package/dist/model/{validatorContractTypeEnum.js → transactionEventType.js} +0 -0
- /package/dist/model/{validatorKeyHolderEnum.js → validatorContractType.js} +0 -0
package/.openapi-generator/FILES
CHANGED
|
@@ -22,15 +22,14 @@ api/validatorMarketplaceWebhooksApi.ts
|
|
|
22
22
|
api/validatorsApi.ts
|
|
23
23
|
git_push.sh
|
|
24
24
|
model/accountEntity.ts
|
|
25
|
-
model/
|
|
25
|
+
model/addLinkedWalletForUserRequest.ts
|
|
26
26
|
model/addLinkedWalletRequest.ts
|
|
27
27
|
model/allManagedUsersResponse.ts
|
|
28
|
-
model/
|
|
28
|
+
model/asset.ts
|
|
29
29
|
model/createManagedUserRequest.ts
|
|
30
|
-
model/createOrderForManagedUserRequest.ts
|
|
31
30
|
model/createRFQRequest.ts
|
|
32
31
|
model/depositAccount.ts
|
|
33
|
-
model/
|
|
32
|
+
model/depositAddressesForUserResponse.ts
|
|
34
33
|
model/errorResponse.ts
|
|
35
34
|
model/ethereumValidatorKey.ts
|
|
36
35
|
model/ethereumValidatorKeyKeystore.ts
|
|
@@ -45,9 +44,10 @@ model/exitEstimateSeller.ts
|
|
|
45
44
|
model/getTransactionsResponse.ts
|
|
46
45
|
model/managedUser.ts
|
|
47
46
|
model/models.ts
|
|
48
|
-
model/
|
|
47
|
+
model/order.ts
|
|
49
48
|
model/orderDocument.ts
|
|
50
49
|
model/orderDocumentSteps.ts
|
|
50
|
+
model/orderType.ts
|
|
51
51
|
model/orderUpdatePayload.ts
|
|
52
52
|
model/portfolioEntity.ts
|
|
53
53
|
model/provideEscrowHashForRFQDocumentRequest.ts
|
|
@@ -57,11 +57,11 @@ model/rFQDocumentBase.ts
|
|
|
57
57
|
model/rFQDocumentBaseUniqueEscrowVault.ts
|
|
58
58
|
model/rFQDocumentBuyer.ts
|
|
59
59
|
model/rFQDocumentBuyerAllOfValidators.ts
|
|
60
|
-
model/
|
|
60
|
+
model/rFQDocumentBuyerStatusFilter.ts
|
|
61
61
|
model/rFQDocumentSeller.ts
|
|
62
62
|
model/rFQDocumentSellerAllOfValidators.ts
|
|
63
|
-
model/
|
|
64
|
-
model/
|
|
63
|
+
model/rFQDocumentSellerStatusFilter.ts
|
|
64
|
+
model/rFQDocumentStatus.ts
|
|
65
65
|
model/rFQDocumentUpdate.ts
|
|
66
66
|
model/rFQUpdatePayload.ts
|
|
67
67
|
model/rFQWebhookEventType.ts
|
|
@@ -71,24 +71,22 @@ model/settlementStepEscrowPayment.ts
|
|
|
71
71
|
model/settlementStepEscrowReleased.ts
|
|
72
72
|
model/settlementStepWithdrawalRecipientSettlement.ts
|
|
73
73
|
model/settlementSteps.ts
|
|
74
|
-
model/
|
|
74
|
+
model/smartContract.ts
|
|
75
75
|
model/stakeStep.ts
|
|
76
76
|
model/stakeStepElement.ts
|
|
77
77
|
model/stepStatus.ts
|
|
78
78
|
model/submittedQuote.ts
|
|
79
|
-
model/tokenEnum.ts
|
|
80
79
|
model/transaction.ts
|
|
81
|
-
model/
|
|
82
|
-
model/
|
|
83
|
-
model/unstakeOrder.ts
|
|
80
|
+
model/transactionEventType.ts
|
|
81
|
+
model/transactionsforUser.ts
|
|
84
82
|
model/unstakeStep.ts
|
|
85
83
|
model/unstakeStepElement.ts
|
|
86
84
|
model/unstakeStepType.ts
|
|
87
|
-
model/
|
|
85
|
+
model/validatorContractType.ts
|
|
88
86
|
model/validatorInfo.ts
|
|
89
87
|
model/validatorInfoValidatorType.ts
|
|
90
88
|
model/validatorInfoValidatorTypeContract.ts
|
|
91
|
-
model/
|
|
89
|
+
model/validatorKeyHolder.ts
|
|
92
90
|
model/wallet.ts
|
|
93
91
|
model/webHookLookupAnswer.ts
|
|
94
92
|
model/webhookPayload.ts
|
|
@@ -108,7 +106,6 @@ model/webhookPayloadRFQValidatorExitedDetails.ts
|
|
|
108
106
|
model/webhookPayloadRFQValidatorWithdrawalChange.ts
|
|
109
107
|
model/webhookRegistration.ts
|
|
110
108
|
model/webhookRegistrationDetails.ts
|
|
111
|
-
model/withdrawalOrder.ts
|
|
112
109
|
model/withdrawalStep.ts
|
|
113
110
|
model/withdrawalStepElement.ts
|
|
114
111
|
model/withdrawalStepType.ts
|
|
@@ -15,9 +15,9 @@ import localVarRequest from 'request';
|
|
|
15
15
|
import http from 'http';
|
|
16
16
|
|
|
17
17
|
/* tslint:disable:no-unused-locals */
|
|
18
|
+
import { Asset } from '../model/asset';
|
|
18
19
|
import { DepositAccount } from '../model/depositAccount';
|
|
19
20
|
import { ErrorResponse } from '../model/errorResponse';
|
|
20
|
-
import { TokenEnum } from '../model/tokenEnum';
|
|
21
21
|
|
|
22
22
|
import { ObjectSerializer, Authentication, VoidAuth, Interceptor } from '../model/models';
|
|
23
23
|
import { HttpBasicAuth, HttpBearerAuth, ApiKeyAuth, OAuth, JWTAuth } from '../model/models';
|
|
@@ -108,7 +108,7 @@ export class DepositAddressesApi {
|
|
|
108
108
|
|
|
109
109
|
|
|
110
110
|
|
|
111
|
-
public async getDepositAddressByToken (token:
|
|
111
|
+
public async getDepositAddressByToken (token: Asset, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ body: DepositAccount, status: number }> {
|
|
112
112
|
|
|
113
113
|
const localVarPath = this.basePath + '/depositAddresses/{token}'
|
|
114
114
|
.replace('{' + 'token' + '}', encodeURIComponent(String(token)));
|
|
@@ -166,14 +166,14 @@ export class DepositAddressesApi {
|
|
|
166
166
|
localVarRequestOptions.form = localVarFormParams;
|
|
167
167
|
}
|
|
168
168
|
}
|
|
169
|
-
return new Promise<{ body:
|
|
169
|
+
return new Promise<{ body: DepositAccount, status: number }>((resolve, reject) => {
|
|
170
170
|
localVarRequest(localVarRequestOptions, (error, response, body) => {
|
|
171
171
|
if (error) {
|
|
172
172
|
console.error('API call error:', error);
|
|
173
173
|
reject(error);
|
|
174
174
|
} else {
|
|
175
175
|
if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
|
|
176
|
-
body = ObjectSerializer.deserialize(body, "
|
|
176
|
+
body = ObjectSerializer.deserialize(body, "DepositAccount");
|
|
177
177
|
resolve({ body: body, status: response.statusCode });
|
|
178
178
|
} else {
|
|
179
179
|
console.error('API response error:', response.statusCode);
|
package/api/linkedWalletsApi.ts
CHANGED
|
@@ -16,8 +16,8 @@ import http from 'http';
|
|
|
16
16
|
|
|
17
17
|
/* tslint:disable:no-unused-locals */
|
|
18
18
|
import { AddLinkedWalletRequest } from '../model/addLinkedWalletRequest';
|
|
19
|
+
import { Asset } from '../model/asset';
|
|
19
20
|
import { ErrorResponse } from '../model/errorResponse';
|
|
20
|
-
import { TokenEnum } from '../model/tokenEnum';
|
|
21
21
|
import { Wallet } from '../model/wallet';
|
|
22
22
|
|
|
23
23
|
import { ObjectSerializer, Authentication, VoidAuth, Interceptor } from '../model/models';
|
|
@@ -195,7 +195,7 @@ export class LinkedWalletsApi {
|
|
|
195
195
|
|
|
196
196
|
|
|
197
197
|
|
|
198
|
-
public async deleteLinkedWallet (walletAddress: string, walletType:
|
|
198
|
+
public async deleteLinkedWallet (walletAddress: string, walletType: Asset, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ body: any, status: number }> {
|
|
199
199
|
|
|
200
200
|
const localVarPath = this.basePath + '/linkedWallets/{walletAddress}/{walletType}'
|
|
201
201
|
.replace('{' + 'walletAddress' + '}', encodeURIComponent(String(walletAddress)))
|
package/api/managedUsersApi.ts
CHANGED
|
@@ -110,7 +110,7 @@ export class ManagedUsersApi {
|
|
|
110
110
|
|
|
111
111
|
|
|
112
112
|
|
|
113
|
-
public async
|
|
113
|
+
public async createUser (createManagedUserRequest: CreateManagedUserRequest, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ body: ManagedUser, status: number }> {
|
|
114
114
|
|
|
115
115
|
const localVarPath = this.basePath + '/managedUsers';
|
|
116
116
|
|
|
@@ -127,7 +127,7 @@ export class ManagedUsersApi {
|
|
|
127
127
|
|
|
128
128
|
// Verify required parameter 'createManagedUserRequest' is not null or undefined
|
|
129
129
|
if (createManagedUserRequest === null || createManagedUserRequest === undefined) {
|
|
130
|
-
throw new Error('Required parameter "createManagedUserRequest" was null or undefined when calling
|
|
130
|
+
throw new Error('Required parameter "createManagedUserRequest" was null or undefined when calling createUser.');
|
|
131
131
|
}
|
|
132
132
|
|
|
133
133
|
|
|
@@ -196,7 +196,7 @@ export class ManagedUsersApi {
|
|
|
196
196
|
|
|
197
197
|
|
|
198
198
|
|
|
199
|
-
public async
|
|
199
|
+
public async deleteUser (userId: string, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ body: any, status: number }> {
|
|
200
200
|
|
|
201
201
|
const localVarPath = this.basePath + '/managedUsers/{userId}'
|
|
202
202
|
.replace('{' + 'userId' + '}', encodeURIComponent(String(userId)));
|
|
@@ -214,7 +214,7 @@ export class ManagedUsersApi {
|
|
|
214
214
|
|
|
215
215
|
// Verify required parameter 'userId' is not null or undefined
|
|
216
216
|
if (userId === null || userId === undefined) {
|
|
217
|
-
throw new Error('Required parameter "userId" was null or undefined when calling
|
|
217
|
+
throw new Error('Required parameter "userId" was null or undefined when calling deleteUser.');
|
|
218
218
|
}
|
|
219
219
|
|
|
220
220
|
|
|
@@ -273,18 +273,18 @@ export class ManagedUsersApi {
|
|
|
273
273
|
}
|
|
274
274
|
/**
|
|
275
275
|
*
|
|
276
|
-
* @summary Get
|
|
277
|
-
* @param
|
|
278
|
-
* @param limit Number of managed users to return per page
|
|
276
|
+
* @summary Get information for a specific user managed by the account
|
|
277
|
+
* @param userId
|
|
279
278
|
*/
|
|
280
279
|
|
|
281
280
|
|
|
282
281
|
|
|
283
282
|
|
|
284
283
|
|
|
285
|
-
public async
|
|
284
|
+
public async getUser (userId: string, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ body: AccountEntity, status: number }> {
|
|
286
285
|
|
|
287
|
-
const localVarPath = this.basePath + '/managedUsers'
|
|
286
|
+
const localVarPath = this.basePath + '/managedUsers/{userId}'
|
|
287
|
+
.replace('{' + 'userId' + '}', encodeURIComponent(String(userId)));
|
|
288
288
|
|
|
289
289
|
let localVarQueryParameters: any = {};
|
|
290
290
|
let localVarHeaderParams: any = (<any>Object).assign({}, this._defaultHeaders);
|
|
@@ -297,15 +297,13 @@ export class ManagedUsersApi {
|
|
|
297
297
|
let localVarFormParams: any = {};
|
|
298
298
|
|
|
299
299
|
|
|
300
|
+
// Verify required parameter 'userId' is not null or undefined
|
|
301
|
+
if (userId === null || userId === undefined) {
|
|
302
|
+
throw new Error('Required parameter "userId" was null or undefined when calling getUser.');
|
|
303
|
+
}
|
|
300
304
|
|
|
301
305
|
|
|
302
306
|
|
|
303
|
-
if (page !== undefined) {
|
|
304
|
-
localVarQueryParameters['page'] = ObjectSerializer.serialize(page, "number");
|
|
305
|
-
}
|
|
306
|
-
if (limit !== undefined) {
|
|
307
|
-
localVarQueryParameters['limit'] = ObjectSerializer.serialize(limit, "number");
|
|
308
|
-
}
|
|
309
307
|
|
|
310
308
|
|
|
311
309
|
|
|
@@ -341,14 +339,14 @@ export class ManagedUsersApi {
|
|
|
341
339
|
localVarRequestOptions.form = localVarFormParams;
|
|
342
340
|
}
|
|
343
341
|
}
|
|
344
|
-
return new Promise<{ body:
|
|
342
|
+
return new Promise<{ body: AccountEntity, status: number }>((resolve, reject) => {
|
|
345
343
|
localVarRequest(localVarRequestOptions, (error, response, body) => {
|
|
346
344
|
if (error) {
|
|
347
345
|
console.error('API call error:', error);
|
|
348
346
|
reject(error);
|
|
349
347
|
} else {
|
|
350
348
|
if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
|
|
351
|
-
body = ObjectSerializer.deserialize(body, "
|
|
349
|
+
body = ObjectSerializer.deserialize(body, "AccountEntity");
|
|
352
350
|
resolve({ body: body, status: response.statusCode });
|
|
353
351
|
} else {
|
|
354
352
|
console.error('API response error:', response.statusCode);
|
|
@@ -361,18 +359,18 @@ export class ManagedUsersApi {
|
|
|
361
359
|
}
|
|
362
360
|
/**
|
|
363
361
|
*
|
|
364
|
-
* @summary Get
|
|
365
|
-
* @param
|
|
362
|
+
* @summary Get all users managed by the account
|
|
363
|
+
* @param page Page number of the managed users list
|
|
364
|
+
* @param limit Number of managed users to return per page
|
|
366
365
|
*/
|
|
367
366
|
|
|
368
367
|
|
|
369
368
|
|
|
370
369
|
|
|
371
370
|
|
|
372
|
-
public async
|
|
371
|
+
public async getUsers (page?: number, limit?: number, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ body: AllManagedUsersResponse, status: number }> {
|
|
373
372
|
|
|
374
|
-
const localVarPath = this.basePath + '/managedUsers
|
|
375
|
-
.replace('{' + 'userId' + '}', encodeURIComponent(String(userId)));
|
|
373
|
+
const localVarPath = this.basePath + '/managedUsers';
|
|
376
374
|
|
|
377
375
|
let localVarQueryParameters: any = {};
|
|
378
376
|
let localVarHeaderParams: any = (<any>Object).assign({}, this._defaultHeaders);
|
|
@@ -385,13 +383,15 @@ export class ManagedUsersApi {
|
|
|
385
383
|
let localVarFormParams: any = {};
|
|
386
384
|
|
|
387
385
|
|
|
388
|
-
// Verify required parameter 'userId' is not null or undefined
|
|
389
|
-
if (userId === null || userId === undefined) {
|
|
390
|
-
throw new Error('Required parameter "userId" was null or undefined when calling getManagedUserInformation.');
|
|
391
|
-
}
|
|
392
386
|
|
|
393
387
|
|
|
394
388
|
|
|
389
|
+
if (page !== undefined) {
|
|
390
|
+
localVarQueryParameters['page'] = ObjectSerializer.serialize(page, "number");
|
|
391
|
+
}
|
|
392
|
+
if (limit !== undefined) {
|
|
393
|
+
localVarQueryParameters['limit'] = ObjectSerializer.serialize(limit, "number");
|
|
394
|
+
}
|
|
395
395
|
|
|
396
396
|
|
|
397
397
|
|
|
@@ -427,14 +427,14 @@ export class ManagedUsersApi {
|
|
|
427
427
|
localVarRequestOptions.form = localVarFormParams;
|
|
428
428
|
}
|
|
429
429
|
}
|
|
430
|
-
return new Promise<{ body:
|
|
430
|
+
return new Promise<{ body: AllManagedUsersResponse, status: number }>((resolve, reject) => {
|
|
431
431
|
localVarRequest(localVarRequestOptions, (error, response, body) => {
|
|
432
432
|
if (error) {
|
|
433
433
|
console.error('API call error:', error);
|
|
434
434
|
reject(error);
|
|
435
435
|
} else {
|
|
436
436
|
if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
|
|
437
|
-
body = ObjectSerializer.deserialize(body, "
|
|
437
|
+
body = ObjectSerializer.deserialize(body, "AllManagedUsersResponse");
|
|
438
438
|
resolve({ body: body, status: response.statusCode });
|
|
439
439
|
} else {
|
|
440
440
|
console.error('API response error:', response.statusCode);
|
|
@@ -15,7 +15,7 @@ import localVarRequest from 'request';
|
|
|
15
15
|
import http from 'http';
|
|
16
16
|
|
|
17
17
|
/* tslint:disable:no-unused-locals */
|
|
18
|
-
import {
|
|
18
|
+
import { DepositAddressesForUserResponse } from '../model/depositAddressesForUserResponse';
|
|
19
19
|
import { ErrorResponse } from '../model/errorResponse';
|
|
20
20
|
|
|
21
21
|
import { ObjectSerializer, Authentication, VoidAuth, Interceptor } from '../model/models';
|
|
@@ -107,7 +107,7 @@ export class ManagedUsersDepositAddressesApi {
|
|
|
107
107
|
|
|
108
108
|
|
|
109
109
|
|
|
110
|
-
public async
|
|
110
|
+
public async getDepositAddressesForUser (userId: string, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ body: DepositAddressesForUserResponse, status: number }> {
|
|
111
111
|
|
|
112
112
|
const localVarPath = this.basePath + '/managedUsers/{userId}/depositAddresses'
|
|
113
113
|
.replace('{' + 'userId' + '}', encodeURIComponent(String(userId)));
|
|
@@ -125,7 +125,7 @@ export class ManagedUsersDepositAddressesApi {
|
|
|
125
125
|
|
|
126
126
|
// Verify required parameter 'userId' is not null or undefined
|
|
127
127
|
if (userId === null || userId === undefined) {
|
|
128
|
-
throw new Error('Required parameter "userId" was null or undefined when calling
|
|
128
|
+
throw new Error('Required parameter "userId" was null or undefined when calling getDepositAddressesForUser.');
|
|
129
129
|
}
|
|
130
130
|
|
|
131
131
|
|
|
@@ -165,14 +165,14 @@ export class ManagedUsersDepositAddressesApi {
|
|
|
165
165
|
localVarRequestOptions.form = localVarFormParams;
|
|
166
166
|
}
|
|
167
167
|
}
|
|
168
|
-
return new Promise<{ body:
|
|
168
|
+
return new Promise<{ body: DepositAddressesForUserResponse, status: number }>((resolve, reject) => {
|
|
169
169
|
localVarRequest(localVarRequestOptions, (error, response, body) => {
|
|
170
170
|
if (error) {
|
|
171
171
|
console.error('API call error:', error);
|
|
172
172
|
reject(error);
|
|
173
173
|
} else {
|
|
174
174
|
if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
|
|
175
|
-
body = ObjectSerializer.deserialize(body, "
|
|
175
|
+
body = ObjectSerializer.deserialize(body, "DepositAddressesForUserResponse");
|
|
176
176
|
resolve({ body: body, status: response.statusCode });
|
|
177
177
|
} else {
|
|
178
178
|
console.error('API response error:', response.statusCode);
|
|
@@ -15,9 +15,9 @@ import localVarRequest from 'request';
|
|
|
15
15
|
import http from 'http';
|
|
16
16
|
|
|
17
17
|
/* tslint:disable:no-unused-locals */
|
|
18
|
-
import {
|
|
18
|
+
import { AddLinkedWalletForUserRequest } from '../model/addLinkedWalletForUserRequest';
|
|
19
|
+
import { Asset } from '../model/asset';
|
|
19
20
|
import { ErrorResponse } from '../model/errorResponse';
|
|
20
|
-
import { TokenEnum } from '../model/tokenEnum';
|
|
21
21
|
import { Wallet } from '../model/wallet';
|
|
22
22
|
|
|
23
23
|
import { ObjectSerializer, Authentication, VoidAuth, Interceptor } from '../model/models';
|
|
@@ -103,14 +103,14 @@ export class ManagedUsersLinkedWalletsApi {
|
|
|
103
103
|
*
|
|
104
104
|
* @summary Add a new linked wallet for a managed user
|
|
105
105
|
* @param userId The unique identifier for the managed user
|
|
106
|
-
* @param
|
|
106
|
+
* @param addLinkedWalletForUserRequest
|
|
107
107
|
*/
|
|
108
108
|
|
|
109
109
|
|
|
110
110
|
|
|
111
111
|
|
|
112
112
|
|
|
113
|
-
public async
|
|
113
|
+
public async addLinkedWalletForUser (userId: string, addLinkedWalletForUserRequest: AddLinkedWalletForUserRequest, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ body: any, status: number }> {
|
|
114
114
|
|
|
115
115
|
const localVarPath = this.basePath + '/managedUsers/{userId}/linkedWallets'
|
|
116
116
|
.replace('{' + 'userId' + '}', encodeURIComponent(String(userId)));
|
|
@@ -128,11 +128,11 @@ export class ManagedUsersLinkedWalletsApi {
|
|
|
128
128
|
|
|
129
129
|
// Verify required parameter 'userId' is not null or undefined
|
|
130
130
|
if (userId === null || userId === undefined) {
|
|
131
|
-
throw new Error('Required parameter "userId" was null or undefined when calling
|
|
131
|
+
throw new Error('Required parameter "userId" was null or undefined when calling addLinkedWalletForUser.');
|
|
132
132
|
}
|
|
133
|
-
// Verify required parameter '
|
|
134
|
-
if (
|
|
135
|
-
throw new Error('Required parameter "
|
|
133
|
+
// Verify required parameter 'addLinkedWalletForUserRequest' is not null or undefined
|
|
134
|
+
if (addLinkedWalletForUserRequest === null || addLinkedWalletForUserRequest === undefined) {
|
|
135
|
+
throw new Error('Required parameter "addLinkedWalletForUserRequest" was null or undefined when calling addLinkedWalletForUser.');
|
|
136
136
|
}
|
|
137
137
|
|
|
138
138
|
|
|
@@ -154,7 +154,7 @@ export class ManagedUsersLinkedWalletsApi {
|
|
|
154
154
|
uri: localVarPath,
|
|
155
155
|
useQuerystring: this._useQuerystring,
|
|
156
156
|
json: true,
|
|
157
|
-
body: ObjectSerializer.serialize(
|
|
157
|
+
body: ObjectSerializer.serialize(addLinkedWalletForUserRequest, "AddLinkedWalletForUserRequest")
|
|
158
158
|
};
|
|
159
159
|
|
|
160
160
|
let authenticationPromise = Promise.resolve();
|
|
@@ -202,7 +202,7 @@ export class ManagedUsersLinkedWalletsApi {
|
|
|
202
202
|
|
|
203
203
|
|
|
204
204
|
|
|
205
|
-
public async
|
|
205
|
+
public async deleteLinkedWalletForUser (userId: string, walletAddress: string, walletType: Asset, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ body: any, status: number }> {
|
|
206
206
|
|
|
207
207
|
const localVarPath = this.basePath + '/managedUsers/{userId}/linkedWallets/{walletType}/{walletAddress}'
|
|
208
208
|
.replace('{' + 'userId' + '}', encodeURIComponent(String(userId)))
|
|
@@ -222,15 +222,15 @@ export class ManagedUsersLinkedWalletsApi {
|
|
|
222
222
|
|
|
223
223
|
// Verify required parameter 'userId' is not null or undefined
|
|
224
224
|
if (userId === null || userId === undefined) {
|
|
225
|
-
throw new Error('Required parameter "userId" was null or undefined when calling
|
|
225
|
+
throw new Error('Required parameter "userId" was null or undefined when calling deleteLinkedWalletForUser.');
|
|
226
226
|
}
|
|
227
227
|
// Verify required parameter 'walletAddress' is not null or undefined
|
|
228
228
|
if (walletAddress === null || walletAddress === undefined) {
|
|
229
|
-
throw new Error('Required parameter "walletAddress" was null or undefined when calling
|
|
229
|
+
throw new Error('Required parameter "walletAddress" was null or undefined when calling deleteLinkedWalletForUser.');
|
|
230
230
|
}
|
|
231
231
|
// Verify required parameter 'walletType' is not null or undefined
|
|
232
232
|
if (walletType === null || walletType === undefined) {
|
|
233
|
-
throw new Error('Required parameter "walletType" was null or undefined when calling
|
|
233
|
+
throw new Error('Required parameter "walletType" was null or undefined when calling deleteLinkedWalletForUser.');
|
|
234
234
|
}
|
|
235
235
|
|
|
236
236
|
|
|
@@ -297,7 +297,7 @@ export class ManagedUsersLinkedWalletsApi {
|
|
|
297
297
|
|
|
298
298
|
|
|
299
299
|
|
|
300
|
-
public async
|
|
300
|
+
public async listLinkedWalletsForUser (userId: string, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ body: Array<Wallet>, status: number }> {
|
|
301
301
|
|
|
302
302
|
const localVarPath = this.basePath + '/managedUsers/{userId}/linkedWallets'
|
|
303
303
|
.replace('{' + 'userId' + '}', encodeURIComponent(String(userId)));
|
|
@@ -315,7 +315,7 @@ export class ManagedUsersLinkedWalletsApi {
|
|
|
315
315
|
|
|
316
316
|
// Verify required parameter 'userId' is not null or undefined
|
|
317
317
|
if (userId === null || userId === undefined) {
|
|
318
|
-
throw new Error('Required parameter "userId" was null or undefined when calling
|
|
318
|
+
throw new Error('Required parameter "userId" was null or undefined when calling listLinkedWalletsForUser.');
|
|
319
319
|
}
|
|
320
320
|
|
|
321
321
|
|
|
@@ -15,8 +15,8 @@ import localVarRequest from 'request';
|
|
|
15
15
|
import http from 'http';
|
|
16
16
|
|
|
17
17
|
/* tslint:disable:no-unused-locals */
|
|
18
|
-
import { CreateOrderForManagedUserRequest } from '../model/createOrderForManagedUserRequest';
|
|
19
18
|
import { ErrorResponse } from '../model/errorResponse';
|
|
19
|
+
import { Order } from '../model/order';
|
|
20
20
|
import { OrderDocument } from '../model/orderDocument';
|
|
21
21
|
|
|
22
22
|
import { ObjectSerializer, Authentication, VoidAuth, Interceptor } from '../model/models';
|
|
@@ -109,7 +109,7 @@ export class ManagedUsersOrdersApi {
|
|
|
109
109
|
|
|
110
110
|
|
|
111
111
|
|
|
112
|
-
public async
|
|
112
|
+
public async cancelOrderForUser (userId: string, orderId: string, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ body: any, status: number }> {
|
|
113
113
|
|
|
114
114
|
const localVarPath = this.basePath + '/managedUsers/{userId}/orders/{orderId}'
|
|
115
115
|
.replace('{' + 'userId' + '}', encodeURIComponent(String(userId)))
|
|
@@ -128,11 +128,11 @@ export class ManagedUsersOrdersApi {
|
|
|
128
128
|
|
|
129
129
|
// Verify required parameter 'userId' is not null or undefined
|
|
130
130
|
if (userId === null || userId === undefined) {
|
|
131
|
-
throw new Error('Required parameter "userId" was null or undefined when calling
|
|
131
|
+
throw new Error('Required parameter "userId" was null or undefined when calling cancelOrderForUser.');
|
|
132
132
|
}
|
|
133
133
|
// Verify required parameter 'orderId' is not null or undefined
|
|
134
134
|
if (orderId === null || orderId === undefined) {
|
|
135
|
-
throw new Error('Required parameter "orderId" was null or undefined when calling
|
|
135
|
+
throw new Error('Required parameter "orderId" was null or undefined when calling cancelOrderForUser.');
|
|
136
136
|
}
|
|
137
137
|
|
|
138
138
|
|
|
@@ -193,14 +193,14 @@ export class ManagedUsersOrdersApi {
|
|
|
193
193
|
* This endpoint allows the client to create a staking, unstaking, or withdrawal order on behalf of a managed user. One key feature of this endpoint is the ability to include an optional `validatorKey` field when creating a staking order. ### Including a Validator Key (Ethereum only) By including a `validatorKey` in the staking order, the client specifies a pre-generated and signed Ethereum validator key that should be used for the staking transaction. This key must meet all required security and operational standards, as it will be directly used for staking on the Ethereum blockchain. The `validatorKey` object includes cryptographic details such as the keystore information, public key, and the cryptographic path. Including this key is beneficial for users who prefer to maintain a level of control over their staking operations and ensure that their specific validators are utilized. ### Without a Validator Key If no `validatorKey` is provided, Northstake handles the staking operation internally. This process requires that the managed user\'s account must have sufficient balance in their deposit account to cover the staking transaction and any associated fees. In this case, Northstake will generate the necessary validator keys, handle the cryptographic operations, and ensure the validator is registered correctly on the blockchain. ### Usage Scenarios - **With Validator Key**: Ensures that a specific, pre-approved validator key is used, providing transparency and control to the user. - **Without Validator Key**: Ideal for users who prefer a hands-off approach, allowing Northstake to manage the technical and operational complexities of staking on their behalf. Clients are advised to ensure that all provided validator keys are secure and generated according to best security practices. Improper handling or exposure of validator keys can lead to significant security risks, including loss of staked assets.
|
|
194
194
|
* @summary Create an order on behalf of a managed user
|
|
195
195
|
* @param userId
|
|
196
|
-
* @param
|
|
196
|
+
* @param order
|
|
197
197
|
*/
|
|
198
198
|
|
|
199
199
|
|
|
200
200
|
|
|
201
201
|
|
|
202
202
|
|
|
203
|
-
public async
|
|
203
|
+
public async createOrderForUser (userId: string, order: Order, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ body: OrderDocument, status: number }> {
|
|
204
204
|
|
|
205
205
|
const localVarPath = this.basePath + '/managedUsers/{userId}/orders'
|
|
206
206
|
.replace('{' + 'userId' + '}', encodeURIComponent(String(userId)));
|
|
@@ -218,11 +218,11 @@ export class ManagedUsersOrdersApi {
|
|
|
218
218
|
|
|
219
219
|
// Verify required parameter 'userId' is not null or undefined
|
|
220
220
|
if (userId === null || userId === undefined) {
|
|
221
|
-
throw new Error('Required parameter "userId" was null or undefined when calling
|
|
221
|
+
throw new Error('Required parameter "userId" was null or undefined when calling createOrderForUser.');
|
|
222
222
|
}
|
|
223
|
-
// Verify required parameter '
|
|
224
|
-
if (
|
|
225
|
-
throw new Error('Required parameter "
|
|
223
|
+
// Verify required parameter 'order' is not null or undefined
|
|
224
|
+
if (order === null || order === undefined) {
|
|
225
|
+
throw new Error('Required parameter "order" was null or undefined when calling createOrderForUser.');
|
|
226
226
|
}
|
|
227
227
|
|
|
228
228
|
|
|
@@ -244,7 +244,7 @@ export class ManagedUsersOrdersApi {
|
|
|
244
244
|
uri: localVarPath,
|
|
245
245
|
useQuerystring: this._useQuerystring,
|
|
246
246
|
json: true,
|
|
247
|
-
body: ObjectSerializer.serialize(
|
|
247
|
+
body: ObjectSerializer.serialize(order, "Order")
|
|
248
248
|
};
|
|
249
249
|
|
|
250
250
|
let authenticationPromise = Promise.resolve();
|
|
@@ -291,7 +291,7 @@ export class ManagedUsersOrdersApi {
|
|
|
291
291
|
|
|
292
292
|
|
|
293
293
|
|
|
294
|
-
public async
|
|
294
|
+
public async getAllOrdersForUser (userId: string, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ body: Array<OrderDocument>, status: number }> {
|
|
295
295
|
|
|
296
296
|
const localVarPath = this.basePath + '/managedUsers/{userId}/orders'
|
|
297
297
|
.replace('{' + 'userId' + '}', encodeURIComponent(String(userId)));
|
|
@@ -309,7 +309,7 @@ export class ManagedUsersOrdersApi {
|
|
|
309
309
|
|
|
310
310
|
// Verify required parameter 'userId' is not null or undefined
|
|
311
311
|
if (userId === null || userId === undefined) {
|
|
312
|
-
throw new Error('Required parameter "userId" was null or undefined when calling
|
|
312
|
+
throw new Error('Required parameter "userId" was null or undefined when calling getAllOrdersForUser.');
|
|
313
313
|
}
|
|
314
314
|
|
|
315
315
|
|
|
@@ -378,7 +378,7 @@ export class ManagedUsersOrdersApi {
|
|
|
378
378
|
|
|
379
379
|
|
|
380
380
|
|
|
381
|
-
public async
|
|
381
|
+
public async getOrderDetailsForUser (userId: string, orderId: string, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ body: OrderDocument, status: number }> {
|
|
382
382
|
|
|
383
383
|
const localVarPath = this.basePath + '/managedUsers/{userId}/orders/{orderId}'
|
|
384
384
|
.replace('{' + 'userId' + '}', encodeURIComponent(String(userId)))
|
|
@@ -397,11 +397,11 @@ export class ManagedUsersOrdersApi {
|
|
|
397
397
|
|
|
398
398
|
// Verify required parameter 'userId' is not null or undefined
|
|
399
399
|
if (userId === null || userId === undefined) {
|
|
400
|
-
throw new Error('Required parameter "userId" was null or undefined when calling
|
|
400
|
+
throw new Error('Required parameter "userId" was null or undefined when calling getOrderDetailsForUser.');
|
|
401
401
|
}
|
|
402
402
|
// Verify required parameter 'orderId' is not null or undefined
|
|
403
403
|
if (orderId === null || orderId === undefined) {
|
|
404
|
-
throw new Error('Required parameter "orderId" was null or undefined when calling
|
|
404
|
+
throw new Error('Required parameter "orderId" was null or undefined when calling getOrderDetailsForUser.');
|
|
405
405
|
}
|
|
406
406
|
|
|
407
407
|
|
|
@@ -107,7 +107,7 @@ export class ManagedUsersPortfolioApi {
|
|
|
107
107
|
|
|
108
108
|
|
|
109
109
|
|
|
110
|
-
public async
|
|
110
|
+
public async getPortfolioForUser (userId: string, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ body: Array<PortfolioEntity>, status: number }> {
|
|
111
111
|
|
|
112
112
|
const localVarPath = this.basePath + '/managedUsers/{userId}/portfolio'
|
|
113
113
|
.replace('{' + 'userId' + '}', encodeURIComponent(String(userId)));
|
|
@@ -125,7 +125,7 @@ export class ManagedUsersPortfolioApi {
|
|
|
125
125
|
|
|
126
126
|
// Verify required parameter 'userId' is not null or undefined
|
|
127
127
|
if (userId === null || userId === undefined) {
|
|
128
|
-
throw new Error('Required parameter "userId" was null or undefined when calling
|
|
128
|
+
throw new Error('Required parameter "userId" was null or undefined when calling getPortfolioForUser.');
|
|
129
129
|
}
|
|
130
130
|
|
|
131
131
|
|
|
@@ -15,10 +15,10 @@ import localVarRequest from 'request';
|
|
|
15
15
|
import http from 'http';
|
|
16
16
|
|
|
17
17
|
/* tslint:disable:no-unused-locals */
|
|
18
|
+
import { Asset } from '../model/asset';
|
|
18
19
|
import { ErrorResponse } from '../model/errorResponse';
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import { TransactionsForManagedUser } from '../model/transactionsForManagedUser';
|
|
20
|
+
import { TransactionEventType } from '../model/transactionEventType';
|
|
21
|
+
import { TransactionsforUser } from '../model/transactionsforUser';
|
|
22
22
|
|
|
23
23
|
import { ObjectSerializer, Authentication, VoidAuth, Interceptor } from '../model/models';
|
|
24
24
|
import { HttpBasicAuth, HttpBearerAuth, ApiKeyAuth, OAuth, JWTAuth } from '../model/models';
|
|
@@ -41,8 +41,8 @@ export interface ManagedUsersTransactionsApiParams {
|
|
|
41
41
|
userId: string;
|
|
42
42
|
startDate?: string;
|
|
43
43
|
endDate?: string;
|
|
44
|
-
type?:
|
|
45
|
-
asset?:
|
|
44
|
+
type?: TransactionEventType;
|
|
45
|
+
asset?: Asset;
|
|
46
46
|
page?: number;
|
|
47
47
|
limit?: number;
|
|
48
48
|
}
|
|
@@ -125,7 +125,7 @@ export class ManagedUsersTransactionsApi {
|
|
|
125
125
|
|
|
126
126
|
|
|
127
127
|
|
|
128
|
-
public async
|
|
128
|
+
public async getTransactionsForUser(params: ManagedUsersTransactionsApiParams, options: { headers: { [name: string]: string } } = { headers: {} }): Promise<{ body: TransactionsforUser, status: number }> {
|
|
129
129
|
|
|
130
130
|
const localVarPath = this.basePath + '/managedUsers/{userId}/transactions'
|
|
131
131
|
.replace('{' + 'userId' + '}', encodeURIComponent(String(params?.userId)));
|
|
@@ -143,7 +143,7 @@ export class ManagedUsersTransactionsApi {
|
|
|
143
143
|
|
|
144
144
|
// Verify required parameter 'userId' is not null or undefined
|
|
145
145
|
if (params?.userId === null || params?.userId === undefined) {
|
|
146
|
-
throw new Error('Required parameter "userId" was null or undefined when calling
|
|
146
|
+
throw new Error('Required parameter "userId" was null or undefined when calling getTransactionsForUser.');
|
|
147
147
|
}
|
|
148
148
|
|
|
149
149
|
|
|
@@ -155,10 +155,10 @@ export class ManagedUsersTransactionsApi {
|
|
|
155
155
|
localVarQueryParameters['endDate'] = ObjectSerializer.serialize(params?.endDate, "string");
|
|
156
156
|
}
|
|
157
157
|
if (params?.type !== undefined) {
|
|
158
|
-
localVarQueryParameters['type'] = ObjectSerializer.serialize(params?.type, "
|
|
158
|
+
localVarQueryParameters['type'] = ObjectSerializer.serialize(params?.type, "TransactionEventType");
|
|
159
159
|
}
|
|
160
160
|
if (params?.asset !== undefined) {
|
|
161
|
-
localVarQueryParameters['asset'] = ObjectSerializer.serialize(params?.asset, "
|
|
161
|
+
localVarQueryParameters['asset'] = ObjectSerializer.serialize(params?.asset, "Asset");
|
|
162
162
|
}
|
|
163
163
|
if (params?.page !== undefined) {
|
|
164
164
|
localVarQueryParameters['page'] = ObjectSerializer.serialize(params?.page, "number");
|
|
@@ -201,14 +201,14 @@ export class ManagedUsersTransactionsApi {
|
|
|
201
201
|
localVarRequestOptions.form = localVarFormParams;
|
|
202
202
|
}
|
|
203
203
|
}
|
|
204
|
-
return new Promise<{ body:
|
|
204
|
+
return new Promise<{ body: TransactionsforUser, status: number }>((resolve, reject) => {
|
|
205
205
|
localVarRequest(localVarRequestOptions, (error, response, body) => {
|
|
206
206
|
if (error) {
|
|
207
207
|
console.error('API call error:', error);
|
|
208
208
|
reject(error);
|
|
209
209
|
} else {
|
|
210
210
|
if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
|
|
211
|
-
body = ObjectSerializer.deserialize(body, "
|
|
211
|
+
body = ObjectSerializer.deserialize(body, "TransactionsforUser");
|
|
212
212
|
resolve({ body: body, status: response.statusCode });
|
|
213
213
|
} else {
|
|
214
214
|
console.error('API response error:', response.statusCode);
|