binance-api-node
Advanced tools
Comparing version 0.10.23 to 0.10.24
@@ -52,2 +52,3 @@ "use strict"; | ||
'x-mbx-order-count-1h': 'orderCount1h', | ||
'x-mbx-order-count-1d': 'orderCount1d', | ||
'x-response-time': 'responseTime' | ||
@@ -450,2 +451,8 @@ }; | ||
}, | ||
universalTransfer: function universalTransfer(payload) { | ||
return privCall('/sapi/v1/asset/transfer', payload, 'POST'); | ||
}, | ||
universalTransferHistory: function universalTransferHistory(payload) { | ||
return privCall('/sapi/v1/asset/transfer', payload); | ||
}, | ||
capitalConfigs: function capitalConfigs() { | ||
@@ -452,0 +459,0 @@ return privCall('/sapi/v1/capital/config/getall'); |
@@ -165,3 +165,64 @@ // tslint:disable:interface-name | ||
export interface GetInfo { | ||
spot: GetInfoDetails | ||
futures: GetInfoDetails | ||
} | ||
export type GetInfoDetails = { | ||
useWeight1m?: string | ||
orderCount10s?: string | ||
orderCount1m?: string | ||
orderCount1h?: string | ||
orderCount1d?: string | ||
responseTime?: string | ||
} | ||
export type TransferType = 'MAIN_C2C' | | ||
'MAIN_UMFUTURE' | | ||
'MAIN_CMFUTURE' | | ||
'MAIN_MARGIN' | | ||
'MAIN_MINING' | | ||
'C2C_MAIN' | | ||
'C2C_UMFUTURE' | | ||
'C2C_MINING' | | ||
'UMFUTURE_MAIN' | | ||
'UMFUTURE_C2C' | | ||
'UMFUTURE_MARGIN' | | ||
'CMFUTURE_MAIN' | | ||
'MARGIN_MAIN' | | ||
'MARGIN_UMFUTURE' | | ||
'MINING_MAIN' | | ||
'MINING_UMFUTURE' | | ||
'MINING_C2C' | ||
export interface UniversalTransfer { | ||
type: TransferType | ||
asset: string | ||
amount: string | ||
recvWindow?: number | ||
} | ||
export interface UniversalTransferHistory { | ||
type: TransferType | ||
startTime?: number | ||
endTime?: number | ||
current?: number | ||
size?: number | ||
recvWindow?: number | ||
} | ||
export interface UniversalTransferHistoryResponse { | ||
total: string, | ||
rows: { | ||
asset: string | ||
amount: string | ||
type: TransferType | ||
status: string | ||
tranId: number | ||
timestamp: number | ||
}[] | ||
} | ||
export interface Binance { | ||
getInfo(): GetInfo | ||
accountInfo(options?: { useServerTime: boolean }): Promise<Account> | ||
@@ -243,2 +304,4 @@ tradeFee(): Promise<TradeFeeResult> | ||
}): Promise<DepositHistoryResponse> | ||
universalTransfer(options: UniversalTransfer): Promise<{tranId: number}> | ||
universalTransferHistory(options: UniversalTransferHistory): Promise<UniversalTransferHistoryResponse> | ||
futuresPing(): Promise<boolean> | ||
@@ -245,0 +308,0 @@ futuresTime(): Promise<number> |
{ | ||
"name": "binance-api-node", | ||
"version": "0.10.23", | ||
"version": "0.10.24", | ||
"description": "A node API wrapper for Binance", | ||
@@ -5,0 +5,0 @@ "main": "dist", |
Sorry, the diff of this file is too big to display
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
147717
2301
2884