@nightlylabs/dex-sdk 1.0.4 → 1.0.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/dist/index.d.cts CHANGED
@@ -6143,13 +6143,13 @@ declare class Client {
6143
6143
  _abis: ReturnType<typeof getABIsForNetwork>;
6144
6144
  _contractAddress: string;
6145
6145
  /**
6146
- * init.
6147
- *
6148
- * @param connection - Aptos connection instance. See {@link Aptos}.
6149
- * @param config - Client configuration options. See {@link ClientConfig}.
6150
-
6151
- * @returns A promise that resolves to {@link Client}.
6152
- */
6146
+ * init.
6147
+ *
6148
+ * @param connection - Aptos connection instance. See {@link Aptos}.
6149
+ * @param config - Client configuration options. See {@link ClientConfig}.
6150
+
6151
+ * @returns A promise that resolves to {@link Client}.
6152
+ */
6153
6153
  static init(connection: Aptos, config?: ClientConfig): Promise<Client>;
6154
6154
  /**
6155
6155
  * constructor.
@@ -6253,20 +6253,20 @@ declare class Client {
6253
6253
  disconnectWebSocket(): Promise<void>;
6254
6254
  isWebSocketConnected(): boolean;
6255
6255
  /**
6256
- * sendWsMessage.
6257
- *
6258
- * @param message - See {@link WsCommand}.
6259
-
6260
- * @returns A promise that resolves to {@link WsMessage}.
6261
- */
6256
+ * sendWsMessage.
6257
+ *
6258
+ * @param message - See {@link WsCommand}.
6259
+
6260
+ * @returns A promise that resolves to {@link WsMessage}.
6261
+ */
6262
6262
  sendWsMessage(message: WsCommand): Promise<WsMessage>;
6263
6263
  /**
6264
- * subscribeIndexPricesUpdates.
6265
- *
6266
- * @param callback - Callback invoked for oracle updates. See {@link WsOracleUpdates}.
6267
-
6268
- * @returns A promise that resolves to an unsubscribe function.
6269
- */
6264
+ * subscribeIndexPricesUpdates.
6265
+ *
6266
+ * @param callback - Callback invoked for oracle updates. See {@link WsOracleUpdates}.
6267
+
6268
+ * @returns A promise that resolves to an unsubscribe function.
6269
+ */
6270
6270
  subscribeIndexPricesUpdates(callback: (data: WsOracleUpdates) => void): Promise<() => Promise<void>>;
6271
6271
  /**
6272
6272
  * unsubscribeIndexPricesUpdates.
@@ -6275,12 +6275,12 @@ declare class Client {
6275
6275
  */
6276
6276
  unsubscribeIndexPricesUpdates(): Promise<void>;
6277
6277
  /**
6278
- * subscribeBorrowLendingUpdates.
6279
- *
6280
- * @param callback - Callback invoked for borrow-lending updates. See {@link WsBorrowLendUpdate}.
6281
-
6282
- * @returns A promise that resolves to an unsubscribe function.
6283
- */
6278
+ * subscribeBorrowLendingUpdates.
6279
+ *
6280
+ * @param callback - Callback invoked for borrow-lending updates. See {@link WsBorrowLendUpdate}.
6281
+
6282
+ * @returns A promise that resolves to an unsubscribe function.
6283
+ */
6284
6284
  subscribeBorrowLendingUpdates(callback: (data: WsBorrowLendUpdate) => void): Promise<() => Promise<void>>;
6285
6285
  /**
6286
6286
  * unsubscribeBorrowLendingUpdates.
@@ -6289,12 +6289,12 @@ declare class Client {
6289
6289
  */
6290
6290
  unsubscribeBorrowLendingUpdates(): Promise<void>;
6291
6291
  /**
6292
- * subscribeBoxOpeningUpdates.
6293
- *
6294
- * @param callback - Callback invoked for box-opening updates. See {@link WsBoxOpeningUpdate}.
6295
-
6296
- * @returns A promise that resolves to an unsubscribe function.
6297
- */
6292
+ * subscribeBoxOpeningUpdates.
6293
+ *
6294
+ * @param callback - Callback invoked for box-opening updates. See {@link WsBoxOpeningUpdate}.
6295
+
6296
+ * @returns A promise that resolves to an unsubscribe function.
6297
+ */
6298
6298
  subscribeBoxOpeningUpdates(callback: (data: WsBoxOpeningUpdate) => void): Promise<() => Promise<void>>;
6299
6299
  /**
6300
6300
  * unsubscribeBoxOpeningUpdates.
@@ -6303,12 +6303,12 @@ declare class Client {
6303
6303
  */
6304
6304
  unsubscribeBoxOpeningUpdates(): Promise<void>;
6305
6305
  /**
6306
- * subscribeLiquidationUpdates.
6307
- *
6308
- * @param callback - Callback invoked for liquidation updates. See {@link WsLiquidationUpdate}.
6309
-
6310
- * @returns A promise that resolves to an unsubscribe function.
6311
- */
6306
+ * subscribeLiquidationUpdates.
6307
+ *
6308
+ * @param callback - Callback invoked for liquidation updates. See {@link WsLiquidationUpdate}.
6309
+
6310
+ * @returns A promise that resolves to an unsubscribe function.
6311
+ */
6312
6312
  subscribeLiquidationUpdates(callback: (data: WsLiquidationUpdate) => void): Promise<() => Promise<void>>;
6313
6313
  /**
6314
6314
  * unsubscribeLiquidationUpdates.
@@ -6317,13 +6317,13 @@ declare class Client {
6317
6317
  */
6318
6318
  unsubscribeLiquidationUpdates(): Promise<void>;
6319
6319
  /**
6320
- * subscribeUserUpdates.
6321
- *
6322
- * @param userId - See string.
6323
- * @param callback - Callback invoked for user updates. See {@link WsUserUpdates}.
6324
-
6325
- * @returns A promise that resolves to an unsubscribe function.
6326
- */
6320
+ * subscribeUserUpdates.
6321
+ *
6322
+ * @param userId - See string.
6323
+ * @param callback - Callback invoked for user updates. See {@link WsUserUpdates}.
6324
+
6325
+ * @returns A promise that resolves to an unsubscribe function.
6326
+ */
6327
6327
  subscribeUserUpdates(userId: string, callback: (data: WsUserUpdates) => void): Promise<() => Promise<void>>;
6328
6328
  /**
6329
6329
  * unsubscribeUserUpdates.
@@ -6332,13 +6332,13 @@ declare class Client {
6332
6332
  */
6333
6333
  unsubscribeUserUpdates(userId: string): Promise<void>;
6334
6334
  /**
6335
- * subscribePerpMarketUpdates.
6336
- *
6337
- * @param market - See string.
6338
- * @param callback - Callback invoked for perpetual market updates. See {@link WsPerpMarketUpdates}.
6339
-
6340
- * @returns A promise that resolves to an unsubscribe function.
6341
- */
6335
+ * subscribePerpMarketUpdates.
6336
+ *
6337
+ * @param market - See string.
6338
+ * @param callback - Callback invoked for perpetual market updates. See {@link WsPerpMarketUpdates}.
6339
+
6340
+ * @returns A promise that resolves to an unsubscribe function.
6341
+ */
6342
6342
  subscribePerpMarketUpdates(market: string, callback: (data: WsPerpMarketUpdates) => void): Promise<() => Promise<void>>;
6343
6343
  /**
6344
6344
  * unsubscribePerpMarketUpdates.
@@ -6347,13 +6347,13 @@ declare class Client {
6347
6347
  */
6348
6348
  unsubscribePerpMarketUpdates(market: string): Promise<void>;
6349
6349
  /**
6350
- * subscribeSpotMarketUpdates.
6351
- *
6352
- * @param market - See string.
6353
- * @param callback - Callback invoked for spot market updates. See {@link WsSpotMarketUpdates}.
6354
-
6355
- * @returns A promise that resolves to an unsubscribe function.
6356
- */
6350
+ * subscribeSpotMarketUpdates.
6351
+ *
6352
+ * @param market - See string.
6353
+ * @param callback - Callback invoked for spot market updates. See {@link WsSpotMarketUpdates}.
6354
+
6355
+ * @returns A promise that resolves to an unsubscribe function.
6356
+ */
6357
6357
  subscribeSpotMarketUpdates(market: string, callback: (data: WsSpotMarketUpdates) => void): Promise<() => Promise<void>>;
6358
6358
  /**
6359
6359
  * unsubscribeSpotMarketUpdates.
@@ -6435,39 +6435,39 @@ declare class Client {
6435
6435
  */
6436
6436
  submitSponsoredMultiAgentTransaction: (tx: MultiAgentTransaction, signature: AccountAuthenticator, secondarySignersAuthenticators: AccountAuthenticator[]) => Promise<SubmitSponsoredTransactionResponse>;
6437
6437
  /**
6438
- * createAndSubmitTransaction.
6439
- *
6440
- * @param aptosPayload - See {@link AnyTransactionPayloadInstance}.
6441
-
6442
- * @returns A promise that resolves to {@link SubmitSponsoredTransactionResponse}.
6443
- */
6438
+ * createAndSubmitTransaction.
6439
+ *
6440
+ * @param aptosPayload - See {@link AnyTransactionPayloadInstance}.
6441
+
6442
+ * @returns A promise that resolves to {@link SubmitSponsoredTransactionResponse}.
6443
+ */
6444
6444
  createAndSubmitTransaction(aptosPayload: AnyTransactionPayloadInstance): Promise<SubmitSponsoredTransactionResponse>;
6445
6445
  /**
6446
- * createOpenBoxesMessage.
6447
- *
6448
- * @param boxId - See string.
6449
- * @param amount - See string.
6450
- * @param userId - See string.
6451
- * @param apiKey - See string.
6452
-
6453
- * @returns The generated box-open message.
6454
- */
6446
+ * createOpenBoxesMessage.
6447
+ *
6448
+ * @param boxId - See string.
6449
+ * @param amount - See string.
6450
+ * @param userId - See string.
6451
+ * @param apiKey - See string.
6452
+
6453
+ * @returns The generated box-open message.
6454
+ */
6455
6455
  createOpenBoxesMessage(boxId: string, amount: string, userId: string, apiKey: string): string;
6456
6456
  /**
6457
- * openBoxes.
6458
- *
6459
- * @param params - See {@link OpenBoxesRequest}.
6460
-
6461
- * @returns A promise that resolves to {@link OpenBoxesResponse}.
6462
- */
6457
+ * openBoxes.
6458
+ *
6459
+ * @param params - See {@link OpenBoxesRequest}.
6460
+
6461
+ * @returns A promise that resolves to {@link OpenBoxesResponse}.
6462
+ */
6463
6463
  openBoxes(params: OpenBoxesRequest): Promise<OpenBoxesResponse>;
6464
6464
  /**
6465
- * removeApiKey.
6466
- *
6467
- * @param params - See {@link RemoveApiKeyParams}.
6468
-
6469
- * @returns A promise that resolves to {@link SubmitSponsoredTransactionResponse}.
6470
- */
6465
+ * removeApiKey.
6466
+ *
6467
+ * @param params - See {@link RemoveApiKeyParams}.
6468
+
6469
+ * @returns A promise that resolves to {@link SubmitSponsoredTransactionResponse}.
6470
+ */
6471
6471
  removeApiKey(params: RemoveApiKeyParams): Promise<SubmitSponsoredTransactionResponse>;
6472
6472
  /**
6473
6473
  * setAliasName.
package/dist/index.d.ts CHANGED
@@ -6143,13 +6143,13 @@ declare class Client {
6143
6143
  _abis: ReturnType<typeof getABIsForNetwork>;
6144
6144
  _contractAddress: string;
6145
6145
  /**
6146
- * init.
6147
- *
6148
- * @param connection - Aptos connection instance. See {@link Aptos}.
6149
- * @param config - Client configuration options. See {@link ClientConfig}.
6150
-
6151
- * @returns A promise that resolves to {@link Client}.
6152
- */
6146
+ * init.
6147
+ *
6148
+ * @param connection - Aptos connection instance. See {@link Aptos}.
6149
+ * @param config - Client configuration options. See {@link ClientConfig}.
6150
+
6151
+ * @returns A promise that resolves to {@link Client}.
6152
+ */
6153
6153
  static init(connection: Aptos, config?: ClientConfig): Promise<Client>;
6154
6154
  /**
6155
6155
  * constructor.
@@ -6253,20 +6253,20 @@ declare class Client {
6253
6253
  disconnectWebSocket(): Promise<void>;
6254
6254
  isWebSocketConnected(): boolean;
6255
6255
  /**
6256
- * sendWsMessage.
6257
- *
6258
- * @param message - See {@link WsCommand}.
6259
-
6260
- * @returns A promise that resolves to {@link WsMessage}.
6261
- */
6256
+ * sendWsMessage.
6257
+ *
6258
+ * @param message - See {@link WsCommand}.
6259
+
6260
+ * @returns A promise that resolves to {@link WsMessage}.
6261
+ */
6262
6262
  sendWsMessage(message: WsCommand): Promise<WsMessage>;
6263
6263
  /**
6264
- * subscribeIndexPricesUpdates.
6265
- *
6266
- * @param callback - Callback invoked for oracle updates. See {@link WsOracleUpdates}.
6267
-
6268
- * @returns A promise that resolves to an unsubscribe function.
6269
- */
6264
+ * subscribeIndexPricesUpdates.
6265
+ *
6266
+ * @param callback - Callback invoked for oracle updates. See {@link WsOracleUpdates}.
6267
+
6268
+ * @returns A promise that resolves to an unsubscribe function.
6269
+ */
6270
6270
  subscribeIndexPricesUpdates(callback: (data: WsOracleUpdates) => void): Promise<() => Promise<void>>;
6271
6271
  /**
6272
6272
  * unsubscribeIndexPricesUpdates.
@@ -6275,12 +6275,12 @@ declare class Client {
6275
6275
  */
6276
6276
  unsubscribeIndexPricesUpdates(): Promise<void>;
6277
6277
  /**
6278
- * subscribeBorrowLendingUpdates.
6279
- *
6280
- * @param callback - Callback invoked for borrow-lending updates. See {@link WsBorrowLendUpdate}.
6281
-
6282
- * @returns A promise that resolves to an unsubscribe function.
6283
- */
6278
+ * subscribeBorrowLendingUpdates.
6279
+ *
6280
+ * @param callback - Callback invoked for borrow-lending updates. See {@link WsBorrowLendUpdate}.
6281
+
6282
+ * @returns A promise that resolves to an unsubscribe function.
6283
+ */
6284
6284
  subscribeBorrowLendingUpdates(callback: (data: WsBorrowLendUpdate) => void): Promise<() => Promise<void>>;
6285
6285
  /**
6286
6286
  * unsubscribeBorrowLendingUpdates.
@@ -6289,12 +6289,12 @@ declare class Client {
6289
6289
  */
6290
6290
  unsubscribeBorrowLendingUpdates(): Promise<void>;
6291
6291
  /**
6292
- * subscribeBoxOpeningUpdates.
6293
- *
6294
- * @param callback - Callback invoked for box-opening updates. See {@link WsBoxOpeningUpdate}.
6295
-
6296
- * @returns A promise that resolves to an unsubscribe function.
6297
- */
6292
+ * subscribeBoxOpeningUpdates.
6293
+ *
6294
+ * @param callback - Callback invoked for box-opening updates. See {@link WsBoxOpeningUpdate}.
6295
+
6296
+ * @returns A promise that resolves to an unsubscribe function.
6297
+ */
6298
6298
  subscribeBoxOpeningUpdates(callback: (data: WsBoxOpeningUpdate) => void): Promise<() => Promise<void>>;
6299
6299
  /**
6300
6300
  * unsubscribeBoxOpeningUpdates.
@@ -6303,12 +6303,12 @@ declare class Client {
6303
6303
  */
6304
6304
  unsubscribeBoxOpeningUpdates(): Promise<void>;
6305
6305
  /**
6306
- * subscribeLiquidationUpdates.
6307
- *
6308
- * @param callback - Callback invoked for liquidation updates. See {@link WsLiquidationUpdate}.
6309
-
6310
- * @returns A promise that resolves to an unsubscribe function.
6311
- */
6306
+ * subscribeLiquidationUpdates.
6307
+ *
6308
+ * @param callback - Callback invoked for liquidation updates. See {@link WsLiquidationUpdate}.
6309
+
6310
+ * @returns A promise that resolves to an unsubscribe function.
6311
+ */
6312
6312
  subscribeLiquidationUpdates(callback: (data: WsLiquidationUpdate) => void): Promise<() => Promise<void>>;
6313
6313
  /**
6314
6314
  * unsubscribeLiquidationUpdates.
@@ -6317,13 +6317,13 @@ declare class Client {
6317
6317
  */
6318
6318
  unsubscribeLiquidationUpdates(): Promise<void>;
6319
6319
  /**
6320
- * subscribeUserUpdates.
6321
- *
6322
- * @param userId - See string.
6323
- * @param callback - Callback invoked for user updates. See {@link WsUserUpdates}.
6324
-
6325
- * @returns A promise that resolves to an unsubscribe function.
6326
- */
6320
+ * subscribeUserUpdates.
6321
+ *
6322
+ * @param userId - See string.
6323
+ * @param callback - Callback invoked for user updates. See {@link WsUserUpdates}.
6324
+
6325
+ * @returns A promise that resolves to an unsubscribe function.
6326
+ */
6327
6327
  subscribeUserUpdates(userId: string, callback: (data: WsUserUpdates) => void): Promise<() => Promise<void>>;
6328
6328
  /**
6329
6329
  * unsubscribeUserUpdates.
@@ -6332,13 +6332,13 @@ declare class Client {
6332
6332
  */
6333
6333
  unsubscribeUserUpdates(userId: string): Promise<void>;
6334
6334
  /**
6335
- * subscribePerpMarketUpdates.
6336
- *
6337
- * @param market - See string.
6338
- * @param callback - Callback invoked for perpetual market updates. See {@link WsPerpMarketUpdates}.
6339
-
6340
- * @returns A promise that resolves to an unsubscribe function.
6341
- */
6335
+ * subscribePerpMarketUpdates.
6336
+ *
6337
+ * @param market - See string.
6338
+ * @param callback - Callback invoked for perpetual market updates. See {@link WsPerpMarketUpdates}.
6339
+
6340
+ * @returns A promise that resolves to an unsubscribe function.
6341
+ */
6342
6342
  subscribePerpMarketUpdates(market: string, callback: (data: WsPerpMarketUpdates) => void): Promise<() => Promise<void>>;
6343
6343
  /**
6344
6344
  * unsubscribePerpMarketUpdates.
@@ -6347,13 +6347,13 @@ declare class Client {
6347
6347
  */
6348
6348
  unsubscribePerpMarketUpdates(market: string): Promise<void>;
6349
6349
  /**
6350
- * subscribeSpotMarketUpdates.
6351
- *
6352
- * @param market - See string.
6353
- * @param callback - Callback invoked for spot market updates. See {@link WsSpotMarketUpdates}.
6354
-
6355
- * @returns A promise that resolves to an unsubscribe function.
6356
- */
6350
+ * subscribeSpotMarketUpdates.
6351
+ *
6352
+ * @param market - See string.
6353
+ * @param callback - Callback invoked for spot market updates. See {@link WsSpotMarketUpdates}.
6354
+
6355
+ * @returns A promise that resolves to an unsubscribe function.
6356
+ */
6357
6357
  subscribeSpotMarketUpdates(market: string, callback: (data: WsSpotMarketUpdates) => void): Promise<() => Promise<void>>;
6358
6358
  /**
6359
6359
  * unsubscribeSpotMarketUpdates.
@@ -6435,39 +6435,39 @@ declare class Client {
6435
6435
  */
6436
6436
  submitSponsoredMultiAgentTransaction: (tx: MultiAgentTransaction, signature: AccountAuthenticator, secondarySignersAuthenticators: AccountAuthenticator[]) => Promise<SubmitSponsoredTransactionResponse>;
6437
6437
  /**
6438
- * createAndSubmitTransaction.
6439
- *
6440
- * @param aptosPayload - See {@link AnyTransactionPayloadInstance}.
6441
-
6442
- * @returns A promise that resolves to {@link SubmitSponsoredTransactionResponse}.
6443
- */
6438
+ * createAndSubmitTransaction.
6439
+ *
6440
+ * @param aptosPayload - See {@link AnyTransactionPayloadInstance}.
6441
+
6442
+ * @returns A promise that resolves to {@link SubmitSponsoredTransactionResponse}.
6443
+ */
6444
6444
  createAndSubmitTransaction(aptosPayload: AnyTransactionPayloadInstance): Promise<SubmitSponsoredTransactionResponse>;
6445
6445
  /**
6446
- * createOpenBoxesMessage.
6447
- *
6448
- * @param boxId - See string.
6449
- * @param amount - See string.
6450
- * @param userId - See string.
6451
- * @param apiKey - See string.
6452
-
6453
- * @returns The generated box-open message.
6454
- */
6446
+ * createOpenBoxesMessage.
6447
+ *
6448
+ * @param boxId - See string.
6449
+ * @param amount - See string.
6450
+ * @param userId - See string.
6451
+ * @param apiKey - See string.
6452
+
6453
+ * @returns The generated box-open message.
6454
+ */
6455
6455
  createOpenBoxesMessage(boxId: string, amount: string, userId: string, apiKey: string): string;
6456
6456
  /**
6457
- * openBoxes.
6458
- *
6459
- * @param params - See {@link OpenBoxesRequest}.
6460
-
6461
- * @returns A promise that resolves to {@link OpenBoxesResponse}.
6462
- */
6457
+ * openBoxes.
6458
+ *
6459
+ * @param params - See {@link OpenBoxesRequest}.
6460
+
6461
+ * @returns A promise that resolves to {@link OpenBoxesResponse}.
6462
+ */
6463
6463
  openBoxes(params: OpenBoxesRequest): Promise<OpenBoxesResponse>;
6464
6464
  /**
6465
- * removeApiKey.
6466
- *
6467
- * @param params - See {@link RemoveApiKeyParams}.
6468
-
6469
- * @returns A promise that resolves to {@link SubmitSponsoredTransactionResponse}.
6470
- */
6465
+ * removeApiKey.
6466
+ *
6467
+ * @param params - See {@link RemoveApiKeyParams}.
6468
+
6469
+ * @returns A promise that resolves to {@link SubmitSponsoredTransactionResponse}.
6470
+ */
6471
6471
  removeApiKey(params: RemoveApiKeyParams): Promise<SubmitSponsoredTransactionResponse>;
6472
6472
  /**
6473
6473
  * setAliasName.