New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

binance

Package Overview
Dependencies
Maintainers
1
Versions
172
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

binance - npm Package Compare versions

Comparing version 2.10.1 to 2.10.2

26

lib/main-client.d.ts
import { AxiosRequestConfig } from 'axios';
import { BasicAssetPaginatedParams, BasicAssetParam, BasicSymbolParam, BinanceBaseUrlKey, CancelOCOParams, CancelOrderParams, ExchangeSymbol, GetAllOrdersParams, GetOrderParams, HistoricalTradesParams, KlinesParams, Kline, NewOCOParams, OrderBookParams, RecentTradesParams, SymbolFromPaginatedRequestFromId, SymbolPrice, RowsWithTotal, CoinStartEndLimit, SymbolArrayParam } from './types/shared';
import { AccountInformation, AddBSwapLiquidityParams, AggregateTrade, AllCoinsInformationResponse, ApiKeyBrokerSubAccount, APIPermissions, APITradingStatus, AssetDetail, BasicBSwapResp, BasicFromPaginatedParams, BasicFuturesSubAccountParams, BasicMarginAssetParams, BasicSubAccount, BasicTimeRangeParam, BrokerSubAccount, BrokerSubAccountHistory, BSwapLiquidity, BSwapOperations, BSwapOperationsParams, CancelSpotOrderResult, ChangePermissionApiKeyBrokerSubAccountParams, ChangePermissionApiKeyBrokerSubAccountResponse, ConvertDustParams, CreateApiKeyBrokerSubAccountParams, CreateApiKeyBrokerSubAccountResponse, CreateBrokerSubAccountParams, CreateSubAccountParams, CrossMarginAccountTransferParams, CurrentAvgPrice, DailyAccountSnapshot, DailyAccountSnapshotParams, DailyChangeStatistic, DeleteApiKeyBrokerSubAccountParams, DepositAddressParams, DepositAddressResponse, DepositHistory, DepositHistoryParams, DustConversion, DustInfo, DustLog, EnableFuturesBrokerSubAccountParams, EnableFuturesBrokerSubAccountResponse, EnableMarginApiKeyBrokerSubAccountParams, EnableMarginBrokerSubAccountParams, EnableMarginBrokerSubAccountResponse, EnableOrDisableIPRestrictionForSubAccountParams, EnableUniversalTransferApiKeyBrokerSubAccountParams, EnableUniversalTransferApiKeyBrokerSubAccountResponse, ExchangeInfo, ExchangeInfoParams, FixedAndActivityProjectParams, FixedAndActivityProjectPositionParams, FlexibleSavingBasicParams, FuturesPositionRisk, GetApiKeyBrokerSubAccountParams, GetBrokerInfoResponse, GetBrokerSubAccountParams, GetBrokerSubAccountHistoryParams, GetBrokerSubAccountDepositHistoryParams, GetOCOParams, GetUniversalTransferBrokerParams, IsolatedMarginAccountInfo, IsolatedMarginAccountTransferParams, LeftDailyPurchaseQuotaFlexibleProductResponse, MarginAccountLoanParams, MarginRecordResponse, MarginTransactionResponse, NewSpotOrderParams, OrderBookResponse, OrderResponseACK, OrderResponseFull, OrderResponseResult, TransferBrokerSubAccountParams, TransferBrokerSubAccount, PurchaseFlexibleProductParams, PurchaseFlexibleProductResponse, PurchaseRecordParams, QueryCrossMarginAccountDetailsParams, QueryCrossMarginPairParams, QueryCrossMarginPairResponse, QueryMarginAssetParams, QueryMarginAssetResponse, QueryMarginPriceIndexResponse, QueryMarginRecordParams, QueryMaxBorrowResponse, QueryMaxTransferOutAmountResponse, RawAccountTrade, RawTrade, RedeemFlexibleProductParams, RemoveBSwapLiquidityParams, SpotOrder, StakingBasicParams, StakingHistory, StakingHistoryParams, StakingPersonalLeftQuota, StakingProduct, StakingProductPosition, StakingProductType, SubAccountAddOrDeleteIPList, SubAccountAssetDetails, SubAccountAssets, SubAccountAssetsParams, SubAccountCOINMDetail, SubAccountCOINMPositionRisk, SubAccountCOINMSummary, SubAccountDepositAddress, SubAccountDepositAddressParams, SubAccountDepositHistoryParams, SubAccountEnableFutures, SubAccountEnableLeverageToken, SubAccountEnableMargin, SubAccountFuturesAccountDetail, SubAccountFuturesAccountSummary, SubAccountFuturesAssetTransfer, SubAccountFuturesAssetTransferHistory, SubAccountFuturesAssetTransferHistoryParams, SubAccountFuturesAssetTransferParams, SubAccountListParams, SubAccountListResponse, SubAccountMarginAccountDetail, SubAccountnableOrDisableIPRestriction, SubAccountsMarginAccountSummary, SubAccountSpotAssetsSummary, SubAccountSpotAssetsSummaryParams, SubAccountSpotAssetTransferHistory, SubAccountSpotAssetTransferHistoryParams, SubAccountStatus, SubAccountSummaryOnFuturesAccountV2Params, SubAccountTransfer, SubAccountTransferHistory, SubAccountTransferHistoryParams, SubAccountTransferParams, SubAccountTransferToMasterParams, SubAccountTransferToSameMasterParams, SubAccountUniversalTransfer, SubAccountUniversalTransferHistoryParams, SubAccountUniversalTransferHistoryResponse, SubAccountUniversalTransferParams, SubAccountUSDMDetail, SubAccountUSDMPositionRisk, SubAccountUSDMSummary, SymbolOrderBookTicker, SymbolTradeFee, SystemStatusResponse, UniversalTransferBrokerParams, UniversalTransferHistoryParams, UniversalTransferParams, VirtualSubAccount, WithdrawAssetsFromManagedSubAccountParams, WithdrawHistory, WithdrawHistoryParams, WithdrawParams, NewFutureAccountTransferParams, GetFutureAccountTransferHistoryParams, FutureAccountTransfer, GetLoanCoinPaginatedHistoryParams, SubAccountDepositHistoryList, ConvertQuoteRequestParams, GetConvertTradeHistoryParams, GetOrderStatusParams, EnableConvertSubAccountParams, AcceptQuoteRequestParams, ReplaceSpotOrderParams, ReplaceSpotOrderResultSuccess } from './types/spot';
import { AccountInformation, AddBSwapLiquidityParams, AggregateTrade, AllCoinsInformationResponse, ApiKeyBrokerSubAccount, APIPermissions, APITradingStatus, AssetDetail, BasicBSwapResp, BasicFromPaginatedParams, BasicFuturesSubAccountParams, BasicMarginAssetParams, BasicSubAccount, BasicTimeRangeParam, BrokerSubAccount, BrokerSubAccountHistory, BSwapLiquidity, BSwapOperations, BSwapOperationsParams, CancelSpotOrderResult, ChangePermissionApiKeyBrokerSubAccountParams, ChangePermissionApiKeyBrokerSubAccountResponse, ConvertDustParams, CreateApiKeyBrokerSubAccountParams, CreateApiKeyBrokerSubAccountResponse, CreateBrokerSubAccountParams, CreateSubAccountParams, CrossMarginAccountTransferParams, CurrentAvgPrice, DailyAccountSnapshot, DailyAccountSnapshotParams, DailyChangeStatistic, DeleteApiKeyBrokerSubAccountParams, DepositAddressParams, DepositAddressResponse, DepositHistory, DepositHistoryParams, DustConversion, DustInfo, DustLog, EnableFuturesBrokerSubAccountParams, EnableFuturesBrokerSubAccountResponse, EnableMarginApiKeyBrokerSubAccountParams, EnableMarginBrokerSubAccountParams, EnableMarginBrokerSubAccountResponse, EnableOrDisableIPRestrictionForSubAccountParams, EnableUniversalTransferApiKeyBrokerSubAccountParams, EnableUniversalTransferApiKeyBrokerSubAccountResponse, ExchangeInfo, ExchangeInfoParams, FixedAndActivityProjectParams, FixedAndActivityProjectPositionParams, FlexibleSavingBasicParams, FuturesPositionRisk, GetApiKeyBrokerSubAccountParams, GetBrokerInfoResponse, GetBrokerSubAccountParams, GetBrokerSubAccountHistoryParams, GetBrokerSubAccountDepositHistoryParams, GetOCOParams, GetUniversalTransferBrokerParams, IsolatedMarginAccountInfo, IsolatedMarginAccountTransferParams, LeftDailyPurchaseQuotaFlexibleProductResponse, MarginAccountLoanParams, MarginRecordResponse, MarginTransactionResponse, NewSpotOrderParams, OrderBookResponse, OrderResponseACK, OrderResponseFull, OrderResponseResult, TransferBrokerSubAccountParams, TransferBrokerSubAccount, PurchaseFlexibleProductParams, PurchaseFlexibleProductResponse, PurchaseRecordParams, QueryCrossMarginAccountDetailsParams, QueryCrossMarginPairParams, QueryCrossMarginPairResponse, QueryMarginAssetParams, QueryMarginAssetResponse, QueryMarginPriceIndexResponse, QueryMarginRecordParams, QueryMaxBorrowResponse, QueryMaxTransferOutAmountResponse, RawAccountTrade, RawTrade, RedeemFlexibleProductParams, RemoveBSwapLiquidityParams, SpotOrder, StakingBasicParams, StakingHistory, StakingHistoryParams, StakingPersonalLeftQuota, StakingProduct, StakingProductPosition, StakingProductType, SubAccountAddOrDeleteIPList, SubAccountAssetDetails, SubAccountAssets, SubAccountAssetsParams, SubAccountCOINMDetail, SubAccountCOINMPositionRisk, SubAccountCOINMSummary, SubAccountDepositAddress, SubAccountDepositAddressParams, SubAccountDepositHistoryParams, SubAccountEnableFutures, SubAccountEnableLeverageToken, SubAccountEnableMargin, SubAccountFuturesAccountDetail, SubAccountFuturesAccountSummary, SubAccountFuturesAssetTransfer, SubAccountFuturesAssetTransferHistory, SubAccountFuturesAssetTransferHistoryParams, SubAccountFuturesAssetTransferParams, SubAccountListParams, SubAccountListResponse, SubAccountMarginAccountDetail, SubAccountnableOrDisableIPRestriction, SubAccountsMarginAccountSummary, SubAccountSpotAssetsSummary, SubAccountSpotAssetsSummaryParams, SubAccountSpotAssetTransferHistory, SubAccountSpotAssetTransferHistoryParams, SubAccountStatus, SubAccountSummaryOnFuturesAccountV2Params, SubAccountTransfer, SubAccountTransferHistory, SubAccountTransferHistoryParams, SubAccountTransferParams, SubAccountTransferToMasterParams, SubAccountTransferToSameMasterParams, SubAccountUniversalTransfer, SubAccountUniversalTransferHistoryParams, SubAccountUniversalTransferHistoryResponse, SubAccountUniversalTransferParams, SubAccountUSDMDetail, SubAccountUSDMPositionRisk, SubAccountUSDMSummary, SymbolOrderBookTicker, SymbolTradeFee, SystemStatusResponse, UniversalTransferBrokerParams, UniversalTransferHistoryParams, UniversalTransferParams, VirtualSubAccount, WithdrawAssetsFromManagedSubAccountParams, WithdrawHistory, WithdrawHistoryParams, WithdrawParams, NewFutureAccountTransferParams, GetFutureAccountTransferHistoryParams, FutureAccountTransfer, GetLoanCoinPaginatedHistoryParams, SubAccountDepositHistoryList, ConvertQuoteRequestParams, GetConvertTradeHistoryParams, GetOrderStatusParams, EnableConvertSubAccountParams, AcceptQuoteRequestParams, ReplaceSpotOrderParams, ReplaceSpotOrderResultSuccess, NewSpotSOROrderParams, SOROrderResponseFull, SORTestOrderResponse } from './types/spot';
import { RestClientOptions } from './util/requestUtils';

@@ -150,3 +150,27 @@ import BaseRestClient from './util/BaseRestClient';

getAllOCO(params?: BasicFromPaginatedParams): Promise<any>;
/**
* Query open OCO
*/
getAllOpenOCO(): Promise<any>;
/**
* Places an order using smart order routing (SOR).
*/
submitNewSOROrder(params: NewSpotSOROrderParams): Promise<SOROrderResponseFull>;
/**
* Test new order creation and signature/recvWindow using smart order routing (SOR).
* Creates and validates a new order but does not send it into the matching engine.
*/
testNewSOROrder(params: NewSpotSOROrderParams & {
computeCommissionRates?: boolean;
}): Promise<{} | SORTestOrderResponse>;
/**
*
*
* Spot Account Endpoints
*
*
*/
/**
* Get current account information
*/
getAccountInformation(): Promise<AccountInformation>;

@@ -153,0 +177,0 @@ getAccountTradeList(params: SymbolFromPaginatedRequestFromId & {

@@ -402,5 +402,33 @@ "use strict";

}
/**
* Query open OCO
*/
getAllOpenOCO() {
return this.getPrivate('api/v3/openOrderList');
}
/**
* Places an order using smart order routing (SOR).
*/
submitNewSOROrder(params) {
this.validateOrderId(params, 'newClientOrderId');
return this.postPrivate('api/v3/sor/order', params);
}
/**
* Test new order creation and signature/recvWindow using smart order routing (SOR).
* Creates and validates a new order but does not send it into the matching engine.
*/
testNewSOROrder(params) {
this.validateOrderId(params, 'newClientOrderId');
return this.postPrivate('api/v3/sor/order/test', params);
}
/**
*
*
* Spot Account Endpoints
*
*
*/
/**
* Get current account information
*/
getAccountInformation() {

@@ -407,0 +435,0 @@ return this.getPrivate('api/v3/account');

@@ -361,2 +361,16 @@ import { ExchangeFilter, ExchangeSymbol, GenericCodeMsgError, numberInString, OrderBookRow, OrderResponseType, OrderSide, OrderStatus, OrderTimeInForce, OrderType, RateLimiter, SideEffects, StringBoolean, SymbolFilter } from './shared';

}
export interface NewSpotSOROrderParams {
symbol: string;
side: OrderSide;
type: OrderType;
timeInForce?: OrderTimeInForce;
quantity: number;
price?: number;
newClientOrderId?: string;
strategyId?: number;
strategyType?: number;
icebergQty?: number;
newOrderRespType?: OrderResponseType;
selfTradePreventionMode?: 'EXPIRE_TAKER' | 'EXPIRE_MAKER' | 'EXPIRE_BOTH' | 'NONE';
}
export type APILockTriggerCondition = 'GCR' | 'IFER' | 'UFR';

@@ -551,2 +565,34 @@ export interface APITriggerConditionSymbolStatus {

}
export interface SOROrderFill {
matchType: string;
price: numberInString;
qty: numberInString;
commission: numberInString;
commissionAsset: string;
tradeId: number;
allocId: number;
}
export type SOROrderResponseFull = OrderResponseFull & {
workingTime: number;
fills: SOROrderFill[];
workingFloor: string;
selfTradePreventionMode: string;
usedSor: true;
};
export interface SORTestOrderResponse {
standardCommissionForOrder: {
maker: numberInString;
taker: numberInString;
};
taxCommissionForOrder: {
maker: numberInString;
taker: numberInString;
};
discount: {
enabledForAccount: boolean;
enabledForSymbol: boolean;
discountAsset: string;
discount: numberInString;
};
}
export interface GenericReplaceSpotOrderResult<C, N> {

@@ -553,0 +599,0 @@ cancelResult: 'SUCCESS' | 'FAILURE';

2

package.json
{
"name": "binance",
"version": "2.10.1",
"version": "2.10.2",
"description": "Node.js & JavaScript SDK for Binance REST APIs & WebSockets, with TypeScript & end-to-end tests.",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc