@binance/wallet 17.0.9 → 18.0.0
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/dist/index.d.mts +21 -0
- package/dist/index.d.ts +21 -0
- package/dist/index.js +13 -5
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +13 -5
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -4163,6 +4163,12 @@ interface DustConvertRequest {
|
|
|
4163
4163
|
* @memberof AssetApiDustConvert
|
|
4164
4164
|
*/
|
|
4165
4165
|
readonly asset: string;
|
|
4166
|
+
/**
|
|
4167
|
+
* `SPOT` or `MARGIN`,default `SPOT`
|
|
4168
|
+
* @type {string}
|
|
4169
|
+
* @memberof AssetApiDustConvert
|
|
4170
|
+
*/
|
|
4171
|
+
readonly accountType?: string;
|
|
4166
4172
|
/**
|
|
4167
4173
|
* A unique id for the request
|
|
4168
4174
|
* @type {string}
|
|
@@ -4199,6 +4205,12 @@ interface DustConvertibleAssetsRequest {
|
|
|
4199
4205
|
* @memberof AssetApiDustConvertibleAssets
|
|
4200
4206
|
*/
|
|
4201
4207
|
readonly targetAsset: string;
|
|
4208
|
+
/**
|
|
4209
|
+
* `SPOT` or `MARGIN`,default `SPOT`
|
|
4210
|
+
* @type {string}
|
|
4211
|
+
* @memberof AssetApiDustConvertibleAssets
|
|
4212
|
+
*/
|
|
4213
|
+
readonly accountType?: string;
|
|
4202
4214
|
/**
|
|
4203
4215
|
*
|
|
4204
4216
|
* @type {number}
|
|
@@ -4986,6 +4998,9 @@ interface CapitalApiInterface {
|
|
|
4986
4998
|
* If `network` not send, return with default network of the coin.
|
|
4987
4999
|
* You can get `network` and `isDefault` in `networkList` of a coin in the response of `Get /sapi/v1/capital/config/getall (HMAC SHA256)`.
|
|
4988
5000
|
* To check if travel rule is required, by using `GET /sapi/v1/localentity/questionnaire-requirements` and if it returns anything other than `NIL` you will need update SAPI to `POST /sapi/v1/localentity/withdraw/apply` else you can continue `POST /sapi/v1/capital/withdraw/apply`. Please note that if you are required to comply to travel rule please refer to the Travel Rule SAPI.
|
|
5001
|
+
* For networks that do not support memo/tag, submitting a withdrawal request with a non-empty `addressTag` will return error `-4106 TAG_NOT_SUPPORTED_FOR_NETWORK`. Please omit the `addressTag` field for such networks. You can check whether a network requires a tag via `GET /sapi/v1/capital/config/getall`:
|
|
5002
|
+
* If `withdrawTag` = `true` → memo/tag is required.
|
|
5003
|
+
* If `withdrawTag` = `false` → memo/tag is not supported; omit `addressTag`.
|
|
4989
5004
|
*
|
|
4990
5005
|
* Weight: 900
|
|
4991
5006
|
*
|
|
@@ -5411,6 +5426,9 @@ declare class CapitalApi implements CapitalApiInterface {
|
|
|
5411
5426
|
* If `network` not send, return with default network of the coin.
|
|
5412
5427
|
* You can get `network` and `isDefault` in `networkList` of a coin in the response of `Get /sapi/v1/capital/config/getall (HMAC SHA256)`.
|
|
5413
5428
|
* To check if travel rule is required, by using `GET /sapi/v1/localentity/questionnaire-requirements` and if it returns anything other than `NIL` you will need update SAPI to `POST /sapi/v1/localentity/withdraw/apply` else you can continue `POST /sapi/v1/capital/withdraw/apply`. Please note that if you are required to comply to travel rule please refer to the Travel Rule SAPI.
|
|
5429
|
+
* For networks that do not support memo/tag, submitting a withdrawal request with a non-empty `addressTag` will return error `-4106 TAG_NOT_SUPPORTED_FOR_NETWORK`. Please omit the `addressTag` field for such networks. You can check whether a network requires a tag via `GET /sapi/v1/capital/config/getall`:
|
|
5430
|
+
* If `withdrawTag` = `true` → memo/tag is required.
|
|
5431
|
+
* If `withdrawTag` = `false` → memo/tag is not supported; omit `addressTag`.
|
|
5414
5432
|
*
|
|
5415
5433
|
* Weight: 900
|
|
5416
5434
|
*
|
|
@@ -7016,6 +7034,9 @@ declare class RestAPI {
|
|
|
7016
7034
|
* If `network` not send, return with default network of the coin.
|
|
7017
7035
|
* You can get `network` and `isDefault` in `networkList` of a coin in the response of `Get /sapi/v1/capital/config/getall (HMAC SHA256)`.
|
|
7018
7036
|
* To check if travel rule is required, by using `GET /sapi/v1/localentity/questionnaire-requirements` and if it returns anything other than `NIL` you will need update SAPI to `POST /sapi/v1/localentity/withdraw/apply` else you can continue `POST /sapi/v1/capital/withdraw/apply`. Please note that if you are required to comply to travel rule please refer to the Travel Rule SAPI.
|
|
7037
|
+
* For networks that do not support memo/tag, submitting a withdrawal request with a non-empty `addressTag` will return error `-4106 TAG_NOT_SUPPORTED_FOR_NETWORK`. Please omit the `addressTag` field for such networks. You can check whether a network requires a tag via `GET /sapi/v1/capital/config/getall`:
|
|
7038
|
+
* If `withdrawTag` = `true` → memo/tag is required.
|
|
7039
|
+
* If `withdrawTag` = `false` → memo/tag is not supported; omit `addressTag`.
|
|
7019
7040
|
*
|
|
7020
7041
|
* Weight: 900
|
|
7021
7042
|
*
|
package/dist/index.d.ts
CHANGED
|
@@ -4163,6 +4163,12 @@ interface DustConvertRequest {
|
|
|
4163
4163
|
* @memberof AssetApiDustConvert
|
|
4164
4164
|
*/
|
|
4165
4165
|
readonly asset: string;
|
|
4166
|
+
/**
|
|
4167
|
+
* `SPOT` or `MARGIN`,default `SPOT`
|
|
4168
|
+
* @type {string}
|
|
4169
|
+
* @memberof AssetApiDustConvert
|
|
4170
|
+
*/
|
|
4171
|
+
readonly accountType?: string;
|
|
4166
4172
|
/**
|
|
4167
4173
|
* A unique id for the request
|
|
4168
4174
|
* @type {string}
|
|
@@ -4199,6 +4205,12 @@ interface DustConvertibleAssetsRequest {
|
|
|
4199
4205
|
* @memberof AssetApiDustConvertibleAssets
|
|
4200
4206
|
*/
|
|
4201
4207
|
readonly targetAsset: string;
|
|
4208
|
+
/**
|
|
4209
|
+
* `SPOT` or `MARGIN`,default `SPOT`
|
|
4210
|
+
* @type {string}
|
|
4211
|
+
* @memberof AssetApiDustConvertibleAssets
|
|
4212
|
+
*/
|
|
4213
|
+
readonly accountType?: string;
|
|
4202
4214
|
/**
|
|
4203
4215
|
*
|
|
4204
4216
|
* @type {number}
|
|
@@ -4986,6 +4998,9 @@ interface CapitalApiInterface {
|
|
|
4986
4998
|
* If `network` not send, return with default network of the coin.
|
|
4987
4999
|
* You can get `network` and `isDefault` in `networkList` of a coin in the response of `Get /sapi/v1/capital/config/getall (HMAC SHA256)`.
|
|
4988
5000
|
* To check if travel rule is required, by using `GET /sapi/v1/localentity/questionnaire-requirements` and if it returns anything other than `NIL` you will need update SAPI to `POST /sapi/v1/localentity/withdraw/apply` else you can continue `POST /sapi/v1/capital/withdraw/apply`. Please note that if you are required to comply to travel rule please refer to the Travel Rule SAPI.
|
|
5001
|
+
* For networks that do not support memo/tag, submitting a withdrawal request with a non-empty `addressTag` will return error `-4106 TAG_NOT_SUPPORTED_FOR_NETWORK`. Please omit the `addressTag` field for such networks. You can check whether a network requires a tag via `GET /sapi/v1/capital/config/getall`:
|
|
5002
|
+
* If `withdrawTag` = `true` → memo/tag is required.
|
|
5003
|
+
* If `withdrawTag` = `false` → memo/tag is not supported; omit `addressTag`.
|
|
4989
5004
|
*
|
|
4990
5005
|
* Weight: 900
|
|
4991
5006
|
*
|
|
@@ -5411,6 +5426,9 @@ declare class CapitalApi implements CapitalApiInterface {
|
|
|
5411
5426
|
* If `network` not send, return with default network of the coin.
|
|
5412
5427
|
* You can get `network` and `isDefault` in `networkList` of a coin in the response of `Get /sapi/v1/capital/config/getall (HMAC SHA256)`.
|
|
5413
5428
|
* To check if travel rule is required, by using `GET /sapi/v1/localentity/questionnaire-requirements` and if it returns anything other than `NIL` you will need update SAPI to `POST /sapi/v1/localentity/withdraw/apply` else you can continue `POST /sapi/v1/capital/withdraw/apply`. Please note that if you are required to comply to travel rule please refer to the Travel Rule SAPI.
|
|
5429
|
+
* For networks that do not support memo/tag, submitting a withdrawal request with a non-empty `addressTag` will return error `-4106 TAG_NOT_SUPPORTED_FOR_NETWORK`. Please omit the `addressTag` field for such networks. You can check whether a network requires a tag via `GET /sapi/v1/capital/config/getall`:
|
|
5430
|
+
* If `withdrawTag` = `true` → memo/tag is required.
|
|
5431
|
+
* If `withdrawTag` = `false` → memo/tag is not supported; omit `addressTag`.
|
|
5414
5432
|
*
|
|
5415
5433
|
* Weight: 900
|
|
5416
5434
|
*
|
|
@@ -7016,6 +7034,9 @@ declare class RestAPI {
|
|
|
7016
7034
|
* If `network` not send, return with default network of the coin.
|
|
7017
7035
|
* You can get `network` and `isDefault` in `networkList` of a coin in the response of `Get /sapi/v1/capital/config/getall (HMAC SHA256)`.
|
|
7018
7036
|
* To check if travel rule is required, by using `GET /sapi/v1/localentity/questionnaire-requirements` and if it returns anything other than `NIL` you will need update SAPI to `POST /sapi/v1/localentity/withdraw/apply` else you can continue `POST /sapi/v1/capital/withdraw/apply`. Please note that if you are required to comply to travel rule please refer to the Travel Rule SAPI.
|
|
7037
|
+
* For networks that do not support memo/tag, submitting a withdrawal request with a non-empty `addressTag` will return error `-4106 TAG_NOT_SUPPORTED_FOR_NETWORK`. Please omit the `addressTag` field for such networks. You can check whether a network requires a tag via `GET /sapi/v1/capital/config/getall`:
|
|
7038
|
+
* If `withdrawTag` = `true` → memo/tag is required.
|
|
7039
|
+
* If `withdrawTag` = `false` → memo/tag is not supported; omit `addressTag`.
|
|
7019
7040
|
*
|
|
7020
7041
|
* Weight: 900
|
|
7021
7042
|
*
|
package/dist/index.js
CHANGED
|
@@ -14,7 +14,7 @@ let __binance_common = require("@binance/common");
|
|
|
14
14
|
|
|
15
15
|
//#region package.json
|
|
16
16
|
var name = "@binance/wallet";
|
|
17
|
-
var version = "
|
|
17
|
+
var version = "18.0.0";
|
|
18
18
|
|
|
19
19
|
//#endregion
|
|
20
20
|
//#region src/rest-api/modules/account-api.ts
|
|
@@ -321,11 +321,12 @@ const AssetApiAxiosParamCreator = function(configuration) {
|
|
|
321
321
|
timeUnit: _timeUnit
|
|
322
322
|
};
|
|
323
323
|
},
|
|
324
|
-
dustConvert: async (asset, clientId, targetAsset, thirdPartyClientId, dustQuotaAssetToTargetAssetPrice) => {
|
|
324
|
+
dustConvert: async (asset, accountType, clientId, targetAsset, thirdPartyClientId, dustQuotaAssetToTargetAssetPrice) => {
|
|
325
325
|
(0, __binance_common.assertParamExists)("dustConvert", "asset", asset);
|
|
326
326
|
const localVarQueryParameter = {};
|
|
327
327
|
const localVarBodyParameter = {};
|
|
328
328
|
if (asset !== void 0 && asset !== null) localVarQueryParameter["asset"] = asset;
|
|
329
|
+
if (accountType !== void 0 && accountType !== null) localVarQueryParameter["accountType"] = accountType;
|
|
329
330
|
if (clientId !== void 0 && clientId !== null) localVarQueryParameter["clientId"] = clientId;
|
|
330
331
|
if (targetAsset !== void 0 && targetAsset !== null) localVarQueryParameter["targetAsset"] = targetAsset;
|
|
331
332
|
if (thirdPartyClientId !== void 0 && thirdPartyClientId !== null) localVarQueryParameter["thirdPartyClientId"] = thirdPartyClientId;
|
|
@@ -340,10 +341,11 @@ const AssetApiAxiosParamCreator = function(configuration) {
|
|
|
340
341
|
timeUnit: _timeUnit
|
|
341
342
|
};
|
|
342
343
|
},
|
|
343
|
-
dustConvertibleAssets: async (targetAsset, dustQuotaAssetToTargetAssetPrice) => {
|
|
344
|
+
dustConvertibleAssets: async (targetAsset, accountType, dustQuotaAssetToTargetAssetPrice) => {
|
|
344
345
|
(0, __binance_common.assertParamExists)("dustConvertibleAssets", "targetAsset", targetAsset);
|
|
345
346
|
const localVarQueryParameter = {};
|
|
346
347
|
const localVarBodyParameter = {};
|
|
348
|
+
if (accountType !== void 0 && accountType !== null) localVarQueryParameter["accountType"] = accountType;
|
|
347
349
|
if (targetAsset !== void 0 && targetAsset !== null) localVarQueryParameter["targetAsset"] = targetAsset;
|
|
348
350
|
if (dustQuotaAssetToTargetAssetPrice !== void 0 && dustQuotaAssetToTargetAssetPrice !== null) localVarQueryParameter["dustQuotaAssetToTargetAssetPrice"] = dustQuotaAssetToTargetAssetPrice;
|
|
349
351
|
let _timeUnit;
|
|
@@ -648,7 +650,7 @@ var AssetApi = class {
|
|
|
648
650
|
* @see {@link https://developers.binance.com/docs/wallet/asset/Dust-Convert Binance API Documentation}
|
|
649
651
|
*/
|
|
650
652
|
async dustConvert(requestParameters) {
|
|
651
|
-
const localVarAxiosArgs = await this.localVarAxiosParamCreator.dustConvert(requestParameters?.asset, requestParameters?.clientId, requestParameters?.targetAsset, requestParameters?.thirdPartyClientId, requestParameters?.dustQuotaAssetToTargetAssetPrice);
|
|
653
|
+
const localVarAxiosArgs = await this.localVarAxiosParamCreator.dustConvert(requestParameters?.asset, requestParameters?.accountType, requestParameters?.clientId, requestParameters?.targetAsset, requestParameters?.thirdPartyClientId, requestParameters?.dustQuotaAssetToTargetAssetPrice);
|
|
652
654
|
return (0, __binance_common.sendRequest)(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
653
655
|
}
|
|
654
656
|
/**
|
|
@@ -664,7 +666,7 @@ var AssetApi = class {
|
|
|
664
666
|
* @see {@link https://developers.binance.com/docs/wallet/asset/Dust-Convertible-Assets Binance API Documentation}
|
|
665
667
|
*/
|
|
666
668
|
async dustConvertibleAssets(requestParameters) {
|
|
667
|
-
const localVarAxiosArgs = await this.localVarAxiosParamCreator.dustConvertibleAssets(requestParameters?.targetAsset, requestParameters?.dustQuotaAssetToTargetAssetPrice);
|
|
669
|
+
const localVarAxiosArgs = await this.localVarAxiosParamCreator.dustConvertibleAssets(requestParameters?.targetAsset, requestParameters?.accountType, requestParameters?.dustQuotaAssetToTargetAssetPrice);
|
|
668
670
|
return (0, __binance_common.sendRequest)(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
669
671
|
}
|
|
670
672
|
/**
|
|
@@ -1255,6 +1257,9 @@ var CapitalApi = class {
|
|
|
1255
1257
|
* If `network` not send, return with default network of the coin.
|
|
1256
1258
|
* You can get `network` and `isDefault` in `networkList` of a coin in the response of `Get /sapi/v1/capital/config/getall (HMAC SHA256)`.
|
|
1257
1259
|
* To check if travel rule is required, by using `GET /sapi/v1/localentity/questionnaire-requirements` and if it returns anything other than `NIL` you will need update SAPI to `POST /sapi/v1/localentity/withdraw/apply` else you can continue `POST /sapi/v1/capital/withdraw/apply`. Please note that if you are required to comply to travel rule please refer to the Travel Rule SAPI.
|
|
1260
|
+
* For networks that do not support memo/tag, submitting a withdrawal request with a non-empty `addressTag` will return error `-4106 TAG_NOT_SUPPORTED_FOR_NETWORK`. Please omit the `addressTag` field for such networks. You can check whether a network requires a tag via `GET /sapi/v1/capital/config/getall`:
|
|
1261
|
+
* If `withdrawTag` = `true` → memo/tag is required.
|
|
1262
|
+
* If `withdrawTag` = `false` → memo/tag is not supported; omit `addressTag`.
|
|
1258
1263
|
*
|
|
1259
1264
|
* Weight: 900
|
|
1260
1265
|
*
|
|
@@ -2513,6 +2518,9 @@ var RestAPI = class {
|
|
|
2513
2518
|
* If `network` not send, return with default network of the coin.
|
|
2514
2519
|
* You can get `network` and `isDefault` in `networkList` of a coin in the response of `Get /sapi/v1/capital/config/getall (HMAC SHA256)`.
|
|
2515
2520
|
* To check if travel rule is required, by using `GET /sapi/v1/localentity/questionnaire-requirements` and if it returns anything other than `NIL` you will need update SAPI to `POST /sapi/v1/localentity/withdraw/apply` else you can continue `POST /sapi/v1/capital/withdraw/apply`. Please note that if you are required to comply to travel rule please refer to the Travel Rule SAPI.
|
|
2521
|
+
* For networks that do not support memo/tag, submitting a withdrawal request with a non-empty `addressTag` will return error `-4106 TAG_NOT_SUPPORTED_FOR_NETWORK`. Please omit the `addressTag` field for such networks. You can check whether a network requires a tag via `GET /sapi/v1/capital/config/getall`:
|
|
2522
|
+
* If `withdrawTag` = `true` → memo/tag is required.
|
|
2523
|
+
* If `withdrawTag` = `false` → memo/tag is not supported; omit `addressTag`.
|
|
2516
2524
|
*
|
|
2517
2525
|
* Weight: 900
|
|
2518
2526
|
*
|