@skip-go/client 1.1.4 → 1.1.6

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.
Files changed (79) hide show
  1. package/dist/api/getAssets.d.ts +1 -1
  2. package/dist/api/getAssets.js +3 -2
  3. package/dist/api/getAssetsBetweenChains.d.ts +1 -1
  4. package/dist/api/getAssetsBetweenChains.js +3 -2
  5. package/dist/api/getBridges.d.ts +1 -1
  6. package/dist/api/getBridges.js +3 -2
  7. package/dist/api/getChains.d.ts +1 -1
  8. package/dist/api/getChains.js +3 -2
  9. package/dist/api/getVenues.js +3 -2
  10. package/dist/api/postAssetsFromSource.d.ts +1 -1
  11. package/dist/api/postAssetsFromSource.js +4 -3
  12. package/dist/api/postBalances.d.ts +2 -2
  13. package/dist/api/postBalances.js +3 -2
  14. package/dist/api/postIbcOriginAssets.js +3 -2
  15. package/dist/api/postMessages.d.ts +6 -473
  16. package/dist/api/postMessages.js +3 -2
  17. package/dist/api/postMessagesDirect.d.ts +5 -1
  18. package/dist/api/postMessagesDirect.js +3 -2
  19. package/dist/api/postRecommendAssets.d.ts +1 -1
  20. package/dist/api/postRecommendAssets.js +3 -2
  21. package/dist/api/postRoute.d.ts +6 -2
  22. package/dist/api/postRoute.js +3 -2
  23. package/dist/api/postSubmit.d.ts +17 -0
  24. package/dist/api/postSubmit.js +3 -0
  25. package/dist/api/postSubmitTransaction.js +3 -2
  26. package/dist/api/postTrackTransaction.js +3 -2
  27. package/dist/api/postTransactionStatus.d.ts +2 -2
  28. package/dist/api/postTransactionStatus.js +3 -2
  29. package/dist/callbacks-BGRu2Ule.d.ts +33 -0
  30. package/dist/chunk-25FJ6EBA.js +36 -0
  31. package/dist/{chunk-4TKPLI5S.js → chunk-2YP6FMPV.js} +1 -1
  32. package/dist/{chunk-MB5ENUER.js → chunk-5QPGL2BH.js} +1 -1
  33. package/dist/{chunk-H6RXHDUX.js → chunk-5WMPFEIQ.js} +1 -1
  34. package/dist/{chunk-R2N4D2PY.js → chunk-C4URP37X.js} +1 -1
  35. package/dist/{chunk-7P6AOFMX.js → chunk-CRTTBUO4.js} +1 -1
  36. package/dist/{chunk-LJSGCCOX.js → chunk-DAR753BM.js} +1 -1
  37. package/dist/chunk-DU3RX43W.js +34 -0
  38. package/dist/chunk-DV3I2S3T.js +181 -0
  39. package/dist/chunk-GV2QOWB4.js +26 -0
  40. package/dist/{chunk-R3KHKN33.js → chunk-IWW34V4S.js} +1 -1
  41. package/dist/{chunk-PZM2IB6H.js → chunk-JZBFAMHE.js} +1 -1
  42. package/dist/{chunk-GTJ2EDUG.js → chunk-KKNOCIFN.js} +2 -2
  43. package/dist/{chunk-EAUM5JYS.js → chunk-NWC6BSNB.js} +1 -1
  44. package/dist/{chunk-R4PWQNPU.js → chunk-NXNVAUER.js} +18 -351
  45. package/dist/{chunk-2NYWLY5S.js → chunk-PPUUN7FI.js} +1 -1
  46. package/dist/{chunk-5EU3SRDQ.js → chunk-RCSN7BAU.js} +2 -2
  47. package/dist/{chunk-KWVMUF5R.js → chunk-RFZBKQ35.js} +1 -1
  48. package/dist/{chunk-WWDCZAB5.js → chunk-RYOVQFZO.js} +1 -1
  49. package/dist/{chunk-BCN2WD5Q.js → chunk-T7GKUROO.js} +1 -1
  50. package/dist/chunk-TV2XPAIF.js +295 -0
  51. package/dist/{chunk-VRPPVMXO.js → chunk-U6XZFJW2.js} +1 -1
  52. package/dist/{chunk-SOGMQT4H.js → chunk-UXUJNZOA.js} +1 -181
  53. package/dist/chunk-X67P5URV.js +10 -0
  54. package/dist/{chunk-RL5AVCSG.js → chunk-XXJUDZKJ.js} +1 -1
  55. package/dist/{client-types-B_ihV5t6.d.ts → client-types-BkeR6R_z.d.ts} +1 -1
  56. package/dist/{generateApi-CpUxWvEf.d.ts → generateApi-8YPJU-Al.d.ts} +1 -1
  57. package/dist/index.d.ts +13 -5
  58. package/dist/index.js +26 -21
  59. package/dist/public-functions/executeRoute.d.ts +40 -4
  60. package/dist/public-functions/executeRoute.js +15 -10
  61. package/dist/public-functions/getCosmosGasAmountForMessage.d.ts +8 -0
  62. package/dist/public-functions/getCosmosGasAmountForMessage.js +2 -0
  63. package/dist/public-functions/getEvmGasAmountForMessage.d.ts +11 -0
  64. package/dist/public-functions/getEvmGasAmountForMessage.js +2 -0
  65. package/dist/public-functions/getFeeInfoForChain.d.ts +1 -1
  66. package/dist/public-functions/getFeeInfoForChain.js +4 -3
  67. package/dist/public-functions/getRecommendedGasPrice.js +5 -4
  68. package/dist/public-functions/getSigningStargateClient.js +4 -3
  69. package/dist/public-functions/setApiOptions.d.ts +1 -1
  70. package/dist/public-functions/setApiOptions.js +3 -2
  71. package/dist/public-functions/setClientOptions.d.ts +3 -3
  72. package/dist/public-functions/setClientOptions.js +4 -3
  73. package/dist/public-functions/waitForTransaction.d.ts +621 -0
  74. package/dist/public-functions/waitForTransaction.js +5 -0
  75. package/dist/{setClientOptions-C4rwBrB4.d.ts → setClientOptions-CI_7IPLT.d.ts} +1 -1
  76. package/dist/{swaggerTypes-sZ9ALP9m.d.ts → swaggerTypes-CAERZYPb.d.ts} +4 -1
  77. package/package.json +1 -1
  78. package/dist/chunk-7FSLD7Y4.js +0 -10
  79. package/dist/executeRoute-Bob9mV8C.d.ts +0 -69
@@ -1,26 +1,23 @@
1
+ import { waitForTransaction } from './chunk-DU3RX43W.js';
2
+ import { getEncodeObjectFromCosmosMessage, getCosmosGasAmountForMessage, getEncodeObjectFromCosmosMessageInjective } from './chunk-TV2XPAIF.js';
3
+ import { getEVMGasAmountForMessage } from './chunk-GV2QOWB4.js';
1
4
  import { BigNumber } from './chunk-VQ5SIQWU.js';
2
5
  import { GAS_STATION_CHAIN_IDS } from './chunk-SWYON2RG.js';
3
- import { getSigningStargateClient, getRpcEndpointForChain, accountParser } from './chunk-MB5ENUER.js';
6
+ import { getSigningStargateClient, getRpcEndpointForChain, accountParser } from './chunk-5QPGL2BH.js';
4
7
  import { chains, findFirstWorkingEndpoint, getIsEthermint, getIsInitia } from './chunk-36MCR5DZ.js';
5
- import { MsgDepositForBurn, MsgDepositForBurnWithCaller, MsgExecute, MsgInitiateTokenDeposit, BaseVestingAccount, Timestamp, toTimestamp, Period, fromTimestamp, isSet, fromJsonTimestamp } from './chunk-TD63P2AG.js';
6
- import { messages } from './chunk-7FSLD7Y4.js';
7
- import { submitTransaction } from './chunk-7P6AOFMX.js';
8
- import { trackTransaction } from './chunk-BCN2WD5Q.js';
9
- import { transactionStatus } from './chunk-2NYWLY5S.js';
10
- import { venues } from './chunk-RL5AVCSG.js';
11
- import { ClientState, balances } from './chunk-EAUM5JYS.js';
12
- import { ApiState, wait, createRequestClient, toCamel } from './chunk-SOGMQT4H.js';
8
+ import { messages } from './chunk-25FJ6EBA.js';
9
+ import { submit } from './chunk-X67P5URV.js';
10
+ import { submitTransaction } from './chunk-CRTTBUO4.js';
11
+ import { venues } from './chunk-XXJUDZKJ.js';
12
+ import { ClientState, balances } from './chunk-NWC6BSNB.js';
13
+ import { ApiState, wait, createRequestClient, toCamel } from './chunk-DV3I2S3T.js';
13
14
  import { PublicKey, Transaction, Connection, LAMPORTS_PER_SOL } from '@solana/web3.js';
14
15
  import { bech32m, bech32 } from 'bech32';
15
16
  import { StargateClient, GasPrice, calculateFee } from '@cosmjs/stargate';
16
17
  import { TxRaw } from 'cosmjs-types/cosmos/tx/v1beta1/tx.js';
17
18
  import { isOfflineDirectSigner, makeAuthInfoBytes, makeSignDoc, encodePubkey } from '@cosmjs/proto-signing';
18
- import { fromBase64, toUtf8, toBase64 } from '@cosmjs/encoding';
19
- import { ChainRestTendermintApi, MsgTransfer as MsgTransfer$1, MsgExecuteContractCompat, createTransactionWithSigners } from '@injectivelabs/sdk-ts';
20
- import { MsgSend } from 'cosmjs-types/cosmos/bank/v1beta1/tx.js';
21
- import { MsgExecuteContract } from 'cosmjs-types/cosmwasm/wasm/v1/tx.js';
22
- import { MsgTransfer } from 'cosmjs-types/ibc/applications/transfer/v1/tx.js';
23
- import _m0 from 'protobufjs/minimal.js';
19
+ import { fromBase64, toBase64 } from '@cosmjs/encoding';
20
+ import { ChainRestTendermintApi, createTransactionWithSigners } from '@injectivelabs/sdk-ts';
24
21
  import { BigNumberInBase, DEFAULT_BLOCK_TIMEOUT_HEIGHT, DEFAULT_STD_FEE } from '@injectivelabs/utils';
25
22
  import { pubkeyType as pubkeyType$1, makeSignDoc as makeSignDoc$1, encodeSecp256k1Pubkey } from '@cosmjs/amino';
26
23
  import { PubKey } from 'cosmjs-types/cosmos/crypto/secp256k1/keys.js';
@@ -100,268 +97,6 @@ var getAccountNumberAndSequenceFromDymension = async (address, chainId) => {
100
97
  sequence
101
98
  };
102
99
  };
103
- function createBaseClawbackVestingAccount() {
104
- return {
105
- baseVestingAccount: void 0,
106
- funderAddress: "",
107
- startTime: /* @__PURE__ */ new Date(),
108
- lockupPeriods: [],
109
- vestingPeriods: []
110
- };
111
- }
112
- var ClawbackVestingAccount = {
113
- typeUrl: "/evmos.vesting.v2.ClawbackVestingAccount",
114
- encode(message, writer = _m0.Writer.create()) {
115
- if (message.baseVestingAccount !== void 0) {
116
- BaseVestingAccount.encode(message.baseVestingAccount, writer.uint32(10).fork()).ldelim();
117
- }
118
- if (message.funderAddress !== "") {
119
- writer.uint32(18).string(message.funderAddress);
120
- }
121
- if (message.startTime !== void 0) {
122
- Timestamp.encode(toTimestamp(message.startTime), writer.uint32(26).fork()).ldelim();
123
- }
124
- for (const v of message.lockupPeriods) {
125
- Period.encode(v, writer.uint32(34).fork()).ldelim();
126
- }
127
- for (const v of message.vestingPeriods) {
128
- Period.encode(v, writer.uint32(42).fork()).ldelim();
129
- }
130
- return writer;
131
- },
132
- decode(input, length) {
133
- const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
134
- let end = length === void 0 ? reader.len : reader.pos + length;
135
- const message = createBaseClawbackVestingAccount();
136
- while (reader.pos < end) {
137
- const tag = reader.uint32();
138
- switch (tag >>> 3) {
139
- case 1:
140
- message.baseVestingAccount = BaseVestingAccount.decode(reader, reader.uint32());
141
- break;
142
- case 2:
143
- message.funderAddress = reader.string();
144
- break;
145
- case 3:
146
- message.startTime = fromTimestamp(Timestamp.decode(reader, reader.uint32()));
147
- break;
148
- case 4:
149
- message.lockupPeriods.push(Period.decode(reader, reader.uint32()));
150
- break;
151
- case 5:
152
- message.vestingPeriods.push(Period.decode(reader, reader.uint32()));
153
- break;
154
- default:
155
- reader.skipType(tag & 7);
156
- break;
157
- }
158
- }
159
- return message;
160
- },
161
- fromJSON(object) {
162
- return {
163
- baseVestingAccount: isSet(object.baseVestingAccount) ? BaseVestingAccount.fromJSON(object.baseVestingAccount) : void 0,
164
- funderAddress: isSet(object.funderAddress) ? String(object.funderAddress) : "",
165
- startTime: isSet(object.startTime) ? fromJsonTimestamp(object.startTime) : void 0,
166
- lockupPeriods: Array.isArray(object?.lockupPeriods) ? object.lockupPeriods.map((e) => Period.fromJSON(e)) : [],
167
- vestingPeriods: Array.isArray(object?.vestingPeriods) ? object.vestingPeriods.map((e) => Period.fromJSON(e)) : []
168
- };
169
- },
170
- toJSON(message) {
171
- const obj = {};
172
- message.baseVestingAccount !== void 0 && (obj.baseVestingAccount = message.baseVestingAccount ? BaseVestingAccount.toJSON(message.baseVestingAccount) : void 0);
173
- message.funderAddress !== void 0 && (obj.funderAddress = message.funderAddress);
174
- message.startTime !== void 0 && (obj.startTime = message.startTime.toISOString());
175
- if (message.lockupPeriods) {
176
- obj.lockupPeriods = message.lockupPeriods.map((e) => e ? Period.toJSON(e) : void 0);
177
- } else {
178
- obj.lockupPeriods = [];
179
- }
180
- if (message.vestingPeriods) {
181
- obj.vestingPeriods = message.vestingPeriods.map((e) => e ? Period.toJSON(e) : void 0);
182
- } else {
183
- obj.vestingPeriods = [];
184
- }
185
- return obj;
186
- },
187
- fromPartial(object) {
188
- const message = createBaseClawbackVestingAccount();
189
- message.baseVestingAccount = object.baseVestingAccount !== void 0 && object.baseVestingAccount !== null ? BaseVestingAccount.fromPartial(object.baseVestingAccount) : void 0;
190
- message.funderAddress = object.funderAddress ?? "";
191
- message.startTime = object.startTime ?? void 0;
192
- message.lockupPeriods = object.lockupPeriods?.map((e) => Period.fromPartial(e)) || [];
193
- message.vestingPeriods = object.vestingPeriods?.map((e) => Period.fromPartial(e)) || [];
194
- return message;
195
- },
196
- fromAmino(object) {
197
- const message = createBaseClawbackVestingAccount();
198
- if (object.base_vesting_account !== void 0 && object.base_vesting_account !== null) {
199
- message.baseVestingAccount = BaseVestingAccount.fromAmino(object.base_vesting_account);
200
- }
201
- if (object.funder_address !== void 0 && object.funder_address !== null) {
202
- message.funderAddress = object.funder_address;
203
- }
204
- if (object.start_time !== void 0 && object.start_time !== null) {
205
- message.startTime = fromTimestamp(Timestamp.fromAmino(object.start_time));
206
- }
207
- message.lockupPeriods = object.lockup_periods?.map((e) => Period.fromAmino(e)) || [];
208
- message.vestingPeriods = object.vesting_periods?.map((e) => Period.fromAmino(e)) || [];
209
- return message;
210
- },
211
- toAmino(message) {
212
- const obj = {};
213
- obj.base_vesting_account = message.baseVestingAccount ? BaseVestingAccount.toAmino(message.baseVestingAccount) : void 0;
214
- obj.funder_address = message.funderAddress === "" ? void 0 : message.funderAddress;
215
- obj.start_time = message.startTime ? Timestamp.toAmino(toTimestamp(message.startTime)) : void 0;
216
- if (message.lockupPeriods) {
217
- obj.lockup_periods = message.lockupPeriods.map((e) => e ? Period.toAmino(e) : void 0);
218
- } else {
219
- obj.lockup_periods = message.lockupPeriods;
220
- }
221
- if (message.vestingPeriods) {
222
- obj.vesting_periods = message.vestingPeriods.map((e) => e ? Period.toAmino(e) : void 0);
223
- } else {
224
- obj.vesting_periods = message.vestingPeriods;
225
- }
226
- return obj;
227
- },
228
- fromAminoMsg(object) {
229
- return ClawbackVestingAccount.fromAmino(object.value);
230
- },
231
- toAminoMsg(message) {
232
- return {
233
- type: "vesting/ClawbackVestingAccount",
234
- value: ClawbackVestingAccount.toAmino(message)
235
- };
236
- },
237
- fromProtoMsg(message) {
238
- return ClawbackVestingAccount.decode(message.value);
239
- },
240
- toProto(message) {
241
- return ClawbackVestingAccount.encode(message).finish();
242
- },
243
- toProtoMsg(message) {
244
- return {
245
- typeUrl: "/evmos.vesting.v2.ClawbackVestingAccount",
246
- value: ClawbackVestingAccount.encode(message).finish()
247
- };
248
- }
249
- };
250
-
251
- // src/private-functions/cosmos/getEncodeObjectFromCosmosMessage.ts
252
- function getEncodeObjectFromCosmosMessage(message) {
253
- const msgJson = JSON.parse(message.msg ?? "");
254
- if (message.msgTypeUrl === "/ibc.applications.transfer.v1.MsgTransfer") {
255
- return {
256
- typeUrl: "/ibc.applications.transfer.v1.MsgTransfer",
257
- value: MsgTransfer.fromJSON({
258
- sourcePort: msgJson.source_port,
259
- sourceChannel: msgJson.source_channel,
260
- token: msgJson.token,
261
- sender: msgJson.sender,
262
- receiver: msgJson.receiver,
263
- timeoutHeight: msgJson.timeout_height,
264
- timeoutTimestamp: msgJson.timeout_timestamp,
265
- memo: msgJson.memo
266
- })
267
- };
268
- }
269
- if (message.msgTypeUrl === "/cosmwasm.wasm.v1.MsgExecuteContract") {
270
- return {
271
- typeUrl: message.msgTypeUrl,
272
- value: MsgExecuteContract.fromPartial({
273
- sender: msgJson.sender,
274
- contract: msgJson.contract,
275
- msg: toUtf8(JSON.stringify(msgJson.msg)),
276
- funds: msgJson.funds
277
- })
278
- };
279
- }
280
- if (message.msgTypeUrl === "/cosmos.bank.v1beta1.MsgSend") {
281
- return {
282
- typeUrl: message.msgTypeUrl,
283
- value: MsgSend.fromPartial({
284
- fromAddress: msgJson.from_address,
285
- toAddress: msgJson.to_address,
286
- amount: msgJson.amount
287
- })
288
- };
289
- }
290
- if (message.msgTypeUrl === "/circle.cctp.v1.MsgDepositForBurn") {
291
- return {
292
- typeUrl: message.msgTypeUrl,
293
- value: MsgDepositForBurn.fromAmino(msgJson)
294
- };
295
- }
296
- if (message.msgTypeUrl === "/circle.cctp.v1.MsgDepositForBurnWithCaller") {
297
- return {
298
- typeUrl: message.msgTypeUrl,
299
- value: MsgDepositForBurnWithCaller.fromAmino(msgJson)
300
- };
301
- }
302
- if (message.msgTypeUrl === "/initia.move.v1.MsgExecute") {
303
- return {
304
- typeUrl: message.msgTypeUrl,
305
- value: MsgExecute.fromPartial({
306
- sender: msgJson.sender,
307
- moduleAddress: msgJson.module_address,
308
- moduleName: msgJson.module_name,
309
- functionName: msgJson.function_name,
310
- args: msgJson.args
311
- })
312
- };
313
- }
314
- if (message.msgTypeUrl === "/opinit.ophost.v1.MsgInitiateTokenDeposit") {
315
- return {
316
- typeUrl: message.msgTypeUrl,
317
- value: MsgInitiateTokenDeposit.fromPartial({
318
- sender: msgJson.sender,
319
- to: msgJson.to,
320
- amount: msgJson.amount,
321
- bridgeId: msgJson.bridge_id
322
- })
323
- };
324
- }
325
- if (message.msgTypeUrl === "/evmos.vesting.v2.ClawbackVestingAccount") {
326
- return {
327
- typeUrl: message.msgTypeUrl,
328
- value: ClawbackVestingAccount.fromPartial({
329
- baseVestingAccount: msgJson.base_vesting_account,
330
- funderAddress: msgJson.funder_address,
331
- lockupPeriods: msgJson.lockup_periods,
332
- startTime: msgJson.start_time,
333
- vestingPeriods: msgJson.vesting_periods
334
- })
335
- };
336
- }
337
- return {
338
- typeUrl: message.msgTypeUrl ?? "",
339
- value: msgJson
340
- };
341
- }
342
- function getEncodeObjectFromCosmosMessageInjective(message) {
343
- const msgJson = JSON.parse(message.msg ?? "");
344
- if (message.msgTypeUrl === "/ibc.applications.transfer.v1.MsgTransfer") {
345
- return MsgTransfer$1.fromJSON({
346
- port: msgJson.source_port,
347
- channelId: msgJson.source_channel,
348
- amount: msgJson.token,
349
- sender: msgJson.sender,
350
- receiver: msgJson.receiver,
351
- timeout: msgJson.timeout_timestamp,
352
- memo: msgJson.memo
353
- });
354
- }
355
- if (message.msgTypeUrl === "/cosmwasm.wasm.v1.MsgExecuteContract") {
356
- return MsgExecuteContractCompat.fromJSON({
357
- sender: msgJson.sender,
358
- contractAddress: msgJson.contract,
359
- msg: msgJson.msg,
360
- funds: msgJson.funds
361
- });
362
- }
363
- throw new Error("Unsupported message type");
364
- }
365
100
  function createTransaction({
366
101
  chainId,
367
102
  message,
@@ -680,10 +415,14 @@ var executeCosmosTransaction = async ({
680
415
  chainId
681
416
  });
682
417
  const txBytes = TxRaw.encode(rawTx).finish();
683
- const txResponse = await stargateClient.broadcastTx(txBytes);
418
+ const rawTxBase64 = Buffer.from(txBytes).toString("base64");
419
+ const txResponse = await submit({
420
+ chainId,
421
+ tx: rawTxBase64
422
+ });
684
423
  return {
685
424
  chainId: tx?.cosmosTx?.chainId ?? "",
686
- txHash: txResponse.transactionHash
425
+ txHash: txResponse?.txHash ?? ""
687
426
  };
688
427
  };
689
428
  function createAbi(abi) {
@@ -1047,28 +786,6 @@ var executeSvmTransaction = async (tx, options) => {
1047
786
  }
1048
787
  }
1049
788
  };
1050
- var DEFAULT_GAS_MULTIPLIER = 1.5;
1051
- async function getCosmosGasAmountForMessage(client, signerAddress, chainId, messages2, encodedMsgs, multiplier = DEFAULT_GAS_MULTIPLIER) {
1052
- if (!messages2 && !encodedMsgs) {
1053
- throw new Error("Either message or encodedMsg must be provided");
1054
- }
1055
- const _encodedMsgs = messages2?.map((message) => getEncodeObjectFromCosmosMessage(message));
1056
- encodedMsgs = encodedMsgs || _encodedMsgs;
1057
- if (!encodedMsgs) {
1058
- throw new Error("Either message or encodedMsg must be provided");
1059
- }
1060
- if (chainId.includes("evmos") || chainId.includes("injective") || chainId.includes("dymension") || process?.env.NODE_ENV === "test") {
1061
- if (messages2?.find((i) => i.msgTypeUrl === "/cosmwasm.wasm.v1.MsgExecuteContract")) {
1062
- return "2400000";
1063
- }
1064
- return "280000";
1065
- }
1066
- const estimatedGas = await client.simulate(signerAddress, encodedMsgs, "");
1067
- const estimatedGasWithBuffer = estimatedGas * multiplier;
1068
- return Math.ceil(estimatedGasWithBuffer).toFixed(0);
1069
- }
1070
-
1071
- // src/private-functions/cosmos/validateCosmosGasBalance.ts
1072
789
  var validateCosmosGasBalance = async ({
1073
790
  chainId,
1074
791
  signerAddress,
@@ -1301,27 +1018,6 @@ var validateEvmTokenApproval = async ({
1301
1018
  }
1302
1019
  }
1303
1020
  };
1304
- async function getEVMGasAmountForMessage(signer, tx, getFallbackGasAmount) {
1305
- const { to, data, value } = tx;
1306
- if (!signer.account) throw new Error("estimateGasForEvmTx: No account found");
1307
- const extendedSigner = signer.extend(publicActions);
1308
- const fee = await extendedSigner.estimateFeesPerGas();
1309
- try {
1310
- const gasAmount = await extendedSigner.estimateGas({
1311
- account: signer.account,
1312
- to,
1313
- data: `0x${data}`,
1314
- value: value === "" ? void 0 : BigInt(value ?? "")
1315
- });
1316
- return gasAmount * fee.maxFeePerGas;
1317
- } catch (error) {
1318
- const fallbackGasAmount = await getFallbackGasAmount?.(tx.chainId ?? "", "evm" /* Evm */);
1319
- if (fallbackGasAmount) {
1320
- return BigInt(fallbackGasAmount) * fee.maxFeePerGas;
1321
- }
1322
- throw error;
1323
- }
1324
- }
1325
1021
 
1326
1022
  // src/private-functions/evm/validateEvmGasBalance.ts
1327
1023
  var validateEvmGasBalance = async ({
@@ -1570,35 +1266,6 @@ var validateGasBalances = async ({
1570
1266
  ClientState.validateGasResults = validateResult;
1571
1267
  };
1572
1268
 
1573
- // src/private-functions/waitForTransaction.ts
1574
- var waitForTransaction = async ({
1575
- chainId,
1576
- txHash,
1577
- onTransactionTracked
1578
- }) => {
1579
- const { explorerLink } = await trackTransaction({
1580
- chainId,
1581
- txHash
1582
- });
1583
- await onTransactionTracked?.({ txHash, chainId, explorerLink });
1584
- while (true) {
1585
- const txStatusResponse = await transactionStatus({
1586
- chainId,
1587
- txHash
1588
- });
1589
- if (txStatusResponse.state === "STATE_COMPLETED_SUCCESS") {
1590
- return txStatusResponse;
1591
- }
1592
- if (txStatusResponse.state === "STATE_COMPLETED_ERROR") {
1593
- throw new Error(`${txStatusResponse.error?.type}: ${txStatusResponse.error?.message}`);
1594
- }
1595
- if (txStatusResponse.state === "STATE_ABANDONED") {
1596
- throw new Error("Tracking for the transaction has been abandoned");
1597
- }
1598
- await wait(1e3);
1599
- }
1600
- };
1601
-
1602
1269
  // src/private-functions/executeTransactions.ts
1603
1270
  var executeTransactions = async (options) => {
1604
1271
  const {
@@ -1,4 +1,4 @@
1
- import { pollingApi } from './chunk-SOGMQT4H.js';
1
+ import { pollingApi } from './chunk-DV3I2S3T.js';
2
2
 
3
3
  // src/api/postTransactionStatus.ts
4
4
  var transactionStatus = pollingApi({
@@ -1,5 +1,5 @@
1
- import { transformAssetsMap } from './chunk-EAUM5JYS.js';
2
- import { api } from './chunk-SOGMQT4H.js';
1
+ import { transformAssetsMap } from './chunk-NWC6BSNB.js';
2
+ import { api } from './chunk-DV3I2S3T.js';
3
3
 
4
4
  // src/api/postAssetsFromSource.ts
5
5
  var assetsFromSource = api({
@@ -1,4 +1,4 @@
1
- import { ApiState, createRequestClient } from './chunk-SOGMQT4H.js';
1
+ import { ApiState, createRequestClient } from './chunk-DV3I2S3T.js';
2
2
 
3
3
  // src/public-functions/setApiOptions.ts
4
4
  var setApiOptions = (options = {}) => {
@@ -1,4 +1,4 @@
1
- import { api } from './chunk-SOGMQT4H.js';
1
+ import { api } from './chunk-DV3I2S3T.js';
2
2
 
3
3
  // src/api/postIbcOriginAssets.ts
4
4
  var ibcOriginAssets = api({
@@ -1,4 +1,4 @@
1
- import { pollingApi } from './chunk-SOGMQT4H.js';
1
+ import { pollingApi } from './chunk-DV3I2S3T.js';
2
2
 
3
3
  // src/api/postTrackTransaction.ts
4
4
  var trackTransaction = pollingApi({