binance-api-node
Advanced tools
Comparing version 0.10.7 to 0.10.8
@@ -520,2 +520,5 @@ "use strict"; | ||
return privCall('/fapi/v1/positionRisk', payload); | ||
}, | ||
futuresAccountBalance: function futuresAccountBalance(payload) { | ||
return privCall('/fapi/v2/balance', payload); | ||
} | ||
@@ -522,0 +525,0 @@ }; |
@@ -276,2 +276,3 @@ // tslint:disable:interface-name | ||
futuresPositionRisk(options?: { recvWindow: number }): Promise<PositionRiskResult[]> | ||
futuresAccountBalance(options?: { recvWindow: number }): Promise<FuturesBalanceResult[]> | ||
} | ||
@@ -863,2 +864,12 @@ | ||
} | ||
export interface FuturesBalanceResult { | ||
accountAlias: string | ||
asset: string | ||
balance: string | ||
crossWalletBalance: string | ||
crossUnPnl: string | ||
availableBalance: string | ||
maxWithdrawAmount: string | ||
} | ||
} |
{ | ||
"name": "binance-api-node", | ||
"version": "0.10.7", | ||
"version": "0.10.8", | ||
"description": "A node API wrapper for Binance", | ||
@@ -5,0 +5,0 @@ "main": "dist", |
@@ -92,2 +92,4 @@ # binance-api-node [![build](https://img.shields.io/travis/Ashlar/binance-api-node/master.svg?style=flat-square)](https://travis-ci.org/Ashlar/binance-api-node) [![cover](https://img.shields.io/coveralls/github/Ashlar/binance-api-node/master?style=flat-square)](https://coveralls.io/github/Ashlar/binance-api-node?branch=master) [![bnb](https://img.shields.io/badge/binance-winner-yellow.svg?style=flat-square)](https://github.com/binance-exchange/binance-api-node) | ||
- [capitalDepositAddress](#capitalDepositAddress) | ||
- [Futures Authenticated REST Endpoints](#futures-authenticated-rest-endpoints) | ||
- [futuresAccountBalance](#futuresAccountBalance) | ||
- [Websockets](#websockets) | ||
@@ -1648,2 +1650,31 @@ - [depth](#depth) | ||
### Futures Authenticated REST endpoints | ||
#### futuresAccountBalance | ||
Get futures account balance | ||
```js | ||
console.log(await client.futuresAccountBalance()); | ||
``` | ||
<details> | ||
<summary>Output</summary> | ||
```js | ||
[ | ||
{ | ||
"accountAlias": "SgsR", // unique account code | ||
"asset": "USDT", // asset name | ||
"balance": "122607.35137903", // wallet balance | ||
"crossWalletBalance": "23.72469206", // crossed wallet balance | ||
"crossUnPnl": "0.00000000" // unrealized profit of crossed positions | ||
"availableBalance": "23.72469206", // available balance | ||
"maxWithdrawAmount": "23.72469206" // maximum amount for transfer out | ||
} | ||
] | ||
``` | ||
</details> | ||
### WebSockets | ||
@@ -1650,0 +1681,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
111456
1899
1956
3462