@monaco-protocol/client-v2 0.0.65-dev.1 → 0.0.66

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.
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { CreateWalletRequest, DepositAddressResponse, DepositRequestRequest, DepositRequestResponse, PagedMarketPositionResponse, PagedTransactionResponse, PagedWalletResponse, TransferResponse, WalletMetricsResponse, WalletResponse, WithdrawalRequestRequest } from '../models/index';
13
+ import type { CreateWalletRequest, DepositAddressResponse, DepositRequestRequest, DepositRequestResponse, PagedMarketPositionResponse, PagedTransactionResponse, PagedWalletResponse, TransferResponse, WalletMetricsResponse, WalletResponse, WithdrawalRequestRequest, WithdrawalRequestResponse } from '../models/index';
14
14
  export interface CreateWalletOperationRequest {
15
15
  authorization: string;
16
16
  createWalletRequest: CreateWalletRequest;
@@ -91,12 +91,12 @@ export declare class WalletsApi extends runtime.BaseAPI {
91
91
  */
92
92
  creditWallet(requestParameters: CreditWalletRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TransferResponse>;
93
93
  /**
94
- * Fetch / create a deposit address for given wallet-id and currency-id
94
+ * Fetch / create a deposit address for given wallet id and currency-id
95
95
  * Fetch / create a deposit address
96
96
  */
97
97
  getDepositAddressRaw(requestParameters: GetDepositAddressRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DepositAddressResponse>>;
98
98
  /**
99
- * Fetch / create a deposit address for given wallet-id and currency-id
99
+ * Fetch / create a deposit address for given wallet id and currency-id
100
100
  * Fetch / create a deposit address
101
101
  */
102
102
  getDepositAddress(requestParameters: GetDepositAddressRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DepositAddressResponse>;
@@ -164,12 +164,12 @@ export declare class WalletsApi extends runtime.BaseAPI {
164
164
  * Request to withdraw funds to an external address from the current wallet
165
165
  * Request to withdraw Funds
166
166
  */
167
- requestWithdrawalRaw(requestParameters: RequestWithdrawalRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
167
+ requestWithdrawalRaw(requestParameters: RequestWithdrawalRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<WithdrawalRequestResponse>>;
168
168
  /**
169
169
  * Request to withdraw funds to an external address from the current wallet
170
170
  * Request to withdraw Funds
171
171
  */
172
- requestWithdrawal(requestParameters: RequestWithdrawalRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
172
+ requestWithdrawal(requestParameters: RequestWithdrawalRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<WithdrawalRequestResponse>;
173
173
  }
174
174
  /**
175
175
  * @export
@@ -111,7 +111,7 @@ class WalletsApi extends runtime.BaseAPI {
111
111
  });
112
112
  }
113
113
  /**
114
- * Fetch / create a deposit address for given wallet-id and currency-id
114
+ * Fetch / create a deposit address for given wallet id and currency-id
115
115
  * Fetch / create a deposit address
116
116
  */
117
117
  getDepositAddressRaw(requestParameters, initOverrides) {
@@ -134,7 +134,7 @@ class WalletsApi extends runtime.BaseAPI {
134
134
  headerParameters['authorization'] = String(requestParameters['authorization']);
135
135
  }
136
136
  const response = yield this.request({
137
- path: `/wallets/{id}/deposit/address`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id']))),
137
+ path: `/wallets/{id}/deposits/addresses`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id']))),
138
138
  method: 'GET',
139
139
  headers: headerParameters,
140
140
  query: queryParameters,
@@ -143,7 +143,7 @@ class WalletsApi extends runtime.BaseAPI {
143
143
  });
144
144
  }
145
145
  /**
146
- * Fetch / create a deposit address for given wallet-id and currency-id
146
+ * Fetch / create a deposit address for given wallet id and currency-id
147
147
  * Fetch / create a deposit address
148
148
  */
149
149
  getDepositAddress(requestParameters, initOverrides) {
@@ -405,7 +405,7 @@ class WalletsApi extends runtime.BaseAPI {
405
405
  headerParameters['authorization'] = String(requestParameters['authorization']);
406
406
  }
407
407
  const response = yield this.request({
408
- path: `/wallets/{id}/deposit`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id']))),
408
+ path: `/wallets/{id}/deposits`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id']))),
409
409
  method: 'POST',
410
410
  headers: headerParameters,
411
411
  query: queryParameters,
@@ -446,13 +446,13 @@ class WalletsApi extends runtime.BaseAPI {
446
446
  headerParameters['authorization'] = String(requestParameters['authorization']);
447
447
  }
448
448
  const response = yield this.request({
449
- path: `/wallets/{id}/withdraw`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id']))),
449
+ path: `/wallets/{id}/withdrawals`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id']))),
450
450
  method: 'POST',
451
451
  headers: headerParameters,
452
452
  query: queryParameters,
453
453
  body: (0, index_1.WithdrawalRequestRequestToJSON)(requestParameters['withdrawalRequestRequest']),
454
454
  }, initOverrides);
455
- return new runtime.VoidApiResponse(response);
455
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.WithdrawalRequestResponseFromJSON)(jsonValue));
456
456
  });
457
457
  }
458
458
  /**
@@ -461,7 +461,8 @@ class WalletsApi extends runtime.BaseAPI {
461
461
  */
462
462
  requestWithdrawal(requestParameters, initOverrides) {
463
463
  return __awaiter(this, void 0, void 0, function* () {
464
- yield this.requestWithdrawalRaw(requestParameters, initOverrides);
464
+ const response = yield this.requestWithdrawalRaw(requestParameters, initOverrides);
465
+ return yield response.value();
465
466
  });
466
467
  }
467
468
  }
@@ -26,7 +26,7 @@ export interface DepositRequest {
26
26
  * @type {string}
27
27
  * @memberof DepositRequest
28
28
  */
29
- ownerAddress?: string;
29
+ address?: string;
30
30
  /**
31
31
  *
32
32
  * @type {string}
@@ -33,7 +33,7 @@ function DepositRequestFromJSONTyped(json, ignoreDiscriminator) {
33
33
  }
34
34
  return {
35
35
  'id': json['id'] == null ? undefined : json['id'],
36
- 'ownerAddress': json['ownerAddress'] == null ? undefined : json['ownerAddress'],
36
+ 'address': json['address'] == null ? undefined : json['address'],
37
37
  'currencyId': json['currencyId'] == null ? undefined : json['currencyId'],
38
38
  };
39
39
  }
@@ -46,7 +46,7 @@ function DepositRequestToJSONTyped(value, ignoreDiscriminator = false) {
46
46
  }
47
47
  return {
48
48
  'id': value['id'],
49
- 'ownerAddress': value['ownerAddress'],
49
+ 'address': value['address'],
50
50
  'currencyId': value['currencyId'],
51
51
  };
52
52
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@monaco-protocol/client-v2",
3
- "version": "0.0.65-dev.1",
3
+ "version": "0.0.66",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "files": [