@myx-trade/sdk 0.1.69 → 0.1.71

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.js CHANGED
@@ -1841,7 +1841,7 @@ var RotationProvider = class extends import_providers.BaseProvider {
1841
1841
  // package.json
1842
1842
  var package_default = {
1843
1843
  name: "@myx-trade/sdk",
1844
- version: "0.1.69",
1844
+ version: "0.1.71",
1845
1845
  private: false,
1846
1846
  publishConfig: {
1847
1847
  access: "public"
@@ -14341,15 +14341,18 @@ var Order = class {
14341
14341
  slPrice: params.slPrice ?? "0",
14342
14342
  useAccountBalance
14343
14343
  };
14344
+ this.logger.info("createIncreaseOrder position params--->", data);
14344
14345
  if (config.seamlessMode) {
14345
14346
  const seamlessWallet = this.seamless.seamlessWallet;
14346
14347
  if (!seamlessWallet) {
14347
14348
  throw new MyxSDKError("INVALID_SEAMLESS_WALLET" /* InvalidSeamlessWallet */, "Invalid seamless wallet");
14348
14349
  }
14350
+ console.log("seamlessWallet-->", seamlessWallet);
14349
14351
  const isEnoughGas = await this.utils.checkSeamlessGas(params.address);
14350
14352
  if (!isEnoughGas) {
14351
14353
  throw new MyxSDKError("INSUFFICIENT_BALANCE" /* InsufficientBalance */, "Insufficient relay fee");
14352
14354
  }
14355
+ console.log("isEnoughGas-->", isEnoughGas);
14353
14356
  const forwarderContract = await getForwarderContract(params.chainId);
14354
14357
  const brokerContract2 = await getSeamlessBrokerContract(
14355
14358
  this.configManager.getConfig().brokerAddress,
package/dist/index.mjs CHANGED
@@ -1752,7 +1752,7 @@ var RotationProvider = class extends BaseProvider {
1752
1752
  // package.json
1753
1753
  var package_default = {
1754
1754
  name: "@myx-trade/sdk",
1755
- version: "0.1.69",
1755
+ version: "0.1.71",
1756
1756
  private: false,
1757
1757
  publishConfig: {
1758
1758
  access: "public"
@@ -14252,15 +14252,18 @@ var Order = class {
14252
14252
  slPrice: params.slPrice ?? "0",
14253
14253
  useAccountBalance
14254
14254
  };
14255
+ this.logger.info("createIncreaseOrder position params--->", data);
14255
14256
  if (config.seamlessMode) {
14256
14257
  const seamlessWallet = this.seamless.seamlessWallet;
14257
14258
  if (!seamlessWallet) {
14258
14259
  throw new MyxSDKError("INVALID_SEAMLESS_WALLET" /* InvalidSeamlessWallet */, "Invalid seamless wallet");
14259
14260
  }
14261
+ console.log("seamlessWallet-->", seamlessWallet);
14260
14262
  const isEnoughGas = await this.utils.checkSeamlessGas(params.address);
14261
14263
  if (!isEnoughGas) {
14262
14264
  throw new MyxSDKError("INSUFFICIENT_BALANCE" /* InsufficientBalance */, "Insufficient relay fee");
14263
14265
  }
14266
+ console.log("isEnoughGas-->", isEnoughGas);
14264
14267
  const forwarderContract = await getForwarderContract(params.chainId);
14265
14268
  const brokerContract2 = await getSeamlessBrokerContract(
14266
14269
  this.configManager.getConfig().brokerAddress,
@@ -20331,7 +20334,7 @@ var Account = class {
20331
20334
 
20332
20335
  // src/manager/seamless/index.ts
20333
20336
  import CryptoJS from "crypto-js";
20334
- import { toUtf8Bytes, keccak256 as keccak2562, hexlify, ethers as ethers9, isHexString, getBytes, ZeroAddress as ZeroAddress2 } from "ethers";
20337
+ import { toUtf8Bytes, keccak256, hexlify, ethers as ethers9, isHexString, getBytes, ZeroAddress as ZeroAddress2 } from "ethers";
20335
20338
  import dayjs from "dayjs";
20336
20339
 
20337
20340
  // src/utils/index.ts
@@ -20457,7 +20460,7 @@ var calculateSignature = async (message) => {
20457
20460
  var seamlessNonceString = "jAkBlC4~5!6@#$%^";
20458
20461
  var generateEthWalletFromHashedSignature = (hashedSignature) => {
20459
20462
  const seedStringToUtf8Bytes = toUtf8Bytes(hashedSignature);
20460
- const seedStringToKeccak256 = keccak2562(seedStringToUtf8Bytes);
20463
+ const seedStringToKeccak256 = keccak256(seedStringToUtf8Bytes);
20461
20464
  const seedStringToKeccak256Array = getBytes(seedStringToKeccak256);
20462
20465
  const privateKey = hexlify(seedStringToKeccak256Array);
20463
20466
  if (!isHexString(privateKey, 32)) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@myx-trade/sdk",
3
- "version": "0.1.69",
3
+ "version": "0.1.71",
4
4
  "private": false,
5
5
  "publishConfig": {
6
6
  "access": "public"