ccxt 4.3.3 → 4.3.5

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/js/src/phemex.js CHANGED
@@ -2868,11 +2868,16 @@ export default class phemex extends Exchange {
2868
2868
  }
2869
2869
  await this.loadMarkets();
2870
2870
  const market = this.market(symbol);
2871
+ const stop = this.safeValue2(params, 'stop', 'trigger', false);
2872
+ params = this.omit(params, 'stop', 'trigger');
2871
2873
  const request = {
2872
2874
  'symbol': market['id'],
2873
2875
  // 'untriggerred': false, // false to cancel non-conditional orders, true to cancel conditional orders
2874
2876
  // 'text': 'up to 40 characters max',
2875
2877
  };
2878
+ if (stop) {
2879
+ request['untriggerred'] = stop;
2880
+ }
2876
2881
  let response = undefined;
2877
2882
  if (market['settle'] === 'USDT') {
2878
2883
  response = await this.privateDeleteGOrdersAll(this.extend(request, params));
@@ -7,6 +7,8 @@ export default class binance extends binanceRest {
7
7
  stream(type: any, subscriptionHash: any, numSubscriptions?: number): string;
8
8
  watchOrderBook(symbol: string, limit?: Int, params?: {}): Promise<OrderBook>;
9
9
  watchOrderBookForSymbols(symbols: string[], limit?: Int, params?: {}): Promise<OrderBook>;
10
+ fetchOrderBookWs(symbol: string, limit?: Int, params?: {}): Promise<OrderBook>;
11
+ handleFetchOrderBook(client: Client, message: any): void;
10
12
  fetchOrderBookSnapshot(client: any, message: any, subscription: any): Promise<void>;
11
13
  handleDelta(bookside: any, delta: any): void;
12
14
  handleDeltas(bookside: any, deltas: any): void;
@@ -20,6 +22,7 @@ export default class binance extends binanceRest {
20
22
  handleTrade(client: Client, message: any): void;
21
23
  watchOHLCV(symbol: string, timeframe?: string, since?: Int, limit?: Int, params?: {}): Promise<OHLCV[]>;
22
24
  handleOHLCV(client: Client, message: any): void;
25
+ fetchTickerWs(symbol: string, params?: {}): Promise<Ticker>;
23
26
  fetchOHLCVWs(symbol: string, timeframe?: string, since?: Int, limit?: Int, params?: {}): Promise<OHLCV[]>;
24
27
  handleFetchOHLCV(client: Client, message: any): void;
25
28
  watchTicker(symbol: string, params?: {}): Promise<Ticker>;
@@ -27,6 +30,7 @@ export default class binance extends binanceRest {
27
30
  watchBidsAsks(symbols?: Strings, params?: {}): Promise<Tickers>;
28
31
  watchMultiTickerHelper(methodName: any, channelName: string, symbols?: Strings, params?: {}): Promise<any>;
29
32
  parseWsTicker(message: any, marketType: any): Ticker;
33
+ handleTickerWs(client: Client, message: any): void;
30
34
  handleBidsAsks(client: Client, message: any): void;
31
35
  handleTickers(client: Client, message: any): void;
32
36
  handleTickersAndBidsAsks(client: Client, message: any, methodType: any): void;
@@ -38,9 +42,13 @@ export default class binance extends binanceRest {
38
42
  loadBalanceSnapshot(client: any, messageHash: any, type: any, isPortfolioMargin: any): Promise<void>;
39
43
  fetchBalanceWs(params?: {}): Promise<Balances>;
40
44
  handleBalanceWs(client: Client, message: any): void;
45
+ handleAccountStatusWs(client: Client, message: any): void;
46
+ fetchPositionWs(symbol: string, params?: {}): Promise<Position[]>;
47
+ fetchPositionsWs(symbols?: Strings, params?: {}): Promise<Position[]>;
48
+ handlePositionsWs(client: Client, message: any): void;
41
49
  watchBalance(params?: {}): Promise<Balances>;
42
50
  handleBalance(client: Client, message: any): void;
43
- checkIsSpot(method: string, symbol: string, params?: {}): void;
51
+ getMarketType(method: any, market: any, params?: {}): any;
44
52
  createOrderWs(symbol: string, type: OrderType, side: OrderSide, amount: number, price?: Num, params?: {}): Promise<Order>;
45
53
  handleOrderWs(client: Client, message: any): void;
46
54
  handleOrdersWs(client: Client, message: any): void;