@binance/derivatives-trading-options 11.0.0 → 12.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 CHANGED
@@ -8516,10 +8516,10 @@ interface IndexPriceStreamsRequest {
8516
8516
  readonly symbol: string;
8517
8517
  /**
8518
8518
  * Unique WebSocket request ID.
8519
- * @type {string}
8519
+ * @type {number}
8520
8520
  * @memberof WebsocketMarketStreamsApiIndexPriceStreams
8521
8521
  */
8522
- readonly id?: string;
8522
+ readonly id?: number;
8523
8523
  }
8524
8524
  /**
8525
8525
  * Request parameters for klineCandlestickStreams operation in WebsocketMarketStreamsApi.
@@ -8540,10 +8540,10 @@ interface KlineCandlestickStreamsRequest {
8540
8540
  readonly interval: string;
8541
8541
  /**
8542
8542
  * Unique WebSocket request ID.
8543
- * @type {string}
8543
+ * @type {number}
8544
8544
  * @memberof WebsocketMarketStreamsApiKlineCandlestickStreams
8545
8545
  */
8546
- readonly id?: string;
8546
+ readonly id?: number;
8547
8547
  }
8548
8548
  /**
8549
8549
  * Request parameters for markPrice operation in WebsocketMarketStreamsApi.
@@ -8558,10 +8558,10 @@ interface MarkPriceRequest {
8558
8558
  readonly underlyingAsset: string;
8559
8559
  /**
8560
8560
  * Unique WebSocket request ID.
8561
- * @type {string}
8561
+ * @type {number}
8562
8562
  * @memberof WebsocketMarketStreamsApiMarkPrice
8563
8563
  */
8564
- readonly id?: string;
8564
+ readonly id?: number;
8565
8565
  }
8566
8566
  /**
8567
8567
  * Request parameters for newSymbolInfo operation in WebsocketMarketStreamsApi.
@@ -8570,10 +8570,10 @@ interface MarkPriceRequest {
8570
8570
  interface NewSymbolInfoRequest {
8571
8571
  /**
8572
8572
  * Unique WebSocket request ID.
8573
- * @type {string}
8573
+ * @type {number}
8574
8574
  * @memberof WebsocketMarketStreamsApiNewSymbolInfo
8575
8575
  */
8576
- readonly id?: string;
8576
+ readonly id?: number;
8577
8577
  }
8578
8578
  /**
8579
8579
  * Request parameters for openInterest operation in WebsocketMarketStreamsApi.
@@ -8594,10 +8594,10 @@ interface OpenInterestRequest {
8594
8594
  readonly expirationDate: string;
8595
8595
  /**
8596
8596
  * Unique WebSocket request ID.
8597
- * @type {string}
8597
+ * @type {number}
8598
8598
  * @memberof WebsocketMarketStreamsApiOpenInterest
8599
8599
  */
8600
- readonly id?: string;
8600
+ readonly id?: number;
8601
8601
  }
8602
8602
  /**
8603
8603
  * Request parameters for partialBookDepthStreams operation in WebsocketMarketStreamsApi.
@@ -8618,10 +8618,10 @@ interface PartialBookDepthStreamsRequest {
8618
8618
  readonly levels: number | bigint;
8619
8619
  /**
8620
8620
  * Unique WebSocket request ID.
8621
- * @type {string}
8621
+ * @type {number}
8622
8622
  * @memberof WebsocketMarketStreamsApiPartialBookDepthStreams
8623
8623
  */
8624
- readonly id?: string;
8624
+ readonly id?: number;
8625
8625
  /**
8626
8626
  * WebSocket stream update speed
8627
8627
  * @type {string}
@@ -8642,10 +8642,10 @@ interface Ticker24HourRequest {
8642
8642
  readonly symbol: string;
8643
8643
  /**
8644
8644
  * Unique WebSocket request ID.
8645
- * @type {string}
8645
+ * @type {number}
8646
8646
  * @memberof WebsocketMarketStreamsApiTicker24Hour
8647
8647
  */
8648
- readonly id?: string;
8648
+ readonly id?: number;
8649
8649
  }
8650
8650
  /**
8651
8651
  * Request parameters for ticker24HourByUnderlyingAssetAndExpirationData operation in WebsocketMarketStreamsApi.
@@ -8666,10 +8666,10 @@ interface Ticker24HourByUnderlyingAssetAndExpirationDataRequest {
8666
8666
  readonly expirationDate: string;
8667
8667
  /**
8668
8668
  * Unique WebSocket request ID.
8669
- * @type {string}
8669
+ * @type {number}
8670
8670
  * @memberof WebsocketMarketStreamsApiTicker24HourByUnderlyingAssetAndExpirationData
8671
8671
  */
8672
- readonly id?: string;
8672
+ readonly id?: number;
8673
8673
  }
8674
8674
  /**
8675
8675
  * Request parameters for tradeStreams operation in WebsocketMarketStreamsApi.
@@ -8684,10 +8684,10 @@ interface TradeStreamsRequest {
8684
8684
  readonly symbol: string;
8685
8685
  /**
8686
8686
  * Unique WebSocket request ID.
8687
- * @type {string}
8687
+ * @type {number}
8688
8688
  * @memberof WebsocketMarketStreamsApiTradeStreams
8689
8689
  */
8690
- readonly id?: string;
8690
+ readonly id?: number;
8691
8691
  }
8692
8692
  /**
8693
8693
  * WebsocketMarketStreamsApi - interface
@@ -8862,7 +8862,7 @@ declare class WebsocketStreamsConnection {
8862
8862
  * @param id Optional subscription ID
8863
8863
  * @returns void
8864
8864
  */
8865
- subscribe(stream: string | string[], id?: string): void;
8865
+ subscribe(stream: string | string[], id?: number): void;
8866
8866
  /**
8867
8867
  * Unsubscribes from one or multiple WebSocket streams
8868
8868
  * Handles both single and pool modes
@@ -8870,7 +8870,7 @@ declare class WebsocketStreamsConnection {
8870
8870
  * @param id Optional unsubscription ID
8871
8871
  * @returns void
8872
8872
  */
8873
- unsubscribe(stream: string | string[], id?: string): void;
8873
+ unsubscribe(stream: string | string[], id?: number): void;
8874
8874
  /**
8875
8875
  * Checks if the WebSocket connection is subscribed to the specified stream.
8876
8876
  * @param stream The name of the WebSocket stream to check.
package/dist/index.d.ts CHANGED
@@ -8517,10 +8517,10 @@ interface IndexPriceStreamsRequest {
8517
8517
  readonly symbol: string;
8518
8518
  /**
8519
8519
  * Unique WebSocket request ID.
8520
- * @type {string}
8520
+ * @type {number}
8521
8521
  * @memberof WebsocketMarketStreamsApiIndexPriceStreams
8522
8522
  */
8523
- readonly id?: string;
8523
+ readonly id?: number;
8524
8524
  }
8525
8525
  /**
8526
8526
  * Request parameters for klineCandlestickStreams operation in WebsocketMarketStreamsApi.
@@ -8541,10 +8541,10 @@ interface KlineCandlestickStreamsRequest {
8541
8541
  readonly interval: string;
8542
8542
  /**
8543
8543
  * Unique WebSocket request ID.
8544
- * @type {string}
8544
+ * @type {number}
8545
8545
  * @memberof WebsocketMarketStreamsApiKlineCandlestickStreams
8546
8546
  */
8547
- readonly id?: string;
8547
+ readonly id?: number;
8548
8548
  }
8549
8549
  /**
8550
8550
  * Request parameters for markPrice operation in WebsocketMarketStreamsApi.
@@ -8559,10 +8559,10 @@ interface MarkPriceRequest {
8559
8559
  readonly underlyingAsset: string;
8560
8560
  /**
8561
8561
  * Unique WebSocket request ID.
8562
- * @type {string}
8562
+ * @type {number}
8563
8563
  * @memberof WebsocketMarketStreamsApiMarkPrice
8564
8564
  */
8565
- readonly id?: string;
8565
+ readonly id?: number;
8566
8566
  }
8567
8567
  /**
8568
8568
  * Request parameters for newSymbolInfo operation in WebsocketMarketStreamsApi.
@@ -8571,10 +8571,10 @@ interface MarkPriceRequest {
8571
8571
  interface NewSymbolInfoRequest {
8572
8572
  /**
8573
8573
  * Unique WebSocket request ID.
8574
- * @type {string}
8574
+ * @type {number}
8575
8575
  * @memberof WebsocketMarketStreamsApiNewSymbolInfo
8576
8576
  */
8577
- readonly id?: string;
8577
+ readonly id?: number;
8578
8578
  }
8579
8579
  /**
8580
8580
  * Request parameters for openInterest operation in WebsocketMarketStreamsApi.
@@ -8595,10 +8595,10 @@ interface OpenInterestRequest {
8595
8595
  readonly expirationDate: string;
8596
8596
  /**
8597
8597
  * Unique WebSocket request ID.
8598
- * @type {string}
8598
+ * @type {number}
8599
8599
  * @memberof WebsocketMarketStreamsApiOpenInterest
8600
8600
  */
8601
- readonly id?: string;
8601
+ readonly id?: number;
8602
8602
  }
8603
8603
  /**
8604
8604
  * Request parameters for partialBookDepthStreams operation in WebsocketMarketStreamsApi.
@@ -8619,10 +8619,10 @@ interface PartialBookDepthStreamsRequest {
8619
8619
  readonly levels: number | bigint;
8620
8620
  /**
8621
8621
  * Unique WebSocket request ID.
8622
- * @type {string}
8622
+ * @type {number}
8623
8623
  * @memberof WebsocketMarketStreamsApiPartialBookDepthStreams
8624
8624
  */
8625
- readonly id?: string;
8625
+ readonly id?: number;
8626
8626
  /**
8627
8627
  * WebSocket stream update speed
8628
8628
  * @type {string}
@@ -8643,10 +8643,10 @@ interface Ticker24HourRequest {
8643
8643
  readonly symbol: string;
8644
8644
  /**
8645
8645
  * Unique WebSocket request ID.
8646
- * @type {string}
8646
+ * @type {number}
8647
8647
  * @memberof WebsocketMarketStreamsApiTicker24Hour
8648
8648
  */
8649
- readonly id?: string;
8649
+ readonly id?: number;
8650
8650
  }
8651
8651
  /**
8652
8652
  * Request parameters for ticker24HourByUnderlyingAssetAndExpirationData operation in WebsocketMarketStreamsApi.
@@ -8667,10 +8667,10 @@ interface Ticker24HourByUnderlyingAssetAndExpirationDataRequest {
8667
8667
  readonly expirationDate: string;
8668
8668
  /**
8669
8669
  * Unique WebSocket request ID.
8670
- * @type {string}
8670
+ * @type {number}
8671
8671
  * @memberof WebsocketMarketStreamsApiTicker24HourByUnderlyingAssetAndExpirationData
8672
8672
  */
8673
- readonly id?: string;
8673
+ readonly id?: number;
8674
8674
  }
8675
8675
  /**
8676
8676
  * Request parameters for tradeStreams operation in WebsocketMarketStreamsApi.
@@ -8685,10 +8685,10 @@ interface TradeStreamsRequest {
8685
8685
  readonly symbol: string;
8686
8686
  /**
8687
8687
  * Unique WebSocket request ID.
8688
- * @type {string}
8688
+ * @type {number}
8689
8689
  * @memberof WebsocketMarketStreamsApiTradeStreams
8690
8690
  */
8691
- readonly id?: string;
8691
+ readonly id?: number;
8692
8692
  }
8693
8693
  /**
8694
8694
  * WebsocketMarketStreamsApi - interface
@@ -8863,7 +8863,7 @@ declare class WebsocketStreamsConnection {
8863
8863
  * @param id Optional subscription ID
8864
8864
  * @returns void
8865
8865
  */
8866
- subscribe(stream: string | string[], id?: string): void;
8866
+ subscribe(stream: string | string[], id?: number): void;
8867
8867
  /**
8868
8868
  * Unsubscribes from one or multiple WebSocket streams
8869
8869
  * Handles both single and pool modes
@@ -8871,7 +8871,7 @@ declare class WebsocketStreamsConnection {
8871
8871
  * @param id Optional unsubscription ID
8872
8872
  * @returns void
8873
8873
  */
8874
- unsubscribe(stream: string | string[], id?: string): void;
8874
+ unsubscribe(stream: string | string[], id?: number): void;
8875
8875
  /**
8876
8876
  * Checks if the WebSocket connection is subscribed to the specified stream.
8877
8877
  * @param stream The name of the WebSocket stream to check.
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/derivatives-trading-options";
17
- var version = "11.0.0";
17
+ var version = "12.0.0";
18
18
 
19
19
  //#endregion
20
20
  //#region src/rest-api/types/place-multiple-orders-orders-parameter-inner.ts
@@ -3081,6 +3081,7 @@ var WebsocketStreams = class {
3081
3081
  ...mode && { mode },
3082
3082
  ...poolSize && { poolSize }
3083
3083
  });
3084
+ websocketBase.streamIdIsStrictlyNumber = true;
3084
3085
  const websocketStreamsConnection = new WebsocketStreamsConnection(websocketBase);
3085
3086
  await websocketBase.connect(stream);
3086
3087
  return websocketStreamsConnection;