@skip-go/client 0.4.5 → 0.5.1
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/chunk-6FNC3XMI.js +45 -0
- package/dist/chunk-IEAKY5XG.js +1872 -0
- package/dist/chunk-JRIEAGIQ.js +10 -0
- package/dist/chunk-TUX4SN3U.js +3996 -0
- package/dist/index.d.ts +307 -0
- package/dist/index.js +4994 -0
- package/dist/parser.d.ts +1 -0
- package/dist/parser.js +11 -0
- package/dist/shared-CvoSvr3u.d.ts +947 -0
- package/dist/transactions.d.ts +11 -0
- package/dist/transactions.js +23 -0
- package/dist/types.d.ts +565 -0
- package/dist/types.js +639 -0
- package/package.json +1 -1
package/dist/index.js
ADDED
|
@@ -0,0 +1,4994 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkJRIEAGIQ_js = require('./chunk-JRIEAGIQ.js');
|
|
4
|
+
var chunkTUX4SN3U_js = require('./chunk-TUX4SN3U.js');
|
|
5
|
+
var chunkIEAKY5XG_js = require('./chunk-IEAKY5XG.js');
|
|
6
|
+
var chunk6FNC3XMI_js = require('./chunk-6FNC3XMI.js');
|
|
7
|
+
var amino = require('@cosmjs/amino');
|
|
8
|
+
var cosmwasmStargate = require('@cosmjs/cosmwasm-stargate');
|
|
9
|
+
var encoding = require('@cosmjs/encoding');
|
|
10
|
+
var math = require('@cosmjs/math');
|
|
11
|
+
var protoSigning = require('@cosmjs/proto-signing');
|
|
12
|
+
require('cosmjs-types/cosmos/crypto/multisig/keys');
|
|
13
|
+
var keys = require('cosmjs-types/cosmos/crypto/secp256k1/keys');
|
|
14
|
+
var any = require('cosmjs-types/google/protobuf/any');
|
|
15
|
+
var stargate = require('@cosmjs/stargate');
|
|
16
|
+
var rest = require('@injectivelabs/sdk-ts/dist/cjs/client/chain/rest');
|
|
17
|
+
var utils = require('@injectivelabs/utils');
|
|
18
|
+
var axios2 = require('axios');
|
|
19
|
+
var signing = require('cosmjs-types/cosmos/tx/signing/v1beta1/signing');
|
|
20
|
+
var tx$1 = require('cosmjs-types/cosmos/tx/v1beta1/tx');
|
|
21
|
+
var tx = require('cosmjs-types/cosmwasm/wasm/v1/tx');
|
|
22
|
+
var viem = require('viem');
|
|
23
|
+
var chainRegistry = require('chain-registry');
|
|
24
|
+
var initiaRegistry = require('@initia/initia-registry');
|
|
25
|
+
var _m08 = require('protobufjs/minimal');
|
|
26
|
+
var coreProtoTs = require('@injectivelabs/core-proto-ts');
|
|
27
|
+
var tx$2 = require('@injectivelabs/sdk-ts/dist/cjs/core/modules/tx/utils/tx');
|
|
28
|
+
var keccak256 = require('keccak256');
|
|
29
|
+
var web3_js = require('@solana/web3.js');
|
|
30
|
+
|
|
31
|
+
function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
|
|
32
|
+
|
|
33
|
+
function _interopNamespace(e) {
|
|
34
|
+
if (e && e.__esModule) return e;
|
|
35
|
+
var n = Object.create(null);
|
|
36
|
+
if (e) {
|
|
37
|
+
Object.keys(e).forEach(function (k) {
|
|
38
|
+
if (k !== 'default') {
|
|
39
|
+
var d = Object.getOwnPropertyDescriptor(e, k);
|
|
40
|
+
Object.defineProperty(n, k, d.get ? d : {
|
|
41
|
+
enumerable: true,
|
|
42
|
+
get: function () { return e[k]; }
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
n.default = e;
|
|
48
|
+
return Object.freeze(n);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
var axios2__default = /*#__PURE__*/_interopDefault(axios2);
|
|
52
|
+
var chainRegistry__namespace = /*#__PURE__*/_interopNamespace(chainRegistry);
|
|
53
|
+
var initiaRegistry__namespace = /*#__PURE__*/_interopNamespace(initiaRegistry);
|
|
54
|
+
var _m08__namespace = /*#__PURE__*/_interopNamespace(_m08);
|
|
55
|
+
var keccak256__default = /*#__PURE__*/_interopDefault(keccak256);
|
|
56
|
+
|
|
57
|
+
function isEthSecp256k1Pubkey(pubkey) {
|
|
58
|
+
return pubkey.type === "ethermint/PubKeyEthSecp256k1";
|
|
59
|
+
}
|
|
60
|
+
var pubkeyType = chunk6FNC3XMI_js.__spreadValues({
|
|
61
|
+
ethsecp256k1: "ethermint/PubKeyEthSecp256k1"
|
|
62
|
+
}, amino.pubkeyType);
|
|
63
|
+
|
|
64
|
+
// src/amino/encoding.ts
|
|
65
|
+
function encodeEthSecp256k1Pubkey(pubkey) {
|
|
66
|
+
if (pubkey.length !== 33 || pubkey[0] !== 2 && pubkey[0] !== 3) {
|
|
67
|
+
throw new Error(
|
|
68
|
+
"Public key must be compressed secp256k1, i.e. 33 bytes starting with 0x02 or 0x03"
|
|
69
|
+
);
|
|
70
|
+
}
|
|
71
|
+
return {
|
|
72
|
+
type: pubkeyType.ethsecp256k1,
|
|
73
|
+
value: encoding.toBase64(pubkey)
|
|
74
|
+
};
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
// src/proto-signing/pubkey.ts
|
|
78
|
+
function makePubkeyAnyFromAccount(account, chainId) {
|
|
79
|
+
const algo = `${account.algo}`;
|
|
80
|
+
const isEthSecp256k1 = algo === "eth_secp256k1" || algo === "ethsecp256k1";
|
|
81
|
+
const pubkey = isEthSecp256k1 ? encodeEthSecp256k1Pubkey(account.pubkey) : amino.encodeSecp256k1Pubkey(account.pubkey);
|
|
82
|
+
const pubkeyAny = encodePubkeyToAny(pubkey, chainId);
|
|
83
|
+
return pubkeyAny;
|
|
84
|
+
}
|
|
85
|
+
function encodePubkeyToAny(pubkey, chainId) {
|
|
86
|
+
if (isEthSecp256k1Pubkey(pubkey)) {
|
|
87
|
+
const pubkeyProto = keys.PubKey.fromPartial({
|
|
88
|
+
key: encoding.fromBase64(pubkey.value)
|
|
89
|
+
});
|
|
90
|
+
let typeUrl = "";
|
|
91
|
+
if (chainId == null ? void 0 : chainId.includes("injective")) {
|
|
92
|
+
typeUrl = "/injective.crypto.v1beta1.ethsecp256k1.PubKey";
|
|
93
|
+
} else {
|
|
94
|
+
typeUrl = "/ethermint.crypto.v1.ethsecp256k1.PubKey";
|
|
95
|
+
}
|
|
96
|
+
return any.Any.fromPartial({
|
|
97
|
+
typeUrl,
|
|
98
|
+
value: Uint8Array.from(keys.PubKey.encode(pubkeyProto).finish())
|
|
99
|
+
});
|
|
100
|
+
} else {
|
|
101
|
+
return protoSigning.encodePubkey(pubkey);
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
var DYDX_CHAIN = {
|
|
105
|
+
$schema: "../chain.schema.json",
|
|
106
|
+
chain_name: "dydx",
|
|
107
|
+
status: "live",
|
|
108
|
+
website: "https://dydx.exchange/",
|
|
109
|
+
network_type: "mainnet",
|
|
110
|
+
pretty_name: "dYdX Protocol",
|
|
111
|
+
chain_id: "dydx-mainnet-1",
|
|
112
|
+
bech32_prefix: "dydx",
|
|
113
|
+
daemon_name: "dydxprotocold",
|
|
114
|
+
node_home: "$HOME/.dydxprotocol",
|
|
115
|
+
key_algos: ["secp256k1"],
|
|
116
|
+
slip44: 118,
|
|
117
|
+
fees: {
|
|
118
|
+
fee_tokens: [
|
|
119
|
+
{
|
|
120
|
+
denom: "adydx",
|
|
121
|
+
fixed_min_gas_price: 125e8,
|
|
122
|
+
low_gas_price: 125e8,
|
|
123
|
+
average_gas_price: 125e8,
|
|
124
|
+
high_gas_price: 2e10
|
|
125
|
+
},
|
|
126
|
+
{
|
|
127
|
+
denom: "ibc/8E27BA2D5493AF5636760E354E46004562C46AB7EC0CC4C1CA14E9E20E2545B5",
|
|
128
|
+
fixed_min_gas_price: 0.025,
|
|
129
|
+
low_gas_price: 0.025,
|
|
130
|
+
average_gas_price: 0.025,
|
|
131
|
+
high_gas_price: 0.03
|
|
132
|
+
}
|
|
133
|
+
]
|
|
134
|
+
},
|
|
135
|
+
staking: {
|
|
136
|
+
staking_tokens: [
|
|
137
|
+
{
|
|
138
|
+
denom: "adydx"
|
|
139
|
+
}
|
|
140
|
+
]
|
|
141
|
+
},
|
|
142
|
+
codebase: {
|
|
143
|
+
git_repo: "https://github.com/dydxprotocol/v4-chain/",
|
|
144
|
+
recommended_version: "v1.0.0",
|
|
145
|
+
compatible_versions: ["v1.0.0"],
|
|
146
|
+
cosmos_sdk_version: "v0.47.4",
|
|
147
|
+
cosmwasm_enabled: false,
|
|
148
|
+
genesis: {
|
|
149
|
+
genesis_url: "https://raw.githubusercontent.com/dydxopsdao/networks/main/dydx-mainnet-1/genesis.json"
|
|
150
|
+
},
|
|
151
|
+
versions: [
|
|
152
|
+
{
|
|
153
|
+
name: "v1",
|
|
154
|
+
recommended_version: "v1.0.0",
|
|
155
|
+
compatible_versions: ["v1.0.0"],
|
|
156
|
+
cosmos_sdk_version: "v0.47.4"
|
|
157
|
+
}
|
|
158
|
+
]
|
|
159
|
+
},
|
|
160
|
+
logo_URIs: {
|
|
161
|
+
png: "https://raw.githubusercontent.com/cosmos/chain-registry/master/dydx/images/dydx.png",
|
|
162
|
+
svg: "https://raw.githubusercontent.com/cosmos/chain-registry/master/dydx/images/dydx.svg"
|
|
163
|
+
},
|
|
164
|
+
peers: {
|
|
165
|
+
seeds: [
|
|
166
|
+
{
|
|
167
|
+
id: "20e1000e88125698264454a884812746c2eb4807",
|
|
168
|
+
address: "seeds.lavenderfive.com:23856",
|
|
169
|
+
provider: "Lavender.Five Nodes \u{1F41D}"
|
|
170
|
+
},
|
|
171
|
+
{
|
|
172
|
+
id: "ebc272824924ea1a27ea3183dd0b9ba713494f83",
|
|
173
|
+
address: "dydx-mainnet-seed.autostake.com:27366",
|
|
174
|
+
provider: "AutoStake \u{1F6E1}\uFE0F Slash Protected"
|
|
175
|
+
},
|
|
176
|
+
{
|
|
177
|
+
id: "65b740ee326c9260c30af1f044e9cda63c73f7c1",
|
|
178
|
+
address: "seeds.kingnodes.net:23856",
|
|
179
|
+
provider: "Kingnodes"
|
|
180
|
+
},
|
|
181
|
+
{
|
|
182
|
+
id: "4c30c8a95e26b07b249813b677caab28bf0c54eb",
|
|
183
|
+
address: "rpc.dydx.nodestake.top:666",
|
|
184
|
+
provider: "NodeStake"
|
|
185
|
+
},
|
|
186
|
+
{
|
|
187
|
+
id: "400f3d9e30b69e78a7fb891f60d76fa3c73f0ecc",
|
|
188
|
+
address: "dydx.rpc.kjnodes.com:17059",
|
|
189
|
+
provider: "kjnodes"
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
id: "e1b058e5cfa2b836ddaa496b10911da62dcf182e",
|
|
193
|
+
address: "dydx-seed-de.allnodes.me:26656",
|
|
194
|
+
provider: "Allnodes \u26A1\uFE0F Nodes & Staking"
|
|
195
|
+
},
|
|
196
|
+
{
|
|
197
|
+
id: "e726816f42831689eab9378d5d577f1d06d25716",
|
|
198
|
+
address: "dydx-seed-us.allnodes.me:26656",
|
|
199
|
+
provider: "Allnodes \u26A1\uFE0F Nodes & Staking"
|
|
200
|
+
}
|
|
201
|
+
],
|
|
202
|
+
persistent_peers: [
|
|
203
|
+
{
|
|
204
|
+
id: "ebc272824924ea1a27ea3183dd0b9ba713494f83",
|
|
205
|
+
address: "dydx-mainnet-peer.autostake.com:27366",
|
|
206
|
+
provider: "AutoStake \u{1F6E1}\uFE0F Slash Protected"
|
|
207
|
+
}
|
|
208
|
+
]
|
|
209
|
+
},
|
|
210
|
+
apis: {
|
|
211
|
+
rpc: [
|
|
212
|
+
{
|
|
213
|
+
address: "https://dydx-rpc.lavenderfive.com:443",
|
|
214
|
+
provider: "Lavender.Five Nodes \u{1F41D}"
|
|
215
|
+
},
|
|
216
|
+
{
|
|
217
|
+
address: "https://dydx-mainnet-rpc.autostake.com:443",
|
|
218
|
+
provider: "AutoStake \u{1F6E1}\uFE0F Slash Protected"
|
|
219
|
+
},
|
|
220
|
+
{
|
|
221
|
+
address: "https://rpc-dydx.ecostake.com:443",
|
|
222
|
+
provider: "ecostake"
|
|
223
|
+
},
|
|
224
|
+
{
|
|
225
|
+
address: "https://rpc.dydx.nodestake.top:443",
|
|
226
|
+
provider: "NodeStake"
|
|
227
|
+
},
|
|
228
|
+
{
|
|
229
|
+
address: "https://dydx.rpc.kjnodes.com:443",
|
|
230
|
+
provider: "kjnodes"
|
|
231
|
+
},
|
|
232
|
+
{
|
|
233
|
+
address: "https://dydx-rpc.publicnode.com:443",
|
|
234
|
+
provider: "Allnodes \u26A1\uFE0F Nodes & Staking"
|
|
235
|
+
}
|
|
236
|
+
],
|
|
237
|
+
rest: [
|
|
238
|
+
{
|
|
239
|
+
address: "https://dydx-api.lavenderfive.com:443",
|
|
240
|
+
provider: "Lavender.Five Nodes \u{1F41D}"
|
|
241
|
+
},
|
|
242
|
+
{
|
|
243
|
+
address: "https://dydx-mainnet-lcd.autostake.com:443",
|
|
244
|
+
provider: "AutoStake \u{1F6E1}\uFE0F Slash Protected"
|
|
245
|
+
},
|
|
246
|
+
{
|
|
247
|
+
address: "https://rest-dydx.ecostake.com:443",
|
|
248
|
+
provider: "ecostake"
|
|
249
|
+
},
|
|
250
|
+
{
|
|
251
|
+
address: "https://api.dydx.nodestake.top:443",
|
|
252
|
+
provider: "NodeStake"
|
|
253
|
+
},
|
|
254
|
+
{
|
|
255
|
+
address: "https://dydx.api.kjnodes.com:443",
|
|
256
|
+
provider: "kjnodes"
|
|
257
|
+
},
|
|
258
|
+
{
|
|
259
|
+
address: "https://dydx-rest.publicnode.com",
|
|
260
|
+
provider: "Allnodes \u26A1\uFE0F Nodes & Staking"
|
|
261
|
+
}
|
|
262
|
+
],
|
|
263
|
+
grpc: [
|
|
264
|
+
{
|
|
265
|
+
address: "https://dydx-grpc.lavenderfive.com",
|
|
266
|
+
provider: "Lavender.Five Nodes \u{1F41D}"
|
|
267
|
+
},
|
|
268
|
+
{
|
|
269
|
+
address: "dydx-mainnet-grpc.autostake.com:443",
|
|
270
|
+
provider: "AutoStake \u{1F6E1}\uFE0F Slash Protected"
|
|
271
|
+
},
|
|
272
|
+
{
|
|
273
|
+
address: "https://grpc.dydx.nodestake.top",
|
|
274
|
+
provider: "NodeStake"
|
|
275
|
+
},
|
|
276
|
+
{
|
|
277
|
+
address: "dydx.grpc.kjnodes.com:443",
|
|
278
|
+
provider: "kjnodes"
|
|
279
|
+
},
|
|
280
|
+
{
|
|
281
|
+
address: "dydx-grpc.publicnode.com:443",
|
|
282
|
+
provider: "Allnodes \u26A1\uFE0F Nodes & Staking"
|
|
283
|
+
}
|
|
284
|
+
]
|
|
285
|
+
},
|
|
286
|
+
explorers: [
|
|
287
|
+
{
|
|
288
|
+
kind: "mintscan",
|
|
289
|
+
url: "https://www.mintscan.io/dydx",
|
|
290
|
+
tx_page: "https://www.mintscan.io/dydx/txs/${txHash}",
|
|
291
|
+
account_page: "https://www.mintscan.io/dydx/account/${accountAddress}"
|
|
292
|
+
},
|
|
293
|
+
{
|
|
294
|
+
kind: "NodeStake",
|
|
295
|
+
url: "https://explorer.nodestake.top/dydx/",
|
|
296
|
+
tx_page: "https://explorer.nodestake.top/dydx/txs/${txHash}",
|
|
297
|
+
account_page: "https://explorer.nodestake.top/dydx/account/${accountAddress}"
|
|
298
|
+
}
|
|
299
|
+
],
|
|
300
|
+
images: [
|
|
301
|
+
{
|
|
302
|
+
png: "https://raw.githubusercontent.com/cosmos/chain-registry/master/dydx/images/dydx.png",
|
|
303
|
+
svg: "https://raw.githubusercontent.com/cosmos/chain-registry/master/dydx/images/dydx.svg"
|
|
304
|
+
}
|
|
305
|
+
]
|
|
306
|
+
};
|
|
307
|
+
var CELESTIA_CHAIN = {
|
|
308
|
+
$schema: "../chain.schema.json",
|
|
309
|
+
chain_name: "celestia",
|
|
310
|
+
chain_id: "celestia",
|
|
311
|
+
pretty_name: "Celestia",
|
|
312
|
+
status: "live",
|
|
313
|
+
network_type: "mainnet",
|
|
314
|
+
bech32_prefix: "celestia",
|
|
315
|
+
daemon_name: "celestia-appd",
|
|
316
|
+
node_home: "$HOME/.celestia-app",
|
|
317
|
+
key_algos: ["secp256k1"],
|
|
318
|
+
slip44: 118,
|
|
319
|
+
fees: {
|
|
320
|
+
fee_tokens: [
|
|
321
|
+
{
|
|
322
|
+
denom: "utia",
|
|
323
|
+
fixed_min_gas_price: 0,
|
|
324
|
+
low_gas_price: 0.1,
|
|
325
|
+
average_gas_price: 0.2,
|
|
326
|
+
high_gas_price: 0.4
|
|
327
|
+
}
|
|
328
|
+
]
|
|
329
|
+
},
|
|
330
|
+
codebase: {
|
|
331
|
+
git_repo: "https://github.com/celestiaorg/celestia-app",
|
|
332
|
+
recommended_version: "v1.3.0",
|
|
333
|
+
compatible_versions: ["v1.3.0"],
|
|
334
|
+
genesis: {
|
|
335
|
+
genesis_url: "https://raw.githubusercontent.com/celestiaorg/networks/master/celestia/genesis.json"
|
|
336
|
+
},
|
|
337
|
+
versions: [
|
|
338
|
+
{
|
|
339
|
+
name: "v1.3.0",
|
|
340
|
+
recommended_version: "v1.3.0",
|
|
341
|
+
compatible_versions: ["v1.3.0"]
|
|
342
|
+
}
|
|
343
|
+
]
|
|
344
|
+
},
|
|
345
|
+
peers: {
|
|
346
|
+
seeds: [
|
|
347
|
+
{
|
|
348
|
+
id: "e6116822e1a5e283d8a85d3ec38f4d232274eaf3",
|
|
349
|
+
address: "consensus-full-seed-1.celestia-bootstrap.net:26656",
|
|
350
|
+
provider: "Celestia Foundation"
|
|
351
|
+
},
|
|
352
|
+
{
|
|
353
|
+
id: "cf7ac8b19ff56a9d47c75551bd4864883d1e24b5",
|
|
354
|
+
address: "consensus-full-seed-1.celestia-bootstrap.net:26656",
|
|
355
|
+
provider: "Celestia Foundation"
|
|
356
|
+
}
|
|
357
|
+
]
|
|
358
|
+
},
|
|
359
|
+
apis: {
|
|
360
|
+
rpc: [
|
|
361
|
+
{
|
|
362
|
+
address: "https://public-celestia-rpc.numia.xyz",
|
|
363
|
+
provider: "Numia"
|
|
364
|
+
},
|
|
365
|
+
{
|
|
366
|
+
address: "https://celestia-rpc.mesa.newmetric.xyz",
|
|
367
|
+
provider: "Newmetric"
|
|
368
|
+
},
|
|
369
|
+
{
|
|
370
|
+
address: "https://rpc.lunaroasis.net",
|
|
371
|
+
provider: "Lunar Oasis"
|
|
372
|
+
}
|
|
373
|
+
],
|
|
374
|
+
rest: [
|
|
375
|
+
{
|
|
376
|
+
address: "https://public-celestia-lcd.numia.xyz",
|
|
377
|
+
provider: "Numia"
|
|
378
|
+
},
|
|
379
|
+
{
|
|
380
|
+
address: "https://celestia-rest.mesa.newmetric.xyz",
|
|
381
|
+
provider: "Newmetric"
|
|
382
|
+
},
|
|
383
|
+
{
|
|
384
|
+
address: "https://api.lunaroasis.net",
|
|
385
|
+
provider: "Lunar Oasis"
|
|
386
|
+
}
|
|
387
|
+
]
|
|
388
|
+
},
|
|
389
|
+
explorers: [
|
|
390
|
+
{
|
|
391
|
+
kind: "Mintscan",
|
|
392
|
+
url: "https://mintscan.io/celestia",
|
|
393
|
+
tx_page: "https://mintscan.io/celestia/txs/${txHash}"
|
|
394
|
+
}
|
|
395
|
+
]
|
|
396
|
+
};
|
|
397
|
+
function chains3() {
|
|
398
|
+
const chains4 = chainRegistry__namespace.chains;
|
|
399
|
+
if (chains4.findIndex((chain) => chain.chain_id === "dydx-mainnet-1") === -1) {
|
|
400
|
+
chains4.push(DYDX_CHAIN);
|
|
401
|
+
}
|
|
402
|
+
if (chains4.findIndex((chain) => chain.chain_id === "celestia") === -1) {
|
|
403
|
+
chains4.push(CELESTIA_CHAIN);
|
|
404
|
+
}
|
|
405
|
+
return chains4;
|
|
406
|
+
}
|
|
407
|
+
function initiaChains() {
|
|
408
|
+
const chains4 = initiaRegistry__namespace.chains;
|
|
409
|
+
return chains4;
|
|
410
|
+
}
|
|
411
|
+
function findFirstWorkingEndpoint(endpoints, type) {
|
|
412
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
413
|
+
for (const endpoint of endpoints) {
|
|
414
|
+
try {
|
|
415
|
+
const url = (() => {
|
|
416
|
+
switch (type) {
|
|
417
|
+
case "rpc":
|
|
418
|
+
const rpc = new URL("health", endpoint);
|
|
419
|
+
return rpc.toString();
|
|
420
|
+
case "rest":
|
|
421
|
+
const url2 = new URL(
|
|
422
|
+
"cosmos/base/tendermint/v1beta1/node_info",
|
|
423
|
+
endpoint
|
|
424
|
+
);
|
|
425
|
+
return url2.toString();
|
|
426
|
+
default:
|
|
427
|
+
throw new Error(`Unknown endpoint type: ${type}`);
|
|
428
|
+
}
|
|
429
|
+
})();
|
|
430
|
+
const response = yield fetch(url);
|
|
431
|
+
if (response.ok) {
|
|
432
|
+
return endpoint;
|
|
433
|
+
} else {
|
|
434
|
+
console.error(
|
|
435
|
+
`Error: ${endpoint} responded with status ${response.status}`
|
|
436
|
+
);
|
|
437
|
+
}
|
|
438
|
+
} catch (error) {
|
|
439
|
+
console.error(`Failed to fetch ${endpoint}: ${error.message}`);
|
|
440
|
+
}
|
|
441
|
+
}
|
|
442
|
+
console.error("No working endpoints found.");
|
|
443
|
+
return null;
|
|
444
|
+
});
|
|
445
|
+
}
|
|
446
|
+
|
|
447
|
+
// src/codegen/circle/cctp/v1/tx.registry.ts
|
|
448
|
+
var registry = [["/circle.cctp.v1.MsgAcceptOwner", chunkTUX4SN3U_js.MsgAcceptOwner], ["/circle.cctp.v1.MsgAddRemoteTokenMessenger", chunkTUX4SN3U_js.MsgAddRemoteTokenMessenger], ["/circle.cctp.v1.MsgDepositForBurn", chunkTUX4SN3U_js.MsgDepositForBurn], ["/circle.cctp.v1.MsgDepositForBurnWithCaller", chunkTUX4SN3U_js.MsgDepositForBurnWithCaller], ["/circle.cctp.v1.MsgDisableAttester", chunkTUX4SN3U_js.MsgDisableAttester], ["/circle.cctp.v1.MsgEnableAttester", chunkTUX4SN3U_js.MsgEnableAttester], ["/circle.cctp.v1.MsgLinkTokenPair", chunkTUX4SN3U_js.MsgLinkTokenPair], ["/circle.cctp.v1.MsgPauseBurningAndMinting", chunkTUX4SN3U_js.MsgPauseBurningAndMinting], ["/circle.cctp.v1.MsgPauseSendingAndReceivingMessages", chunkTUX4SN3U_js.MsgPauseSendingAndReceivingMessages], ["/circle.cctp.v1.MsgReceiveMessage", chunkTUX4SN3U_js.MsgReceiveMessage], ["/circle.cctp.v1.MsgRemoveRemoteTokenMessenger", chunkTUX4SN3U_js.MsgRemoveRemoteTokenMessenger], ["/circle.cctp.v1.MsgReplaceDepositForBurn", chunkTUX4SN3U_js.MsgReplaceDepositForBurn], ["/circle.cctp.v1.MsgReplaceMessage", chunkTUX4SN3U_js.MsgReplaceMessage], ["/circle.cctp.v1.MsgSendMessage", chunkTUX4SN3U_js.MsgSendMessage], ["/circle.cctp.v1.MsgSendMessageWithCaller", chunkTUX4SN3U_js.MsgSendMessageWithCaller], ["/circle.cctp.v1.MsgUnlinkTokenPair", chunkTUX4SN3U_js.MsgUnlinkTokenPair], ["/circle.cctp.v1.MsgUnpauseBurningAndMinting", chunkTUX4SN3U_js.MsgUnpauseBurningAndMinting], ["/circle.cctp.v1.MsgUnpauseSendingAndReceivingMessages", chunkTUX4SN3U_js.MsgUnpauseSendingAndReceivingMessages], ["/circle.cctp.v1.MsgUpdateOwner", chunkTUX4SN3U_js.MsgUpdateOwner], ["/circle.cctp.v1.MsgUpdateAttesterManager", chunkTUX4SN3U_js.MsgUpdateAttesterManager], ["/circle.cctp.v1.MsgUpdateTokenController", chunkTUX4SN3U_js.MsgUpdateTokenController], ["/circle.cctp.v1.MsgUpdatePauser", chunkTUX4SN3U_js.MsgUpdatePauser], ["/circle.cctp.v1.MsgUpdateMaxMessageBodySize", chunkTUX4SN3U_js.MsgUpdateMaxMessageBodySize], ["/circle.cctp.v1.MsgSetMaxBurnAmountPerMessage", chunkTUX4SN3U_js.MsgSetMaxBurnAmountPerMessage], ["/circle.cctp.v1.MsgUpdateSignatureThreshold", chunkTUX4SN3U_js.MsgUpdateSignatureThreshold]];
|
|
449
|
+
|
|
450
|
+
// src/codegen/circle/cctp/v1/tx.amino.ts
|
|
451
|
+
var AminoConverter = {
|
|
452
|
+
"/circle.cctp.v1.MsgAcceptOwner": {
|
|
453
|
+
aminoType: "cctp/AcceptOwner",
|
|
454
|
+
toAmino: chunkTUX4SN3U_js.MsgAcceptOwner.toAmino,
|
|
455
|
+
fromAmino: chunkTUX4SN3U_js.MsgAcceptOwner.fromAmino
|
|
456
|
+
},
|
|
457
|
+
"/circle.cctp.v1.MsgAddRemoteTokenMessenger": {
|
|
458
|
+
aminoType: "cctp/AddRemoteTokenMessenger",
|
|
459
|
+
toAmino: chunkTUX4SN3U_js.MsgAddRemoteTokenMessenger.toAmino,
|
|
460
|
+
fromAmino: chunkTUX4SN3U_js.MsgAddRemoteTokenMessenger.fromAmino
|
|
461
|
+
},
|
|
462
|
+
"/circle.cctp.v1.MsgDepositForBurn": {
|
|
463
|
+
aminoType: "cctp/DepositForBurn",
|
|
464
|
+
toAmino: chunkTUX4SN3U_js.MsgDepositForBurn.toAmino,
|
|
465
|
+
fromAmino: chunkTUX4SN3U_js.MsgDepositForBurn.fromAmino
|
|
466
|
+
},
|
|
467
|
+
"/circle.cctp.v1.MsgDepositForBurnWithCaller": {
|
|
468
|
+
aminoType: "cctp/DepositForBurnWithCaller",
|
|
469
|
+
toAmino: chunkTUX4SN3U_js.MsgDepositForBurnWithCaller.toAmino,
|
|
470
|
+
fromAmino: chunkTUX4SN3U_js.MsgDepositForBurnWithCaller.fromAmino
|
|
471
|
+
},
|
|
472
|
+
"/circle.cctp.v1.MsgDisableAttester": {
|
|
473
|
+
aminoType: "cctp/DisableAttester",
|
|
474
|
+
toAmino: chunkTUX4SN3U_js.MsgDisableAttester.toAmino,
|
|
475
|
+
fromAmino: chunkTUX4SN3U_js.MsgDisableAttester.fromAmino
|
|
476
|
+
},
|
|
477
|
+
"/circle.cctp.v1.MsgEnableAttester": {
|
|
478
|
+
aminoType: "cctp/EnableAttester",
|
|
479
|
+
toAmino: chunkTUX4SN3U_js.MsgEnableAttester.toAmino,
|
|
480
|
+
fromAmino: chunkTUX4SN3U_js.MsgEnableAttester.fromAmino
|
|
481
|
+
},
|
|
482
|
+
"/circle.cctp.v1.MsgLinkTokenPair": {
|
|
483
|
+
aminoType: "cctp/LinkTokenPair",
|
|
484
|
+
toAmino: chunkTUX4SN3U_js.MsgLinkTokenPair.toAmino,
|
|
485
|
+
fromAmino: chunkTUX4SN3U_js.MsgLinkTokenPair.fromAmino
|
|
486
|
+
},
|
|
487
|
+
"/circle.cctp.v1.MsgPauseBurningAndMinting": {
|
|
488
|
+
aminoType: "cctp/PauseBurningAndMinting",
|
|
489
|
+
toAmino: chunkTUX4SN3U_js.MsgPauseBurningAndMinting.toAmino,
|
|
490
|
+
fromAmino: chunkTUX4SN3U_js.MsgPauseBurningAndMinting.fromAmino
|
|
491
|
+
},
|
|
492
|
+
"/circle.cctp.v1.MsgPauseSendingAndReceivingMessages": {
|
|
493
|
+
aminoType: "cctp/PauseSendingAndReceivingMessages",
|
|
494
|
+
toAmino: chunkTUX4SN3U_js.MsgPauseSendingAndReceivingMessages.toAmino,
|
|
495
|
+
fromAmino: chunkTUX4SN3U_js.MsgPauseSendingAndReceivingMessages.fromAmino
|
|
496
|
+
},
|
|
497
|
+
"/circle.cctp.v1.MsgReceiveMessage": {
|
|
498
|
+
aminoType: "cctp/ReceiveMessage",
|
|
499
|
+
toAmino: chunkTUX4SN3U_js.MsgReceiveMessage.toAmino,
|
|
500
|
+
fromAmino: chunkTUX4SN3U_js.MsgReceiveMessage.fromAmino
|
|
501
|
+
},
|
|
502
|
+
"/circle.cctp.v1.MsgRemoveRemoteTokenMessenger": {
|
|
503
|
+
aminoType: "cctp/RemoveRemoteTokenMessenger",
|
|
504
|
+
toAmino: chunkTUX4SN3U_js.MsgRemoveRemoteTokenMessenger.toAmino,
|
|
505
|
+
fromAmino: chunkTUX4SN3U_js.MsgRemoveRemoteTokenMessenger.fromAmino
|
|
506
|
+
},
|
|
507
|
+
"/circle.cctp.v1.MsgReplaceDepositForBurn": {
|
|
508
|
+
aminoType: "cctp/ReplaceDepositForBurn",
|
|
509
|
+
toAmino: chunkTUX4SN3U_js.MsgReplaceDepositForBurn.toAmino,
|
|
510
|
+
fromAmino: chunkTUX4SN3U_js.MsgReplaceDepositForBurn.fromAmino
|
|
511
|
+
},
|
|
512
|
+
"/circle.cctp.v1.MsgReplaceMessage": {
|
|
513
|
+
aminoType: "cctp/ReplaceMessage",
|
|
514
|
+
toAmino: chunkTUX4SN3U_js.MsgReplaceMessage.toAmino,
|
|
515
|
+
fromAmino: chunkTUX4SN3U_js.MsgReplaceMessage.fromAmino
|
|
516
|
+
},
|
|
517
|
+
"/circle.cctp.v1.MsgSendMessage": {
|
|
518
|
+
aminoType: "cctp/SendMessage",
|
|
519
|
+
toAmino: chunkTUX4SN3U_js.MsgSendMessage.toAmino,
|
|
520
|
+
fromAmino: chunkTUX4SN3U_js.MsgSendMessage.fromAmino
|
|
521
|
+
},
|
|
522
|
+
"/circle.cctp.v1.MsgSendMessageWithCaller": {
|
|
523
|
+
aminoType: "cctp/SendMessageWithCaller",
|
|
524
|
+
toAmino: chunkTUX4SN3U_js.MsgSendMessageWithCaller.toAmino,
|
|
525
|
+
fromAmino: chunkTUX4SN3U_js.MsgSendMessageWithCaller.fromAmino
|
|
526
|
+
},
|
|
527
|
+
"/circle.cctp.v1.MsgUnlinkTokenPair": {
|
|
528
|
+
aminoType: "cctp/UnlinkTokenPair",
|
|
529
|
+
toAmino: chunkTUX4SN3U_js.MsgUnlinkTokenPair.toAmino,
|
|
530
|
+
fromAmino: chunkTUX4SN3U_js.MsgUnlinkTokenPair.fromAmino
|
|
531
|
+
},
|
|
532
|
+
"/circle.cctp.v1.MsgUnpauseBurningAndMinting": {
|
|
533
|
+
aminoType: "cctp/UnpauseBurningAndMinting",
|
|
534
|
+
toAmino: chunkTUX4SN3U_js.MsgUnpauseBurningAndMinting.toAmino,
|
|
535
|
+
fromAmino: chunkTUX4SN3U_js.MsgUnpauseBurningAndMinting.fromAmino
|
|
536
|
+
},
|
|
537
|
+
"/circle.cctp.v1.MsgUnpauseSendingAndReceivingMessages": {
|
|
538
|
+
aminoType: "cctp/UnpauseSendingAndReceivingMessages",
|
|
539
|
+
toAmino: chunkTUX4SN3U_js.MsgUnpauseSendingAndReceivingMessages.toAmino,
|
|
540
|
+
fromAmino: chunkTUX4SN3U_js.MsgUnpauseSendingAndReceivingMessages.fromAmino
|
|
541
|
+
},
|
|
542
|
+
"/circle.cctp.v1.MsgUpdateOwner": {
|
|
543
|
+
aminoType: "cctp/UpdateOwner",
|
|
544
|
+
toAmino: chunkTUX4SN3U_js.MsgUpdateOwner.toAmino,
|
|
545
|
+
fromAmino: chunkTUX4SN3U_js.MsgUpdateOwner.fromAmino
|
|
546
|
+
},
|
|
547
|
+
"/circle.cctp.v1.MsgUpdateAttesterManager": {
|
|
548
|
+
aminoType: "cctp/UpdateAttesterManager",
|
|
549
|
+
toAmino: chunkTUX4SN3U_js.MsgUpdateAttesterManager.toAmino,
|
|
550
|
+
fromAmino: chunkTUX4SN3U_js.MsgUpdateAttesterManager.fromAmino
|
|
551
|
+
},
|
|
552
|
+
"/circle.cctp.v1.MsgUpdateTokenController": {
|
|
553
|
+
aminoType: "cctp/UpdateTokenController",
|
|
554
|
+
toAmino: chunkTUX4SN3U_js.MsgUpdateTokenController.toAmino,
|
|
555
|
+
fromAmino: chunkTUX4SN3U_js.MsgUpdateTokenController.fromAmino
|
|
556
|
+
},
|
|
557
|
+
"/circle.cctp.v1.MsgUpdatePauser": {
|
|
558
|
+
aminoType: "cctp/UpdatePauser",
|
|
559
|
+
toAmino: chunkTUX4SN3U_js.MsgUpdatePauser.toAmino,
|
|
560
|
+
fromAmino: chunkTUX4SN3U_js.MsgUpdatePauser.fromAmino
|
|
561
|
+
},
|
|
562
|
+
"/circle.cctp.v1.MsgUpdateMaxMessageBodySize": {
|
|
563
|
+
aminoType: "cctp/UpdateMaxMessageBodySize",
|
|
564
|
+
toAmino: chunkTUX4SN3U_js.MsgUpdateMaxMessageBodySize.toAmino,
|
|
565
|
+
fromAmino: chunkTUX4SN3U_js.MsgUpdateMaxMessageBodySize.fromAmino
|
|
566
|
+
},
|
|
567
|
+
"/circle.cctp.v1.MsgSetMaxBurnAmountPerMessage": {
|
|
568
|
+
aminoType: "cctp/SetMaxBurnAmountPerMessage",
|
|
569
|
+
toAmino: chunkTUX4SN3U_js.MsgSetMaxBurnAmountPerMessage.toAmino,
|
|
570
|
+
fromAmino: chunkTUX4SN3U_js.MsgSetMaxBurnAmountPerMessage.fromAmino
|
|
571
|
+
},
|
|
572
|
+
"/circle.cctp.v1.MsgUpdateSignatureThreshold": {
|
|
573
|
+
aminoType: "cctp/UpdateSignatureThreshold",
|
|
574
|
+
toAmino: chunkTUX4SN3U_js.MsgUpdateSignatureThreshold.toAmino,
|
|
575
|
+
fromAmino: chunkTUX4SN3U_js.MsgUpdateSignatureThreshold.fromAmino
|
|
576
|
+
}
|
|
577
|
+
};
|
|
578
|
+
|
|
579
|
+
// src/codegen/circle/client.ts
|
|
580
|
+
var circleAminoConverters = chunk6FNC3XMI_js.__spreadValues({}, AminoConverter);
|
|
581
|
+
var circleProtoRegistry = [...registry];
|
|
582
|
+
function createBaseParams() {
|
|
583
|
+
return {
|
|
584
|
+
enableErc20: false,
|
|
585
|
+
enableEvmHook: false
|
|
586
|
+
};
|
|
587
|
+
}
|
|
588
|
+
var Params = {
|
|
589
|
+
typeUrl: "/evmos.erc20.v1.Params",
|
|
590
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
591
|
+
if (message.enableErc20 === true) {
|
|
592
|
+
writer.uint32(8).bool(message.enableErc20);
|
|
593
|
+
}
|
|
594
|
+
if (message.enableEvmHook === true) {
|
|
595
|
+
writer.uint32(16).bool(message.enableEvmHook);
|
|
596
|
+
}
|
|
597
|
+
return writer;
|
|
598
|
+
},
|
|
599
|
+
decode(input, length) {
|
|
600
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
601
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
602
|
+
const message = createBaseParams();
|
|
603
|
+
while (reader.pos < end) {
|
|
604
|
+
const tag = reader.uint32();
|
|
605
|
+
switch (tag >>> 3) {
|
|
606
|
+
case 1:
|
|
607
|
+
message.enableErc20 = reader.bool();
|
|
608
|
+
break;
|
|
609
|
+
case 2:
|
|
610
|
+
message.enableEvmHook = reader.bool();
|
|
611
|
+
break;
|
|
612
|
+
default:
|
|
613
|
+
reader.skipType(tag & 7);
|
|
614
|
+
break;
|
|
615
|
+
}
|
|
616
|
+
}
|
|
617
|
+
return message;
|
|
618
|
+
},
|
|
619
|
+
fromJSON(object) {
|
|
620
|
+
return {
|
|
621
|
+
enableErc20: chunkTUX4SN3U_js.isSet(object.enableErc20) ? Boolean(object.enableErc20) : false,
|
|
622
|
+
enableEvmHook: chunkTUX4SN3U_js.isSet(object.enableEvmHook) ? Boolean(object.enableEvmHook) : false
|
|
623
|
+
};
|
|
624
|
+
},
|
|
625
|
+
toJSON(message) {
|
|
626
|
+
const obj = {};
|
|
627
|
+
message.enableErc20 !== void 0 && (obj.enableErc20 = message.enableErc20);
|
|
628
|
+
message.enableEvmHook !== void 0 && (obj.enableEvmHook = message.enableEvmHook);
|
|
629
|
+
return obj;
|
|
630
|
+
},
|
|
631
|
+
fromPartial(object) {
|
|
632
|
+
var _a, _b;
|
|
633
|
+
const message = createBaseParams();
|
|
634
|
+
message.enableErc20 = (_a = object.enableErc20) != null ? _a : false;
|
|
635
|
+
message.enableEvmHook = (_b = object.enableEvmHook) != null ? _b : false;
|
|
636
|
+
return message;
|
|
637
|
+
},
|
|
638
|
+
fromAmino(object) {
|
|
639
|
+
const message = createBaseParams();
|
|
640
|
+
if (object.enable_erc20 !== void 0 && object.enable_erc20 !== null) {
|
|
641
|
+
message.enableErc20 = object.enable_erc20;
|
|
642
|
+
}
|
|
643
|
+
if (object.enable_evm_hook !== void 0 && object.enable_evm_hook !== null) {
|
|
644
|
+
message.enableEvmHook = object.enable_evm_hook;
|
|
645
|
+
}
|
|
646
|
+
return message;
|
|
647
|
+
},
|
|
648
|
+
toAmino(message) {
|
|
649
|
+
const obj = {};
|
|
650
|
+
obj.enable_erc20 = message.enableErc20 === false ? void 0 : message.enableErc20;
|
|
651
|
+
obj.enable_evm_hook = message.enableEvmHook === false ? void 0 : message.enableEvmHook;
|
|
652
|
+
return obj;
|
|
653
|
+
},
|
|
654
|
+
fromAminoMsg(object) {
|
|
655
|
+
return Params.fromAmino(object.value);
|
|
656
|
+
},
|
|
657
|
+
toAminoMsg(message) {
|
|
658
|
+
return {
|
|
659
|
+
type: "erc20/Params",
|
|
660
|
+
value: Params.toAmino(message)
|
|
661
|
+
};
|
|
662
|
+
},
|
|
663
|
+
fromProtoMsg(message) {
|
|
664
|
+
return Params.decode(message.value);
|
|
665
|
+
},
|
|
666
|
+
toProto(message) {
|
|
667
|
+
return Params.encode(message).finish();
|
|
668
|
+
},
|
|
669
|
+
toProtoMsg(message) {
|
|
670
|
+
return {
|
|
671
|
+
typeUrl: "/evmos.erc20.v1.Params",
|
|
672
|
+
value: Params.encode(message).finish()
|
|
673
|
+
};
|
|
674
|
+
}
|
|
675
|
+
};
|
|
676
|
+
function createBaseMsgConvertCoin() {
|
|
677
|
+
return {
|
|
678
|
+
coin: chunkTUX4SN3U_js.Coin.fromPartial({}),
|
|
679
|
+
receiver: "",
|
|
680
|
+
sender: ""
|
|
681
|
+
};
|
|
682
|
+
}
|
|
683
|
+
var MsgConvertCoin = {
|
|
684
|
+
typeUrl: "/evmos.erc20.v1.MsgConvertCoin",
|
|
685
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
686
|
+
if (message.coin !== void 0) {
|
|
687
|
+
chunkTUX4SN3U_js.Coin.encode(message.coin, writer.uint32(10).fork()).ldelim();
|
|
688
|
+
}
|
|
689
|
+
if (message.receiver !== "") {
|
|
690
|
+
writer.uint32(18).string(message.receiver);
|
|
691
|
+
}
|
|
692
|
+
if (message.sender !== "") {
|
|
693
|
+
writer.uint32(26).string(message.sender);
|
|
694
|
+
}
|
|
695
|
+
return writer;
|
|
696
|
+
},
|
|
697
|
+
decode(input, length) {
|
|
698
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
699
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
700
|
+
const message = createBaseMsgConvertCoin();
|
|
701
|
+
while (reader.pos < end) {
|
|
702
|
+
const tag = reader.uint32();
|
|
703
|
+
switch (tag >>> 3) {
|
|
704
|
+
case 1:
|
|
705
|
+
message.coin = chunkTUX4SN3U_js.Coin.decode(reader, reader.uint32());
|
|
706
|
+
break;
|
|
707
|
+
case 2:
|
|
708
|
+
message.receiver = reader.string();
|
|
709
|
+
break;
|
|
710
|
+
case 3:
|
|
711
|
+
message.sender = reader.string();
|
|
712
|
+
break;
|
|
713
|
+
default:
|
|
714
|
+
reader.skipType(tag & 7);
|
|
715
|
+
break;
|
|
716
|
+
}
|
|
717
|
+
}
|
|
718
|
+
return message;
|
|
719
|
+
},
|
|
720
|
+
fromJSON(object) {
|
|
721
|
+
return {
|
|
722
|
+
coin: chunkTUX4SN3U_js.isSet(object.coin) ? chunkTUX4SN3U_js.Coin.fromJSON(object.coin) : void 0,
|
|
723
|
+
receiver: chunkTUX4SN3U_js.isSet(object.receiver) ? String(object.receiver) : "",
|
|
724
|
+
sender: chunkTUX4SN3U_js.isSet(object.sender) ? String(object.sender) : ""
|
|
725
|
+
};
|
|
726
|
+
},
|
|
727
|
+
toJSON(message) {
|
|
728
|
+
const obj = {};
|
|
729
|
+
message.coin !== void 0 && (obj.coin = message.coin ? chunkTUX4SN3U_js.Coin.toJSON(message.coin) : void 0);
|
|
730
|
+
message.receiver !== void 0 && (obj.receiver = message.receiver);
|
|
731
|
+
message.sender !== void 0 && (obj.sender = message.sender);
|
|
732
|
+
return obj;
|
|
733
|
+
},
|
|
734
|
+
fromPartial(object) {
|
|
735
|
+
var _a, _b;
|
|
736
|
+
const message = createBaseMsgConvertCoin();
|
|
737
|
+
message.coin = object.coin !== void 0 && object.coin !== null ? chunkTUX4SN3U_js.Coin.fromPartial(object.coin) : void 0;
|
|
738
|
+
message.receiver = (_a = object.receiver) != null ? _a : "";
|
|
739
|
+
message.sender = (_b = object.sender) != null ? _b : "";
|
|
740
|
+
return message;
|
|
741
|
+
},
|
|
742
|
+
fromAmino(object) {
|
|
743
|
+
const message = createBaseMsgConvertCoin();
|
|
744
|
+
if (object.coin !== void 0 && object.coin !== null) {
|
|
745
|
+
message.coin = chunkTUX4SN3U_js.Coin.fromAmino(object.coin);
|
|
746
|
+
}
|
|
747
|
+
if (object.receiver !== void 0 && object.receiver !== null) {
|
|
748
|
+
message.receiver = object.receiver;
|
|
749
|
+
}
|
|
750
|
+
if (object.sender !== void 0 && object.sender !== null) {
|
|
751
|
+
message.sender = object.sender;
|
|
752
|
+
}
|
|
753
|
+
return message;
|
|
754
|
+
},
|
|
755
|
+
toAmino(message) {
|
|
756
|
+
const obj = {};
|
|
757
|
+
obj.coin = message.coin ? chunkTUX4SN3U_js.Coin.toAmino(message.coin) : void 0;
|
|
758
|
+
obj.receiver = message.receiver === "" ? void 0 : message.receiver;
|
|
759
|
+
obj.sender = message.sender === "" ? void 0 : message.sender;
|
|
760
|
+
return obj;
|
|
761
|
+
},
|
|
762
|
+
fromAminoMsg(object) {
|
|
763
|
+
return MsgConvertCoin.fromAmino(object.value);
|
|
764
|
+
},
|
|
765
|
+
toAminoMsg(message) {
|
|
766
|
+
return {
|
|
767
|
+
type: "evmos/MsgConvertCoin",
|
|
768
|
+
value: MsgConvertCoin.toAmino(message)
|
|
769
|
+
};
|
|
770
|
+
},
|
|
771
|
+
fromProtoMsg(message) {
|
|
772
|
+
return MsgConvertCoin.decode(message.value);
|
|
773
|
+
},
|
|
774
|
+
toProto(message) {
|
|
775
|
+
return MsgConvertCoin.encode(message).finish();
|
|
776
|
+
},
|
|
777
|
+
toProtoMsg(message) {
|
|
778
|
+
return {
|
|
779
|
+
typeUrl: "/evmos.erc20.v1.MsgConvertCoin",
|
|
780
|
+
value: MsgConvertCoin.encode(message).finish()
|
|
781
|
+
};
|
|
782
|
+
}
|
|
783
|
+
};
|
|
784
|
+
function createBaseMsgConvertERC20() {
|
|
785
|
+
return {
|
|
786
|
+
contractAddress: "",
|
|
787
|
+
amount: "",
|
|
788
|
+
receiver: "",
|
|
789
|
+
sender: ""
|
|
790
|
+
};
|
|
791
|
+
}
|
|
792
|
+
var MsgConvertERC20 = {
|
|
793
|
+
typeUrl: "/evmos.erc20.v1.MsgConvertERC20",
|
|
794
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
795
|
+
if (message.contractAddress !== "") {
|
|
796
|
+
writer.uint32(10).string(message.contractAddress);
|
|
797
|
+
}
|
|
798
|
+
if (message.amount !== "") {
|
|
799
|
+
writer.uint32(18).string(message.amount);
|
|
800
|
+
}
|
|
801
|
+
if (message.receiver !== "") {
|
|
802
|
+
writer.uint32(26).string(message.receiver);
|
|
803
|
+
}
|
|
804
|
+
if (message.sender !== "") {
|
|
805
|
+
writer.uint32(34).string(message.sender);
|
|
806
|
+
}
|
|
807
|
+
return writer;
|
|
808
|
+
},
|
|
809
|
+
decode(input, length) {
|
|
810
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
811
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
812
|
+
const message = createBaseMsgConvertERC20();
|
|
813
|
+
while (reader.pos < end) {
|
|
814
|
+
const tag = reader.uint32();
|
|
815
|
+
switch (tag >>> 3) {
|
|
816
|
+
case 1:
|
|
817
|
+
message.contractAddress = reader.string();
|
|
818
|
+
break;
|
|
819
|
+
case 2:
|
|
820
|
+
message.amount = reader.string();
|
|
821
|
+
break;
|
|
822
|
+
case 3:
|
|
823
|
+
message.receiver = reader.string();
|
|
824
|
+
break;
|
|
825
|
+
case 4:
|
|
826
|
+
message.sender = reader.string();
|
|
827
|
+
break;
|
|
828
|
+
default:
|
|
829
|
+
reader.skipType(tag & 7);
|
|
830
|
+
break;
|
|
831
|
+
}
|
|
832
|
+
}
|
|
833
|
+
return message;
|
|
834
|
+
},
|
|
835
|
+
fromJSON(object) {
|
|
836
|
+
return {
|
|
837
|
+
contractAddress: chunkTUX4SN3U_js.isSet(object.contractAddress) ? String(object.contractAddress) : "",
|
|
838
|
+
amount: chunkTUX4SN3U_js.isSet(object.amount) ? String(object.amount) : "",
|
|
839
|
+
receiver: chunkTUX4SN3U_js.isSet(object.receiver) ? String(object.receiver) : "",
|
|
840
|
+
sender: chunkTUX4SN3U_js.isSet(object.sender) ? String(object.sender) : ""
|
|
841
|
+
};
|
|
842
|
+
},
|
|
843
|
+
toJSON(message) {
|
|
844
|
+
const obj = {};
|
|
845
|
+
message.contractAddress !== void 0 && (obj.contractAddress = message.contractAddress);
|
|
846
|
+
message.amount !== void 0 && (obj.amount = message.amount);
|
|
847
|
+
message.receiver !== void 0 && (obj.receiver = message.receiver);
|
|
848
|
+
message.sender !== void 0 && (obj.sender = message.sender);
|
|
849
|
+
return obj;
|
|
850
|
+
},
|
|
851
|
+
fromPartial(object) {
|
|
852
|
+
var _a, _b, _c, _d;
|
|
853
|
+
const message = createBaseMsgConvertERC20();
|
|
854
|
+
message.contractAddress = (_a = object.contractAddress) != null ? _a : "";
|
|
855
|
+
message.amount = (_b = object.amount) != null ? _b : "";
|
|
856
|
+
message.receiver = (_c = object.receiver) != null ? _c : "";
|
|
857
|
+
message.sender = (_d = object.sender) != null ? _d : "";
|
|
858
|
+
return message;
|
|
859
|
+
},
|
|
860
|
+
fromAmino(object) {
|
|
861
|
+
const message = createBaseMsgConvertERC20();
|
|
862
|
+
if (object.contract_address !== void 0 && object.contract_address !== null) {
|
|
863
|
+
message.contractAddress = object.contract_address;
|
|
864
|
+
}
|
|
865
|
+
if (object.amount !== void 0 && object.amount !== null) {
|
|
866
|
+
message.amount = object.amount;
|
|
867
|
+
}
|
|
868
|
+
if (object.receiver !== void 0 && object.receiver !== null) {
|
|
869
|
+
message.receiver = object.receiver;
|
|
870
|
+
}
|
|
871
|
+
if (object.sender !== void 0 && object.sender !== null) {
|
|
872
|
+
message.sender = object.sender;
|
|
873
|
+
}
|
|
874
|
+
return message;
|
|
875
|
+
},
|
|
876
|
+
toAmino(message) {
|
|
877
|
+
const obj = {};
|
|
878
|
+
obj.contract_address = message.contractAddress === "" ? void 0 : message.contractAddress;
|
|
879
|
+
obj.amount = message.amount === "" ? void 0 : message.amount;
|
|
880
|
+
obj.receiver = message.receiver === "" ? void 0 : message.receiver;
|
|
881
|
+
obj.sender = message.sender === "" ? void 0 : message.sender;
|
|
882
|
+
return obj;
|
|
883
|
+
},
|
|
884
|
+
fromAminoMsg(object) {
|
|
885
|
+
return MsgConvertERC20.fromAmino(object.value);
|
|
886
|
+
},
|
|
887
|
+
toAminoMsg(message) {
|
|
888
|
+
return {
|
|
889
|
+
type: "evmos/MsgConvertERC20",
|
|
890
|
+
value: MsgConvertERC20.toAmino(message)
|
|
891
|
+
};
|
|
892
|
+
},
|
|
893
|
+
fromProtoMsg(message) {
|
|
894
|
+
return MsgConvertERC20.decode(message.value);
|
|
895
|
+
},
|
|
896
|
+
toProto(message) {
|
|
897
|
+
return MsgConvertERC20.encode(message).finish();
|
|
898
|
+
},
|
|
899
|
+
toProtoMsg(message) {
|
|
900
|
+
return {
|
|
901
|
+
typeUrl: "/evmos.erc20.v1.MsgConvertERC20",
|
|
902
|
+
value: MsgConvertERC20.encode(message).finish()
|
|
903
|
+
};
|
|
904
|
+
}
|
|
905
|
+
};
|
|
906
|
+
function createBaseMsgUpdateParams() {
|
|
907
|
+
return {
|
|
908
|
+
authority: "",
|
|
909
|
+
params: Params.fromPartial({})
|
|
910
|
+
};
|
|
911
|
+
}
|
|
912
|
+
var MsgUpdateParams = {
|
|
913
|
+
typeUrl: "/evmos.erc20.v1.MsgUpdateParams",
|
|
914
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
915
|
+
if (message.authority !== "") {
|
|
916
|
+
writer.uint32(10).string(message.authority);
|
|
917
|
+
}
|
|
918
|
+
if (message.params !== void 0) {
|
|
919
|
+
Params.encode(message.params, writer.uint32(18).fork()).ldelim();
|
|
920
|
+
}
|
|
921
|
+
return writer;
|
|
922
|
+
},
|
|
923
|
+
decode(input, length) {
|
|
924
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
925
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
926
|
+
const message = createBaseMsgUpdateParams();
|
|
927
|
+
while (reader.pos < end) {
|
|
928
|
+
const tag = reader.uint32();
|
|
929
|
+
switch (tag >>> 3) {
|
|
930
|
+
case 1:
|
|
931
|
+
message.authority = reader.string();
|
|
932
|
+
break;
|
|
933
|
+
case 2:
|
|
934
|
+
message.params = Params.decode(reader, reader.uint32());
|
|
935
|
+
break;
|
|
936
|
+
default:
|
|
937
|
+
reader.skipType(tag & 7);
|
|
938
|
+
break;
|
|
939
|
+
}
|
|
940
|
+
}
|
|
941
|
+
return message;
|
|
942
|
+
},
|
|
943
|
+
fromJSON(object) {
|
|
944
|
+
return {
|
|
945
|
+
authority: chunkTUX4SN3U_js.isSet(object.authority) ? String(object.authority) : "",
|
|
946
|
+
params: chunkTUX4SN3U_js.isSet(object.params) ? Params.fromJSON(object.params) : void 0
|
|
947
|
+
};
|
|
948
|
+
},
|
|
949
|
+
toJSON(message) {
|
|
950
|
+
const obj = {};
|
|
951
|
+
message.authority !== void 0 && (obj.authority = message.authority);
|
|
952
|
+
message.params !== void 0 && (obj.params = message.params ? Params.toJSON(message.params) : void 0);
|
|
953
|
+
return obj;
|
|
954
|
+
},
|
|
955
|
+
fromPartial(object) {
|
|
956
|
+
var _a;
|
|
957
|
+
const message = createBaseMsgUpdateParams();
|
|
958
|
+
message.authority = (_a = object.authority) != null ? _a : "";
|
|
959
|
+
message.params = object.params !== void 0 && object.params !== null ? Params.fromPartial(object.params) : void 0;
|
|
960
|
+
return message;
|
|
961
|
+
},
|
|
962
|
+
fromAmino(object) {
|
|
963
|
+
const message = createBaseMsgUpdateParams();
|
|
964
|
+
if (object.authority !== void 0 && object.authority !== null) {
|
|
965
|
+
message.authority = object.authority;
|
|
966
|
+
}
|
|
967
|
+
if (object.params !== void 0 && object.params !== null) {
|
|
968
|
+
message.params = Params.fromAmino(object.params);
|
|
969
|
+
}
|
|
970
|
+
return message;
|
|
971
|
+
},
|
|
972
|
+
toAmino(message) {
|
|
973
|
+
const obj = {};
|
|
974
|
+
obj.authority = message.authority === "" ? void 0 : message.authority;
|
|
975
|
+
obj.params = message.params ? Params.toAmino(message.params) : void 0;
|
|
976
|
+
return obj;
|
|
977
|
+
},
|
|
978
|
+
fromAminoMsg(object) {
|
|
979
|
+
return MsgUpdateParams.fromAmino(object.value);
|
|
980
|
+
},
|
|
981
|
+
toAminoMsg(message) {
|
|
982
|
+
return {
|
|
983
|
+
type: "evmos/erc20/MsgUpdateParams",
|
|
984
|
+
value: MsgUpdateParams.toAmino(message)
|
|
985
|
+
};
|
|
986
|
+
},
|
|
987
|
+
fromProtoMsg(message) {
|
|
988
|
+
return MsgUpdateParams.decode(message.value);
|
|
989
|
+
},
|
|
990
|
+
toProto(message) {
|
|
991
|
+
return MsgUpdateParams.encode(message).finish();
|
|
992
|
+
},
|
|
993
|
+
toProtoMsg(message) {
|
|
994
|
+
return {
|
|
995
|
+
typeUrl: "/evmos.erc20.v1.MsgUpdateParams",
|
|
996
|
+
value: MsgUpdateParams.encode(message).finish()
|
|
997
|
+
};
|
|
998
|
+
}
|
|
999
|
+
};
|
|
1000
|
+
|
|
1001
|
+
// src/codegen/evmos/erc20/v1/tx.registry.ts
|
|
1002
|
+
var registry2 = [["/evmos.erc20.v1.MsgConvertCoin", MsgConvertCoin], ["/evmos.erc20.v1.MsgConvertERC20", MsgConvertERC20], ["/evmos.erc20.v1.MsgUpdateParams", MsgUpdateParams]];
|
|
1003
|
+
function createBaseInflationDistribution() {
|
|
1004
|
+
return {
|
|
1005
|
+
stakingRewards: "",
|
|
1006
|
+
usageIncentives: "",
|
|
1007
|
+
communityPool: ""
|
|
1008
|
+
};
|
|
1009
|
+
}
|
|
1010
|
+
var InflationDistribution = {
|
|
1011
|
+
typeUrl: "/evmos.inflation.v1.InflationDistribution",
|
|
1012
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
1013
|
+
if (message.stakingRewards !== "") {
|
|
1014
|
+
writer.uint32(10).string(math.Decimal.fromUserInput(message.stakingRewards, 18).atomics);
|
|
1015
|
+
}
|
|
1016
|
+
if (message.usageIncentives !== "") {
|
|
1017
|
+
writer.uint32(18).string(math.Decimal.fromUserInput(message.usageIncentives, 18).atomics);
|
|
1018
|
+
}
|
|
1019
|
+
if (message.communityPool !== "") {
|
|
1020
|
+
writer.uint32(26).string(math.Decimal.fromUserInput(message.communityPool, 18).atomics);
|
|
1021
|
+
}
|
|
1022
|
+
return writer;
|
|
1023
|
+
},
|
|
1024
|
+
decode(input, length) {
|
|
1025
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
1026
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
1027
|
+
const message = createBaseInflationDistribution();
|
|
1028
|
+
while (reader.pos < end) {
|
|
1029
|
+
const tag = reader.uint32();
|
|
1030
|
+
switch (tag >>> 3) {
|
|
1031
|
+
case 1:
|
|
1032
|
+
message.stakingRewards = math.Decimal.fromAtomics(reader.string(), 18).toString();
|
|
1033
|
+
break;
|
|
1034
|
+
case 2:
|
|
1035
|
+
message.usageIncentives = math.Decimal.fromAtomics(reader.string(), 18).toString();
|
|
1036
|
+
break;
|
|
1037
|
+
case 3:
|
|
1038
|
+
message.communityPool = math.Decimal.fromAtomics(reader.string(), 18).toString();
|
|
1039
|
+
break;
|
|
1040
|
+
default:
|
|
1041
|
+
reader.skipType(tag & 7);
|
|
1042
|
+
break;
|
|
1043
|
+
}
|
|
1044
|
+
}
|
|
1045
|
+
return message;
|
|
1046
|
+
},
|
|
1047
|
+
fromJSON(object) {
|
|
1048
|
+
return {
|
|
1049
|
+
stakingRewards: chunkTUX4SN3U_js.isSet(object.stakingRewards) ? String(object.stakingRewards) : "",
|
|
1050
|
+
usageIncentives: chunkTUX4SN3U_js.isSet(object.usageIncentives) ? String(object.usageIncentives) : "",
|
|
1051
|
+
communityPool: chunkTUX4SN3U_js.isSet(object.communityPool) ? String(object.communityPool) : ""
|
|
1052
|
+
};
|
|
1053
|
+
},
|
|
1054
|
+
toJSON(message) {
|
|
1055
|
+
const obj = {};
|
|
1056
|
+
message.stakingRewards !== void 0 && (obj.stakingRewards = message.stakingRewards);
|
|
1057
|
+
message.usageIncentives !== void 0 && (obj.usageIncentives = message.usageIncentives);
|
|
1058
|
+
message.communityPool !== void 0 && (obj.communityPool = message.communityPool);
|
|
1059
|
+
return obj;
|
|
1060
|
+
},
|
|
1061
|
+
fromPartial(object) {
|
|
1062
|
+
var _a, _b, _c;
|
|
1063
|
+
const message = createBaseInflationDistribution();
|
|
1064
|
+
message.stakingRewards = (_a = object.stakingRewards) != null ? _a : "";
|
|
1065
|
+
message.usageIncentives = (_b = object.usageIncentives) != null ? _b : "";
|
|
1066
|
+
message.communityPool = (_c = object.communityPool) != null ? _c : "";
|
|
1067
|
+
return message;
|
|
1068
|
+
},
|
|
1069
|
+
fromAmino(object) {
|
|
1070
|
+
const message = createBaseInflationDistribution();
|
|
1071
|
+
if (object.staking_rewards !== void 0 && object.staking_rewards !== null) {
|
|
1072
|
+
message.stakingRewards = object.staking_rewards;
|
|
1073
|
+
}
|
|
1074
|
+
if (object.usage_incentives !== void 0 && object.usage_incentives !== null) {
|
|
1075
|
+
message.usageIncentives = object.usage_incentives;
|
|
1076
|
+
}
|
|
1077
|
+
if (object.community_pool !== void 0 && object.community_pool !== null) {
|
|
1078
|
+
message.communityPool = object.community_pool;
|
|
1079
|
+
}
|
|
1080
|
+
return message;
|
|
1081
|
+
},
|
|
1082
|
+
toAmino(message) {
|
|
1083
|
+
const obj = {};
|
|
1084
|
+
obj.staking_rewards = chunkTUX4SN3U_js.padDecimal(message.stakingRewards) === "" ? void 0 : chunkTUX4SN3U_js.padDecimal(message.stakingRewards);
|
|
1085
|
+
obj.usage_incentives = chunkTUX4SN3U_js.padDecimal(message.usageIncentives) === "" ? void 0 : chunkTUX4SN3U_js.padDecimal(message.usageIncentives);
|
|
1086
|
+
obj.community_pool = chunkTUX4SN3U_js.padDecimal(message.communityPool) === "" ? void 0 : chunkTUX4SN3U_js.padDecimal(message.communityPool);
|
|
1087
|
+
return obj;
|
|
1088
|
+
},
|
|
1089
|
+
fromAminoMsg(object) {
|
|
1090
|
+
return InflationDistribution.fromAmino(object.value);
|
|
1091
|
+
},
|
|
1092
|
+
toAminoMsg(message) {
|
|
1093
|
+
return {
|
|
1094
|
+
type: "inflation/InflationDistribution",
|
|
1095
|
+
value: InflationDistribution.toAmino(message)
|
|
1096
|
+
};
|
|
1097
|
+
},
|
|
1098
|
+
fromProtoMsg(message) {
|
|
1099
|
+
return InflationDistribution.decode(message.value);
|
|
1100
|
+
},
|
|
1101
|
+
toProto(message) {
|
|
1102
|
+
return InflationDistribution.encode(message).finish();
|
|
1103
|
+
},
|
|
1104
|
+
toProtoMsg(message) {
|
|
1105
|
+
return {
|
|
1106
|
+
typeUrl: "/evmos.inflation.v1.InflationDistribution",
|
|
1107
|
+
value: InflationDistribution.encode(message).finish()
|
|
1108
|
+
};
|
|
1109
|
+
}
|
|
1110
|
+
};
|
|
1111
|
+
function createBaseExponentialCalculation() {
|
|
1112
|
+
return {
|
|
1113
|
+
a: "",
|
|
1114
|
+
r: "",
|
|
1115
|
+
c: "",
|
|
1116
|
+
bondingTarget: "",
|
|
1117
|
+
maxVariance: ""
|
|
1118
|
+
};
|
|
1119
|
+
}
|
|
1120
|
+
var ExponentialCalculation = {
|
|
1121
|
+
typeUrl: "/evmos.inflation.v1.ExponentialCalculation",
|
|
1122
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
1123
|
+
if (message.a !== "") {
|
|
1124
|
+
writer.uint32(10).string(math.Decimal.fromUserInput(message.a, 18).atomics);
|
|
1125
|
+
}
|
|
1126
|
+
if (message.r !== "") {
|
|
1127
|
+
writer.uint32(18).string(math.Decimal.fromUserInput(message.r, 18).atomics);
|
|
1128
|
+
}
|
|
1129
|
+
if (message.c !== "") {
|
|
1130
|
+
writer.uint32(26).string(math.Decimal.fromUserInput(message.c, 18).atomics);
|
|
1131
|
+
}
|
|
1132
|
+
if (message.bondingTarget !== "") {
|
|
1133
|
+
writer.uint32(34).string(math.Decimal.fromUserInput(message.bondingTarget, 18).atomics);
|
|
1134
|
+
}
|
|
1135
|
+
if (message.maxVariance !== "") {
|
|
1136
|
+
writer.uint32(42).string(math.Decimal.fromUserInput(message.maxVariance, 18).atomics);
|
|
1137
|
+
}
|
|
1138
|
+
return writer;
|
|
1139
|
+
},
|
|
1140
|
+
decode(input, length) {
|
|
1141
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
1142
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
1143
|
+
const message = createBaseExponentialCalculation();
|
|
1144
|
+
while (reader.pos < end) {
|
|
1145
|
+
const tag = reader.uint32();
|
|
1146
|
+
switch (tag >>> 3) {
|
|
1147
|
+
case 1:
|
|
1148
|
+
message.a = math.Decimal.fromAtomics(reader.string(), 18).toString();
|
|
1149
|
+
break;
|
|
1150
|
+
case 2:
|
|
1151
|
+
message.r = math.Decimal.fromAtomics(reader.string(), 18).toString();
|
|
1152
|
+
break;
|
|
1153
|
+
case 3:
|
|
1154
|
+
message.c = math.Decimal.fromAtomics(reader.string(), 18).toString();
|
|
1155
|
+
break;
|
|
1156
|
+
case 4:
|
|
1157
|
+
message.bondingTarget = math.Decimal.fromAtomics(reader.string(), 18).toString();
|
|
1158
|
+
break;
|
|
1159
|
+
case 5:
|
|
1160
|
+
message.maxVariance = math.Decimal.fromAtomics(reader.string(), 18).toString();
|
|
1161
|
+
break;
|
|
1162
|
+
default:
|
|
1163
|
+
reader.skipType(tag & 7);
|
|
1164
|
+
break;
|
|
1165
|
+
}
|
|
1166
|
+
}
|
|
1167
|
+
return message;
|
|
1168
|
+
},
|
|
1169
|
+
fromJSON(object) {
|
|
1170
|
+
return {
|
|
1171
|
+
a: chunkTUX4SN3U_js.isSet(object.a) ? String(object.a) : "",
|
|
1172
|
+
r: chunkTUX4SN3U_js.isSet(object.r) ? String(object.r) : "",
|
|
1173
|
+
c: chunkTUX4SN3U_js.isSet(object.c) ? String(object.c) : "",
|
|
1174
|
+
bondingTarget: chunkTUX4SN3U_js.isSet(object.bondingTarget) ? String(object.bondingTarget) : "",
|
|
1175
|
+
maxVariance: chunkTUX4SN3U_js.isSet(object.maxVariance) ? String(object.maxVariance) : ""
|
|
1176
|
+
};
|
|
1177
|
+
},
|
|
1178
|
+
toJSON(message) {
|
|
1179
|
+
const obj = {};
|
|
1180
|
+
message.a !== void 0 && (obj.a = message.a);
|
|
1181
|
+
message.r !== void 0 && (obj.r = message.r);
|
|
1182
|
+
message.c !== void 0 && (obj.c = message.c);
|
|
1183
|
+
message.bondingTarget !== void 0 && (obj.bondingTarget = message.bondingTarget);
|
|
1184
|
+
message.maxVariance !== void 0 && (obj.maxVariance = message.maxVariance);
|
|
1185
|
+
return obj;
|
|
1186
|
+
},
|
|
1187
|
+
fromPartial(object) {
|
|
1188
|
+
var _a, _b, _c, _d, _e;
|
|
1189
|
+
const message = createBaseExponentialCalculation();
|
|
1190
|
+
message.a = (_a = object.a) != null ? _a : "";
|
|
1191
|
+
message.r = (_b = object.r) != null ? _b : "";
|
|
1192
|
+
message.c = (_c = object.c) != null ? _c : "";
|
|
1193
|
+
message.bondingTarget = (_d = object.bondingTarget) != null ? _d : "";
|
|
1194
|
+
message.maxVariance = (_e = object.maxVariance) != null ? _e : "";
|
|
1195
|
+
return message;
|
|
1196
|
+
},
|
|
1197
|
+
fromAmino(object) {
|
|
1198
|
+
const message = createBaseExponentialCalculation();
|
|
1199
|
+
if (object.a !== void 0 && object.a !== null) {
|
|
1200
|
+
message.a = object.a;
|
|
1201
|
+
}
|
|
1202
|
+
if (object.r !== void 0 && object.r !== null) {
|
|
1203
|
+
message.r = object.r;
|
|
1204
|
+
}
|
|
1205
|
+
if (object.c !== void 0 && object.c !== null) {
|
|
1206
|
+
message.c = object.c;
|
|
1207
|
+
}
|
|
1208
|
+
if (object.bonding_target !== void 0 && object.bonding_target !== null) {
|
|
1209
|
+
message.bondingTarget = object.bonding_target;
|
|
1210
|
+
}
|
|
1211
|
+
if (object.max_variance !== void 0 && object.max_variance !== null) {
|
|
1212
|
+
message.maxVariance = object.max_variance;
|
|
1213
|
+
}
|
|
1214
|
+
return message;
|
|
1215
|
+
},
|
|
1216
|
+
toAmino(message) {
|
|
1217
|
+
const obj = {};
|
|
1218
|
+
obj.a = chunkTUX4SN3U_js.padDecimal(message.a) === "" ? void 0 : chunkTUX4SN3U_js.padDecimal(message.a);
|
|
1219
|
+
obj.r = chunkTUX4SN3U_js.padDecimal(message.r) === "" ? void 0 : chunkTUX4SN3U_js.padDecimal(message.r);
|
|
1220
|
+
obj.c = chunkTUX4SN3U_js.padDecimal(message.c) === "" ? void 0 : chunkTUX4SN3U_js.padDecimal(message.c);
|
|
1221
|
+
obj.bonding_target = chunkTUX4SN3U_js.padDecimal(message.bondingTarget) === "" ? void 0 : chunkTUX4SN3U_js.padDecimal(message.bondingTarget);
|
|
1222
|
+
obj.max_variance = chunkTUX4SN3U_js.padDecimal(message.maxVariance) === "" ? void 0 : chunkTUX4SN3U_js.padDecimal(message.maxVariance);
|
|
1223
|
+
return obj;
|
|
1224
|
+
},
|
|
1225
|
+
fromAminoMsg(object) {
|
|
1226
|
+
return ExponentialCalculation.fromAmino(object.value);
|
|
1227
|
+
},
|
|
1228
|
+
toAminoMsg(message) {
|
|
1229
|
+
return {
|
|
1230
|
+
type: "inflation/ExponentialCalculation",
|
|
1231
|
+
value: ExponentialCalculation.toAmino(message)
|
|
1232
|
+
};
|
|
1233
|
+
},
|
|
1234
|
+
fromProtoMsg(message) {
|
|
1235
|
+
return ExponentialCalculation.decode(message.value);
|
|
1236
|
+
},
|
|
1237
|
+
toProto(message) {
|
|
1238
|
+
return ExponentialCalculation.encode(message).finish();
|
|
1239
|
+
},
|
|
1240
|
+
toProtoMsg(message) {
|
|
1241
|
+
return {
|
|
1242
|
+
typeUrl: "/evmos.inflation.v1.ExponentialCalculation",
|
|
1243
|
+
value: ExponentialCalculation.encode(message).finish()
|
|
1244
|
+
};
|
|
1245
|
+
}
|
|
1246
|
+
};
|
|
1247
|
+
function createBaseParams2() {
|
|
1248
|
+
return {
|
|
1249
|
+
mintDenom: "",
|
|
1250
|
+
exponentialCalculation: ExponentialCalculation.fromPartial({}),
|
|
1251
|
+
inflationDistribution: InflationDistribution.fromPartial({}),
|
|
1252
|
+
enableInflation: false
|
|
1253
|
+
};
|
|
1254
|
+
}
|
|
1255
|
+
var Params2 = {
|
|
1256
|
+
typeUrl: "/evmos.inflation.v1.Params",
|
|
1257
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
1258
|
+
if (message.mintDenom !== "") {
|
|
1259
|
+
writer.uint32(10).string(message.mintDenom);
|
|
1260
|
+
}
|
|
1261
|
+
if (message.exponentialCalculation !== void 0) {
|
|
1262
|
+
ExponentialCalculation.encode(message.exponentialCalculation, writer.uint32(18).fork()).ldelim();
|
|
1263
|
+
}
|
|
1264
|
+
if (message.inflationDistribution !== void 0) {
|
|
1265
|
+
InflationDistribution.encode(message.inflationDistribution, writer.uint32(26).fork()).ldelim();
|
|
1266
|
+
}
|
|
1267
|
+
if (message.enableInflation === true) {
|
|
1268
|
+
writer.uint32(32).bool(message.enableInflation);
|
|
1269
|
+
}
|
|
1270
|
+
return writer;
|
|
1271
|
+
},
|
|
1272
|
+
decode(input, length) {
|
|
1273
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
1274
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
1275
|
+
const message = createBaseParams2();
|
|
1276
|
+
while (reader.pos < end) {
|
|
1277
|
+
const tag = reader.uint32();
|
|
1278
|
+
switch (tag >>> 3) {
|
|
1279
|
+
case 1:
|
|
1280
|
+
message.mintDenom = reader.string();
|
|
1281
|
+
break;
|
|
1282
|
+
case 2:
|
|
1283
|
+
message.exponentialCalculation = ExponentialCalculation.decode(reader, reader.uint32());
|
|
1284
|
+
break;
|
|
1285
|
+
case 3:
|
|
1286
|
+
message.inflationDistribution = InflationDistribution.decode(reader, reader.uint32());
|
|
1287
|
+
break;
|
|
1288
|
+
case 4:
|
|
1289
|
+
message.enableInflation = reader.bool();
|
|
1290
|
+
break;
|
|
1291
|
+
default:
|
|
1292
|
+
reader.skipType(tag & 7);
|
|
1293
|
+
break;
|
|
1294
|
+
}
|
|
1295
|
+
}
|
|
1296
|
+
return message;
|
|
1297
|
+
},
|
|
1298
|
+
fromJSON(object) {
|
|
1299
|
+
return {
|
|
1300
|
+
mintDenom: chunkTUX4SN3U_js.isSet(object.mintDenom) ? String(object.mintDenom) : "",
|
|
1301
|
+
exponentialCalculation: chunkTUX4SN3U_js.isSet(object.exponentialCalculation) ? ExponentialCalculation.fromJSON(object.exponentialCalculation) : void 0,
|
|
1302
|
+
inflationDistribution: chunkTUX4SN3U_js.isSet(object.inflationDistribution) ? InflationDistribution.fromJSON(object.inflationDistribution) : void 0,
|
|
1303
|
+
enableInflation: chunkTUX4SN3U_js.isSet(object.enableInflation) ? Boolean(object.enableInflation) : false
|
|
1304
|
+
};
|
|
1305
|
+
},
|
|
1306
|
+
toJSON(message) {
|
|
1307
|
+
const obj = {};
|
|
1308
|
+
message.mintDenom !== void 0 && (obj.mintDenom = message.mintDenom);
|
|
1309
|
+
message.exponentialCalculation !== void 0 && (obj.exponentialCalculation = message.exponentialCalculation ? ExponentialCalculation.toJSON(message.exponentialCalculation) : void 0);
|
|
1310
|
+
message.inflationDistribution !== void 0 && (obj.inflationDistribution = message.inflationDistribution ? InflationDistribution.toJSON(message.inflationDistribution) : void 0);
|
|
1311
|
+
message.enableInflation !== void 0 && (obj.enableInflation = message.enableInflation);
|
|
1312
|
+
return obj;
|
|
1313
|
+
},
|
|
1314
|
+
fromPartial(object) {
|
|
1315
|
+
var _a, _b;
|
|
1316
|
+
const message = createBaseParams2();
|
|
1317
|
+
message.mintDenom = (_a = object.mintDenom) != null ? _a : "";
|
|
1318
|
+
message.exponentialCalculation = object.exponentialCalculation !== void 0 && object.exponentialCalculation !== null ? ExponentialCalculation.fromPartial(object.exponentialCalculation) : void 0;
|
|
1319
|
+
message.inflationDistribution = object.inflationDistribution !== void 0 && object.inflationDistribution !== null ? InflationDistribution.fromPartial(object.inflationDistribution) : void 0;
|
|
1320
|
+
message.enableInflation = (_b = object.enableInflation) != null ? _b : false;
|
|
1321
|
+
return message;
|
|
1322
|
+
},
|
|
1323
|
+
fromAmino(object) {
|
|
1324
|
+
const message = createBaseParams2();
|
|
1325
|
+
if (object.mint_denom !== void 0 && object.mint_denom !== null) {
|
|
1326
|
+
message.mintDenom = object.mint_denom;
|
|
1327
|
+
}
|
|
1328
|
+
if (object.exponential_calculation !== void 0 && object.exponential_calculation !== null) {
|
|
1329
|
+
message.exponentialCalculation = ExponentialCalculation.fromAmino(object.exponential_calculation);
|
|
1330
|
+
}
|
|
1331
|
+
if (object.inflation_distribution !== void 0 && object.inflation_distribution !== null) {
|
|
1332
|
+
message.inflationDistribution = InflationDistribution.fromAmino(object.inflation_distribution);
|
|
1333
|
+
}
|
|
1334
|
+
if (object.enable_inflation !== void 0 && object.enable_inflation !== null) {
|
|
1335
|
+
message.enableInflation = object.enable_inflation;
|
|
1336
|
+
}
|
|
1337
|
+
return message;
|
|
1338
|
+
},
|
|
1339
|
+
toAmino(message) {
|
|
1340
|
+
const obj = {};
|
|
1341
|
+
obj.mint_denom = message.mintDenom === "" ? void 0 : message.mintDenom;
|
|
1342
|
+
obj.exponential_calculation = message.exponentialCalculation ? ExponentialCalculation.toAmino(message.exponentialCalculation) : void 0;
|
|
1343
|
+
obj.inflation_distribution = message.inflationDistribution ? InflationDistribution.toAmino(message.inflationDistribution) : void 0;
|
|
1344
|
+
obj.enable_inflation = message.enableInflation === false ? void 0 : message.enableInflation;
|
|
1345
|
+
return obj;
|
|
1346
|
+
},
|
|
1347
|
+
fromAminoMsg(object) {
|
|
1348
|
+
return Params2.fromAmino(object.value);
|
|
1349
|
+
},
|
|
1350
|
+
toAminoMsg(message) {
|
|
1351
|
+
return {
|
|
1352
|
+
type: "inflation/Params",
|
|
1353
|
+
value: Params2.toAmino(message)
|
|
1354
|
+
};
|
|
1355
|
+
},
|
|
1356
|
+
fromProtoMsg(message) {
|
|
1357
|
+
return Params2.decode(message.value);
|
|
1358
|
+
},
|
|
1359
|
+
toProto(message) {
|
|
1360
|
+
return Params2.encode(message).finish();
|
|
1361
|
+
},
|
|
1362
|
+
toProtoMsg(message) {
|
|
1363
|
+
return {
|
|
1364
|
+
typeUrl: "/evmos.inflation.v1.Params",
|
|
1365
|
+
value: Params2.encode(message).finish()
|
|
1366
|
+
};
|
|
1367
|
+
}
|
|
1368
|
+
};
|
|
1369
|
+
function createBaseMsgUpdateParams2() {
|
|
1370
|
+
return {
|
|
1371
|
+
authority: "",
|
|
1372
|
+
params: Params2.fromPartial({})
|
|
1373
|
+
};
|
|
1374
|
+
}
|
|
1375
|
+
var MsgUpdateParams2 = {
|
|
1376
|
+
typeUrl: "/evmos.inflation.v1.MsgUpdateParams",
|
|
1377
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
1378
|
+
if (message.authority !== "") {
|
|
1379
|
+
writer.uint32(10).string(message.authority);
|
|
1380
|
+
}
|
|
1381
|
+
if (message.params !== void 0) {
|
|
1382
|
+
Params2.encode(message.params, writer.uint32(18).fork()).ldelim();
|
|
1383
|
+
}
|
|
1384
|
+
return writer;
|
|
1385
|
+
},
|
|
1386
|
+
decode(input, length) {
|
|
1387
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
1388
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
1389
|
+
const message = createBaseMsgUpdateParams2();
|
|
1390
|
+
while (reader.pos < end) {
|
|
1391
|
+
const tag = reader.uint32();
|
|
1392
|
+
switch (tag >>> 3) {
|
|
1393
|
+
case 1:
|
|
1394
|
+
message.authority = reader.string();
|
|
1395
|
+
break;
|
|
1396
|
+
case 2:
|
|
1397
|
+
message.params = Params2.decode(reader, reader.uint32());
|
|
1398
|
+
break;
|
|
1399
|
+
default:
|
|
1400
|
+
reader.skipType(tag & 7);
|
|
1401
|
+
break;
|
|
1402
|
+
}
|
|
1403
|
+
}
|
|
1404
|
+
return message;
|
|
1405
|
+
},
|
|
1406
|
+
fromJSON(object) {
|
|
1407
|
+
return {
|
|
1408
|
+
authority: chunkTUX4SN3U_js.isSet(object.authority) ? String(object.authority) : "",
|
|
1409
|
+
params: chunkTUX4SN3U_js.isSet(object.params) ? Params2.fromJSON(object.params) : void 0
|
|
1410
|
+
};
|
|
1411
|
+
},
|
|
1412
|
+
toJSON(message) {
|
|
1413
|
+
const obj = {};
|
|
1414
|
+
message.authority !== void 0 && (obj.authority = message.authority);
|
|
1415
|
+
message.params !== void 0 && (obj.params = message.params ? Params2.toJSON(message.params) : void 0);
|
|
1416
|
+
return obj;
|
|
1417
|
+
},
|
|
1418
|
+
fromPartial(object) {
|
|
1419
|
+
var _a;
|
|
1420
|
+
const message = createBaseMsgUpdateParams2();
|
|
1421
|
+
message.authority = (_a = object.authority) != null ? _a : "";
|
|
1422
|
+
message.params = object.params !== void 0 && object.params !== null ? Params2.fromPartial(object.params) : void 0;
|
|
1423
|
+
return message;
|
|
1424
|
+
},
|
|
1425
|
+
fromAmino(object) {
|
|
1426
|
+
const message = createBaseMsgUpdateParams2();
|
|
1427
|
+
if (object.authority !== void 0 && object.authority !== null) {
|
|
1428
|
+
message.authority = object.authority;
|
|
1429
|
+
}
|
|
1430
|
+
if (object.params !== void 0 && object.params !== null) {
|
|
1431
|
+
message.params = Params2.fromAmino(object.params);
|
|
1432
|
+
}
|
|
1433
|
+
return message;
|
|
1434
|
+
},
|
|
1435
|
+
toAmino(message) {
|
|
1436
|
+
const obj = {};
|
|
1437
|
+
obj.authority = message.authority === "" ? void 0 : message.authority;
|
|
1438
|
+
obj.params = message.params ? Params2.toAmino(message.params) : void 0;
|
|
1439
|
+
return obj;
|
|
1440
|
+
},
|
|
1441
|
+
fromAminoMsg(object) {
|
|
1442
|
+
return MsgUpdateParams2.fromAmino(object.value);
|
|
1443
|
+
},
|
|
1444
|
+
toAminoMsg(message) {
|
|
1445
|
+
return {
|
|
1446
|
+
type: "evmos/inflation/MsgUpdateParams",
|
|
1447
|
+
value: MsgUpdateParams2.toAmino(message)
|
|
1448
|
+
};
|
|
1449
|
+
},
|
|
1450
|
+
fromProtoMsg(message) {
|
|
1451
|
+
return MsgUpdateParams2.decode(message.value);
|
|
1452
|
+
},
|
|
1453
|
+
toProto(message) {
|
|
1454
|
+
return MsgUpdateParams2.encode(message).finish();
|
|
1455
|
+
},
|
|
1456
|
+
toProtoMsg(message) {
|
|
1457
|
+
return {
|
|
1458
|
+
typeUrl: "/evmos.inflation.v1.MsgUpdateParams",
|
|
1459
|
+
value: MsgUpdateParams2.encode(message).finish()
|
|
1460
|
+
};
|
|
1461
|
+
}
|
|
1462
|
+
};
|
|
1463
|
+
|
|
1464
|
+
// src/codegen/evmos/inflation/v1/tx.registry.ts
|
|
1465
|
+
var registry3 = [["/evmos.inflation.v1.MsgUpdateParams", MsgUpdateParams2]];
|
|
1466
|
+
function createBaseParams3() {
|
|
1467
|
+
return {
|
|
1468
|
+
enableRevenue: false,
|
|
1469
|
+
developerShares: "",
|
|
1470
|
+
addrDerivationCostCreate: chunkTUX4SN3U_js.Long.UZERO
|
|
1471
|
+
};
|
|
1472
|
+
}
|
|
1473
|
+
var Params3 = {
|
|
1474
|
+
typeUrl: "/evmos.revenue.v1.Params",
|
|
1475
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
1476
|
+
if (message.enableRevenue === true) {
|
|
1477
|
+
writer.uint32(8).bool(message.enableRevenue);
|
|
1478
|
+
}
|
|
1479
|
+
if (message.developerShares !== "") {
|
|
1480
|
+
writer.uint32(18).string(math.Decimal.fromUserInput(message.developerShares, 18).atomics);
|
|
1481
|
+
}
|
|
1482
|
+
if (!message.addrDerivationCostCreate.isZero()) {
|
|
1483
|
+
writer.uint32(24).uint64(message.addrDerivationCostCreate);
|
|
1484
|
+
}
|
|
1485
|
+
return writer;
|
|
1486
|
+
},
|
|
1487
|
+
decode(input, length) {
|
|
1488
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
1489
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
1490
|
+
const message = createBaseParams3();
|
|
1491
|
+
while (reader.pos < end) {
|
|
1492
|
+
const tag = reader.uint32();
|
|
1493
|
+
switch (tag >>> 3) {
|
|
1494
|
+
case 1:
|
|
1495
|
+
message.enableRevenue = reader.bool();
|
|
1496
|
+
break;
|
|
1497
|
+
case 2:
|
|
1498
|
+
message.developerShares = math.Decimal.fromAtomics(reader.string(), 18).toString();
|
|
1499
|
+
break;
|
|
1500
|
+
case 3:
|
|
1501
|
+
message.addrDerivationCostCreate = reader.uint64();
|
|
1502
|
+
break;
|
|
1503
|
+
default:
|
|
1504
|
+
reader.skipType(tag & 7);
|
|
1505
|
+
break;
|
|
1506
|
+
}
|
|
1507
|
+
}
|
|
1508
|
+
return message;
|
|
1509
|
+
},
|
|
1510
|
+
fromJSON(object) {
|
|
1511
|
+
return {
|
|
1512
|
+
enableRevenue: chunkTUX4SN3U_js.isSet(object.enableRevenue) ? Boolean(object.enableRevenue) : false,
|
|
1513
|
+
developerShares: chunkTUX4SN3U_js.isSet(object.developerShares) ? String(object.developerShares) : "",
|
|
1514
|
+
addrDerivationCostCreate: chunkTUX4SN3U_js.isSet(object.addrDerivationCostCreate) ? chunkTUX4SN3U_js.Long.fromValue(object.addrDerivationCostCreate) : chunkTUX4SN3U_js.Long.UZERO
|
|
1515
|
+
};
|
|
1516
|
+
},
|
|
1517
|
+
toJSON(message) {
|
|
1518
|
+
const obj = {};
|
|
1519
|
+
message.enableRevenue !== void 0 && (obj.enableRevenue = message.enableRevenue);
|
|
1520
|
+
message.developerShares !== void 0 && (obj.developerShares = message.developerShares);
|
|
1521
|
+
message.addrDerivationCostCreate !== void 0 && (obj.addrDerivationCostCreate = (message.addrDerivationCostCreate || chunkTUX4SN3U_js.Long.UZERO).toString());
|
|
1522
|
+
return obj;
|
|
1523
|
+
},
|
|
1524
|
+
fromPartial(object) {
|
|
1525
|
+
var _a, _b;
|
|
1526
|
+
const message = createBaseParams3();
|
|
1527
|
+
message.enableRevenue = (_a = object.enableRevenue) != null ? _a : false;
|
|
1528
|
+
message.developerShares = (_b = object.developerShares) != null ? _b : "";
|
|
1529
|
+
message.addrDerivationCostCreate = object.addrDerivationCostCreate !== void 0 && object.addrDerivationCostCreate !== null ? chunkTUX4SN3U_js.Long.fromValue(object.addrDerivationCostCreate) : chunkTUX4SN3U_js.Long.UZERO;
|
|
1530
|
+
return message;
|
|
1531
|
+
},
|
|
1532
|
+
fromAmino(object) {
|
|
1533
|
+
const message = createBaseParams3();
|
|
1534
|
+
if (object.enable_revenue !== void 0 && object.enable_revenue !== null) {
|
|
1535
|
+
message.enableRevenue = object.enable_revenue;
|
|
1536
|
+
}
|
|
1537
|
+
if (object.developer_shares !== void 0 && object.developer_shares !== null) {
|
|
1538
|
+
message.developerShares = object.developer_shares;
|
|
1539
|
+
}
|
|
1540
|
+
if (object.addr_derivation_cost_create !== void 0 && object.addr_derivation_cost_create !== null) {
|
|
1541
|
+
message.addrDerivationCostCreate = chunkTUX4SN3U_js.Long.fromString(object.addr_derivation_cost_create);
|
|
1542
|
+
}
|
|
1543
|
+
return message;
|
|
1544
|
+
},
|
|
1545
|
+
toAmino(message) {
|
|
1546
|
+
const obj = {};
|
|
1547
|
+
obj.enable_revenue = message.enableRevenue === false ? void 0 : message.enableRevenue;
|
|
1548
|
+
obj.developer_shares = chunkTUX4SN3U_js.padDecimal(message.developerShares) === "" ? void 0 : chunkTUX4SN3U_js.padDecimal(message.developerShares);
|
|
1549
|
+
obj.addr_derivation_cost_create = !message.addrDerivationCostCreate.isZero() ? message.addrDerivationCostCreate.toString() : void 0;
|
|
1550
|
+
return obj;
|
|
1551
|
+
},
|
|
1552
|
+
fromAminoMsg(object) {
|
|
1553
|
+
return Params3.fromAmino(object.value);
|
|
1554
|
+
},
|
|
1555
|
+
toAminoMsg(message) {
|
|
1556
|
+
return {
|
|
1557
|
+
type: "revenue/Params",
|
|
1558
|
+
value: Params3.toAmino(message)
|
|
1559
|
+
};
|
|
1560
|
+
},
|
|
1561
|
+
fromProtoMsg(message) {
|
|
1562
|
+
return Params3.decode(message.value);
|
|
1563
|
+
},
|
|
1564
|
+
toProto(message) {
|
|
1565
|
+
return Params3.encode(message).finish();
|
|
1566
|
+
},
|
|
1567
|
+
toProtoMsg(message) {
|
|
1568
|
+
return {
|
|
1569
|
+
typeUrl: "/evmos.revenue.v1.Params",
|
|
1570
|
+
value: Params3.encode(message).finish()
|
|
1571
|
+
};
|
|
1572
|
+
}
|
|
1573
|
+
};
|
|
1574
|
+
function createBaseMsgRegisterRevenue() {
|
|
1575
|
+
return {
|
|
1576
|
+
contractAddress: "",
|
|
1577
|
+
deployerAddress: "",
|
|
1578
|
+
withdrawerAddress: "",
|
|
1579
|
+
nonces: []
|
|
1580
|
+
};
|
|
1581
|
+
}
|
|
1582
|
+
var MsgRegisterRevenue = {
|
|
1583
|
+
typeUrl: "/evmos.revenue.v1.MsgRegisterRevenue",
|
|
1584
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
1585
|
+
if (message.contractAddress !== "") {
|
|
1586
|
+
writer.uint32(10).string(message.contractAddress);
|
|
1587
|
+
}
|
|
1588
|
+
if (message.deployerAddress !== "") {
|
|
1589
|
+
writer.uint32(18).string(message.deployerAddress);
|
|
1590
|
+
}
|
|
1591
|
+
if (message.withdrawerAddress !== "") {
|
|
1592
|
+
writer.uint32(26).string(message.withdrawerAddress);
|
|
1593
|
+
}
|
|
1594
|
+
writer.uint32(34).fork();
|
|
1595
|
+
for (const v of message.nonces) {
|
|
1596
|
+
writer.uint64(v);
|
|
1597
|
+
}
|
|
1598
|
+
writer.ldelim();
|
|
1599
|
+
return writer;
|
|
1600
|
+
},
|
|
1601
|
+
decode(input, length) {
|
|
1602
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
1603
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
1604
|
+
const message = createBaseMsgRegisterRevenue();
|
|
1605
|
+
while (reader.pos < end) {
|
|
1606
|
+
const tag = reader.uint32();
|
|
1607
|
+
switch (tag >>> 3) {
|
|
1608
|
+
case 1:
|
|
1609
|
+
message.contractAddress = reader.string();
|
|
1610
|
+
break;
|
|
1611
|
+
case 2:
|
|
1612
|
+
message.deployerAddress = reader.string();
|
|
1613
|
+
break;
|
|
1614
|
+
case 3:
|
|
1615
|
+
message.withdrawerAddress = reader.string();
|
|
1616
|
+
break;
|
|
1617
|
+
case 4:
|
|
1618
|
+
if ((tag & 7) === 2) {
|
|
1619
|
+
const end2 = reader.uint32() + reader.pos;
|
|
1620
|
+
while (reader.pos < end2) {
|
|
1621
|
+
message.nonces.push(reader.uint64());
|
|
1622
|
+
}
|
|
1623
|
+
} else {
|
|
1624
|
+
message.nonces.push(reader.uint64());
|
|
1625
|
+
}
|
|
1626
|
+
break;
|
|
1627
|
+
default:
|
|
1628
|
+
reader.skipType(tag & 7);
|
|
1629
|
+
break;
|
|
1630
|
+
}
|
|
1631
|
+
}
|
|
1632
|
+
return message;
|
|
1633
|
+
},
|
|
1634
|
+
fromJSON(object) {
|
|
1635
|
+
return {
|
|
1636
|
+
contractAddress: chunkTUX4SN3U_js.isSet(object.contractAddress) ? String(object.contractAddress) : "",
|
|
1637
|
+
deployerAddress: chunkTUX4SN3U_js.isSet(object.deployerAddress) ? String(object.deployerAddress) : "",
|
|
1638
|
+
withdrawerAddress: chunkTUX4SN3U_js.isSet(object.withdrawerAddress) ? String(object.withdrawerAddress) : "",
|
|
1639
|
+
nonces: Array.isArray(object == null ? void 0 : object.nonces) ? object.nonces.map((e) => chunkTUX4SN3U_js.Long.fromValue(e)) : []
|
|
1640
|
+
};
|
|
1641
|
+
},
|
|
1642
|
+
toJSON(message) {
|
|
1643
|
+
const obj = {};
|
|
1644
|
+
message.contractAddress !== void 0 && (obj.contractAddress = message.contractAddress);
|
|
1645
|
+
message.deployerAddress !== void 0 && (obj.deployerAddress = message.deployerAddress);
|
|
1646
|
+
message.withdrawerAddress !== void 0 && (obj.withdrawerAddress = message.withdrawerAddress);
|
|
1647
|
+
if (message.nonces) {
|
|
1648
|
+
obj.nonces = message.nonces.map((e) => (e || chunkTUX4SN3U_js.Long.UZERO).toString());
|
|
1649
|
+
} else {
|
|
1650
|
+
obj.nonces = [];
|
|
1651
|
+
}
|
|
1652
|
+
return obj;
|
|
1653
|
+
},
|
|
1654
|
+
fromPartial(object) {
|
|
1655
|
+
var _a, _b, _c, _d;
|
|
1656
|
+
const message = createBaseMsgRegisterRevenue();
|
|
1657
|
+
message.contractAddress = (_a = object.contractAddress) != null ? _a : "";
|
|
1658
|
+
message.deployerAddress = (_b = object.deployerAddress) != null ? _b : "";
|
|
1659
|
+
message.withdrawerAddress = (_c = object.withdrawerAddress) != null ? _c : "";
|
|
1660
|
+
message.nonces = ((_d = object.nonces) == null ? void 0 : _d.map((e) => chunkTUX4SN3U_js.Long.fromValue(e))) || [];
|
|
1661
|
+
return message;
|
|
1662
|
+
},
|
|
1663
|
+
fromAmino(object) {
|
|
1664
|
+
var _a;
|
|
1665
|
+
const message = createBaseMsgRegisterRevenue();
|
|
1666
|
+
if (object.contract_address !== void 0 && object.contract_address !== null) {
|
|
1667
|
+
message.contractAddress = object.contract_address;
|
|
1668
|
+
}
|
|
1669
|
+
if (object.deployer_address !== void 0 && object.deployer_address !== null) {
|
|
1670
|
+
message.deployerAddress = object.deployer_address;
|
|
1671
|
+
}
|
|
1672
|
+
if (object.withdrawer_address !== void 0 && object.withdrawer_address !== null) {
|
|
1673
|
+
message.withdrawerAddress = object.withdrawer_address;
|
|
1674
|
+
}
|
|
1675
|
+
message.nonces = ((_a = object.nonces) == null ? void 0 : _a.map((e) => chunkTUX4SN3U_js.Long.fromString(e))) || [];
|
|
1676
|
+
return message;
|
|
1677
|
+
},
|
|
1678
|
+
toAmino(message) {
|
|
1679
|
+
const obj = {};
|
|
1680
|
+
obj.contract_address = message.contractAddress === "" ? void 0 : message.contractAddress;
|
|
1681
|
+
obj.deployer_address = message.deployerAddress === "" ? void 0 : message.deployerAddress;
|
|
1682
|
+
obj.withdrawer_address = message.withdrawerAddress === "" ? void 0 : message.withdrawerAddress;
|
|
1683
|
+
if (message.nonces) {
|
|
1684
|
+
obj.nonces = message.nonces.map((e) => e);
|
|
1685
|
+
} else {
|
|
1686
|
+
obj.nonces = message.nonces;
|
|
1687
|
+
}
|
|
1688
|
+
return obj;
|
|
1689
|
+
},
|
|
1690
|
+
fromAminoMsg(object) {
|
|
1691
|
+
return MsgRegisterRevenue.fromAmino(object.value);
|
|
1692
|
+
},
|
|
1693
|
+
toAminoMsg(message) {
|
|
1694
|
+
return {
|
|
1695
|
+
type: "evmos/MsgRegisterRevenue",
|
|
1696
|
+
value: MsgRegisterRevenue.toAmino(message)
|
|
1697
|
+
};
|
|
1698
|
+
},
|
|
1699
|
+
fromProtoMsg(message) {
|
|
1700
|
+
return MsgRegisterRevenue.decode(message.value);
|
|
1701
|
+
},
|
|
1702
|
+
toProto(message) {
|
|
1703
|
+
return MsgRegisterRevenue.encode(message).finish();
|
|
1704
|
+
},
|
|
1705
|
+
toProtoMsg(message) {
|
|
1706
|
+
return {
|
|
1707
|
+
typeUrl: "/evmos.revenue.v1.MsgRegisterRevenue",
|
|
1708
|
+
value: MsgRegisterRevenue.encode(message).finish()
|
|
1709
|
+
};
|
|
1710
|
+
}
|
|
1711
|
+
};
|
|
1712
|
+
function createBaseMsgUpdateRevenue() {
|
|
1713
|
+
return {
|
|
1714
|
+
contractAddress: "",
|
|
1715
|
+
deployerAddress: "",
|
|
1716
|
+
withdrawerAddress: ""
|
|
1717
|
+
};
|
|
1718
|
+
}
|
|
1719
|
+
var MsgUpdateRevenue = {
|
|
1720
|
+
typeUrl: "/evmos.revenue.v1.MsgUpdateRevenue",
|
|
1721
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
1722
|
+
if (message.contractAddress !== "") {
|
|
1723
|
+
writer.uint32(10).string(message.contractAddress);
|
|
1724
|
+
}
|
|
1725
|
+
if (message.deployerAddress !== "") {
|
|
1726
|
+
writer.uint32(18).string(message.deployerAddress);
|
|
1727
|
+
}
|
|
1728
|
+
if (message.withdrawerAddress !== "") {
|
|
1729
|
+
writer.uint32(26).string(message.withdrawerAddress);
|
|
1730
|
+
}
|
|
1731
|
+
return writer;
|
|
1732
|
+
},
|
|
1733
|
+
decode(input, length) {
|
|
1734
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
1735
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
1736
|
+
const message = createBaseMsgUpdateRevenue();
|
|
1737
|
+
while (reader.pos < end) {
|
|
1738
|
+
const tag = reader.uint32();
|
|
1739
|
+
switch (tag >>> 3) {
|
|
1740
|
+
case 1:
|
|
1741
|
+
message.contractAddress = reader.string();
|
|
1742
|
+
break;
|
|
1743
|
+
case 2:
|
|
1744
|
+
message.deployerAddress = reader.string();
|
|
1745
|
+
break;
|
|
1746
|
+
case 3:
|
|
1747
|
+
message.withdrawerAddress = reader.string();
|
|
1748
|
+
break;
|
|
1749
|
+
default:
|
|
1750
|
+
reader.skipType(tag & 7);
|
|
1751
|
+
break;
|
|
1752
|
+
}
|
|
1753
|
+
}
|
|
1754
|
+
return message;
|
|
1755
|
+
},
|
|
1756
|
+
fromJSON(object) {
|
|
1757
|
+
return {
|
|
1758
|
+
contractAddress: chunkTUX4SN3U_js.isSet(object.contractAddress) ? String(object.contractAddress) : "",
|
|
1759
|
+
deployerAddress: chunkTUX4SN3U_js.isSet(object.deployerAddress) ? String(object.deployerAddress) : "",
|
|
1760
|
+
withdrawerAddress: chunkTUX4SN3U_js.isSet(object.withdrawerAddress) ? String(object.withdrawerAddress) : ""
|
|
1761
|
+
};
|
|
1762
|
+
},
|
|
1763
|
+
toJSON(message) {
|
|
1764
|
+
const obj = {};
|
|
1765
|
+
message.contractAddress !== void 0 && (obj.contractAddress = message.contractAddress);
|
|
1766
|
+
message.deployerAddress !== void 0 && (obj.deployerAddress = message.deployerAddress);
|
|
1767
|
+
message.withdrawerAddress !== void 0 && (obj.withdrawerAddress = message.withdrawerAddress);
|
|
1768
|
+
return obj;
|
|
1769
|
+
},
|
|
1770
|
+
fromPartial(object) {
|
|
1771
|
+
var _a, _b, _c;
|
|
1772
|
+
const message = createBaseMsgUpdateRevenue();
|
|
1773
|
+
message.contractAddress = (_a = object.contractAddress) != null ? _a : "";
|
|
1774
|
+
message.deployerAddress = (_b = object.deployerAddress) != null ? _b : "";
|
|
1775
|
+
message.withdrawerAddress = (_c = object.withdrawerAddress) != null ? _c : "";
|
|
1776
|
+
return message;
|
|
1777
|
+
},
|
|
1778
|
+
fromAmino(object) {
|
|
1779
|
+
const message = createBaseMsgUpdateRevenue();
|
|
1780
|
+
if (object.contract_address !== void 0 && object.contract_address !== null) {
|
|
1781
|
+
message.contractAddress = object.contract_address;
|
|
1782
|
+
}
|
|
1783
|
+
if (object.deployer_address !== void 0 && object.deployer_address !== null) {
|
|
1784
|
+
message.deployerAddress = object.deployer_address;
|
|
1785
|
+
}
|
|
1786
|
+
if (object.withdrawer_address !== void 0 && object.withdrawer_address !== null) {
|
|
1787
|
+
message.withdrawerAddress = object.withdrawer_address;
|
|
1788
|
+
}
|
|
1789
|
+
return message;
|
|
1790
|
+
},
|
|
1791
|
+
toAmino(message) {
|
|
1792
|
+
const obj = {};
|
|
1793
|
+
obj.contract_address = message.contractAddress === "" ? void 0 : message.contractAddress;
|
|
1794
|
+
obj.deployer_address = message.deployerAddress === "" ? void 0 : message.deployerAddress;
|
|
1795
|
+
obj.withdrawer_address = message.withdrawerAddress === "" ? void 0 : message.withdrawerAddress;
|
|
1796
|
+
return obj;
|
|
1797
|
+
},
|
|
1798
|
+
fromAminoMsg(object) {
|
|
1799
|
+
return MsgUpdateRevenue.fromAmino(object.value);
|
|
1800
|
+
},
|
|
1801
|
+
toAminoMsg(message) {
|
|
1802
|
+
return {
|
|
1803
|
+
type: "evmos/MsgUpdateRevenue",
|
|
1804
|
+
value: MsgUpdateRevenue.toAmino(message)
|
|
1805
|
+
};
|
|
1806
|
+
},
|
|
1807
|
+
fromProtoMsg(message) {
|
|
1808
|
+
return MsgUpdateRevenue.decode(message.value);
|
|
1809
|
+
},
|
|
1810
|
+
toProto(message) {
|
|
1811
|
+
return MsgUpdateRevenue.encode(message).finish();
|
|
1812
|
+
},
|
|
1813
|
+
toProtoMsg(message) {
|
|
1814
|
+
return {
|
|
1815
|
+
typeUrl: "/evmos.revenue.v1.MsgUpdateRevenue",
|
|
1816
|
+
value: MsgUpdateRevenue.encode(message).finish()
|
|
1817
|
+
};
|
|
1818
|
+
}
|
|
1819
|
+
};
|
|
1820
|
+
function createBaseMsgCancelRevenue() {
|
|
1821
|
+
return {
|
|
1822
|
+
contractAddress: "",
|
|
1823
|
+
deployerAddress: ""
|
|
1824
|
+
};
|
|
1825
|
+
}
|
|
1826
|
+
var MsgCancelRevenue = {
|
|
1827
|
+
typeUrl: "/evmos.revenue.v1.MsgCancelRevenue",
|
|
1828
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
1829
|
+
if (message.contractAddress !== "") {
|
|
1830
|
+
writer.uint32(10).string(message.contractAddress);
|
|
1831
|
+
}
|
|
1832
|
+
if (message.deployerAddress !== "") {
|
|
1833
|
+
writer.uint32(18).string(message.deployerAddress);
|
|
1834
|
+
}
|
|
1835
|
+
return writer;
|
|
1836
|
+
},
|
|
1837
|
+
decode(input, length) {
|
|
1838
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
1839
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
1840
|
+
const message = createBaseMsgCancelRevenue();
|
|
1841
|
+
while (reader.pos < end) {
|
|
1842
|
+
const tag = reader.uint32();
|
|
1843
|
+
switch (tag >>> 3) {
|
|
1844
|
+
case 1:
|
|
1845
|
+
message.contractAddress = reader.string();
|
|
1846
|
+
break;
|
|
1847
|
+
case 2:
|
|
1848
|
+
message.deployerAddress = reader.string();
|
|
1849
|
+
break;
|
|
1850
|
+
default:
|
|
1851
|
+
reader.skipType(tag & 7);
|
|
1852
|
+
break;
|
|
1853
|
+
}
|
|
1854
|
+
}
|
|
1855
|
+
return message;
|
|
1856
|
+
},
|
|
1857
|
+
fromJSON(object) {
|
|
1858
|
+
return {
|
|
1859
|
+
contractAddress: chunkTUX4SN3U_js.isSet(object.contractAddress) ? String(object.contractAddress) : "",
|
|
1860
|
+
deployerAddress: chunkTUX4SN3U_js.isSet(object.deployerAddress) ? String(object.deployerAddress) : ""
|
|
1861
|
+
};
|
|
1862
|
+
},
|
|
1863
|
+
toJSON(message) {
|
|
1864
|
+
const obj = {};
|
|
1865
|
+
message.contractAddress !== void 0 && (obj.contractAddress = message.contractAddress);
|
|
1866
|
+
message.deployerAddress !== void 0 && (obj.deployerAddress = message.deployerAddress);
|
|
1867
|
+
return obj;
|
|
1868
|
+
},
|
|
1869
|
+
fromPartial(object) {
|
|
1870
|
+
var _a, _b;
|
|
1871
|
+
const message = createBaseMsgCancelRevenue();
|
|
1872
|
+
message.contractAddress = (_a = object.contractAddress) != null ? _a : "";
|
|
1873
|
+
message.deployerAddress = (_b = object.deployerAddress) != null ? _b : "";
|
|
1874
|
+
return message;
|
|
1875
|
+
},
|
|
1876
|
+
fromAmino(object) {
|
|
1877
|
+
const message = createBaseMsgCancelRevenue();
|
|
1878
|
+
if (object.contract_address !== void 0 && object.contract_address !== null) {
|
|
1879
|
+
message.contractAddress = object.contract_address;
|
|
1880
|
+
}
|
|
1881
|
+
if (object.deployer_address !== void 0 && object.deployer_address !== null) {
|
|
1882
|
+
message.deployerAddress = object.deployer_address;
|
|
1883
|
+
}
|
|
1884
|
+
return message;
|
|
1885
|
+
},
|
|
1886
|
+
toAmino(message) {
|
|
1887
|
+
const obj = {};
|
|
1888
|
+
obj.contract_address = message.contractAddress === "" ? void 0 : message.contractAddress;
|
|
1889
|
+
obj.deployer_address = message.deployerAddress === "" ? void 0 : message.deployerAddress;
|
|
1890
|
+
return obj;
|
|
1891
|
+
},
|
|
1892
|
+
fromAminoMsg(object) {
|
|
1893
|
+
return MsgCancelRevenue.fromAmino(object.value);
|
|
1894
|
+
},
|
|
1895
|
+
toAminoMsg(message) {
|
|
1896
|
+
return {
|
|
1897
|
+
type: "evmos/MsgCancelRevenue",
|
|
1898
|
+
value: MsgCancelRevenue.toAmino(message)
|
|
1899
|
+
};
|
|
1900
|
+
},
|
|
1901
|
+
fromProtoMsg(message) {
|
|
1902
|
+
return MsgCancelRevenue.decode(message.value);
|
|
1903
|
+
},
|
|
1904
|
+
toProto(message) {
|
|
1905
|
+
return MsgCancelRevenue.encode(message).finish();
|
|
1906
|
+
},
|
|
1907
|
+
toProtoMsg(message) {
|
|
1908
|
+
return {
|
|
1909
|
+
typeUrl: "/evmos.revenue.v1.MsgCancelRevenue",
|
|
1910
|
+
value: MsgCancelRevenue.encode(message).finish()
|
|
1911
|
+
};
|
|
1912
|
+
}
|
|
1913
|
+
};
|
|
1914
|
+
function createBaseMsgUpdateParams3() {
|
|
1915
|
+
return {
|
|
1916
|
+
authority: "",
|
|
1917
|
+
params: Params3.fromPartial({})
|
|
1918
|
+
};
|
|
1919
|
+
}
|
|
1920
|
+
var MsgUpdateParams3 = {
|
|
1921
|
+
typeUrl: "/evmos.revenue.v1.MsgUpdateParams",
|
|
1922
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
1923
|
+
if (message.authority !== "") {
|
|
1924
|
+
writer.uint32(10).string(message.authority);
|
|
1925
|
+
}
|
|
1926
|
+
if (message.params !== void 0) {
|
|
1927
|
+
Params3.encode(message.params, writer.uint32(18).fork()).ldelim();
|
|
1928
|
+
}
|
|
1929
|
+
return writer;
|
|
1930
|
+
},
|
|
1931
|
+
decode(input, length) {
|
|
1932
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
1933
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
1934
|
+
const message = createBaseMsgUpdateParams3();
|
|
1935
|
+
while (reader.pos < end) {
|
|
1936
|
+
const tag = reader.uint32();
|
|
1937
|
+
switch (tag >>> 3) {
|
|
1938
|
+
case 1:
|
|
1939
|
+
message.authority = reader.string();
|
|
1940
|
+
break;
|
|
1941
|
+
case 2:
|
|
1942
|
+
message.params = Params3.decode(reader, reader.uint32());
|
|
1943
|
+
break;
|
|
1944
|
+
default:
|
|
1945
|
+
reader.skipType(tag & 7);
|
|
1946
|
+
break;
|
|
1947
|
+
}
|
|
1948
|
+
}
|
|
1949
|
+
return message;
|
|
1950
|
+
},
|
|
1951
|
+
fromJSON(object) {
|
|
1952
|
+
return {
|
|
1953
|
+
authority: chunkTUX4SN3U_js.isSet(object.authority) ? String(object.authority) : "",
|
|
1954
|
+
params: chunkTUX4SN3U_js.isSet(object.params) ? Params3.fromJSON(object.params) : void 0
|
|
1955
|
+
};
|
|
1956
|
+
},
|
|
1957
|
+
toJSON(message) {
|
|
1958
|
+
const obj = {};
|
|
1959
|
+
message.authority !== void 0 && (obj.authority = message.authority);
|
|
1960
|
+
message.params !== void 0 && (obj.params = message.params ? Params3.toJSON(message.params) : void 0);
|
|
1961
|
+
return obj;
|
|
1962
|
+
},
|
|
1963
|
+
fromPartial(object) {
|
|
1964
|
+
var _a;
|
|
1965
|
+
const message = createBaseMsgUpdateParams3();
|
|
1966
|
+
message.authority = (_a = object.authority) != null ? _a : "";
|
|
1967
|
+
message.params = object.params !== void 0 && object.params !== null ? Params3.fromPartial(object.params) : void 0;
|
|
1968
|
+
return message;
|
|
1969
|
+
},
|
|
1970
|
+
fromAmino(object) {
|
|
1971
|
+
const message = createBaseMsgUpdateParams3();
|
|
1972
|
+
if (object.authority !== void 0 && object.authority !== null) {
|
|
1973
|
+
message.authority = object.authority;
|
|
1974
|
+
}
|
|
1975
|
+
if (object.params !== void 0 && object.params !== null) {
|
|
1976
|
+
message.params = Params3.fromAmino(object.params);
|
|
1977
|
+
}
|
|
1978
|
+
return message;
|
|
1979
|
+
},
|
|
1980
|
+
toAmino(message) {
|
|
1981
|
+
const obj = {};
|
|
1982
|
+
obj.authority = message.authority === "" ? void 0 : message.authority;
|
|
1983
|
+
obj.params = message.params ? Params3.toAmino(message.params) : void 0;
|
|
1984
|
+
return obj;
|
|
1985
|
+
},
|
|
1986
|
+
fromAminoMsg(object) {
|
|
1987
|
+
return MsgUpdateParams3.fromAmino(object.value);
|
|
1988
|
+
},
|
|
1989
|
+
toAminoMsg(message) {
|
|
1990
|
+
return {
|
|
1991
|
+
type: "evmos/MsgUpdateParams",
|
|
1992
|
+
value: MsgUpdateParams3.toAmino(message)
|
|
1993
|
+
};
|
|
1994
|
+
},
|
|
1995
|
+
fromProtoMsg(message) {
|
|
1996
|
+
return MsgUpdateParams3.decode(message.value);
|
|
1997
|
+
},
|
|
1998
|
+
toProto(message) {
|
|
1999
|
+
return MsgUpdateParams3.encode(message).finish();
|
|
2000
|
+
},
|
|
2001
|
+
toProtoMsg(message) {
|
|
2002
|
+
return {
|
|
2003
|
+
typeUrl: "/evmos.revenue.v1.MsgUpdateParams",
|
|
2004
|
+
value: MsgUpdateParams3.encode(message).finish()
|
|
2005
|
+
};
|
|
2006
|
+
}
|
|
2007
|
+
};
|
|
2008
|
+
|
|
2009
|
+
// src/codegen/evmos/revenue/v1/tx.registry.ts
|
|
2010
|
+
var registry4 = [["/evmos.revenue.v1.MsgRegisterRevenue", MsgRegisterRevenue], ["/evmos.revenue.v1.MsgUpdateRevenue", MsgUpdateRevenue], ["/evmos.revenue.v1.MsgCancelRevenue", MsgCancelRevenue], ["/evmos.revenue.v1.MsgUpdateParams", MsgUpdateParams3]];
|
|
2011
|
+
function createBaseMsgCreateClawbackVestingAccount() {
|
|
2012
|
+
return {
|
|
2013
|
+
funderAddress: "",
|
|
2014
|
+
vestingAddress: "",
|
|
2015
|
+
enableGovClawback: false
|
|
2016
|
+
};
|
|
2017
|
+
}
|
|
2018
|
+
var MsgCreateClawbackVestingAccount = {
|
|
2019
|
+
typeUrl: "/evmos.vesting.v2.MsgCreateClawbackVestingAccount",
|
|
2020
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
2021
|
+
if (message.funderAddress !== "") {
|
|
2022
|
+
writer.uint32(10).string(message.funderAddress);
|
|
2023
|
+
}
|
|
2024
|
+
if (message.vestingAddress !== "") {
|
|
2025
|
+
writer.uint32(18).string(message.vestingAddress);
|
|
2026
|
+
}
|
|
2027
|
+
if (message.enableGovClawback === true) {
|
|
2028
|
+
writer.uint32(24).bool(message.enableGovClawback);
|
|
2029
|
+
}
|
|
2030
|
+
return writer;
|
|
2031
|
+
},
|
|
2032
|
+
decode(input, length) {
|
|
2033
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
2034
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
2035
|
+
const message = createBaseMsgCreateClawbackVestingAccount();
|
|
2036
|
+
while (reader.pos < end) {
|
|
2037
|
+
const tag = reader.uint32();
|
|
2038
|
+
switch (tag >>> 3) {
|
|
2039
|
+
case 1:
|
|
2040
|
+
message.funderAddress = reader.string();
|
|
2041
|
+
break;
|
|
2042
|
+
case 2:
|
|
2043
|
+
message.vestingAddress = reader.string();
|
|
2044
|
+
break;
|
|
2045
|
+
case 3:
|
|
2046
|
+
message.enableGovClawback = reader.bool();
|
|
2047
|
+
break;
|
|
2048
|
+
default:
|
|
2049
|
+
reader.skipType(tag & 7);
|
|
2050
|
+
break;
|
|
2051
|
+
}
|
|
2052
|
+
}
|
|
2053
|
+
return message;
|
|
2054
|
+
},
|
|
2055
|
+
fromJSON(object) {
|
|
2056
|
+
return {
|
|
2057
|
+
funderAddress: chunkTUX4SN3U_js.isSet(object.funderAddress) ? String(object.funderAddress) : "",
|
|
2058
|
+
vestingAddress: chunkTUX4SN3U_js.isSet(object.vestingAddress) ? String(object.vestingAddress) : "",
|
|
2059
|
+
enableGovClawback: chunkTUX4SN3U_js.isSet(object.enableGovClawback) ? Boolean(object.enableGovClawback) : false
|
|
2060
|
+
};
|
|
2061
|
+
},
|
|
2062
|
+
toJSON(message) {
|
|
2063
|
+
const obj = {};
|
|
2064
|
+
message.funderAddress !== void 0 && (obj.funderAddress = message.funderAddress);
|
|
2065
|
+
message.vestingAddress !== void 0 && (obj.vestingAddress = message.vestingAddress);
|
|
2066
|
+
message.enableGovClawback !== void 0 && (obj.enableGovClawback = message.enableGovClawback);
|
|
2067
|
+
return obj;
|
|
2068
|
+
},
|
|
2069
|
+
fromPartial(object) {
|
|
2070
|
+
var _a, _b, _c;
|
|
2071
|
+
const message = createBaseMsgCreateClawbackVestingAccount();
|
|
2072
|
+
message.funderAddress = (_a = object.funderAddress) != null ? _a : "";
|
|
2073
|
+
message.vestingAddress = (_b = object.vestingAddress) != null ? _b : "";
|
|
2074
|
+
message.enableGovClawback = (_c = object.enableGovClawback) != null ? _c : false;
|
|
2075
|
+
return message;
|
|
2076
|
+
},
|
|
2077
|
+
fromAmino(object) {
|
|
2078
|
+
const message = createBaseMsgCreateClawbackVestingAccount();
|
|
2079
|
+
if (object.funder_address !== void 0 && object.funder_address !== null) {
|
|
2080
|
+
message.funderAddress = object.funder_address;
|
|
2081
|
+
}
|
|
2082
|
+
if (object.vesting_address !== void 0 && object.vesting_address !== null) {
|
|
2083
|
+
message.vestingAddress = object.vesting_address;
|
|
2084
|
+
}
|
|
2085
|
+
if (object.enable_gov_clawback !== void 0 && object.enable_gov_clawback !== null) {
|
|
2086
|
+
message.enableGovClawback = object.enable_gov_clawback;
|
|
2087
|
+
}
|
|
2088
|
+
return message;
|
|
2089
|
+
},
|
|
2090
|
+
toAmino(message) {
|
|
2091
|
+
const obj = {};
|
|
2092
|
+
obj.funder_address = message.funderAddress === "" ? void 0 : message.funderAddress;
|
|
2093
|
+
obj.vesting_address = message.vestingAddress === "" ? void 0 : message.vestingAddress;
|
|
2094
|
+
obj.enable_gov_clawback = message.enableGovClawback === false ? void 0 : message.enableGovClawback;
|
|
2095
|
+
return obj;
|
|
2096
|
+
},
|
|
2097
|
+
fromAminoMsg(object) {
|
|
2098
|
+
return MsgCreateClawbackVestingAccount.fromAmino(object.value);
|
|
2099
|
+
},
|
|
2100
|
+
toAminoMsg(message) {
|
|
2101
|
+
return {
|
|
2102
|
+
type: "evmos/MsgCreateClawbackVestingAccount",
|
|
2103
|
+
value: MsgCreateClawbackVestingAccount.toAmino(message)
|
|
2104
|
+
};
|
|
2105
|
+
},
|
|
2106
|
+
fromProtoMsg(message) {
|
|
2107
|
+
return MsgCreateClawbackVestingAccount.decode(message.value);
|
|
2108
|
+
},
|
|
2109
|
+
toProto(message) {
|
|
2110
|
+
return MsgCreateClawbackVestingAccount.encode(message).finish();
|
|
2111
|
+
},
|
|
2112
|
+
toProtoMsg(message) {
|
|
2113
|
+
return {
|
|
2114
|
+
typeUrl: "/evmos.vesting.v2.MsgCreateClawbackVestingAccount",
|
|
2115
|
+
value: MsgCreateClawbackVestingAccount.encode(message).finish()
|
|
2116
|
+
};
|
|
2117
|
+
}
|
|
2118
|
+
};
|
|
2119
|
+
function createBaseMsgFundVestingAccount() {
|
|
2120
|
+
return {
|
|
2121
|
+
funderAddress: "",
|
|
2122
|
+
vestingAddress: "",
|
|
2123
|
+
startTime: /* @__PURE__ */ new Date(),
|
|
2124
|
+
lockupPeriods: [],
|
|
2125
|
+
vestingPeriods: []
|
|
2126
|
+
};
|
|
2127
|
+
}
|
|
2128
|
+
var MsgFundVestingAccount = {
|
|
2129
|
+
typeUrl: "/evmos.vesting.v2.MsgFundVestingAccount",
|
|
2130
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
2131
|
+
if (message.funderAddress !== "") {
|
|
2132
|
+
writer.uint32(10).string(message.funderAddress);
|
|
2133
|
+
}
|
|
2134
|
+
if (message.vestingAddress !== "") {
|
|
2135
|
+
writer.uint32(18).string(message.vestingAddress);
|
|
2136
|
+
}
|
|
2137
|
+
if (message.startTime !== void 0) {
|
|
2138
|
+
chunkTUX4SN3U_js.Timestamp.encode(chunkTUX4SN3U_js.toTimestamp(message.startTime), writer.uint32(26).fork()).ldelim();
|
|
2139
|
+
}
|
|
2140
|
+
for (const v of message.lockupPeriods) {
|
|
2141
|
+
chunkTUX4SN3U_js.Period.encode(v, writer.uint32(34).fork()).ldelim();
|
|
2142
|
+
}
|
|
2143
|
+
for (const v of message.vestingPeriods) {
|
|
2144
|
+
chunkTUX4SN3U_js.Period.encode(v, writer.uint32(42).fork()).ldelim();
|
|
2145
|
+
}
|
|
2146
|
+
return writer;
|
|
2147
|
+
},
|
|
2148
|
+
decode(input, length) {
|
|
2149
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
2150
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
2151
|
+
const message = createBaseMsgFundVestingAccount();
|
|
2152
|
+
while (reader.pos < end) {
|
|
2153
|
+
const tag = reader.uint32();
|
|
2154
|
+
switch (tag >>> 3) {
|
|
2155
|
+
case 1:
|
|
2156
|
+
message.funderAddress = reader.string();
|
|
2157
|
+
break;
|
|
2158
|
+
case 2:
|
|
2159
|
+
message.vestingAddress = reader.string();
|
|
2160
|
+
break;
|
|
2161
|
+
case 3:
|
|
2162
|
+
message.startTime = chunkTUX4SN3U_js.fromTimestamp(chunkTUX4SN3U_js.Timestamp.decode(reader, reader.uint32()));
|
|
2163
|
+
break;
|
|
2164
|
+
case 4:
|
|
2165
|
+
message.lockupPeriods.push(chunkTUX4SN3U_js.Period.decode(reader, reader.uint32()));
|
|
2166
|
+
break;
|
|
2167
|
+
case 5:
|
|
2168
|
+
message.vestingPeriods.push(chunkTUX4SN3U_js.Period.decode(reader, reader.uint32()));
|
|
2169
|
+
break;
|
|
2170
|
+
default:
|
|
2171
|
+
reader.skipType(tag & 7);
|
|
2172
|
+
break;
|
|
2173
|
+
}
|
|
2174
|
+
}
|
|
2175
|
+
return message;
|
|
2176
|
+
},
|
|
2177
|
+
fromJSON(object) {
|
|
2178
|
+
return {
|
|
2179
|
+
funderAddress: chunkTUX4SN3U_js.isSet(object.funderAddress) ? String(object.funderAddress) : "",
|
|
2180
|
+
vestingAddress: chunkTUX4SN3U_js.isSet(object.vestingAddress) ? String(object.vestingAddress) : "",
|
|
2181
|
+
startTime: chunkTUX4SN3U_js.isSet(object.startTime) ? chunkTUX4SN3U_js.fromJsonTimestamp(object.startTime) : void 0,
|
|
2182
|
+
lockupPeriods: Array.isArray(object == null ? void 0 : object.lockupPeriods) ? object.lockupPeriods.map((e) => chunkTUX4SN3U_js.Period.fromJSON(e)) : [],
|
|
2183
|
+
vestingPeriods: Array.isArray(object == null ? void 0 : object.vestingPeriods) ? object.vestingPeriods.map((e) => chunkTUX4SN3U_js.Period.fromJSON(e)) : []
|
|
2184
|
+
};
|
|
2185
|
+
},
|
|
2186
|
+
toJSON(message) {
|
|
2187
|
+
const obj = {};
|
|
2188
|
+
message.funderAddress !== void 0 && (obj.funderAddress = message.funderAddress);
|
|
2189
|
+
message.vestingAddress !== void 0 && (obj.vestingAddress = message.vestingAddress);
|
|
2190
|
+
message.startTime !== void 0 && (obj.startTime = message.startTime.toISOString());
|
|
2191
|
+
if (message.lockupPeriods) {
|
|
2192
|
+
obj.lockupPeriods = message.lockupPeriods.map((e) => e ? chunkTUX4SN3U_js.Period.toJSON(e) : void 0);
|
|
2193
|
+
} else {
|
|
2194
|
+
obj.lockupPeriods = [];
|
|
2195
|
+
}
|
|
2196
|
+
if (message.vestingPeriods) {
|
|
2197
|
+
obj.vestingPeriods = message.vestingPeriods.map((e) => e ? chunkTUX4SN3U_js.Period.toJSON(e) : void 0);
|
|
2198
|
+
} else {
|
|
2199
|
+
obj.vestingPeriods = [];
|
|
2200
|
+
}
|
|
2201
|
+
return obj;
|
|
2202
|
+
},
|
|
2203
|
+
fromPartial(object) {
|
|
2204
|
+
var _a, _b, _c, _d, _e;
|
|
2205
|
+
const message = createBaseMsgFundVestingAccount();
|
|
2206
|
+
message.funderAddress = (_a = object.funderAddress) != null ? _a : "";
|
|
2207
|
+
message.vestingAddress = (_b = object.vestingAddress) != null ? _b : "";
|
|
2208
|
+
message.startTime = (_c = object.startTime) != null ? _c : void 0;
|
|
2209
|
+
message.lockupPeriods = ((_d = object.lockupPeriods) == null ? void 0 : _d.map((e) => chunkTUX4SN3U_js.Period.fromPartial(e))) || [];
|
|
2210
|
+
message.vestingPeriods = ((_e = object.vestingPeriods) == null ? void 0 : _e.map((e) => chunkTUX4SN3U_js.Period.fromPartial(e))) || [];
|
|
2211
|
+
return message;
|
|
2212
|
+
},
|
|
2213
|
+
fromAmino(object) {
|
|
2214
|
+
var _a, _b;
|
|
2215
|
+
const message = createBaseMsgFundVestingAccount();
|
|
2216
|
+
if (object.funder_address !== void 0 && object.funder_address !== null) {
|
|
2217
|
+
message.funderAddress = object.funder_address;
|
|
2218
|
+
}
|
|
2219
|
+
if (object.vesting_address !== void 0 && object.vesting_address !== null) {
|
|
2220
|
+
message.vestingAddress = object.vesting_address;
|
|
2221
|
+
}
|
|
2222
|
+
if (object.start_time !== void 0 && object.start_time !== null) {
|
|
2223
|
+
message.startTime = chunkTUX4SN3U_js.fromTimestamp(chunkTUX4SN3U_js.Timestamp.fromAmino(object.start_time));
|
|
2224
|
+
}
|
|
2225
|
+
message.lockupPeriods = ((_a = object.lockup_periods) == null ? void 0 : _a.map((e) => chunkTUX4SN3U_js.Period.fromAmino(e))) || [];
|
|
2226
|
+
message.vestingPeriods = ((_b = object.vesting_periods) == null ? void 0 : _b.map((e) => chunkTUX4SN3U_js.Period.fromAmino(e))) || [];
|
|
2227
|
+
return message;
|
|
2228
|
+
},
|
|
2229
|
+
toAmino(message) {
|
|
2230
|
+
const obj = {};
|
|
2231
|
+
obj.funder_address = message.funderAddress === "" ? void 0 : message.funderAddress;
|
|
2232
|
+
obj.vesting_address = message.vestingAddress === "" ? void 0 : message.vestingAddress;
|
|
2233
|
+
obj.start_time = message.startTime ? chunkTUX4SN3U_js.Timestamp.toAmino(chunkTUX4SN3U_js.toTimestamp(message.startTime)) : void 0;
|
|
2234
|
+
if (message.lockupPeriods) {
|
|
2235
|
+
obj.lockup_periods = message.lockupPeriods.map((e) => e ? chunkTUX4SN3U_js.Period.toAmino(e) : void 0);
|
|
2236
|
+
} else {
|
|
2237
|
+
obj.lockup_periods = message.lockupPeriods;
|
|
2238
|
+
}
|
|
2239
|
+
if (message.vestingPeriods) {
|
|
2240
|
+
obj.vesting_periods = message.vestingPeriods.map((e) => e ? chunkTUX4SN3U_js.Period.toAmino(e) : void 0);
|
|
2241
|
+
} else {
|
|
2242
|
+
obj.vesting_periods = message.vestingPeriods;
|
|
2243
|
+
}
|
|
2244
|
+
return obj;
|
|
2245
|
+
},
|
|
2246
|
+
fromAminoMsg(object) {
|
|
2247
|
+
return MsgFundVestingAccount.fromAmino(object.value);
|
|
2248
|
+
},
|
|
2249
|
+
toAminoMsg(message) {
|
|
2250
|
+
return {
|
|
2251
|
+
type: "evmos/MsgFundVestingAccount",
|
|
2252
|
+
value: MsgFundVestingAccount.toAmino(message)
|
|
2253
|
+
};
|
|
2254
|
+
},
|
|
2255
|
+
fromProtoMsg(message) {
|
|
2256
|
+
return MsgFundVestingAccount.decode(message.value);
|
|
2257
|
+
},
|
|
2258
|
+
toProto(message) {
|
|
2259
|
+
return MsgFundVestingAccount.encode(message).finish();
|
|
2260
|
+
},
|
|
2261
|
+
toProtoMsg(message) {
|
|
2262
|
+
return {
|
|
2263
|
+
typeUrl: "/evmos.vesting.v2.MsgFundVestingAccount",
|
|
2264
|
+
value: MsgFundVestingAccount.encode(message).finish()
|
|
2265
|
+
};
|
|
2266
|
+
}
|
|
2267
|
+
};
|
|
2268
|
+
function createBaseMsgClawback() {
|
|
2269
|
+
return {
|
|
2270
|
+
funderAddress: "",
|
|
2271
|
+
accountAddress: "",
|
|
2272
|
+
destAddress: ""
|
|
2273
|
+
};
|
|
2274
|
+
}
|
|
2275
|
+
var MsgClawback = {
|
|
2276
|
+
typeUrl: "/evmos.vesting.v2.MsgClawback",
|
|
2277
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
2278
|
+
if (message.funderAddress !== "") {
|
|
2279
|
+
writer.uint32(10).string(message.funderAddress);
|
|
2280
|
+
}
|
|
2281
|
+
if (message.accountAddress !== "") {
|
|
2282
|
+
writer.uint32(18).string(message.accountAddress);
|
|
2283
|
+
}
|
|
2284
|
+
if (message.destAddress !== "") {
|
|
2285
|
+
writer.uint32(26).string(message.destAddress);
|
|
2286
|
+
}
|
|
2287
|
+
return writer;
|
|
2288
|
+
},
|
|
2289
|
+
decode(input, length) {
|
|
2290
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
2291
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
2292
|
+
const message = createBaseMsgClawback();
|
|
2293
|
+
while (reader.pos < end) {
|
|
2294
|
+
const tag = reader.uint32();
|
|
2295
|
+
switch (tag >>> 3) {
|
|
2296
|
+
case 1:
|
|
2297
|
+
message.funderAddress = reader.string();
|
|
2298
|
+
break;
|
|
2299
|
+
case 2:
|
|
2300
|
+
message.accountAddress = reader.string();
|
|
2301
|
+
break;
|
|
2302
|
+
case 3:
|
|
2303
|
+
message.destAddress = reader.string();
|
|
2304
|
+
break;
|
|
2305
|
+
default:
|
|
2306
|
+
reader.skipType(tag & 7);
|
|
2307
|
+
break;
|
|
2308
|
+
}
|
|
2309
|
+
}
|
|
2310
|
+
return message;
|
|
2311
|
+
},
|
|
2312
|
+
fromJSON(object) {
|
|
2313
|
+
return {
|
|
2314
|
+
funderAddress: chunkTUX4SN3U_js.isSet(object.funderAddress) ? String(object.funderAddress) : "",
|
|
2315
|
+
accountAddress: chunkTUX4SN3U_js.isSet(object.accountAddress) ? String(object.accountAddress) : "",
|
|
2316
|
+
destAddress: chunkTUX4SN3U_js.isSet(object.destAddress) ? String(object.destAddress) : ""
|
|
2317
|
+
};
|
|
2318
|
+
},
|
|
2319
|
+
toJSON(message) {
|
|
2320
|
+
const obj = {};
|
|
2321
|
+
message.funderAddress !== void 0 && (obj.funderAddress = message.funderAddress);
|
|
2322
|
+
message.accountAddress !== void 0 && (obj.accountAddress = message.accountAddress);
|
|
2323
|
+
message.destAddress !== void 0 && (obj.destAddress = message.destAddress);
|
|
2324
|
+
return obj;
|
|
2325
|
+
},
|
|
2326
|
+
fromPartial(object) {
|
|
2327
|
+
var _a, _b, _c;
|
|
2328
|
+
const message = createBaseMsgClawback();
|
|
2329
|
+
message.funderAddress = (_a = object.funderAddress) != null ? _a : "";
|
|
2330
|
+
message.accountAddress = (_b = object.accountAddress) != null ? _b : "";
|
|
2331
|
+
message.destAddress = (_c = object.destAddress) != null ? _c : "";
|
|
2332
|
+
return message;
|
|
2333
|
+
},
|
|
2334
|
+
fromAmino(object) {
|
|
2335
|
+
const message = createBaseMsgClawback();
|
|
2336
|
+
if (object.funder_address !== void 0 && object.funder_address !== null) {
|
|
2337
|
+
message.funderAddress = object.funder_address;
|
|
2338
|
+
}
|
|
2339
|
+
if (object.account_address !== void 0 && object.account_address !== null) {
|
|
2340
|
+
message.accountAddress = object.account_address;
|
|
2341
|
+
}
|
|
2342
|
+
if (object.dest_address !== void 0 && object.dest_address !== null) {
|
|
2343
|
+
message.destAddress = object.dest_address;
|
|
2344
|
+
}
|
|
2345
|
+
return message;
|
|
2346
|
+
},
|
|
2347
|
+
toAmino(message) {
|
|
2348
|
+
const obj = {};
|
|
2349
|
+
obj.funder_address = message.funderAddress === "" ? void 0 : message.funderAddress;
|
|
2350
|
+
obj.account_address = message.accountAddress === "" ? void 0 : message.accountAddress;
|
|
2351
|
+
obj.dest_address = message.destAddress === "" ? void 0 : message.destAddress;
|
|
2352
|
+
return obj;
|
|
2353
|
+
},
|
|
2354
|
+
fromAminoMsg(object) {
|
|
2355
|
+
return MsgClawback.fromAmino(object.value);
|
|
2356
|
+
},
|
|
2357
|
+
toAminoMsg(message) {
|
|
2358
|
+
return {
|
|
2359
|
+
type: "evmos/MsgClawback",
|
|
2360
|
+
value: MsgClawback.toAmino(message)
|
|
2361
|
+
};
|
|
2362
|
+
},
|
|
2363
|
+
fromProtoMsg(message) {
|
|
2364
|
+
return MsgClawback.decode(message.value);
|
|
2365
|
+
},
|
|
2366
|
+
toProto(message) {
|
|
2367
|
+
return MsgClawback.encode(message).finish();
|
|
2368
|
+
},
|
|
2369
|
+
toProtoMsg(message) {
|
|
2370
|
+
return {
|
|
2371
|
+
typeUrl: "/evmos.vesting.v2.MsgClawback",
|
|
2372
|
+
value: MsgClawback.encode(message).finish()
|
|
2373
|
+
};
|
|
2374
|
+
}
|
|
2375
|
+
};
|
|
2376
|
+
function createBaseMsgUpdateVestingFunder() {
|
|
2377
|
+
return {
|
|
2378
|
+
funderAddress: "",
|
|
2379
|
+
newFunderAddress: "",
|
|
2380
|
+
vestingAddress: ""
|
|
2381
|
+
};
|
|
2382
|
+
}
|
|
2383
|
+
var MsgUpdateVestingFunder = {
|
|
2384
|
+
typeUrl: "/evmos.vesting.v2.MsgUpdateVestingFunder",
|
|
2385
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
2386
|
+
if (message.funderAddress !== "") {
|
|
2387
|
+
writer.uint32(10).string(message.funderAddress);
|
|
2388
|
+
}
|
|
2389
|
+
if (message.newFunderAddress !== "") {
|
|
2390
|
+
writer.uint32(18).string(message.newFunderAddress);
|
|
2391
|
+
}
|
|
2392
|
+
if (message.vestingAddress !== "") {
|
|
2393
|
+
writer.uint32(26).string(message.vestingAddress);
|
|
2394
|
+
}
|
|
2395
|
+
return writer;
|
|
2396
|
+
},
|
|
2397
|
+
decode(input, length) {
|
|
2398
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
2399
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
2400
|
+
const message = createBaseMsgUpdateVestingFunder();
|
|
2401
|
+
while (reader.pos < end) {
|
|
2402
|
+
const tag = reader.uint32();
|
|
2403
|
+
switch (tag >>> 3) {
|
|
2404
|
+
case 1:
|
|
2405
|
+
message.funderAddress = reader.string();
|
|
2406
|
+
break;
|
|
2407
|
+
case 2:
|
|
2408
|
+
message.newFunderAddress = reader.string();
|
|
2409
|
+
break;
|
|
2410
|
+
case 3:
|
|
2411
|
+
message.vestingAddress = reader.string();
|
|
2412
|
+
break;
|
|
2413
|
+
default:
|
|
2414
|
+
reader.skipType(tag & 7);
|
|
2415
|
+
break;
|
|
2416
|
+
}
|
|
2417
|
+
}
|
|
2418
|
+
return message;
|
|
2419
|
+
},
|
|
2420
|
+
fromJSON(object) {
|
|
2421
|
+
return {
|
|
2422
|
+
funderAddress: chunkTUX4SN3U_js.isSet(object.funderAddress) ? String(object.funderAddress) : "",
|
|
2423
|
+
newFunderAddress: chunkTUX4SN3U_js.isSet(object.newFunderAddress) ? String(object.newFunderAddress) : "",
|
|
2424
|
+
vestingAddress: chunkTUX4SN3U_js.isSet(object.vestingAddress) ? String(object.vestingAddress) : ""
|
|
2425
|
+
};
|
|
2426
|
+
},
|
|
2427
|
+
toJSON(message) {
|
|
2428
|
+
const obj = {};
|
|
2429
|
+
message.funderAddress !== void 0 && (obj.funderAddress = message.funderAddress);
|
|
2430
|
+
message.newFunderAddress !== void 0 && (obj.newFunderAddress = message.newFunderAddress);
|
|
2431
|
+
message.vestingAddress !== void 0 && (obj.vestingAddress = message.vestingAddress);
|
|
2432
|
+
return obj;
|
|
2433
|
+
},
|
|
2434
|
+
fromPartial(object) {
|
|
2435
|
+
var _a, _b, _c;
|
|
2436
|
+
const message = createBaseMsgUpdateVestingFunder();
|
|
2437
|
+
message.funderAddress = (_a = object.funderAddress) != null ? _a : "";
|
|
2438
|
+
message.newFunderAddress = (_b = object.newFunderAddress) != null ? _b : "";
|
|
2439
|
+
message.vestingAddress = (_c = object.vestingAddress) != null ? _c : "";
|
|
2440
|
+
return message;
|
|
2441
|
+
},
|
|
2442
|
+
fromAmino(object) {
|
|
2443
|
+
const message = createBaseMsgUpdateVestingFunder();
|
|
2444
|
+
if (object.funder_address !== void 0 && object.funder_address !== null) {
|
|
2445
|
+
message.funderAddress = object.funder_address;
|
|
2446
|
+
}
|
|
2447
|
+
if (object.new_funder_address !== void 0 && object.new_funder_address !== null) {
|
|
2448
|
+
message.newFunderAddress = object.new_funder_address;
|
|
2449
|
+
}
|
|
2450
|
+
if (object.vesting_address !== void 0 && object.vesting_address !== null) {
|
|
2451
|
+
message.vestingAddress = object.vesting_address;
|
|
2452
|
+
}
|
|
2453
|
+
return message;
|
|
2454
|
+
},
|
|
2455
|
+
toAmino(message) {
|
|
2456
|
+
const obj = {};
|
|
2457
|
+
obj.funder_address = message.funderAddress === "" ? void 0 : message.funderAddress;
|
|
2458
|
+
obj.new_funder_address = message.newFunderAddress === "" ? void 0 : message.newFunderAddress;
|
|
2459
|
+
obj.vesting_address = message.vestingAddress === "" ? void 0 : message.vestingAddress;
|
|
2460
|
+
return obj;
|
|
2461
|
+
},
|
|
2462
|
+
fromAminoMsg(object) {
|
|
2463
|
+
return MsgUpdateVestingFunder.fromAmino(object.value);
|
|
2464
|
+
},
|
|
2465
|
+
toAminoMsg(message) {
|
|
2466
|
+
return {
|
|
2467
|
+
type: "evmos/MsgUpdateVestingFunder",
|
|
2468
|
+
value: MsgUpdateVestingFunder.toAmino(message)
|
|
2469
|
+
};
|
|
2470
|
+
},
|
|
2471
|
+
fromProtoMsg(message) {
|
|
2472
|
+
return MsgUpdateVestingFunder.decode(message.value);
|
|
2473
|
+
},
|
|
2474
|
+
toProto(message) {
|
|
2475
|
+
return MsgUpdateVestingFunder.encode(message).finish();
|
|
2476
|
+
},
|
|
2477
|
+
toProtoMsg(message) {
|
|
2478
|
+
return {
|
|
2479
|
+
typeUrl: "/evmos.vesting.v2.MsgUpdateVestingFunder",
|
|
2480
|
+
value: MsgUpdateVestingFunder.encode(message).finish()
|
|
2481
|
+
};
|
|
2482
|
+
}
|
|
2483
|
+
};
|
|
2484
|
+
function createBaseMsgConvertVestingAccount() {
|
|
2485
|
+
return {
|
|
2486
|
+
vestingAddress: ""
|
|
2487
|
+
};
|
|
2488
|
+
}
|
|
2489
|
+
var MsgConvertVestingAccount = {
|
|
2490
|
+
typeUrl: "/evmos.vesting.v2.MsgConvertVestingAccount",
|
|
2491
|
+
encode(message, writer = _m08__namespace.Writer.create()) {
|
|
2492
|
+
if (message.vestingAddress !== "") {
|
|
2493
|
+
writer.uint32(10).string(message.vestingAddress);
|
|
2494
|
+
}
|
|
2495
|
+
return writer;
|
|
2496
|
+
},
|
|
2497
|
+
decode(input, length) {
|
|
2498
|
+
const reader = input instanceof _m08__namespace.Reader ? input : new _m08__namespace.Reader(input);
|
|
2499
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
2500
|
+
const message = createBaseMsgConvertVestingAccount();
|
|
2501
|
+
while (reader.pos < end) {
|
|
2502
|
+
const tag = reader.uint32();
|
|
2503
|
+
switch (tag >>> 3) {
|
|
2504
|
+
case 1:
|
|
2505
|
+
message.vestingAddress = reader.string();
|
|
2506
|
+
break;
|
|
2507
|
+
default:
|
|
2508
|
+
reader.skipType(tag & 7);
|
|
2509
|
+
break;
|
|
2510
|
+
}
|
|
2511
|
+
}
|
|
2512
|
+
return message;
|
|
2513
|
+
},
|
|
2514
|
+
fromJSON(object) {
|
|
2515
|
+
return {
|
|
2516
|
+
vestingAddress: chunkTUX4SN3U_js.isSet(object.vestingAddress) ? String(object.vestingAddress) : ""
|
|
2517
|
+
};
|
|
2518
|
+
},
|
|
2519
|
+
toJSON(message) {
|
|
2520
|
+
const obj = {};
|
|
2521
|
+
message.vestingAddress !== void 0 && (obj.vestingAddress = message.vestingAddress);
|
|
2522
|
+
return obj;
|
|
2523
|
+
},
|
|
2524
|
+
fromPartial(object) {
|
|
2525
|
+
var _a;
|
|
2526
|
+
const message = createBaseMsgConvertVestingAccount();
|
|
2527
|
+
message.vestingAddress = (_a = object.vestingAddress) != null ? _a : "";
|
|
2528
|
+
return message;
|
|
2529
|
+
},
|
|
2530
|
+
fromAmino(object) {
|
|
2531
|
+
const message = createBaseMsgConvertVestingAccount();
|
|
2532
|
+
if (object.vesting_address !== void 0 && object.vesting_address !== null) {
|
|
2533
|
+
message.vestingAddress = object.vesting_address;
|
|
2534
|
+
}
|
|
2535
|
+
return message;
|
|
2536
|
+
},
|
|
2537
|
+
toAmino(message) {
|
|
2538
|
+
const obj = {};
|
|
2539
|
+
obj.vesting_address = message.vestingAddress === "" ? void 0 : message.vestingAddress;
|
|
2540
|
+
return obj;
|
|
2541
|
+
},
|
|
2542
|
+
fromAminoMsg(object) {
|
|
2543
|
+
return MsgConvertVestingAccount.fromAmino(object.value);
|
|
2544
|
+
},
|
|
2545
|
+
toAminoMsg(message) {
|
|
2546
|
+
return {
|
|
2547
|
+
type: "evmos/MsgConvertVestingAccount",
|
|
2548
|
+
value: MsgConvertVestingAccount.toAmino(message)
|
|
2549
|
+
};
|
|
2550
|
+
},
|
|
2551
|
+
fromProtoMsg(message) {
|
|
2552
|
+
return MsgConvertVestingAccount.decode(message.value);
|
|
2553
|
+
},
|
|
2554
|
+
toProto(message) {
|
|
2555
|
+
return MsgConvertVestingAccount.encode(message).finish();
|
|
2556
|
+
},
|
|
2557
|
+
toProtoMsg(message) {
|
|
2558
|
+
return {
|
|
2559
|
+
typeUrl: "/evmos.vesting.v2.MsgConvertVestingAccount",
|
|
2560
|
+
value: MsgConvertVestingAccount.encode(message).finish()
|
|
2561
|
+
};
|
|
2562
|
+
}
|
|
2563
|
+
};
|
|
2564
|
+
|
|
2565
|
+
// src/codegen/evmos/vesting/v2/tx.registry.ts
|
|
2566
|
+
var registry5 = [["/evmos.vesting.v2.MsgCreateClawbackVestingAccount", MsgCreateClawbackVestingAccount], ["/evmos.vesting.v2.MsgFundVestingAccount", MsgFundVestingAccount], ["/evmos.vesting.v2.MsgClawback", MsgClawback], ["/evmos.vesting.v2.MsgUpdateVestingFunder", MsgUpdateVestingFunder], ["/evmos.vesting.v2.MsgConvertVestingAccount", MsgConvertVestingAccount]];
|
|
2567
|
+
|
|
2568
|
+
// src/codegen/evmos/erc20/v1/tx.amino.ts
|
|
2569
|
+
var AminoConverter2 = {
|
|
2570
|
+
"/evmos.erc20.v1.MsgConvertCoin": {
|
|
2571
|
+
aminoType: "evmos/MsgConvertCoin",
|
|
2572
|
+
toAmino: MsgConvertCoin.toAmino,
|
|
2573
|
+
fromAmino: MsgConvertCoin.fromAmino
|
|
2574
|
+
},
|
|
2575
|
+
"/evmos.erc20.v1.MsgConvertERC20": {
|
|
2576
|
+
aminoType: "evmos/MsgConvertERC20",
|
|
2577
|
+
toAmino: MsgConvertERC20.toAmino,
|
|
2578
|
+
fromAmino: MsgConvertERC20.fromAmino
|
|
2579
|
+
},
|
|
2580
|
+
"/evmos.erc20.v1.MsgUpdateParams": {
|
|
2581
|
+
aminoType: "evmos/erc20/MsgUpdateParams",
|
|
2582
|
+
toAmino: MsgUpdateParams.toAmino,
|
|
2583
|
+
fromAmino: MsgUpdateParams.fromAmino
|
|
2584
|
+
}
|
|
2585
|
+
};
|
|
2586
|
+
|
|
2587
|
+
// src/codegen/evmos/inflation/v1/tx.amino.ts
|
|
2588
|
+
var AminoConverter3 = {
|
|
2589
|
+
"/evmos.inflation.v1.MsgUpdateParams": {
|
|
2590
|
+
aminoType: "evmos/inflation/MsgUpdateParams",
|
|
2591
|
+
toAmino: MsgUpdateParams2.toAmino,
|
|
2592
|
+
fromAmino: MsgUpdateParams2.fromAmino
|
|
2593
|
+
}
|
|
2594
|
+
};
|
|
2595
|
+
|
|
2596
|
+
// src/codegen/evmos/revenue/v1/tx.amino.ts
|
|
2597
|
+
var AminoConverter4 = {
|
|
2598
|
+
"/evmos.revenue.v1.MsgRegisterRevenue": {
|
|
2599
|
+
aminoType: "evmos/MsgRegisterRevenue",
|
|
2600
|
+
toAmino: MsgRegisterRevenue.toAmino,
|
|
2601
|
+
fromAmino: MsgRegisterRevenue.fromAmino
|
|
2602
|
+
},
|
|
2603
|
+
"/evmos.revenue.v1.MsgUpdateRevenue": {
|
|
2604
|
+
aminoType: "evmos/MsgUpdateRevenue",
|
|
2605
|
+
toAmino: MsgUpdateRevenue.toAmino,
|
|
2606
|
+
fromAmino: MsgUpdateRevenue.fromAmino
|
|
2607
|
+
},
|
|
2608
|
+
"/evmos.revenue.v1.MsgCancelRevenue": {
|
|
2609
|
+
aminoType: "evmos/MsgCancelRevenue",
|
|
2610
|
+
toAmino: MsgCancelRevenue.toAmino,
|
|
2611
|
+
fromAmino: MsgCancelRevenue.fromAmino
|
|
2612
|
+
},
|
|
2613
|
+
"/evmos.revenue.v1.MsgUpdateParams": {
|
|
2614
|
+
aminoType: "evmos/MsgUpdateParams",
|
|
2615
|
+
toAmino: MsgUpdateParams3.toAmino,
|
|
2616
|
+
fromAmino: MsgUpdateParams3.fromAmino
|
|
2617
|
+
}
|
|
2618
|
+
};
|
|
2619
|
+
|
|
2620
|
+
// src/codegen/evmos/vesting/v2/tx.amino.ts
|
|
2621
|
+
var AminoConverter5 = {
|
|
2622
|
+
"/evmos.vesting.v2.MsgCreateClawbackVestingAccount": {
|
|
2623
|
+
aminoType: "evmos/MsgCreateClawbackVestingAccount",
|
|
2624
|
+
toAmino: MsgCreateClawbackVestingAccount.toAmino,
|
|
2625
|
+
fromAmino: MsgCreateClawbackVestingAccount.fromAmino
|
|
2626
|
+
},
|
|
2627
|
+
"/evmos.vesting.v2.MsgFundVestingAccount": {
|
|
2628
|
+
aminoType: "evmos/MsgFundVestingAccount",
|
|
2629
|
+
toAmino: MsgFundVestingAccount.toAmino,
|
|
2630
|
+
fromAmino: MsgFundVestingAccount.fromAmino
|
|
2631
|
+
},
|
|
2632
|
+
"/evmos.vesting.v2.MsgClawback": {
|
|
2633
|
+
aminoType: "evmos/MsgClawback",
|
|
2634
|
+
toAmino: MsgClawback.toAmino,
|
|
2635
|
+
fromAmino: MsgClawback.fromAmino
|
|
2636
|
+
},
|
|
2637
|
+
"/evmos.vesting.v2.MsgUpdateVestingFunder": {
|
|
2638
|
+
aminoType: "evmos/MsgUpdateVestingFunder",
|
|
2639
|
+
toAmino: MsgUpdateVestingFunder.toAmino,
|
|
2640
|
+
fromAmino: MsgUpdateVestingFunder.fromAmino
|
|
2641
|
+
},
|
|
2642
|
+
"/evmos.vesting.v2.MsgConvertVestingAccount": {
|
|
2643
|
+
aminoType: "evmos/MsgConvertVestingAccount",
|
|
2644
|
+
toAmino: MsgConvertVestingAccount.toAmino,
|
|
2645
|
+
fromAmino: MsgConvertVestingAccount.fromAmino
|
|
2646
|
+
}
|
|
2647
|
+
};
|
|
2648
|
+
|
|
2649
|
+
// src/codegen/evmos/client.ts
|
|
2650
|
+
var evmosAminoConverters = chunk6FNC3XMI_js.__spreadValues(chunk6FNC3XMI_js.__spreadValues(chunk6FNC3XMI_js.__spreadValues(chunk6FNC3XMI_js.__spreadValues({}, AminoConverter2), AminoConverter3), AminoConverter4), AminoConverter5);
|
|
2651
|
+
var evmosProtoRegistry = [...registry2, ...registry3, ...registry4, ...registry5];
|
|
2652
|
+
|
|
2653
|
+
// src/constants/abis.ts
|
|
2654
|
+
function createAbi(abi) {
|
|
2655
|
+
return abi;
|
|
2656
|
+
}
|
|
2657
|
+
var erc20ABI = /* @__PURE__ */ createAbi([
|
|
2658
|
+
{
|
|
2659
|
+
type: "event",
|
|
2660
|
+
name: "Approval",
|
|
2661
|
+
inputs: [
|
|
2662
|
+
{
|
|
2663
|
+
indexed: true,
|
|
2664
|
+
name: "owner",
|
|
2665
|
+
type: "address"
|
|
2666
|
+
},
|
|
2667
|
+
{
|
|
2668
|
+
indexed: true,
|
|
2669
|
+
name: "spender",
|
|
2670
|
+
type: "address"
|
|
2671
|
+
},
|
|
2672
|
+
{
|
|
2673
|
+
indexed: false,
|
|
2674
|
+
name: "value",
|
|
2675
|
+
type: "uint256"
|
|
2676
|
+
}
|
|
2677
|
+
]
|
|
2678
|
+
},
|
|
2679
|
+
{
|
|
2680
|
+
type: "event",
|
|
2681
|
+
name: "Transfer",
|
|
2682
|
+
inputs: [
|
|
2683
|
+
{
|
|
2684
|
+
indexed: true,
|
|
2685
|
+
name: "from",
|
|
2686
|
+
type: "address"
|
|
2687
|
+
},
|
|
2688
|
+
{
|
|
2689
|
+
indexed: true,
|
|
2690
|
+
name: "to",
|
|
2691
|
+
type: "address"
|
|
2692
|
+
},
|
|
2693
|
+
{
|
|
2694
|
+
indexed: false,
|
|
2695
|
+
name: "value",
|
|
2696
|
+
type: "uint256"
|
|
2697
|
+
}
|
|
2698
|
+
]
|
|
2699
|
+
},
|
|
2700
|
+
{
|
|
2701
|
+
type: "function",
|
|
2702
|
+
name: "allowance",
|
|
2703
|
+
stateMutability: "view",
|
|
2704
|
+
inputs: [
|
|
2705
|
+
{
|
|
2706
|
+
name: "owner",
|
|
2707
|
+
type: "address"
|
|
2708
|
+
},
|
|
2709
|
+
{
|
|
2710
|
+
name: "spender",
|
|
2711
|
+
type: "address"
|
|
2712
|
+
}
|
|
2713
|
+
],
|
|
2714
|
+
outputs: [
|
|
2715
|
+
{
|
|
2716
|
+
name: "",
|
|
2717
|
+
type: "uint256"
|
|
2718
|
+
}
|
|
2719
|
+
]
|
|
2720
|
+
},
|
|
2721
|
+
{
|
|
2722
|
+
type: "function",
|
|
2723
|
+
name: "approve",
|
|
2724
|
+
stateMutability: "nonpayable",
|
|
2725
|
+
inputs: [
|
|
2726
|
+
{
|
|
2727
|
+
name: "spender",
|
|
2728
|
+
type: "address"
|
|
2729
|
+
},
|
|
2730
|
+
{
|
|
2731
|
+
name: "amount",
|
|
2732
|
+
type: "uint256"
|
|
2733
|
+
}
|
|
2734
|
+
],
|
|
2735
|
+
outputs: [
|
|
2736
|
+
{
|
|
2737
|
+
name: "",
|
|
2738
|
+
type: "bool"
|
|
2739
|
+
}
|
|
2740
|
+
]
|
|
2741
|
+
},
|
|
2742
|
+
{
|
|
2743
|
+
type: "function",
|
|
2744
|
+
name: "balanceOf",
|
|
2745
|
+
stateMutability: "view",
|
|
2746
|
+
inputs: [
|
|
2747
|
+
{
|
|
2748
|
+
name: "account",
|
|
2749
|
+
type: "address"
|
|
2750
|
+
}
|
|
2751
|
+
],
|
|
2752
|
+
outputs: [
|
|
2753
|
+
{
|
|
2754
|
+
name: "",
|
|
2755
|
+
type: "uint256"
|
|
2756
|
+
}
|
|
2757
|
+
]
|
|
2758
|
+
},
|
|
2759
|
+
{
|
|
2760
|
+
type: "function",
|
|
2761
|
+
name: "decimals",
|
|
2762
|
+
stateMutability: "view",
|
|
2763
|
+
inputs: [],
|
|
2764
|
+
outputs: [
|
|
2765
|
+
{
|
|
2766
|
+
name: "",
|
|
2767
|
+
type: "uint8"
|
|
2768
|
+
}
|
|
2769
|
+
]
|
|
2770
|
+
},
|
|
2771
|
+
{
|
|
2772
|
+
type: "function",
|
|
2773
|
+
name: "name",
|
|
2774
|
+
stateMutability: "view",
|
|
2775
|
+
inputs: [],
|
|
2776
|
+
outputs: [
|
|
2777
|
+
{
|
|
2778
|
+
name: "",
|
|
2779
|
+
type: "string"
|
|
2780
|
+
}
|
|
2781
|
+
]
|
|
2782
|
+
},
|
|
2783
|
+
{
|
|
2784
|
+
type: "function",
|
|
2785
|
+
name: "symbol",
|
|
2786
|
+
stateMutability: "view",
|
|
2787
|
+
inputs: [],
|
|
2788
|
+
outputs: [
|
|
2789
|
+
{
|
|
2790
|
+
name: "",
|
|
2791
|
+
type: "string"
|
|
2792
|
+
}
|
|
2793
|
+
]
|
|
2794
|
+
},
|
|
2795
|
+
{
|
|
2796
|
+
type: "function",
|
|
2797
|
+
name: "totalSupply",
|
|
2798
|
+
stateMutability: "view",
|
|
2799
|
+
inputs: [],
|
|
2800
|
+
outputs: [
|
|
2801
|
+
{
|
|
2802
|
+
name: "",
|
|
2803
|
+
type: "uint256"
|
|
2804
|
+
}
|
|
2805
|
+
]
|
|
2806
|
+
},
|
|
2807
|
+
{
|
|
2808
|
+
type: "function",
|
|
2809
|
+
name: "transfer",
|
|
2810
|
+
stateMutability: "nonpayable",
|
|
2811
|
+
inputs: [
|
|
2812
|
+
{
|
|
2813
|
+
name: "recipient",
|
|
2814
|
+
type: "address"
|
|
2815
|
+
},
|
|
2816
|
+
{
|
|
2817
|
+
name: "amount",
|
|
2818
|
+
type: "uint256"
|
|
2819
|
+
}
|
|
2820
|
+
],
|
|
2821
|
+
outputs: [
|
|
2822
|
+
{
|
|
2823
|
+
name: "",
|
|
2824
|
+
type: "bool"
|
|
2825
|
+
}
|
|
2826
|
+
]
|
|
2827
|
+
},
|
|
2828
|
+
{
|
|
2829
|
+
type: "function",
|
|
2830
|
+
name: "transferFrom",
|
|
2831
|
+
stateMutability: "nonpayable",
|
|
2832
|
+
inputs: [
|
|
2833
|
+
{
|
|
2834
|
+
name: "sender",
|
|
2835
|
+
type: "address"
|
|
2836
|
+
},
|
|
2837
|
+
{
|
|
2838
|
+
name: "recipient",
|
|
2839
|
+
type: "address"
|
|
2840
|
+
},
|
|
2841
|
+
{
|
|
2842
|
+
name: "amount",
|
|
2843
|
+
type: "uint256"
|
|
2844
|
+
}
|
|
2845
|
+
],
|
|
2846
|
+
outputs: [
|
|
2847
|
+
{
|
|
2848
|
+
name: "",
|
|
2849
|
+
type: "bool"
|
|
2850
|
+
}
|
|
2851
|
+
]
|
|
2852
|
+
}
|
|
2853
|
+
]);
|
|
2854
|
+
|
|
2855
|
+
// src/constants/constants.ts
|
|
2856
|
+
var DEFAULT_GAS_DENOM_OVERRIDES = {
|
|
2857
|
+
"noble-1": "uusdc"
|
|
2858
|
+
};
|
|
2859
|
+
function createTransaction({
|
|
2860
|
+
chainId,
|
|
2861
|
+
message,
|
|
2862
|
+
timeoutHeight,
|
|
2863
|
+
memo = "",
|
|
2864
|
+
fee = utils.DEFAULT_STD_FEE,
|
|
2865
|
+
signMode = 1,
|
|
2866
|
+
pubKey,
|
|
2867
|
+
accountNumber,
|
|
2868
|
+
sequence
|
|
2869
|
+
}) {
|
|
2870
|
+
const signers = {
|
|
2871
|
+
pubKey,
|
|
2872
|
+
accountNumber,
|
|
2873
|
+
sequence
|
|
2874
|
+
};
|
|
2875
|
+
const actualSigners = Array.isArray(signers) ? signers : [signers];
|
|
2876
|
+
const [signer] = actualSigners;
|
|
2877
|
+
const body = tx$2.createBody({ message, memo, timeoutHeight });
|
|
2878
|
+
if (!fee.amount[0]) {
|
|
2879
|
+
throw new Error("createTransaction error: unable to get fee amount");
|
|
2880
|
+
}
|
|
2881
|
+
const feeMessage = tx$2.createFee({
|
|
2882
|
+
fee: fee.amount[0],
|
|
2883
|
+
payer: fee.payer,
|
|
2884
|
+
granter: fee.granter,
|
|
2885
|
+
gasLimit: parseInt(fee.gas, 10)
|
|
2886
|
+
});
|
|
2887
|
+
const signInfo = tx$2.createSigners({
|
|
2888
|
+
chainId,
|
|
2889
|
+
mode: signMode,
|
|
2890
|
+
signers: actualSigners
|
|
2891
|
+
});
|
|
2892
|
+
const authInfo = tx$2.createAuthInfo({
|
|
2893
|
+
signerInfo: signInfo,
|
|
2894
|
+
fee: feeMessage
|
|
2895
|
+
});
|
|
2896
|
+
const bodyBytes = coreProtoTs.CosmosTxV1Beta1Tx.TxBody.encode(body).finish();
|
|
2897
|
+
const authInfoBytes = coreProtoTs.CosmosTxV1Beta1Tx.AuthInfo.encode(authInfo).finish();
|
|
2898
|
+
const signDoc = tx$2.createSignDoc({
|
|
2899
|
+
chainId,
|
|
2900
|
+
bodyBytes,
|
|
2901
|
+
authInfoBytes,
|
|
2902
|
+
accountNumber: signer.accountNumber
|
|
2903
|
+
});
|
|
2904
|
+
const signDocBytes = coreProtoTs.CosmosTxV1Beta1Tx.SignDoc.encode(signDoc).finish();
|
|
2905
|
+
const toSignBytes = Buffer.from(signDocBytes);
|
|
2906
|
+
const toSignHash = keccak256__default.default(Buffer.from(signDocBytes));
|
|
2907
|
+
const txRaw = coreProtoTs.CosmosTxV1Beta1Tx.TxRaw.create();
|
|
2908
|
+
txRaw.authInfoBytes = authInfoBytes;
|
|
2909
|
+
txRaw.bodyBytes = bodyBytes;
|
|
2910
|
+
return {
|
|
2911
|
+
txRaw,
|
|
2912
|
+
signDoc,
|
|
2913
|
+
signers,
|
|
2914
|
+
signer,
|
|
2915
|
+
signBytes: toSignBytes,
|
|
2916
|
+
signHashedBytes: toSignHash,
|
|
2917
|
+
bodyBytes,
|
|
2918
|
+
authInfoBytes
|
|
2919
|
+
};
|
|
2920
|
+
}
|
|
2921
|
+
var RequestClient = class {
|
|
2922
|
+
constructor({ baseURL, apiKey }) {
|
|
2923
|
+
this.httpClient = axios2__default.default.create({
|
|
2924
|
+
baseURL,
|
|
2925
|
+
headers: apiKey ? {
|
|
2926
|
+
authorization: apiKey
|
|
2927
|
+
} : void 0
|
|
2928
|
+
});
|
|
2929
|
+
}
|
|
2930
|
+
get(path, params) {
|
|
2931
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
2932
|
+
var _a, _b;
|
|
2933
|
+
try {
|
|
2934
|
+
const response = yield this.httpClient.get(path, {
|
|
2935
|
+
params
|
|
2936
|
+
});
|
|
2937
|
+
return response.data;
|
|
2938
|
+
} catch (error) {
|
|
2939
|
+
if (error instanceof axios2.AxiosError && ((_b = (_a = error.response) == null ? void 0 : _a.data) == null ? void 0 : _b.message)) {
|
|
2940
|
+
throw new Error(error.response.data.message);
|
|
2941
|
+
}
|
|
2942
|
+
throw error;
|
|
2943
|
+
}
|
|
2944
|
+
});
|
|
2945
|
+
}
|
|
2946
|
+
post(_0) {
|
|
2947
|
+
return chunk6FNC3XMI_js.__async(this, arguments, function* (path, data = {}) {
|
|
2948
|
+
var _a, _b;
|
|
2949
|
+
try {
|
|
2950
|
+
const response = yield this.httpClient.post(path, data);
|
|
2951
|
+
return response.data;
|
|
2952
|
+
} catch (error) {
|
|
2953
|
+
if (error instanceof axios2.AxiosError && ((_b = (_a = error.response) == null ? void 0 : _a.data) == null ? void 0 : _b.message)) {
|
|
2954
|
+
throw new Error(error.response.data.message);
|
|
2955
|
+
}
|
|
2956
|
+
throw error;
|
|
2957
|
+
}
|
|
2958
|
+
});
|
|
2959
|
+
}
|
|
2960
|
+
};
|
|
2961
|
+
var SKIP_API_URL = "https://api.skip.build";
|
|
2962
|
+
var SkipRouter = class {
|
|
2963
|
+
constructor(options = {}) {
|
|
2964
|
+
var _a, _b, _c;
|
|
2965
|
+
this.requestClient = new RequestClient({
|
|
2966
|
+
baseURL: options.apiURL || SKIP_API_URL,
|
|
2967
|
+
apiKey: options.apiKey
|
|
2968
|
+
});
|
|
2969
|
+
this.aminoTypes = new stargate.AminoTypes(chunk6FNC3XMI_js.__spreadValues(chunk6FNC3XMI_js.__spreadValues(chunk6FNC3XMI_js.__spreadValues(chunk6FNC3XMI_js.__spreadValues(chunk6FNC3XMI_js.__spreadValues({}, stargate.createDefaultAminoConverters()), cosmwasmStargate.createWasmAminoConverters()), circleAminoConverters), evmosAminoConverters), (_a = options.aminoTypes) != null ? _a : {}));
|
|
2970
|
+
this.registry = new protoSigning.Registry([
|
|
2971
|
+
...stargate.defaultRegistryTypes,
|
|
2972
|
+
["/cosmwasm.wasm.v1.MsgExecuteContract", tx.MsgExecuteContract],
|
|
2973
|
+
["/initia.move.v1.MsgExecute", chunkTUX4SN3U_js.MsgExecute],
|
|
2974
|
+
["/opinit.ophost.v1.MsgInitiateTokenDeposit", chunkTUX4SN3U_js.MsgInitiateTokenDeposit],
|
|
2975
|
+
...circleProtoRegistry,
|
|
2976
|
+
...evmosProtoRegistry,
|
|
2977
|
+
...(_b = options.registryTypes) != null ? _b : []
|
|
2978
|
+
]);
|
|
2979
|
+
this.endpointOptions = (_c = options.endpointOptions) != null ? _c : {};
|
|
2980
|
+
this.getCosmosSigner = options.getCosmosSigner;
|
|
2981
|
+
this.getEVMSigner = options.getEVMSigner;
|
|
2982
|
+
this.getSVMSigner = options.getSVMSigner;
|
|
2983
|
+
}
|
|
2984
|
+
assets() {
|
|
2985
|
+
return chunk6FNC3XMI_js.__async(this, arguments, function* (options = {}) {
|
|
2986
|
+
const response = yield this.requestClient.get(
|
|
2987
|
+
"/v2/fungible/assets",
|
|
2988
|
+
chunkIEAKY5XG_js.assetsRequestToJSON(chunk6FNC3XMI_js.__spreadValues({}, options))
|
|
2989
|
+
);
|
|
2990
|
+
return Object.entries(response.chain_to_assets_map).reduce(
|
|
2991
|
+
(acc, [chainID, { assets }]) => {
|
|
2992
|
+
acc[chainID] = assets.map((asset) => chunkIEAKY5XG_js.assetFromJSON(asset));
|
|
2993
|
+
return acc;
|
|
2994
|
+
},
|
|
2995
|
+
{}
|
|
2996
|
+
);
|
|
2997
|
+
});
|
|
2998
|
+
}
|
|
2999
|
+
assetsFromSource(options) {
|
|
3000
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3001
|
+
const response = yield this.requestClient.post(
|
|
3002
|
+
"/v2/fungible/assets_from_source",
|
|
3003
|
+
chunkIEAKY5XG_js.assetsFromSourceRequestToJSON(chunk6FNC3XMI_js.__spreadValues({}, options))
|
|
3004
|
+
);
|
|
3005
|
+
return Object.entries(response.dest_assets).reduce(
|
|
3006
|
+
(acc, [chainID, { assets }]) => {
|
|
3007
|
+
acc[chainID] = assets.map((asset) => chunkIEAKY5XG_js.assetFromJSON(asset));
|
|
3008
|
+
return acc;
|
|
3009
|
+
},
|
|
3010
|
+
{}
|
|
3011
|
+
);
|
|
3012
|
+
});
|
|
3013
|
+
}
|
|
3014
|
+
assetsBetweenChains(options) {
|
|
3015
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3016
|
+
const response = yield this.requestClient.post(
|
|
3017
|
+
"/v2/fungible/assets_between_chains",
|
|
3018
|
+
chunkIEAKY5XG_js.assetsBetweenChainsRequestToJSON(options)
|
|
3019
|
+
);
|
|
3020
|
+
return chunkIEAKY5XG_js.assetsBetweenChainsResponseFromJSON(response).assetsBetweenChains;
|
|
3021
|
+
});
|
|
3022
|
+
}
|
|
3023
|
+
bridges() {
|
|
3024
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3025
|
+
const response = yield this.requestClient.get(
|
|
3026
|
+
"/v2/info/bridges"
|
|
3027
|
+
);
|
|
3028
|
+
return chunkIEAKY5XG_js.bridgesResponseFromJSON(response).bridges;
|
|
3029
|
+
});
|
|
3030
|
+
}
|
|
3031
|
+
chains() {
|
|
3032
|
+
return chunk6FNC3XMI_js.__async(this, arguments, function* ({
|
|
3033
|
+
includeEVM,
|
|
3034
|
+
includeSVM,
|
|
3035
|
+
onlyTestnets,
|
|
3036
|
+
chainIDs
|
|
3037
|
+
} = { includeEVM: false, includeSVM: false }) {
|
|
3038
|
+
const response = yield this.requestClient.get("/v2/info/chains", {
|
|
3039
|
+
include_evm: includeEVM,
|
|
3040
|
+
include_svm: includeSVM,
|
|
3041
|
+
only_testnets: onlyTestnets,
|
|
3042
|
+
chain_ids: chainIDs
|
|
3043
|
+
});
|
|
3044
|
+
return response.chains.map((chain) => chunkIEAKY5XG_js.chainFromJSON(chain));
|
|
3045
|
+
});
|
|
3046
|
+
}
|
|
3047
|
+
executeRoute(options) {
|
|
3048
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3049
|
+
var _a;
|
|
3050
|
+
const { route, userAddresses } = options;
|
|
3051
|
+
let addressList = [];
|
|
3052
|
+
let i = 0;
|
|
3053
|
+
for (let j = 0; j < userAddresses.length; j++) {
|
|
3054
|
+
if (route.requiredChainAddresses[i] !== ((_a = userAddresses[j]) == null ? void 0 : _a.chainID)) {
|
|
3055
|
+
i = j;
|
|
3056
|
+
continue;
|
|
3057
|
+
}
|
|
3058
|
+
addressList.push(userAddresses[j].address);
|
|
3059
|
+
i++;
|
|
3060
|
+
}
|
|
3061
|
+
if (addressList.length !== route.requiredChainAddresses.length) {
|
|
3062
|
+
addressList = userAddresses.map((x) => x.address);
|
|
3063
|
+
}
|
|
3064
|
+
const validLength = addressList.length === route.requiredChainAddresses.length || addressList.length === route.chainIDs.length;
|
|
3065
|
+
if (!validLength) {
|
|
3066
|
+
raise("executeRoute error: invalid address list");
|
|
3067
|
+
}
|
|
3068
|
+
const messages = yield this.messages({
|
|
3069
|
+
sourceAssetDenom: route.sourceAssetDenom,
|
|
3070
|
+
sourceAssetChainID: route.sourceAssetChainID,
|
|
3071
|
+
destAssetDenom: route.destAssetDenom,
|
|
3072
|
+
destAssetChainID: route.destAssetChainID,
|
|
3073
|
+
amountIn: route.amountIn,
|
|
3074
|
+
amountOut: route.estimatedAmountOut || "0",
|
|
3075
|
+
addressList,
|
|
3076
|
+
operations: route.operations,
|
|
3077
|
+
slippageTolerancePercent: options.slippageTolerancePercent || "1"
|
|
3078
|
+
});
|
|
3079
|
+
yield this.executeTxs(chunk6FNC3XMI_js.__spreadProps(chunk6FNC3XMI_js.__spreadValues({}, options), { txs: messages.txs }));
|
|
3080
|
+
});
|
|
3081
|
+
}
|
|
3082
|
+
executeTxs(options) {
|
|
3083
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3084
|
+
var _a;
|
|
3085
|
+
const {
|
|
3086
|
+
txs,
|
|
3087
|
+
userAddresses,
|
|
3088
|
+
validateGasBalance,
|
|
3089
|
+
getGasPrice,
|
|
3090
|
+
gasAmountMultiplier = chunkTUX4SN3U_js.DEFAULT_GAS_MULTIPLIER,
|
|
3091
|
+
getFallbackGasAmount
|
|
3092
|
+
} = options;
|
|
3093
|
+
let gasTokenUsed;
|
|
3094
|
+
if (validateGasBalance) {
|
|
3095
|
+
gasTokenUsed = yield this.validateGasBalances({
|
|
3096
|
+
txs,
|
|
3097
|
+
userAddresses,
|
|
3098
|
+
getOfflineSigner: options.getCosmosSigner,
|
|
3099
|
+
getGasPrice,
|
|
3100
|
+
gasAmountMultiplier,
|
|
3101
|
+
getFallbackGasAmount
|
|
3102
|
+
});
|
|
3103
|
+
}
|
|
3104
|
+
for (let i = 0; i < txs.length; i++) {
|
|
3105
|
+
const tx = txs[i];
|
|
3106
|
+
if (!tx) {
|
|
3107
|
+
raise(`executeRoute error: invalid message at index ${i}`);
|
|
3108
|
+
}
|
|
3109
|
+
let txResult;
|
|
3110
|
+
if ("cosmosTx" in tx) {
|
|
3111
|
+
const cosmosTx = tx.cosmosTx;
|
|
3112
|
+
const currentUserAddress = (_a = userAddresses.find(
|
|
3113
|
+
(x) => x.chainID === cosmosTx.chainID
|
|
3114
|
+
)) == null ? void 0 : _a.address;
|
|
3115
|
+
if (!currentUserAddress) {
|
|
3116
|
+
raise(
|
|
3117
|
+
`executeRoute error: invalid address for chain '${cosmosTx.chainID}'`
|
|
3118
|
+
);
|
|
3119
|
+
}
|
|
3120
|
+
if (cosmosTx.chainID === "stride-1" && !gasTokenUsed) {
|
|
3121
|
+
const getOfflineSigner = options.getCosmosSigner || this.getCosmosSigner;
|
|
3122
|
+
if (!getOfflineSigner) {
|
|
3123
|
+
throw new Error(
|
|
3124
|
+
"executeRoute error: 'getCosmosSigner' is not provided or configured in skip router"
|
|
3125
|
+
);
|
|
3126
|
+
}
|
|
3127
|
+
const signer = yield getOfflineSigner(tx.cosmosTx.chainID);
|
|
3128
|
+
const endpoint = yield this.getRpcEndpointForChain(
|
|
3129
|
+
tx.cosmosTx.chainID
|
|
3130
|
+
);
|
|
3131
|
+
const client = yield stargate.SigningStargateClient.connectWithSigner(
|
|
3132
|
+
endpoint,
|
|
3133
|
+
signer,
|
|
3134
|
+
{
|
|
3135
|
+
aminoTypes: this.aminoTypes,
|
|
3136
|
+
registry: this.registry,
|
|
3137
|
+
accountParser: chunkJRIEAGIQ_js.accountParser
|
|
3138
|
+
}
|
|
3139
|
+
);
|
|
3140
|
+
gasTokenUsed = yield this.validateCosmosGasBalance({
|
|
3141
|
+
chainID: cosmosTx.chainID,
|
|
3142
|
+
messages: cosmosTx.msgs,
|
|
3143
|
+
signerAddress: currentUserAddress,
|
|
3144
|
+
getGasPrice,
|
|
3145
|
+
gasAmountMultiplier,
|
|
3146
|
+
getFallbackGasAmount,
|
|
3147
|
+
client
|
|
3148
|
+
});
|
|
3149
|
+
}
|
|
3150
|
+
const txResponse = yield this.executeCosmosMessage({
|
|
3151
|
+
messages: cosmosTx.msgs,
|
|
3152
|
+
chainID: cosmosTx.chainID,
|
|
3153
|
+
getCosmosSigner: options.getCosmosSigner,
|
|
3154
|
+
getGasPrice,
|
|
3155
|
+
gasAmountMultiplier,
|
|
3156
|
+
signerAddress: currentUserAddress,
|
|
3157
|
+
getFallbackGasAmount,
|
|
3158
|
+
gasTokenUsed
|
|
3159
|
+
});
|
|
3160
|
+
txResult = {
|
|
3161
|
+
chainID: cosmosTx.chainID,
|
|
3162
|
+
txHash: txResponse.transactionHash
|
|
3163
|
+
};
|
|
3164
|
+
} else if ("evmTx" in tx) {
|
|
3165
|
+
const txResponse = yield this.executeEvmMsg(tx, options);
|
|
3166
|
+
txResult = {
|
|
3167
|
+
chainID: tx.evmTx.chainID,
|
|
3168
|
+
txHash: txResponse.transactionHash
|
|
3169
|
+
};
|
|
3170
|
+
} else if ("svmTx" in tx) {
|
|
3171
|
+
const { svmTx } = tx;
|
|
3172
|
+
const getSVMSigner = options.getSVMSigner || this.getSVMSigner;
|
|
3173
|
+
if (!getSVMSigner) {
|
|
3174
|
+
throw new Error(
|
|
3175
|
+
"executeRoute error: 'getSVMSigner' is not provided or configured in skip router"
|
|
3176
|
+
);
|
|
3177
|
+
}
|
|
3178
|
+
const svmSigner = yield getSVMSigner();
|
|
3179
|
+
const txReceipt = yield this.executeSVMTransaction({
|
|
3180
|
+
signer: svmSigner,
|
|
3181
|
+
message: svmTx
|
|
3182
|
+
});
|
|
3183
|
+
txResult = {
|
|
3184
|
+
chainID: svmTx.chainID,
|
|
3185
|
+
txHash: txReceipt
|
|
3186
|
+
};
|
|
3187
|
+
} else {
|
|
3188
|
+
raise(`executeRoute error: invalid message type`);
|
|
3189
|
+
}
|
|
3190
|
+
if (options.onTransactionBroadcast) {
|
|
3191
|
+
yield options.onTransactionBroadcast(chunk6FNC3XMI_js.__spreadValues({}, txResult));
|
|
3192
|
+
}
|
|
3193
|
+
const txStatusResponse = yield this.waitForTransaction(chunk6FNC3XMI_js.__spreadProps(chunk6FNC3XMI_js.__spreadValues({}, txResult), {
|
|
3194
|
+
onTransactionTracked: options.onTransactionTracked
|
|
3195
|
+
}));
|
|
3196
|
+
if (options.onTransactionCompleted) {
|
|
3197
|
+
yield options.onTransactionCompleted(
|
|
3198
|
+
txResult.chainID,
|
|
3199
|
+
txResult.txHash,
|
|
3200
|
+
txStatusResponse
|
|
3201
|
+
);
|
|
3202
|
+
}
|
|
3203
|
+
}
|
|
3204
|
+
});
|
|
3205
|
+
}
|
|
3206
|
+
executeEvmMsg(message, options) {
|
|
3207
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3208
|
+
const { evmTx } = message;
|
|
3209
|
+
const getEVMSigner = options.getEVMSigner || this.getEVMSigner;
|
|
3210
|
+
if (!getEVMSigner) {
|
|
3211
|
+
throw new Error("Unable to get EVM signer");
|
|
3212
|
+
}
|
|
3213
|
+
const evmSigner = yield getEVMSigner(evmTx.chainID);
|
|
3214
|
+
return yield this.executeEVMTransaction({
|
|
3215
|
+
message: evmTx,
|
|
3216
|
+
signer: evmSigner
|
|
3217
|
+
});
|
|
3218
|
+
});
|
|
3219
|
+
}
|
|
3220
|
+
executeCosmosMessage(options) {
|
|
3221
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3222
|
+
const {
|
|
3223
|
+
signerAddress,
|
|
3224
|
+
getCosmosSigner,
|
|
3225
|
+
chainID,
|
|
3226
|
+
messages,
|
|
3227
|
+
getGasPrice,
|
|
3228
|
+
gasAmountMultiplier,
|
|
3229
|
+
getFallbackGasAmount,
|
|
3230
|
+
gasTokenUsed
|
|
3231
|
+
} = options;
|
|
3232
|
+
const getOfflineSigner = this.getCosmosSigner || getCosmosSigner || raise(
|
|
3233
|
+
"executeRoute error: 'getCosmosSigner' is not provided or configured in skip router"
|
|
3234
|
+
);
|
|
3235
|
+
const signer = yield getOfflineSigner(chainID);
|
|
3236
|
+
const accounts = yield signer.getAccounts();
|
|
3237
|
+
const accountFromSigner = accounts.find(
|
|
3238
|
+
(account) => account.address === signerAddress
|
|
3239
|
+
);
|
|
3240
|
+
if (!accountFromSigner) {
|
|
3241
|
+
throw new Error(
|
|
3242
|
+
"executeMultiChainMessage error: failed to retrieve account from signer"
|
|
3243
|
+
);
|
|
3244
|
+
}
|
|
3245
|
+
const endpoint = yield this.getRpcEndpointForChain(chainID);
|
|
3246
|
+
const stargateClient = yield stargate.SigningStargateClient.connectWithSigner(
|
|
3247
|
+
endpoint,
|
|
3248
|
+
signer,
|
|
3249
|
+
{
|
|
3250
|
+
aminoTypes: this.aminoTypes,
|
|
3251
|
+
registry: this.registry,
|
|
3252
|
+
accountParser: chunkJRIEAGIQ_js.accountParser
|
|
3253
|
+
}
|
|
3254
|
+
);
|
|
3255
|
+
const fee = yield this.estimateGasForMessage({
|
|
3256
|
+
stargateClient,
|
|
3257
|
+
chainID,
|
|
3258
|
+
signerAddress,
|
|
3259
|
+
gasAmountMultiplier,
|
|
3260
|
+
getGasPrice,
|
|
3261
|
+
messages,
|
|
3262
|
+
getFallbackGasAmount
|
|
3263
|
+
});
|
|
3264
|
+
if (gasTokenUsed) {
|
|
3265
|
+
const _fee = fee.amount.find((x) => x.denom === gasTokenUsed.denom);
|
|
3266
|
+
if (_fee) {
|
|
3267
|
+
fee.amount = [_fee];
|
|
3268
|
+
}
|
|
3269
|
+
}
|
|
3270
|
+
if (fee.amount.length > 1) {
|
|
3271
|
+
fee.amount = [fee.amount[0]];
|
|
3272
|
+
}
|
|
3273
|
+
const { accountNumber, sequence } = yield this.getAccountNumberAndSequence(
|
|
3274
|
+
signerAddress,
|
|
3275
|
+
chainID
|
|
3276
|
+
);
|
|
3277
|
+
let rawTx;
|
|
3278
|
+
if (protoSigning.isOfflineDirectSigner(signer)) {
|
|
3279
|
+
rawTx = yield this.signCosmosMessageDirect({
|
|
3280
|
+
signerAddress,
|
|
3281
|
+
signer,
|
|
3282
|
+
chainID,
|
|
3283
|
+
cosmosMsgs: messages,
|
|
3284
|
+
fee,
|
|
3285
|
+
signerData: {
|
|
3286
|
+
accountNumber,
|
|
3287
|
+
sequence,
|
|
3288
|
+
chainId: chainID
|
|
3289
|
+
}
|
|
3290
|
+
});
|
|
3291
|
+
} else {
|
|
3292
|
+
rawTx = yield this.signCosmosMessageAmino({
|
|
3293
|
+
signerAddress,
|
|
3294
|
+
signer,
|
|
3295
|
+
chainID,
|
|
3296
|
+
cosmosMsgs: messages,
|
|
3297
|
+
fee,
|
|
3298
|
+
signerData: {
|
|
3299
|
+
accountNumber,
|
|
3300
|
+
sequence,
|
|
3301
|
+
chainId: chainID
|
|
3302
|
+
}
|
|
3303
|
+
});
|
|
3304
|
+
}
|
|
3305
|
+
const txBytes = tx$1.TxRaw.encode(rawTx).finish();
|
|
3306
|
+
const tx = yield stargateClient.broadcastTx(txBytes);
|
|
3307
|
+
return tx;
|
|
3308
|
+
});
|
|
3309
|
+
}
|
|
3310
|
+
estimateGasForMessage(_0) {
|
|
3311
|
+
return chunk6FNC3XMI_js.__async(this, arguments, function* ({
|
|
3312
|
+
stargateClient,
|
|
3313
|
+
chainID,
|
|
3314
|
+
signerAddress,
|
|
3315
|
+
gasAmountMultiplier,
|
|
3316
|
+
getGasPrice,
|
|
3317
|
+
messages,
|
|
3318
|
+
encodedMsgs,
|
|
3319
|
+
getFallbackGasAmount
|
|
3320
|
+
}) {
|
|
3321
|
+
var _a;
|
|
3322
|
+
const estimatedGasAmount = yield (() => chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3323
|
+
try {
|
|
3324
|
+
const estimatedGas = yield chunkTUX4SN3U_js.getCosmosGasAmountForMessage(
|
|
3325
|
+
stargateClient,
|
|
3326
|
+
signerAddress,
|
|
3327
|
+
chainID,
|
|
3328
|
+
messages,
|
|
3329
|
+
encodedMsgs,
|
|
3330
|
+
gasAmountMultiplier
|
|
3331
|
+
);
|
|
3332
|
+
return estimatedGas;
|
|
3333
|
+
} catch (error) {
|
|
3334
|
+
if (getFallbackGasAmount) {
|
|
3335
|
+
const fallbackGasAmount = yield getFallbackGasAmount(
|
|
3336
|
+
chainID,
|
|
3337
|
+
"cosmos"
|
|
3338
|
+
);
|
|
3339
|
+
if (!fallbackGasAmount) {
|
|
3340
|
+
raise(
|
|
3341
|
+
`executeRoute error: unable to estimate gas for message(s) ${messages || encodedMsgs}`
|
|
3342
|
+
);
|
|
3343
|
+
}
|
|
3344
|
+
return String(fallbackGasAmount);
|
|
3345
|
+
}
|
|
3346
|
+
raise(
|
|
3347
|
+
`executeRoute error: unable to estimate gas for message(s) ${messages || encodedMsgs}`
|
|
3348
|
+
);
|
|
3349
|
+
}
|
|
3350
|
+
}))();
|
|
3351
|
+
const gasPrice = (getGasPrice ? yield getGasPrice(chainID, "cosmos") : yield this.getRecommendedGasPrice(chainID)) || raise(
|
|
3352
|
+
`executeRoute error: unable to get gas prices for chain '${chainID}'`
|
|
3353
|
+
);
|
|
3354
|
+
const fee = stargate.calculateFee(
|
|
3355
|
+
Math.ceil(parseFloat(estimatedGasAmount)),
|
|
3356
|
+
gasPrice
|
|
3357
|
+
);
|
|
3358
|
+
if (chainID === "stride-1") {
|
|
3359
|
+
const chains4 = yield this.chains();
|
|
3360
|
+
const tiaOnStride = (_a = chains4.find((x) => x.chainID === chainID)) == null ? void 0 : _a.feeAssets.find(
|
|
3361
|
+
(item) => item.denom.toLowerCase() === "ibc/BF3B4F53F3694B66E13C23107C84B6485BD2B96296BB7EC680EA77BBA75B4801".toLowerCase()
|
|
3362
|
+
);
|
|
3363
|
+
if (tiaOnStride && tiaOnStride.gasPrice) {
|
|
3364
|
+
let price = tiaOnStride.gasPrice.average;
|
|
3365
|
+
if (price === "") {
|
|
3366
|
+
price = tiaOnStride.gasPrice.high;
|
|
3367
|
+
}
|
|
3368
|
+
if (price === "") {
|
|
3369
|
+
price = tiaOnStride.gasPrice.low;
|
|
3370
|
+
}
|
|
3371
|
+
const tiaOnStrideGasPrice = new stargate.GasPrice(
|
|
3372
|
+
math.Decimal.fromUserInput(price, 18),
|
|
3373
|
+
tiaOnStride.denom
|
|
3374
|
+
);
|
|
3375
|
+
const tiaOnStrideFee = stargate.calculateFee(
|
|
3376
|
+
Math.ceil(parseFloat(estimatedGasAmount)),
|
|
3377
|
+
tiaOnStrideGasPrice
|
|
3378
|
+
);
|
|
3379
|
+
if (tiaOnStrideFee.amount[0]) {
|
|
3380
|
+
fee.amount.push(tiaOnStrideFee.amount[0]);
|
|
3381
|
+
}
|
|
3382
|
+
}
|
|
3383
|
+
}
|
|
3384
|
+
if (!fee) {
|
|
3385
|
+
raise(
|
|
3386
|
+
`executeRoute error: unable to get fee for message(s) ${messages || encodedMsgs}`
|
|
3387
|
+
);
|
|
3388
|
+
}
|
|
3389
|
+
return fee;
|
|
3390
|
+
});
|
|
3391
|
+
}
|
|
3392
|
+
executeEVMTransaction(_0) {
|
|
3393
|
+
return chunk6FNC3XMI_js.__async(this, arguments, function* ({
|
|
3394
|
+
message,
|
|
3395
|
+
signer
|
|
3396
|
+
}) {
|
|
3397
|
+
if (!signer.account) {
|
|
3398
|
+
throw new Error(
|
|
3399
|
+
"executeEVMTransaction error: failed to retrieve account from signer"
|
|
3400
|
+
);
|
|
3401
|
+
}
|
|
3402
|
+
const extendedSigner = signer.extend(viem.publicActions);
|
|
3403
|
+
for (const requiredApproval of message.requiredERC20Approvals) {
|
|
3404
|
+
const allowance = yield extendedSigner.readContract({
|
|
3405
|
+
address: requiredApproval.tokenContract,
|
|
3406
|
+
abi: erc20ABI,
|
|
3407
|
+
functionName: "allowance",
|
|
3408
|
+
args: [
|
|
3409
|
+
signer.account.address,
|
|
3410
|
+
requiredApproval.spender
|
|
3411
|
+
]
|
|
3412
|
+
});
|
|
3413
|
+
if (allowance > BigInt(requiredApproval.amount)) {
|
|
3414
|
+
continue;
|
|
3415
|
+
}
|
|
3416
|
+
const txHash2 = yield extendedSigner.writeContract({
|
|
3417
|
+
account: signer.account,
|
|
3418
|
+
address: requiredApproval.tokenContract,
|
|
3419
|
+
abi: erc20ABI,
|
|
3420
|
+
functionName: "approve",
|
|
3421
|
+
args: [requiredApproval.spender, viem.maxUint256],
|
|
3422
|
+
chain: signer.chain
|
|
3423
|
+
});
|
|
3424
|
+
const receipt2 = yield extendedSigner.waitForTransactionReceipt({
|
|
3425
|
+
hash: txHash2
|
|
3426
|
+
});
|
|
3427
|
+
if (receipt2.status === "reverted") {
|
|
3428
|
+
throw new Error(
|
|
3429
|
+
`executeEVMTransaction error: evm tx reverted for hash ${receipt2.transactionHash}`
|
|
3430
|
+
);
|
|
3431
|
+
}
|
|
3432
|
+
}
|
|
3433
|
+
const txHash = yield extendedSigner.sendTransaction({
|
|
3434
|
+
account: signer.account,
|
|
3435
|
+
to: message.to,
|
|
3436
|
+
data: `0x${message.data}`,
|
|
3437
|
+
chain: signer.chain,
|
|
3438
|
+
value: message.value === "" ? void 0 : BigInt(message.value)
|
|
3439
|
+
});
|
|
3440
|
+
const receipt = yield extendedSigner.waitForTransactionReceipt({
|
|
3441
|
+
hash: txHash
|
|
3442
|
+
});
|
|
3443
|
+
return receipt;
|
|
3444
|
+
});
|
|
3445
|
+
}
|
|
3446
|
+
executeSVMTransaction(_0) {
|
|
3447
|
+
return chunk6FNC3XMI_js.__async(this, arguments, function* ({
|
|
3448
|
+
signer,
|
|
3449
|
+
message
|
|
3450
|
+
}) {
|
|
3451
|
+
var _a;
|
|
3452
|
+
const _tx = Buffer.from(message.tx, "base64");
|
|
3453
|
+
const transaction = web3_js.Transaction.from(_tx);
|
|
3454
|
+
const endpoint = yield this.getRpcEndpointForChain(message.chainID);
|
|
3455
|
+
const connection = new web3_js.Connection(endpoint);
|
|
3456
|
+
let signature;
|
|
3457
|
+
if ("signTransaction" in signer) {
|
|
3458
|
+
const tx = yield signer.signTransaction(transaction);
|
|
3459
|
+
const serializedTx = tx.serialize();
|
|
3460
|
+
yield this.submitTransaction({
|
|
3461
|
+
chainID: message.chainID,
|
|
3462
|
+
tx: Buffer.from(serializedTx).toString("base64")
|
|
3463
|
+
});
|
|
3464
|
+
const sig = yield connection.sendRawTransaction(serializedTx, {
|
|
3465
|
+
preflightCommitment: "confirmed",
|
|
3466
|
+
maxRetries: 5
|
|
3467
|
+
});
|
|
3468
|
+
signature = sig;
|
|
3469
|
+
}
|
|
3470
|
+
if (!signature) {
|
|
3471
|
+
throw new Error("executeSVMTransaction error: signature not found");
|
|
3472
|
+
}
|
|
3473
|
+
let getStatusCount = 0;
|
|
3474
|
+
let errorCount = 0;
|
|
3475
|
+
while (true) {
|
|
3476
|
+
try {
|
|
3477
|
+
const result = yield connection.getSignatureStatus(signature, {
|
|
3478
|
+
searchTransactionHistory: true
|
|
3479
|
+
});
|
|
3480
|
+
if (((_a = result == null ? void 0 : result.value) == null ? void 0 : _a.confirmationStatus) === "confirmed") {
|
|
3481
|
+
return signature;
|
|
3482
|
+
} else if (getStatusCount > 12) {
|
|
3483
|
+
yield wait(3e3);
|
|
3484
|
+
throw new Error(
|
|
3485
|
+
`executeSVMTransaction error: waiting finalized status timed out for ${signature}`
|
|
3486
|
+
);
|
|
3487
|
+
}
|
|
3488
|
+
getStatusCount++;
|
|
3489
|
+
yield wait(3e3);
|
|
3490
|
+
} catch (error) {
|
|
3491
|
+
errorCount++;
|
|
3492
|
+
if (errorCount > 12) {
|
|
3493
|
+
throw error;
|
|
3494
|
+
}
|
|
3495
|
+
}
|
|
3496
|
+
}
|
|
3497
|
+
});
|
|
3498
|
+
}
|
|
3499
|
+
signCosmosMessageDirect(options) {
|
|
3500
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3501
|
+
const {
|
|
3502
|
+
signer,
|
|
3503
|
+
signerAddress,
|
|
3504
|
+
chainID,
|
|
3505
|
+
cosmosMsgs,
|
|
3506
|
+
fee,
|
|
3507
|
+
signerData: { accountNumber, sequence, chainId }
|
|
3508
|
+
} = options;
|
|
3509
|
+
if (chainID.includes("evmos")) {
|
|
3510
|
+
return this.signCosmosMessageDirectEvmos(
|
|
3511
|
+
signerAddress,
|
|
3512
|
+
signer,
|
|
3513
|
+
cosmosMsgs,
|
|
3514
|
+
fee,
|
|
3515
|
+
{ accountNumber, sequence, chainId }
|
|
3516
|
+
);
|
|
3517
|
+
}
|
|
3518
|
+
if (chainID.includes("injective")) {
|
|
3519
|
+
return this.signCosmosMessageDirectInjective(
|
|
3520
|
+
signerAddress,
|
|
3521
|
+
signer,
|
|
3522
|
+
cosmosMsgs,
|
|
3523
|
+
fee,
|
|
3524
|
+
{ accountNumber, sequence, chainId }
|
|
3525
|
+
);
|
|
3526
|
+
}
|
|
3527
|
+
const accounts = yield signer.getAccounts();
|
|
3528
|
+
const accountFromSigner = accounts.find(
|
|
3529
|
+
(account) => account.address === signerAddress
|
|
3530
|
+
);
|
|
3531
|
+
if (!accountFromSigner) {
|
|
3532
|
+
throw new Error(
|
|
3533
|
+
"signCosmosMessageDirect error: failed to retrieve account from signer"
|
|
3534
|
+
);
|
|
3535
|
+
}
|
|
3536
|
+
const messages = cosmosMsgs.map(
|
|
3537
|
+
(cosmosMsg) => chunkTUX4SN3U_js.getEncodeObjectFromCosmosMessage(cosmosMsg)
|
|
3538
|
+
);
|
|
3539
|
+
const txBodyEncodeObject = {
|
|
3540
|
+
typeUrl: "/cosmos.tx.v1beta1.TxBody",
|
|
3541
|
+
value: {
|
|
3542
|
+
messages
|
|
3543
|
+
}
|
|
3544
|
+
};
|
|
3545
|
+
const txBodyBytes = this.registry.encode(txBodyEncodeObject);
|
|
3546
|
+
const gasLimit = math.Int53.fromString(fee.gas).toNumber();
|
|
3547
|
+
const pubkeyAny = makePubkeyAnyFromAccount(accountFromSigner, chainID);
|
|
3548
|
+
const authInfoBytes = protoSigning.makeAuthInfoBytes(
|
|
3549
|
+
[{ pubkey: pubkeyAny, sequence }],
|
|
3550
|
+
fee.amount,
|
|
3551
|
+
gasLimit,
|
|
3552
|
+
fee.granter,
|
|
3553
|
+
fee.payer
|
|
3554
|
+
);
|
|
3555
|
+
const signDoc = protoSigning.makeSignDoc(
|
|
3556
|
+
txBodyBytes,
|
|
3557
|
+
authInfoBytes,
|
|
3558
|
+
chainId,
|
|
3559
|
+
accountNumber
|
|
3560
|
+
);
|
|
3561
|
+
const { signature, signed } = yield signer.signDirect(
|
|
3562
|
+
signerAddress,
|
|
3563
|
+
signDoc
|
|
3564
|
+
);
|
|
3565
|
+
return tx$1.TxRaw.fromPartial({
|
|
3566
|
+
bodyBytes: signed.bodyBytes,
|
|
3567
|
+
authInfoBytes: signed.authInfoBytes,
|
|
3568
|
+
signatures: [encoding.fromBase64(signature.signature)]
|
|
3569
|
+
});
|
|
3570
|
+
});
|
|
3571
|
+
}
|
|
3572
|
+
// TODO: This is previously existing code, just moved to a new function.
|
|
3573
|
+
// Using signCosmosMessageDirectEvmos on evmos DOES currently fail.
|
|
3574
|
+
// I need to investigate what exactly is even different about this and hopefully remove it all together.
|
|
3575
|
+
signCosmosMessageDirectEvmos(_0, _1, _2, _3, _4) {
|
|
3576
|
+
return chunk6FNC3XMI_js.__async(this, arguments, function* (signerAddress, signer, cosmosMsgs, fee, { accountNumber, sequence, chainId }) {
|
|
3577
|
+
const accounts = yield signer.getAccounts();
|
|
3578
|
+
const accountFromSigner = accounts.find(
|
|
3579
|
+
(account) => account.address === signerAddress
|
|
3580
|
+
);
|
|
3581
|
+
if (!accountFromSigner) {
|
|
3582
|
+
throw new Error(
|
|
3583
|
+
"signCosmosMessageDirectEvmos: failed to retrieve account from signer"
|
|
3584
|
+
);
|
|
3585
|
+
}
|
|
3586
|
+
const messages = cosmosMsgs.map(
|
|
3587
|
+
(cosmosMsg) => chunkTUX4SN3U_js.getEncodeObjectFromCosmosMessageInjective(cosmosMsg)
|
|
3588
|
+
);
|
|
3589
|
+
const pk = Buffer.from(accountFromSigner.pubkey).toString("base64");
|
|
3590
|
+
const { signDoc } = createTransaction({
|
|
3591
|
+
pubKey: pk,
|
|
3592
|
+
chainId,
|
|
3593
|
+
message: messages,
|
|
3594
|
+
sequence,
|
|
3595
|
+
accountNumber,
|
|
3596
|
+
timeoutHeight: 0,
|
|
3597
|
+
fee
|
|
3598
|
+
});
|
|
3599
|
+
const directSignResponse = yield signer.signDirect(
|
|
3600
|
+
signerAddress,
|
|
3601
|
+
// @ts-expect-error TODO: Fix this
|
|
3602
|
+
signDoc
|
|
3603
|
+
);
|
|
3604
|
+
return tx$1.TxRaw.fromPartial({
|
|
3605
|
+
bodyBytes: directSignResponse.signed.bodyBytes,
|
|
3606
|
+
authInfoBytes: directSignResponse.signed.authInfoBytes,
|
|
3607
|
+
signatures: [encoding.fromBase64(directSignResponse.signature.signature)]
|
|
3608
|
+
});
|
|
3609
|
+
});
|
|
3610
|
+
}
|
|
3611
|
+
// TODO: This is previously existing code, just moved to a new function.
|
|
3612
|
+
// Using signCosmosMessageDirectInjective on injective DOES currently fail.
|
|
3613
|
+
// I need to investigate what exactly is even different about this and hopefully remove it all together.
|
|
3614
|
+
signCosmosMessageDirectInjective(_0, _1, _2, _3, _4) {
|
|
3615
|
+
return chunk6FNC3XMI_js.__async(this, arguments, function* (signerAddress, signer, cosmosMsgs, fee, { accountNumber, sequence, chainId }) {
|
|
3616
|
+
const accounts = yield signer.getAccounts();
|
|
3617
|
+
const accountFromSigner = accounts.find(
|
|
3618
|
+
(account) => account.address === signerAddress
|
|
3619
|
+
);
|
|
3620
|
+
if (!accountFromSigner) {
|
|
3621
|
+
throw new Error(
|
|
3622
|
+
"signCosmosMessageDirectInjective: failed to retrieve account from signer"
|
|
3623
|
+
);
|
|
3624
|
+
}
|
|
3625
|
+
const restEndpoint = yield this.getRestEndpointForChain(chainId);
|
|
3626
|
+
const chainRestTendermintApi = new rest.ChainRestTendermintApi(restEndpoint);
|
|
3627
|
+
const latestBlock = yield chainRestTendermintApi.fetchLatestBlock();
|
|
3628
|
+
const latestHeight = latestBlock.header.height;
|
|
3629
|
+
const timeoutHeight = new utils.BigNumberInBase(latestHeight).plus(
|
|
3630
|
+
utils.DEFAULT_BLOCK_TIMEOUT_HEIGHT
|
|
3631
|
+
);
|
|
3632
|
+
const pk = Buffer.from(accountFromSigner.pubkey).toString("base64");
|
|
3633
|
+
const messages = cosmosMsgs.map(
|
|
3634
|
+
(cosmosMsg) => chunkTUX4SN3U_js.getEncodeObjectFromCosmosMessageInjective(cosmosMsg)
|
|
3635
|
+
);
|
|
3636
|
+
const { signDoc } = createTransaction({
|
|
3637
|
+
pubKey: pk,
|
|
3638
|
+
chainId,
|
|
3639
|
+
message: messages,
|
|
3640
|
+
sequence,
|
|
3641
|
+
accountNumber,
|
|
3642
|
+
timeoutHeight: timeoutHeight.toNumber(),
|
|
3643
|
+
fee
|
|
3644
|
+
});
|
|
3645
|
+
const directSignResponse = yield signer.signDirect(
|
|
3646
|
+
signerAddress,
|
|
3647
|
+
// @ts-expect-error TODO: Fix this
|
|
3648
|
+
signDoc
|
|
3649
|
+
);
|
|
3650
|
+
return tx$1.TxRaw.fromPartial({
|
|
3651
|
+
bodyBytes: directSignResponse.signed.bodyBytes,
|
|
3652
|
+
authInfoBytes: directSignResponse.signed.authInfoBytes,
|
|
3653
|
+
signatures: [encoding.fromBase64(directSignResponse.signature.signature)]
|
|
3654
|
+
});
|
|
3655
|
+
});
|
|
3656
|
+
}
|
|
3657
|
+
signCosmosMessageAmino(options) {
|
|
3658
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3659
|
+
const {
|
|
3660
|
+
signer,
|
|
3661
|
+
signerAddress,
|
|
3662
|
+
chainID,
|
|
3663
|
+
cosmosMsgs,
|
|
3664
|
+
fee,
|
|
3665
|
+
signerData: { accountNumber, sequence, chainId }
|
|
3666
|
+
} = options;
|
|
3667
|
+
const accounts = yield signer.getAccounts();
|
|
3668
|
+
const accountFromSigner = accounts.find(
|
|
3669
|
+
(account) => account.address === signerAddress
|
|
3670
|
+
);
|
|
3671
|
+
if (!accountFromSigner) {
|
|
3672
|
+
throw new Error(
|
|
3673
|
+
"signCosmosMessageAmino: failed to retrieve account from signer"
|
|
3674
|
+
);
|
|
3675
|
+
}
|
|
3676
|
+
const messages = cosmosMsgs.map(
|
|
3677
|
+
(cosmosMsg) => chunkTUX4SN3U_js.getEncodeObjectFromCosmosMessage(cosmosMsg)
|
|
3678
|
+
);
|
|
3679
|
+
const aminoMsgTransferIndex = messages.findIndex(
|
|
3680
|
+
(x) => x.typeUrl === "/ibc.applications.transfer.v1.MsgTransfer"
|
|
3681
|
+
);
|
|
3682
|
+
if (aminoMsgTransferIndex !== -1) {
|
|
3683
|
+
const endpoint = yield this.getRpcEndpointForChain(chainID);
|
|
3684
|
+
const client = yield stargate.StargateClient.connect(endpoint, {
|
|
3685
|
+
accountParser: chunkJRIEAGIQ_js.accountParser
|
|
3686
|
+
});
|
|
3687
|
+
const currentHeight = yield client.getHeight();
|
|
3688
|
+
messages[aminoMsgTransferIndex].value.timeoutHeight = {
|
|
3689
|
+
revisionHeight: currentHeight + 100,
|
|
3690
|
+
revisionNumber: currentHeight + 100
|
|
3691
|
+
};
|
|
3692
|
+
messages[aminoMsgTransferIndex].value.timeoutTimestamp = 0;
|
|
3693
|
+
}
|
|
3694
|
+
const signMode = signing.SignMode.SIGN_MODE_LEGACY_AMINO_JSON;
|
|
3695
|
+
const msgs = messages.map((msg) => this.aminoTypes.toAmino(msg));
|
|
3696
|
+
const signDoc = amino.makeSignDoc(
|
|
3697
|
+
msgs,
|
|
3698
|
+
fee,
|
|
3699
|
+
chainId,
|
|
3700
|
+
"",
|
|
3701
|
+
accountNumber,
|
|
3702
|
+
sequence
|
|
3703
|
+
);
|
|
3704
|
+
const { signature, signed } = yield signer.signAmino(
|
|
3705
|
+
signerAddress,
|
|
3706
|
+
signDoc
|
|
3707
|
+
);
|
|
3708
|
+
const signedTxBody = {
|
|
3709
|
+
messages: signed.msgs.map((msg) => this.aminoTypes.fromAmino(msg)),
|
|
3710
|
+
memo: signed.memo
|
|
3711
|
+
};
|
|
3712
|
+
signedTxBody.messages[0].value.memo = messages[0].value.memo;
|
|
3713
|
+
const signedTxBodyEncodeObject = {
|
|
3714
|
+
typeUrl: "/cosmos.tx.v1beta1.TxBody",
|
|
3715
|
+
value: signedTxBody
|
|
3716
|
+
};
|
|
3717
|
+
const signedTxBodyBytes = this.registry.encode(signedTxBodyEncodeObject);
|
|
3718
|
+
const signedGasLimit = math.Int53.fromString(signed.fee.gas).toNumber();
|
|
3719
|
+
const signedSequence = math.Int53.fromString(signed.sequence).toNumber();
|
|
3720
|
+
const pubkeyAny = makePubkeyAnyFromAccount(accountFromSigner, chainID);
|
|
3721
|
+
const signedAuthInfoBytes = protoSigning.makeAuthInfoBytes(
|
|
3722
|
+
[{ pubkey: pubkeyAny, sequence: signedSequence }],
|
|
3723
|
+
signed.fee.amount,
|
|
3724
|
+
signedGasLimit,
|
|
3725
|
+
signed.fee.granter,
|
|
3726
|
+
signed.fee.payer,
|
|
3727
|
+
signMode
|
|
3728
|
+
);
|
|
3729
|
+
return tx$1.TxRaw.fromPartial({
|
|
3730
|
+
bodyBytes: signedTxBodyBytes,
|
|
3731
|
+
authInfoBytes: signedAuthInfoBytes,
|
|
3732
|
+
signatures: [encoding.fromBase64(signature.signature)]
|
|
3733
|
+
});
|
|
3734
|
+
});
|
|
3735
|
+
}
|
|
3736
|
+
messages(options) {
|
|
3737
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3738
|
+
const response = yield this.requestClient.post("/v2/fungible/msgs", chunk6FNC3XMI_js.__spreadProps(chunk6FNC3XMI_js.__spreadValues({}, chunkIEAKY5XG_js.msgsRequestToJSON(options)), {
|
|
3739
|
+
slippage_tolerance_percent: options.slippageTolerancePercent || "0"
|
|
3740
|
+
}));
|
|
3741
|
+
return chunkIEAKY5XG_js.messageResponseFromJSON(response);
|
|
3742
|
+
});
|
|
3743
|
+
}
|
|
3744
|
+
route(options) {
|
|
3745
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3746
|
+
const response = yield this.requestClient.post("/v2/fungible/route", chunk6FNC3XMI_js.__spreadProps(chunk6FNC3XMI_js.__spreadValues({}, chunkIEAKY5XG_js.routeRequestToJSON(options)), {
|
|
3747
|
+
cumulative_affiliate_fee_bps: options.cumulativeAffiliateFeeBPS || "0"
|
|
3748
|
+
}));
|
|
3749
|
+
return chunkIEAKY5XG_js.routeResponseFromJSON(response);
|
|
3750
|
+
});
|
|
3751
|
+
}
|
|
3752
|
+
msgsDirect(options) {
|
|
3753
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3754
|
+
const response = yield this.requestClient.post("/v2/fungible/msgs_direct", chunk6FNC3XMI_js.__spreadValues({}, chunkIEAKY5XG_js.msgsDirectRequestToJSON(options)));
|
|
3755
|
+
return {
|
|
3756
|
+
msgs: response.msgs.map((msg) => chunkIEAKY5XG_js.msgFromJSON(msg)),
|
|
3757
|
+
txs: response.txs.map((tx) => chunkIEAKY5XG_js.txFromJSON(tx)),
|
|
3758
|
+
route: chunkIEAKY5XG_js.routeResponseFromJSON(response.route)
|
|
3759
|
+
};
|
|
3760
|
+
});
|
|
3761
|
+
}
|
|
3762
|
+
recommendAssets(request) {
|
|
3763
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3764
|
+
const options = chunkIEAKY5XG_js.recommendAssetsRequestToJSON({
|
|
3765
|
+
requests: Array.isArray(request) ? request : [request]
|
|
3766
|
+
});
|
|
3767
|
+
const response = yield this.requestClient.post(
|
|
3768
|
+
"/v2/fungible/recommend_assets",
|
|
3769
|
+
options
|
|
3770
|
+
);
|
|
3771
|
+
return chunkIEAKY5XG_js.recommendAssetsResponseFromJSON(response).recommendationEntries;
|
|
3772
|
+
});
|
|
3773
|
+
}
|
|
3774
|
+
ibcOriginAssets(assets) {
|
|
3775
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3776
|
+
const response = yield this.requestClient.post(
|
|
3777
|
+
"/v2/fungible/ibc_origin_assets",
|
|
3778
|
+
chunkIEAKY5XG_js.originAssetsRequestToJSON({
|
|
3779
|
+
assets
|
|
3780
|
+
})
|
|
3781
|
+
);
|
|
3782
|
+
return chunkIEAKY5XG_js.originAssetsResponseFromJSON(response).originAssets;
|
|
3783
|
+
});
|
|
3784
|
+
}
|
|
3785
|
+
submitTransaction(_0) {
|
|
3786
|
+
return chunk6FNC3XMI_js.__async(this, arguments, function* ({
|
|
3787
|
+
chainID,
|
|
3788
|
+
tx
|
|
3789
|
+
}) {
|
|
3790
|
+
const response = yield this.requestClient.post("/v2/tx/submit", {
|
|
3791
|
+
chain_id: chainID,
|
|
3792
|
+
tx
|
|
3793
|
+
});
|
|
3794
|
+
return chunkIEAKY5XG_js.submitTxResponseFromJSON(response);
|
|
3795
|
+
});
|
|
3796
|
+
}
|
|
3797
|
+
trackTransaction(_0) {
|
|
3798
|
+
return chunk6FNC3XMI_js.__async(this, arguments, function* ({
|
|
3799
|
+
chainID,
|
|
3800
|
+
txHash,
|
|
3801
|
+
options
|
|
3802
|
+
}) {
|
|
3803
|
+
var _a, _b, _c, _d, _e, _f;
|
|
3804
|
+
const maxRetries = (_b = (_a = options == null ? void 0 : options.retry) == null ? void 0 : _a.maxRetries) != null ? _b : 5;
|
|
3805
|
+
const retryInterval = (_d = (_c = options == null ? void 0 : options.retry) == null ? void 0 : _c.retryInterval) != null ? _d : 1e3;
|
|
3806
|
+
const backoffMultiplier = (_f = (_e = options == null ? void 0 : options.retry) == null ? void 0 : _e.backoffMultiplier) != null ? _f : 2;
|
|
3807
|
+
let retries = 0;
|
|
3808
|
+
let lastError;
|
|
3809
|
+
while (retries < maxRetries) {
|
|
3810
|
+
try {
|
|
3811
|
+
const response = yield this.requestClient.post("/v2/tx/track", {
|
|
3812
|
+
chain_id: chainID,
|
|
3813
|
+
tx_hash: txHash
|
|
3814
|
+
});
|
|
3815
|
+
return chunkIEAKY5XG_js.trackTxResponseFromJSON(response);
|
|
3816
|
+
} catch (error) {
|
|
3817
|
+
lastError = error;
|
|
3818
|
+
retries++;
|
|
3819
|
+
yield wait(retryInterval * Math.pow(backoffMultiplier, retries - 1));
|
|
3820
|
+
}
|
|
3821
|
+
}
|
|
3822
|
+
throw lastError;
|
|
3823
|
+
});
|
|
3824
|
+
}
|
|
3825
|
+
transactionStatus(_0) {
|
|
3826
|
+
return chunk6FNC3XMI_js.__async(this, arguments, function* ({
|
|
3827
|
+
chainID,
|
|
3828
|
+
txHash,
|
|
3829
|
+
options
|
|
3830
|
+
}) {
|
|
3831
|
+
var _a, _b, _c, _d, _e, _f;
|
|
3832
|
+
const maxRetries = (_b = (_a = options == null ? void 0 : options.retry) == null ? void 0 : _a.maxRetries) != null ? _b : 5;
|
|
3833
|
+
const retryInterval = (_d = (_c = options == null ? void 0 : options.retry) == null ? void 0 : _c.retryInterval) != null ? _d : 1e3;
|
|
3834
|
+
const backoffMultiplier = (_f = (_e = options == null ? void 0 : options.retry) == null ? void 0 : _e.backoffMultiplier) != null ? _f : 2;
|
|
3835
|
+
let retries = 0;
|
|
3836
|
+
let lastError;
|
|
3837
|
+
while (retries < maxRetries) {
|
|
3838
|
+
try {
|
|
3839
|
+
const response = yield this.requestClient.get("/v2/tx/status", {
|
|
3840
|
+
chain_id: chainID,
|
|
3841
|
+
tx_hash: txHash
|
|
3842
|
+
});
|
|
3843
|
+
return chunkIEAKY5XG_js.txStatusResponseFromJSON(response);
|
|
3844
|
+
} catch (error) {
|
|
3845
|
+
lastError = error;
|
|
3846
|
+
retries++;
|
|
3847
|
+
yield wait(retryInterval * Math.pow(backoffMultiplier, retries - 1));
|
|
3848
|
+
}
|
|
3849
|
+
}
|
|
3850
|
+
throw lastError;
|
|
3851
|
+
});
|
|
3852
|
+
}
|
|
3853
|
+
waitForTransaction(_0) {
|
|
3854
|
+
return chunk6FNC3XMI_js.__async(this, arguments, function* ({
|
|
3855
|
+
chainID,
|
|
3856
|
+
txHash,
|
|
3857
|
+
onTransactionTracked
|
|
3858
|
+
}) {
|
|
3859
|
+
const { explorerLink } = yield this.trackTransaction({
|
|
3860
|
+
chainID,
|
|
3861
|
+
txHash,
|
|
3862
|
+
options: {
|
|
3863
|
+
retry: {
|
|
3864
|
+
backoffMultiplier: 2.5
|
|
3865
|
+
}
|
|
3866
|
+
}
|
|
3867
|
+
});
|
|
3868
|
+
if (onTransactionTracked) {
|
|
3869
|
+
yield onTransactionTracked({ txHash, chainID, explorerLink });
|
|
3870
|
+
}
|
|
3871
|
+
while (true) {
|
|
3872
|
+
const txStatusResponse = yield this.transactionStatus({
|
|
3873
|
+
chainID,
|
|
3874
|
+
txHash
|
|
3875
|
+
});
|
|
3876
|
+
if (txStatusResponse.status === "STATE_COMPLETED") {
|
|
3877
|
+
return txStatusResponse;
|
|
3878
|
+
}
|
|
3879
|
+
yield wait(1e3);
|
|
3880
|
+
}
|
|
3881
|
+
});
|
|
3882
|
+
}
|
|
3883
|
+
venues(onlyTestnets) {
|
|
3884
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3885
|
+
const response = yield this.requestClient.get("/v2/fungible/venues", {
|
|
3886
|
+
only_testnets: onlyTestnets
|
|
3887
|
+
});
|
|
3888
|
+
return response.venues.map((venue) => chunkIEAKY5XG_js.swapVenueFromJSON(venue));
|
|
3889
|
+
});
|
|
3890
|
+
}
|
|
3891
|
+
getCosmsosGasAmountForMessage(client, signerAddress, chainID, cosmosMessages) {
|
|
3892
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3893
|
+
return chunkTUX4SN3U_js.getCosmosGasAmountForMessage(
|
|
3894
|
+
client,
|
|
3895
|
+
signerAddress,
|
|
3896
|
+
chainID,
|
|
3897
|
+
cosmosMessages
|
|
3898
|
+
);
|
|
3899
|
+
});
|
|
3900
|
+
}
|
|
3901
|
+
getAccountNumberAndSequence(address, chainID) {
|
|
3902
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3903
|
+
if (chainID.includes("dymension")) {
|
|
3904
|
+
return this.getAccountNumberAndSequenceFromDymension(address, chainID);
|
|
3905
|
+
}
|
|
3906
|
+
const endpoint = yield this.getRpcEndpointForChain(chainID);
|
|
3907
|
+
const client = yield stargate.StargateClient.connect(endpoint, {
|
|
3908
|
+
accountParser: chunkJRIEAGIQ_js.accountParser
|
|
3909
|
+
});
|
|
3910
|
+
const account = yield client.getAccount(address);
|
|
3911
|
+
if (!account) {
|
|
3912
|
+
throw new Error(
|
|
3913
|
+
"getAccountNumberAndSequence: failed to retrieve account"
|
|
3914
|
+
);
|
|
3915
|
+
}
|
|
3916
|
+
client.disconnect();
|
|
3917
|
+
return {
|
|
3918
|
+
accountNumber: account.accountNumber,
|
|
3919
|
+
sequence: account.sequence
|
|
3920
|
+
};
|
|
3921
|
+
});
|
|
3922
|
+
}
|
|
3923
|
+
getAccountNumberAndSequenceFromDymension(address, chainID) {
|
|
3924
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3925
|
+
const endpoint = yield this.getRestEndpointForChain(chainID);
|
|
3926
|
+
const response = yield axios2__default.default.get(
|
|
3927
|
+
`${endpoint}/cosmos/auth/v1beta1/accounts/${address}`
|
|
3928
|
+
);
|
|
3929
|
+
let sequence = 0;
|
|
3930
|
+
let accountNumber = 0;
|
|
3931
|
+
if (response.data.account.base_account) {
|
|
3932
|
+
sequence = response.data.account.base_account.sequence;
|
|
3933
|
+
accountNumber = response.data.account.base_account.account_number;
|
|
3934
|
+
} else {
|
|
3935
|
+
sequence = response.data.account.sequence;
|
|
3936
|
+
accountNumber = response.data.account.account_number;
|
|
3937
|
+
}
|
|
3938
|
+
return {
|
|
3939
|
+
accountNumber,
|
|
3940
|
+
sequence
|
|
3941
|
+
};
|
|
3942
|
+
});
|
|
3943
|
+
}
|
|
3944
|
+
getAccountNumberAndSequenceFromEvmos(address, chainID) {
|
|
3945
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3946
|
+
const endpoint = yield this.getRestEndpointForChain(chainID);
|
|
3947
|
+
const response = yield axios2__default.default.get(
|
|
3948
|
+
`${endpoint}/cosmos/auth/v1beta1/accounts/${address}`
|
|
3949
|
+
);
|
|
3950
|
+
const accountNumber = response.data.account.base_account.account_number;
|
|
3951
|
+
const sequence = response.data.account.base_account.sequence;
|
|
3952
|
+
return {
|
|
3953
|
+
accountNumber,
|
|
3954
|
+
sequence
|
|
3955
|
+
};
|
|
3956
|
+
});
|
|
3957
|
+
}
|
|
3958
|
+
getAccountNumberAndSequenceInjective(address, chainID) {
|
|
3959
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3960
|
+
const endpoint = yield this.getRestEndpointForChain(chainID);
|
|
3961
|
+
const chainRestAuthApi = new rest.ChainRestAuthApi(endpoint);
|
|
3962
|
+
const accountDetailsResponse = yield chainRestAuthApi.fetchAccount(address);
|
|
3963
|
+
return {
|
|
3964
|
+
accountNumber: parseInt(
|
|
3965
|
+
accountDetailsResponse.account.base_account.account_number
|
|
3966
|
+
),
|
|
3967
|
+
sequence: parseInt(accountDetailsResponse.account.base_account.sequence)
|
|
3968
|
+
};
|
|
3969
|
+
});
|
|
3970
|
+
}
|
|
3971
|
+
getRpcEndpointForChain(chainID) {
|
|
3972
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
3973
|
+
var _a, _b, _c, _d, _e;
|
|
3974
|
+
if (this.endpointOptions.getRpcEndpointForChain) {
|
|
3975
|
+
return this.endpointOptions.getRpcEndpointForChain(chainID);
|
|
3976
|
+
}
|
|
3977
|
+
if (this.endpointOptions.endpoints && this.endpointOptions.endpoints[chainID]) {
|
|
3978
|
+
const endpointOptions = this.endpointOptions.endpoints[chainID];
|
|
3979
|
+
if (endpointOptions == null ? void 0 : endpointOptions.rpc) {
|
|
3980
|
+
return endpointOptions.rpc;
|
|
3981
|
+
}
|
|
3982
|
+
}
|
|
3983
|
+
let chain;
|
|
3984
|
+
chain = chains3().find((chain2) => chain2.chain_id === chainID);
|
|
3985
|
+
if (!chain) {
|
|
3986
|
+
chain = initiaChains().find((chain2) => chain2.chain_id === chainID);
|
|
3987
|
+
}
|
|
3988
|
+
if (!chain) {
|
|
3989
|
+
throw new Error(
|
|
3990
|
+
`getRpcEndpointForChain: failed to find chain id '${chainID}' in registry`
|
|
3991
|
+
);
|
|
3992
|
+
}
|
|
3993
|
+
if (((_b = (_a = chain.apis) == null ? void 0 : _a.rpc) == null ? void 0 : _b.length) === 0 || !((_c = chain.apis) == null ? void 0 : _c.rpc)) {
|
|
3994
|
+
throw new Error(
|
|
3995
|
+
`getRpcEndpointForChain error: failed to find RPC endpoint for chain '${chainID}'`
|
|
3996
|
+
);
|
|
3997
|
+
}
|
|
3998
|
+
const endpoints = (_e = (_d = chain.apis) == null ? void 0 : _d.rpc) == null ? void 0 : _e.map((api) => api.address);
|
|
3999
|
+
const endpoint = yield findFirstWorkingEndpoint(endpoints, "rpc");
|
|
4000
|
+
if (!endpoint) {
|
|
4001
|
+
throw new Error(
|
|
4002
|
+
`getRpcEndpointForChain error: failed to find RPC endpoint for chain '${chainID}'`
|
|
4003
|
+
);
|
|
4004
|
+
}
|
|
4005
|
+
return endpoint;
|
|
4006
|
+
});
|
|
4007
|
+
}
|
|
4008
|
+
getRestEndpointForChain(chainID) {
|
|
4009
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
4010
|
+
var _a, _b, _c, _d, _e;
|
|
4011
|
+
if (this.endpointOptions.getRestEndpointForChain) {
|
|
4012
|
+
return this.endpointOptions.getRestEndpointForChain(chainID);
|
|
4013
|
+
}
|
|
4014
|
+
if (this.endpointOptions.endpoints && this.endpointOptions.endpoints[chainID]) {
|
|
4015
|
+
const endpointOptions = this.endpointOptions.endpoints[chainID];
|
|
4016
|
+
if (endpointOptions == null ? void 0 : endpointOptions.rest) {
|
|
4017
|
+
return endpointOptions.rest;
|
|
4018
|
+
}
|
|
4019
|
+
}
|
|
4020
|
+
let chain;
|
|
4021
|
+
chain = chains3().find((chain2) => chain2.chain_id === chainID);
|
|
4022
|
+
if (!chain) {
|
|
4023
|
+
chain = initiaChains().find((chain2) => chain2.chain_id === chainID);
|
|
4024
|
+
}
|
|
4025
|
+
if (!chain) {
|
|
4026
|
+
throw new Error(
|
|
4027
|
+
`getRestEndpointForChain error: failed to find chain id '${chainID}' in registry`
|
|
4028
|
+
);
|
|
4029
|
+
}
|
|
4030
|
+
if (((_b = (_a = chain.apis) == null ? void 0 : _a.rest) == null ? void 0 : _b.length) === 0 || !((_c = chain.apis) == null ? void 0 : _c.rest)) {
|
|
4031
|
+
throw new Error(
|
|
4032
|
+
`getRpcEndpointForChain error: failed to find RPC endpoint for chain '${chainID}'`
|
|
4033
|
+
);
|
|
4034
|
+
}
|
|
4035
|
+
const endpoints = (_e = (_d = chain.apis) == null ? void 0 : _d.rest) == null ? void 0 : _e.map((api) => api.address);
|
|
4036
|
+
const endpoint = yield findFirstWorkingEndpoint(endpoints, "rest");
|
|
4037
|
+
if (!endpoint) {
|
|
4038
|
+
throw new Error(
|
|
4039
|
+
`getRestEndpointForChain error: failed to find REST endpoint for chain '${chainID}'`
|
|
4040
|
+
);
|
|
4041
|
+
}
|
|
4042
|
+
return endpoint;
|
|
4043
|
+
});
|
|
4044
|
+
}
|
|
4045
|
+
getCosmosFeeForMessage(_0, _1) {
|
|
4046
|
+
return chunk6FNC3XMI_js.__async(this, arguments, function* (chainID, msgs, gasAmountMultiplier = chunkTUX4SN3U_js.DEFAULT_GAS_MULTIPLIER, signer, gasPrice) {
|
|
4047
|
+
var _a, _b;
|
|
4048
|
+
gasPrice || (gasPrice = yield this.getRecommendedGasPrice(chainID));
|
|
4049
|
+
if (!gasPrice) {
|
|
4050
|
+
throw new Error(
|
|
4051
|
+
`getFeeForMessage error: Unable to get gas price for chain: ${chainID}`
|
|
4052
|
+
);
|
|
4053
|
+
}
|
|
4054
|
+
signer || (signer = yield (_a = this.getCosmosSigner) == null ? void 0 : _a.call(this, chainID));
|
|
4055
|
+
if (!signer) {
|
|
4056
|
+
throw new Error(
|
|
4057
|
+
"getFeeForMessage error: signer is not provided or 'getCosmosSigner' is not configured in skip router"
|
|
4058
|
+
);
|
|
4059
|
+
}
|
|
4060
|
+
const accounts = yield signer.getAccounts();
|
|
4061
|
+
const signerAddress = ((_b = accounts[0]) == null ? void 0 : _b.address) || raise(
|
|
4062
|
+
`getFeeForMessage error: unable to resolve account address from signer`
|
|
4063
|
+
);
|
|
4064
|
+
const endpoint = yield this.getRpcEndpointForChain(chainID);
|
|
4065
|
+
const client = yield stargate.SigningStargateClient.connectWithSigner(
|
|
4066
|
+
endpoint,
|
|
4067
|
+
signer,
|
|
4068
|
+
{
|
|
4069
|
+
aminoTypes: this.aminoTypes,
|
|
4070
|
+
registry: this.registry,
|
|
4071
|
+
accountParser: chunkJRIEAGIQ_js.accountParser
|
|
4072
|
+
}
|
|
4073
|
+
);
|
|
4074
|
+
const gasNeeded = yield chunkTUX4SN3U_js.getCosmosGasAmountForMessage(
|
|
4075
|
+
client,
|
|
4076
|
+
signerAddress,
|
|
4077
|
+
chainID,
|
|
4078
|
+
msgs,
|
|
4079
|
+
void 0,
|
|
4080
|
+
gasAmountMultiplier
|
|
4081
|
+
);
|
|
4082
|
+
const fee = stargate.calculateFee(Math.ceil(parseFloat(gasNeeded)), gasPrice);
|
|
4083
|
+
if (!fee) {
|
|
4084
|
+
throw new Error("getFeeForMessage error: unable to get fee for message");
|
|
4085
|
+
}
|
|
4086
|
+
return fee;
|
|
4087
|
+
});
|
|
4088
|
+
}
|
|
4089
|
+
getRecommendedGasPrice(chainID) {
|
|
4090
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
4091
|
+
const feeInfo = yield this.getFeeInfoForChain(chainID);
|
|
4092
|
+
if (!feeInfo || !feeInfo.gasPrice) {
|
|
4093
|
+
return void 0;
|
|
4094
|
+
}
|
|
4095
|
+
let price = feeInfo.gasPrice.average;
|
|
4096
|
+
if (price === "") {
|
|
4097
|
+
price = feeInfo.gasPrice.high;
|
|
4098
|
+
}
|
|
4099
|
+
if (price === "") {
|
|
4100
|
+
price = feeInfo.gasPrice.low;
|
|
4101
|
+
}
|
|
4102
|
+
return new stargate.GasPrice(math.Decimal.fromUserInput(price, 18), feeInfo.denom);
|
|
4103
|
+
});
|
|
4104
|
+
}
|
|
4105
|
+
getFeeInfoForChain(chainID) {
|
|
4106
|
+
return chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
4107
|
+
var _a, _b;
|
|
4108
|
+
const skipChains = [
|
|
4109
|
+
...yield this.chains({}),
|
|
4110
|
+
...yield this.chains({ onlyTestnets: true })
|
|
4111
|
+
];
|
|
4112
|
+
const skipChain = skipChains.find((chain2) => chain2.chainID === chainID);
|
|
4113
|
+
if (!skipChain) {
|
|
4114
|
+
return void 0;
|
|
4115
|
+
}
|
|
4116
|
+
const defaultGasToken = yield this.getDefaultGasTokenForChain(chainID);
|
|
4117
|
+
if (!defaultGasToken && !skipChain.feeAssets) {
|
|
4118
|
+
return void 0;
|
|
4119
|
+
}
|
|
4120
|
+
const skipFeeInfo = defaultGasToken ? skipChain.feeAssets.find((skipFee) => skipFee.denom === defaultGasToken) : skipChain.feeAssets[0];
|
|
4121
|
+
if (!skipFeeInfo && ((_b = (_a = skipChain.feeAssets) == null ? void 0 : _a[0]) == null ? void 0 : _b.gasPrice) !== null) {
|
|
4122
|
+
return skipChain.feeAssets[0];
|
|
4123
|
+
}
|
|
4124
|
+
if (skipFeeInfo && skipFeeInfo.gasPrice !== null) {
|
|
4125
|
+
return skipFeeInfo;
|
|
4126
|
+
}
|
|
4127
|
+
let chain;
|
|
4128
|
+
chain = chains3().find((chain2) => chain2.chain_id === chainID);
|
|
4129
|
+
if (!chain) {
|
|
4130
|
+
chain = initiaChains().find((chain2) => chain2.chain_id === chainID);
|
|
4131
|
+
}
|
|
4132
|
+
if (!chain) {
|
|
4133
|
+
return void 0;
|
|
4134
|
+
}
|
|
4135
|
+
if (!chain.fees) {
|
|
4136
|
+
return void 0;
|
|
4137
|
+
}
|
|
4138
|
+
const registryFeeInfo = chain.fees.fee_tokens.find(
|
|
4139
|
+
(feeToken) => feeToken.denom === defaultGasToken
|
|
4140
|
+
);
|
|
4141
|
+
if (!registryFeeInfo) {
|
|
4142
|
+
return void 0;
|
|
4143
|
+
}
|
|
4144
|
+
return {
|
|
4145
|
+
denom: registryFeeInfo.denom,
|
|
4146
|
+
gasPrice: {
|
|
4147
|
+
low: registryFeeInfo.low_gas_price ? `${registryFeeInfo.low_gas_price}` : "",
|
|
4148
|
+
average: registryFeeInfo.average_gas_price ? `${registryFeeInfo.average_gas_price}` : "",
|
|
4149
|
+
high: registryFeeInfo.high_gas_price ? `${registryFeeInfo.high_gas_price}` : ""
|
|
4150
|
+
}
|
|
4151
|
+
};
|
|
4152
|
+
});
|
|
4153
|
+
}
|
|
4154
|
+
getDefaultGasTokenForChain(chainID) {
|
|
4155
|
+
var _a;
|
|
4156
|
+
const gasDenom = DEFAULT_GAS_DENOM_OVERRIDES[chainID];
|
|
4157
|
+
if (gasDenom) {
|
|
4158
|
+
return gasDenom;
|
|
4159
|
+
}
|
|
4160
|
+
let chain;
|
|
4161
|
+
chain = chains3().find((chain2) => chain2.chain_id === chainID);
|
|
4162
|
+
if (!chain) {
|
|
4163
|
+
chain = initiaChains().find((chain2) => chain2.chain_id === chainID);
|
|
4164
|
+
}
|
|
4165
|
+
if (!chain) {
|
|
4166
|
+
return void 0;
|
|
4167
|
+
}
|
|
4168
|
+
if (!chain.fees) {
|
|
4169
|
+
return void 0;
|
|
4170
|
+
}
|
|
4171
|
+
const stakingTokens = this.getStakingTokensForChain(chainID);
|
|
4172
|
+
if (stakingTokens && stakingTokens.length > 0) {
|
|
4173
|
+
const feeAsset = chain.fees.fee_tokens.find(
|
|
4174
|
+
(feeToken) => {
|
|
4175
|
+
var _a2;
|
|
4176
|
+
return feeToken.denom === ((_a2 = stakingTokens[0]) == null ? void 0 : _a2.denom);
|
|
4177
|
+
}
|
|
4178
|
+
);
|
|
4179
|
+
if (feeAsset) {
|
|
4180
|
+
return feeAsset.denom;
|
|
4181
|
+
}
|
|
4182
|
+
}
|
|
4183
|
+
const nonIBCAsset = chain.fees.fee_tokens.find(
|
|
4184
|
+
(token) => !token.denom.startsWith("ibc/") && !token.denom.startsWith("l2/")
|
|
4185
|
+
);
|
|
4186
|
+
if (nonIBCAsset) {
|
|
4187
|
+
return nonIBCAsset.denom;
|
|
4188
|
+
}
|
|
4189
|
+
const nonL2Asset = chain.fees.fee_tokens.find(
|
|
4190
|
+
(token) => !token.denom.startsWith("l2/")
|
|
4191
|
+
);
|
|
4192
|
+
if (nonL2Asset) {
|
|
4193
|
+
return nonL2Asset.denom;
|
|
4194
|
+
}
|
|
4195
|
+
return (_a = chain.fees.fee_tokens[0]) == null ? void 0 : _a.denom;
|
|
4196
|
+
}
|
|
4197
|
+
getStakingTokensForChain(chainID) {
|
|
4198
|
+
let chain;
|
|
4199
|
+
chain = chains3().find((chain2) => chain2.chain_id === chainID);
|
|
4200
|
+
if (!chain) {
|
|
4201
|
+
chain = initiaChains().find((chain2) => chain2.chain_id === chainID);
|
|
4202
|
+
}
|
|
4203
|
+
if (!chain) {
|
|
4204
|
+
throw new Error(
|
|
4205
|
+
`getStakingTokensForChain error: failed to find chain id '${chainID}' in registry`
|
|
4206
|
+
);
|
|
4207
|
+
}
|
|
4208
|
+
if (!chain.staking) {
|
|
4209
|
+
return void 0;
|
|
4210
|
+
}
|
|
4211
|
+
return chain.staking.staking_tokens;
|
|
4212
|
+
}
|
|
4213
|
+
validateGasBalances(_0) {
|
|
4214
|
+
return chunk6FNC3XMI_js.__async(this, arguments, function* ({
|
|
4215
|
+
txs,
|
|
4216
|
+
userAddresses,
|
|
4217
|
+
getOfflineSigner,
|
|
4218
|
+
getGasPrice,
|
|
4219
|
+
gasAmountMultiplier,
|
|
4220
|
+
getFallbackGasAmount
|
|
4221
|
+
}) {
|
|
4222
|
+
var _a;
|
|
4223
|
+
for (let i = 0; i < txs.length; i++) {
|
|
4224
|
+
const tx = txs[i];
|
|
4225
|
+
if (!tx) {
|
|
4226
|
+
raise(`validateGasBalances error: invalid tx at index ${i}`);
|
|
4227
|
+
}
|
|
4228
|
+
if ("cosmosTx" in tx) {
|
|
4229
|
+
const msgs = tx.cosmosTx.msgs;
|
|
4230
|
+
if (!msgs) {
|
|
4231
|
+
raise(`validateGasBalances error: invalid msgs ${msgs}`);
|
|
4232
|
+
}
|
|
4233
|
+
getOfflineSigner = getOfflineSigner || this.getCosmosSigner;
|
|
4234
|
+
if (!getOfflineSigner) {
|
|
4235
|
+
throw new Error(
|
|
4236
|
+
"executeRoute error: 'getCosmosSigner' is not provided or configured in skip router"
|
|
4237
|
+
);
|
|
4238
|
+
}
|
|
4239
|
+
const signer = yield getOfflineSigner(tx.cosmosTx.chainID);
|
|
4240
|
+
const endpoint = yield this.getRpcEndpointForChain(tx.cosmosTx.chainID);
|
|
4241
|
+
const client = yield stargate.SigningStargateClient.connectWithSigner(
|
|
4242
|
+
endpoint,
|
|
4243
|
+
signer,
|
|
4244
|
+
{
|
|
4245
|
+
aminoTypes: this.aminoTypes,
|
|
4246
|
+
registry: this.registry,
|
|
4247
|
+
accountParser: chunkJRIEAGIQ_js.accountParser
|
|
4248
|
+
}
|
|
4249
|
+
);
|
|
4250
|
+
const currentAddress = ((_a = userAddresses.find(
|
|
4251
|
+
(address) => address.chainID === tx.cosmosTx.chainID
|
|
4252
|
+
)) == null ? void 0 : _a.address) || raise(
|
|
4253
|
+
`validateGasBalance error: invalid address for chain '${tx.cosmosTx.chainID}'`
|
|
4254
|
+
);
|
|
4255
|
+
return yield this.validateCosmosGasBalance({
|
|
4256
|
+
client,
|
|
4257
|
+
signerAddress: currentAddress,
|
|
4258
|
+
chainID: tx.cosmosTx.chainID,
|
|
4259
|
+
messages: msgs,
|
|
4260
|
+
getGasPrice,
|
|
4261
|
+
gasAmountMultiplier,
|
|
4262
|
+
getFallbackGasAmount
|
|
4263
|
+
});
|
|
4264
|
+
}
|
|
4265
|
+
}
|
|
4266
|
+
});
|
|
4267
|
+
}
|
|
4268
|
+
validateCosmosGasBalance(_0) {
|
|
4269
|
+
return chunk6FNC3XMI_js.__async(this, arguments, function* ({
|
|
4270
|
+
chainID,
|
|
4271
|
+
client,
|
|
4272
|
+
signerAddress,
|
|
4273
|
+
messages,
|
|
4274
|
+
getGasPrice,
|
|
4275
|
+
gasAmountMultiplier,
|
|
4276
|
+
getFallbackGasAmount
|
|
4277
|
+
}) {
|
|
4278
|
+
var _a, _b;
|
|
4279
|
+
const fee = yield this.estimateGasForMessage({
|
|
4280
|
+
stargateClient: client,
|
|
4281
|
+
chainID,
|
|
4282
|
+
signerAddress,
|
|
4283
|
+
gasAmountMultiplier,
|
|
4284
|
+
getGasPrice,
|
|
4285
|
+
messages,
|
|
4286
|
+
getFallbackGasAmount
|
|
4287
|
+
});
|
|
4288
|
+
if (!fee.amount[0]) {
|
|
4289
|
+
throw new Error(
|
|
4290
|
+
`validateCosmosGasBalance error: unable to get fee amount`
|
|
4291
|
+
);
|
|
4292
|
+
}
|
|
4293
|
+
const mainnetAssets = yield this.assets();
|
|
4294
|
+
const testnetAssets = yield this.assets({ onlyTestnets: true });
|
|
4295
|
+
const assets = chunk6FNC3XMI_js.__spreadValues(chunk6FNC3XMI_js.__spreadValues({}, mainnetAssets), testnetAssets);
|
|
4296
|
+
const assetByChainID = assets[chainID];
|
|
4297
|
+
const result = yield Promise.all(
|
|
4298
|
+
fee.amount.map((amount) => chunk6FNC3XMI_js.__async(this, null, function* () {
|
|
4299
|
+
const asset = assetByChainID == null ? void 0 : assetByChainID.find(
|
|
4300
|
+
(asset2) => asset2.denom.toLowerCase() === amount.denom.toLowerCase()
|
|
4301
|
+
);
|
|
4302
|
+
if (!asset || !asset.decimals) {
|
|
4303
|
+
return {
|
|
4304
|
+
errMessage: `${amount.denom} is not found in assets for ${chainID}.`,
|
|
4305
|
+
amount
|
|
4306
|
+
};
|
|
4307
|
+
}
|
|
4308
|
+
const balance = yield client.getBalance(signerAddress, amount.denom);
|
|
4309
|
+
if (parseInt(balance.amount) < parseInt(amount.amount)) {
|
|
4310
|
+
const formattedBalance = Number(balance.amount) / Math.pow(10, asset.decimals);
|
|
4311
|
+
const formattedAmount = Number(amount.amount) / Math.pow(10, asset.decimals);
|
|
4312
|
+
return {
|
|
4313
|
+
errMessage: `Insufficient fee token to initiate transfer on ${chainID}. Need ${formattedAmount} ${asset.recommendedSymbol || amount.denom}, but only have ${formattedBalance} ${asset.recommendedSymbol || amount.denom}.`,
|
|
4314
|
+
amount
|
|
4315
|
+
};
|
|
4316
|
+
}
|
|
4317
|
+
return {
|
|
4318
|
+
errMessage: null,
|
|
4319
|
+
amount
|
|
4320
|
+
};
|
|
4321
|
+
}))
|
|
4322
|
+
);
|
|
4323
|
+
const successful = result.find((res) => res.errMessage === null);
|
|
4324
|
+
if (!successful) {
|
|
4325
|
+
if (result.length > 1) {
|
|
4326
|
+
throw new Error(
|
|
4327
|
+
((_a = result[0]) == null ? void 0 : _a.errMessage) || `Insufficient fee token to initiate transfer on ${chainID}.`
|
|
4328
|
+
);
|
|
4329
|
+
}
|
|
4330
|
+
throw new Error(
|
|
4331
|
+
((_b = result[0]) == null ? void 0 : _b.errMessage) || `Insufficient fee token to initiate transfer on ${chainID}.`
|
|
4332
|
+
);
|
|
4333
|
+
}
|
|
4334
|
+
return successful.amount;
|
|
4335
|
+
});
|
|
4336
|
+
}
|
|
4337
|
+
};
|
|
4338
|
+
function raise(message, options) {
|
|
4339
|
+
throw new Error(message, options);
|
|
4340
|
+
}
|
|
4341
|
+
function wait(ms) {
|
|
4342
|
+
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
4343
|
+
}
|
|
4344
|
+
|
|
4345
|
+
Object.defineProperty(exports, "DEFAULT_GAS_MULTIPLIER", {
|
|
4346
|
+
enumerable: true,
|
|
4347
|
+
get: function () { return chunkTUX4SN3U_js.DEFAULT_GAS_MULTIPLIER; }
|
|
4348
|
+
});
|
|
4349
|
+
Object.defineProperty(exports, "getCosmosGasAmountForMessage", {
|
|
4350
|
+
enumerable: true,
|
|
4351
|
+
get: function () { return chunkTUX4SN3U_js.getCosmosGasAmountForMessage; }
|
|
4352
|
+
});
|
|
4353
|
+
Object.defineProperty(exports, "getEncodeObjectFromCosmosMessage", {
|
|
4354
|
+
enumerable: true,
|
|
4355
|
+
get: function () { return chunkTUX4SN3U_js.getEncodeObjectFromCosmosMessage; }
|
|
4356
|
+
});
|
|
4357
|
+
Object.defineProperty(exports, "getEncodeObjectFromCosmosMessageInjective", {
|
|
4358
|
+
enumerable: true,
|
|
4359
|
+
get: function () { return chunkTUX4SN3U_js.getEncodeObjectFromCosmosMessageInjective; }
|
|
4360
|
+
});
|
|
4361
|
+
Object.defineProperty(exports, "affiliateFromJSON", {
|
|
4362
|
+
enumerable: true,
|
|
4363
|
+
get: function () { return chunkIEAKY5XG_js.affiliateFromJSON; }
|
|
4364
|
+
});
|
|
4365
|
+
Object.defineProperty(exports, "affiliateToJSON", {
|
|
4366
|
+
enumerable: true,
|
|
4367
|
+
get: function () { return chunkIEAKY5XG_js.affiliateToJSON; }
|
|
4368
|
+
});
|
|
4369
|
+
Object.defineProperty(exports, "assetBetweenChainsFromJSON", {
|
|
4370
|
+
enumerable: true,
|
|
4371
|
+
get: function () { return chunkIEAKY5XG_js.assetBetweenChainsFromJSON; }
|
|
4372
|
+
});
|
|
4373
|
+
Object.defineProperty(exports, "assetBetweenChainsToJSON", {
|
|
4374
|
+
enumerable: true,
|
|
4375
|
+
get: function () { return chunkIEAKY5XG_js.assetBetweenChainsToJSON; }
|
|
4376
|
+
});
|
|
4377
|
+
Object.defineProperty(exports, "assetFromJSON", {
|
|
4378
|
+
enumerable: true,
|
|
4379
|
+
get: function () { return chunkIEAKY5XG_js.assetFromJSON; }
|
|
4380
|
+
});
|
|
4381
|
+
Object.defineProperty(exports, "assetOrErrorFromJSON", {
|
|
4382
|
+
enumerable: true,
|
|
4383
|
+
get: function () { return chunkIEAKY5XG_js.assetOrErrorFromJSON; }
|
|
4384
|
+
});
|
|
4385
|
+
Object.defineProperty(exports, "assetOrErrorToJSON", {
|
|
4386
|
+
enumerable: true,
|
|
4387
|
+
get: function () { return chunkIEAKY5XG_js.assetOrErrorToJSON; }
|
|
4388
|
+
});
|
|
4389
|
+
Object.defineProperty(exports, "assetRecommendationFromJSON", {
|
|
4390
|
+
enumerable: true,
|
|
4391
|
+
get: function () { return chunkIEAKY5XG_js.assetRecommendationFromJSON; }
|
|
4392
|
+
});
|
|
4393
|
+
Object.defineProperty(exports, "assetRecommendationRequestFromJSON", {
|
|
4394
|
+
enumerable: true,
|
|
4395
|
+
get: function () { return chunkIEAKY5XG_js.assetRecommendationRequestFromJSON; }
|
|
4396
|
+
});
|
|
4397
|
+
Object.defineProperty(exports, "assetRecommendationRequestToJSON", {
|
|
4398
|
+
enumerable: true,
|
|
4399
|
+
get: function () { return chunkIEAKY5XG_js.assetRecommendationRequestToJSON; }
|
|
4400
|
+
});
|
|
4401
|
+
Object.defineProperty(exports, "assetRecommendationToJSON", {
|
|
4402
|
+
enumerable: true,
|
|
4403
|
+
get: function () { return chunkIEAKY5XG_js.assetRecommendationToJSON; }
|
|
4404
|
+
});
|
|
4405
|
+
Object.defineProperty(exports, "assetToJSON", {
|
|
4406
|
+
enumerable: true,
|
|
4407
|
+
get: function () { return chunkIEAKY5XG_js.assetToJSON; }
|
|
4408
|
+
});
|
|
4409
|
+
Object.defineProperty(exports, "assetsBetweenChainsRequestFromJSON", {
|
|
4410
|
+
enumerable: true,
|
|
4411
|
+
get: function () { return chunkIEAKY5XG_js.assetsBetweenChainsRequestFromJSON; }
|
|
4412
|
+
});
|
|
4413
|
+
Object.defineProperty(exports, "assetsBetweenChainsRequestToJSON", {
|
|
4414
|
+
enumerable: true,
|
|
4415
|
+
get: function () { return chunkIEAKY5XG_js.assetsBetweenChainsRequestToJSON; }
|
|
4416
|
+
});
|
|
4417
|
+
Object.defineProperty(exports, "assetsBetweenChainsResponseFromJSON", {
|
|
4418
|
+
enumerable: true,
|
|
4419
|
+
get: function () { return chunkIEAKY5XG_js.assetsBetweenChainsResponseFromJSON; }
|
|
4420
|
+
});
|
|
4421
|
+
Object.defineProperty(exports, "assetsFromSourceRequestFromJSON", {
|
|
4422
|
+
enumerable: true,
|
|
4423
|
+
get: function () { return chunkIEAKY5XG_js.assetsFromSourceRequestFromJSON; }
|
|
4424
|
+
});
|
|
4425
|
+
Object.defineProperty(exports, "assetsFromSourceRequestToJSON", {
|
|
4426
|
+
enumerable: true,
|
|
4427
|
+
get: function () { return chunkIEAKY5XG_js.assetsFromSourceRequestToJSON; }
|
|
4428
|
+
});
|
|
4429
|
+
Object.defineProperty(exports, "assetsRequestFromJSON", {
|
|
4430
|
+
enumerable: true,
|
|
4431
|
+
get: function () { return chunkIEAKY5XG_js.assetsRequestFromJSON; }
|
|
4432
|
+
});
|
|
4433
|
+
Object.defineProperty(exports, "assetsRequestToJSON", {
|
|
4434
|
+
enumerable: true,
|
|
4435
|
+
get: function () { return chunkIEAKY5XG_js.assetsRequestToJSON; }
|
|
4436
|
+
});
|
|
4437
|
+
Object.defineProperty(exports, "axelarTransferFromJSON", {
|
|
4438
|
+
enumerable: true,
|
|
4439
|
+
get: function () { return chunkIEAKY5XG_js.axelarTransferFromJSON; }
|
|
4440
|
+
});
|
|
4441
|
+
Object.defineProperty(exports, "axelarTransferInfoFromJSON", {
|
|
4442
|
+
enumerable: true,
|
|
4443
|
+
get: function () { return chunkIEAKY5XG_js.axelarTransferInfoFromJSON; }
|
|
4444
|
+
});
|
|
4445
|
+
Object.defineProperty(exports, "axelarTransferInfoToJSON", {
|
|
4446
|
+
enumerable: true,
|
|
4447
|
+
get: function () { return chunkIEAKY5XG_js.axelarTransferInfoToJSON; }
|
|
4448
|
+
});
|
|
4449
|
+
Object.defineProperty(exports, "axelarTransferToJSON", {
|
|
4450
|
+
enumerable: true,
|
|
4451
|
+
get: function () { return chunkIEAKY5XG_js.axelarTransferToJSON; }
|
|
4452
|
+
});
|
|
4453
|
+
Object.defineProperty(exports, "axelarTransferTransactionsFromJSON", {
|
|
4454
|
+
enumerable: true,
|
|
4455
|
+
get: function () { return chunkIEAKY5XG_js.axelarTransferTransactionsFromJSON; }
|
|
4456
|
+
});
|
|
4457
|
+
Object.defineProperty(exports, "axelarTransferTransactionsToJSON", {
|
|
4458
|
+
enumerable: true,
|
|
4459
|
+
get: function () { return chunkIEAKY5XG_js.axelarTransferTransactionsToJSON; }
|
|
4460
|
+
});
|
|
4461
|
+
Object.defineProperty(exports, "bankSendFromJSON", {
|
|
4462
|
+
enumerable: true,
|
|
4463
|
+
get: function () { return chunkIEAKY5XG_js.bankSendFromJSON; }
|
|
4464
|
+
});
|
|
4465
|
+
Object.defineProperty(exports, "bankSendToJSON", {
|
|
4466
|
+
enumerable: true,
|
|
4467
|
+
get: function () { return chunkIEAKY5XG_js.bankSendToJSON; }
|
|
4468
|
+
});
|
|
4469
|
+
Object.defineProperty(exports, "bridgeFromJSON", {
|
|
4470
|
+
enumerable: true,
|
|
4471
|
+
get: function () { return chunkIEAKY5XG_js.bridgeFromJSON; }
|
|
4472
|
+
});
|
|
4473
|
+
Object.defineProperty(exports, "bridgeToJSON", {
|
|
4474
|
+
enumerable: true,
|
|
4475
|
+
get: function () { return chunkIEAKY5XG_js.bridgeToJSON; }
|
|
4476
|
+
});
|
|
4477
|
+
Object.defineProperty(exports, "bridgesResponseFromJSON", {
|
|
4478
|
+
enumerable: true,
|
|
4479
|
+
get: function () { return chunkIEAKY5XG_js.bridgesResponseFromJSON; }
|
|
4480
|
+
});
|
|
4481
|
+
Object.defineProperty(exports, "bridgesResponseToJSON", {
|
|
4482
|
+
enumerable: true,
|
|
4483
|
+
get: function () { return chunkIEAKY5XG_js.bridgesResponseToJSON; }
|
|
4484
|
+
});
|
|
4485
|
+
Object.defineProperty(exports, "cctpTransferFromJSON", {
|
|
4486
|
+
enumerable: true,
|
|
4487
|
+
get: function () { return chunkIEAKY5XG_js.cctpTransferFromJSON; }
|
|
4488
|
+
});
|
|
4489
|
+
Object.defineProperty(exports, "cctpTransferInfoFromJSON", {
|
|
4490
|
+
enumerable: true,
|
|
4491
|
+
get: function () { return chunkIEAKY5XG_js.cctpTransferInfoFromJSON; }
|
|
4492
|
+
});
|
|
4493
|
+
Object.defineProperty(exports, "cctpTransferInfoToJSON", {
|
|
4494
|
+
enumerable: true,
|
|
4495
|
+
get: function () { return chunkIEAKY5XG_js.cctpTransferInfoToJSON; }
|
|
4496
|
+
});
|
|
4497
|
+
Object.defineProperty(exports, "cctpTransferToJSON", {
|
|
4498
|
+
enumerable: true,
|
|
4499
|
+
get: function () { return chunkIEAKY5XG_js.cctpTransferToJSON; }
|
|
4500
|
+
});
|
|
4501
|
+
Object.defineProperty(exports, "cctpTransferTransactionsFromJSON", {
|
|
4502
|
+
enumerable: true,
|
|
4503
|
+
get: function () { return chunkIEAKY5XG_js.cctpTransferTransactionsFromJSON; }
|
|
4504
|
+
});
|
|
4505
|
+
Object.defineProperty(exports, "cctpTransferTransactionsToJSON", {
|
|
4506
|
+
enumerable: true,
|
|
4507
|
+
get: function () { return chunkIEAKY5XG_js.cctpTransferTransactionsToJSON; }
|
|
4508
|
+
});
|
|
4509
|
+
Object.defineProperty(exports, "chainAffiliatesFromJSON", {
|
|
4510
|
+
enumerable: true,
|
|
4511
|
+
get: function () { return chunkIEAKY5XG_js.chainAffiliatesFromJSON; }
|
|
4512
|
+
});
|
|
4513
|
+
Object.defineProperty(exports, "chainAffiliatesToJSON", {
|
|
4514
|
+
enumerable: true,
|
|
4515
|
+
get: function () { return chunkIEAKY5XG_js.chainAffiliatesToJSON; }
|
|
4516
|
+
});
|
|
4517
|
+
Object.defineProperty(exports, "chainFromJSON", {
|
|
4518
|
+
enumerable: true,
|
|
4519
|
+
get: function () { return chunkIEAKY5XG_js.chainFromJSON; }
|
|
4520
|
+
});
|
|
4521
|
+
Object.defineProperty(exports, "chainIDsToAffiliatesMapFromJSON", {
|
|
4522
|
+
enumerable: true,
|
|
4523
|
+
get: function () { return chunkIEAKY5XG_js.chainIDsToAffiliatesMapFromJSON; }
|
|
4524
|
+
});
|
|
4525
|
+
Object.defineProperty(exports, "chainIDsToAffiliatesMapToJSON", {
|
|
4526
|
+
enumerable: true,
|
|
4527
|
+
get: function () { return chunkIEAKY5XG_js.chainIDsToAffiliatesMapToJSON; }
|
|
4528
|
+
});
|
|
4529
|
+
Object.defineProperty(exports, "chainToJSON", {
|
|
4530
|
+
enumerable: true,
|
|
4531
|
+
get: function () { return chunkIEAKY5XG_js.chainToJSON; }
|
|
4532
|
+
});
|
|
4533
|
+
Object.defineProperty(exports, "chainTransactionFromJSON", {
|
|
4534
|
+
enumerable: true,
|
|
4535
|
+
get: function () { return chunkIEAKY5XG_js.chainTransactionFromJSON; }
|
|
4536
|
+
});
|
|
4537
|
+
Object.defineProperty(exports, "chainTransactionToJSON", {
|
|
4538
|
+
enumerable: true,
|
|
4539
|
+
get: function () { return chunkIEAKY5XG_js.chainTransactionToJSON; }
|
|
4540
|
+
});
|
|
4541
|
+
Object.defineProperty(exports, "contractCallWithTokenTransactionsFromJSON", {
|
|
4542
|
+
enumerable: true,
|
|
4543
|
+
get: function () { return chunkIEAKY5XG_js.contractCallWithTokenTransactionsFromJSON; }
|
|
4544
|
+
});
|
|
4545
|
+
Object.defineProperty(exports, "contractCallWithTokenTransactionsToJSON", {
|
|
4546
|
+
enumerable: true,
|
|
4547
|
+
get: function () { return chunkIEAKY5XG_js.contractCallWithTokenTransactionsToJSON; }
|
|
4548
|
+
});
|
|
4549
|
+
Object.defineProperty(exports, "cosmWasmContractMsgFromJSON", {
|
|
4550
|
+
enumerable: true,
|
|
4551
|
+
get: function () { return chunkIEAKY5XG_js.cosmWasmContractMsgFromJSON; }
|
|
4552
|
+
});
|
|
4553
|
+
Object.defineProperty(exports, "cosmWasmContractMsgToJSON", {
|
|
4554
|
+
enumerable: true,
|
|
4555
|
+
get: function () { return chunkIEAKY5XG_js.cosmWasmContractMsgToJSON; }
|
|
4556
|
+
});
|
|
4557
|
+
Object.defineProperty(exports, "cosmosMsgFromJSON", {
|
|
4558
|
+
enumerable: true,
|
|
4559
|
+
get: function () { return chunkIEAKY5XG_js.cosmosMsgFromJSON; }
|
|
4560
|
+
});
|
|
4561
|
+
Object.defineProperty(exports, "cosmosMsgToJSON", {
|
|
4562
|
+
enumerable: true,
|
|
4563
|
+
get: function () { return chunkIEAKY5XG_js.cosmosMsgToJSON; }
|
|
4564
|
+
});
|
|
4565
|
+
Object.defineProperty(exports, "cosmosTxFromJSON", {
|
|
4566
|
+
enumerable: true,
|
|
4567
|
+
get: function () { return chunkIEAKY5XG_js.cosmosTxFromJSON; }
|
|
4568
|
+
});
|
|
4569
|
+
Object.defineProperty(exports, "cosmosTxToJSON", {
|
|
4570
|
+
enumerable: true,
|
|
4571
|
+
get: function () { return chunkIEAKY5XG_js.cosmosTxToJSON; }
|
|
4572
|
+
});
|
|
4573
|
+
Object.defineProperty(exports, "denomWithChainIDFromJSON", {
|
|
4574
|
+
enumerable: true,
|
|
4575
|
+
get: function () { return chunkIEAKY5XG_js.denomWithChainIDFromJSON; }
|
|
4576
|
+
});
|
|
4577
|
+
Object.defineProperty(exports, "denomWithChainIDToJSON", {
|
|
4578
|
+
enumerable: true,
|
|
4579
|
+
get: function () { return chunkIEAKY5XG_js.denomWithChainIDToJSON; }
|
|
4580
|
+
});
|
|
4581
|
+
Object.defineProperty(exports, "erc20ApprovalFromJSON", {
|
|
4582
|
+
enumerable: true,
|
|
4583
|
+
get: function () { return chunkIEAKY5XG_js.erc20ApprovalFromJSON; }
|
|
4584
|
+
});
|
|
4585
|
+
Object.defineProperty(exports, "erc20ApprovalToJSON", {
|
|
4586
|
+
enumerable: true,
|
|
4587
|
+
get: function () { return chunkIEAKY5XG_js.erc20ApprovalToJSON; }
|
|
4588
|
+
});
|
|
4589
|
+
Object.defineProperty(exports, "estimatedFeeFromJSON", {
|
|
4590
|
+
enumerable: true,
|
|
4591
|
+
get: function () { return chunkIEAKY5XG_js.estimatedFeeFromJSON; }
|
|
4592
|
+
});
|
|
4593
|
+
Object.defineProperty(exports, "estimatedFeeToJSON", {
|
|
4594
|
+
enumerable: true,
|
|
4595
|
+
get: function () { return chunkIEAKY5XG_js.estimatedFeeToJSON; }
|
|
4596
|
+
});
|
|
4597
|
+
Object.defineProperty(exports, "evmSwapFromJSON", {
|
|
4598
|
+
enumerable: true,
|
|
4599
|
+
get: function () { return chunkIEAKY5XG_js.evmSwapFromJSON; }
|
|
4600
|
+
});
|
|
4601
|
+
Object.defineProperty(exports, "evmSwapToJSON", {
|
|
4602
|
+
enumerable: true,
|
|
4603
|
+
get: function () { return chunkIEAKY5XG_js.evmSwapToJSON; }
|
|
4604
|
+
});
|
|
4605
|
+
Object.defineProperty(exports, "evmTxFromJSON", {
|
|
4606
|
+
enumerable: true,
|
|
4607
|
+
get: function () { return chunkIEAKY5XG_js.evmTxFromJSON; }
|
|
4608
|
+
});
|
|
4609
|
+
Object.defineProperty(exports, "evmTxToJSON", {
|
|
4610
|
+
enumerable: true,
|
|
4611
|
+
get: function () { return chunkIEAKY5XG_js.evmTxToJSON; }
|
|
4612
|
+
});
|
|
4613
|
+
Object.defineProperty(exports, "feeAssetFromJSON", {
|
|
4614
|
+
enumerable: true,
|
|
4615
|
+
get: function () { return chunkIEAKY5XG_js.feeAssetFromJSON; }
|
|
4616
|
+
});
|
|
4617
|
+
Object.defineProperty(exports, "feeAssetToJSON", {
|
|
4618
|
+
enumerable: true,
|
|
4619
|
+
get: function () { return chunkIEAKY5XG_js.feeAssetToJSON; }
|
|
4620
|
+
});
|
|
4621
|
+
Object.defineProperty(exports, "hyperlaneTransferFromJSON", {
|
|
4622
|
+
enumerable: true,
|
|
4623
|
+
get: function () { return chunkIEAKY5XG_js.hyperlaneTransferFromJSON; }
|
|
4624
|
+
});
|
|
4625
|
+
Object.defineProperty(exports, "hyperlaneTransferInfoFromJSON", {
|
|
4626
|
+
enumerable: true,
|
|
4627
|
+
get: function () { return chunkIEAKY5XG_js.hyperlaneTransferInfoFromJSON; }
|
|
4628
|
+
});
|
|
4629
|
+
Object.defineProperty(exports, "hyperlaneTransferInfoToJSON", {
|
|
4630
|
+
enumerable: true,
|
|
4631
|
+
get: function () { return chunkIEAKY5XG_js.hyperlaneTransferInfoToJSON; }
|
|
4632
|
+
});
|
|
4633
|
+
Object.defineProperty(exports, "hyperlaneTransferToJSON", {
|
|
4634
|
+
enumerable: true,
|
|
4635
|
+
get: function () { return chunkIEAKY5XG_js.hyperlaneTransferToJSON; }
|
|
4636
|
+
});
|
|
4637
|
+
Object.defineProperty(exports, "hyperlaneTransferTransactionsFromJSON", {
|
|
4638
|
+
enumerable: true,
|
|
4639
|
+
get: function () { return chunkIEAKY5XG_js.hyperlaneTransferTransactionsFromJSON; }
|
|
4640
|
+
});
|
|
4641
|
+
Object.defineProperty(exports, "hyperlaneTransferTransactionsToJSON", {
|
|
4642
|
+
enumerable: true,
|
|
4643
|
+
get: function () { return chunkIEAKY5XG_js.hyperlaneTransferTransactionsToJSON; }
|
|
4644
|
+
});
|
|
4645
|
+
Object.defineProperty(exports, "ibcAddressFromJSON", {
|
|
4646
|
+
enumerable: true,
|
|
4647
|
+
get: function () { return chunkIEAKY5XG_js.ibcAddressFromJSON; }
|
|
4648
|
+
});
|
|
4649
|
+
Object.defineProperty(exports, "ibcAddressToJSON", {
|
|
4650
|
+
enumerable: true,
|
|
4651
|
+
get: function () { return chunkIEAKY5XG_js.ibcAddressToJSON; }
|
|
4652
|
+
});
|
|
4653
|
+
Object.defineProperty(exports, "ibcCapabilitiesFromJSON", {
|
|
4654
|
+
enumerable: true,
|
|
4655
|
+
get: function () { return chunkIEAKY5XG_js.ibcCapabilitiesFromJSON; }
|
|
4656
|
+
});
|
|
4657
|
+
Object.defineProperty(exports, "ibcCapabilitiesToJSON", {
|
|
4658
|
+
enumerable: true,
|
|
4659
|
+
get: function () { return chunkIEAKY5XG_js.ibcCapabilitiesToJSON; }
|
|
4660
|
+
});
|
|
4661
|
+
Object.defineProperty(exports, "messageResponseFromJSON", {
|
|
4662
|
+
enumerable: true,
|
|
4663
|
+
get: function () { return chunkIEAKY5XG_js.messageResponseFromJSON; }
|
|
4664
|
+
});
|
|
4665
|
+
Object.defineProperty(exports, "msgFromJSON", {
|
|
4666
|
+
enumerable: true,
|
|
4667
|
+
get: function () { return chunkIEAKY5XG_js.msgFromJSON; }
|
|
4668
|
+
});
|
|
4669
|
+
Object.defineProperty(exports, "msgToJSON", {
|
|
4670
|
+
enumerable: true,
|
|
4671
|
+
get: function () { return chunkIEAKY5XG_js.msgToJSON; }
|
|
4672
|
+
});
|
|
4673
|
+
Object.defineProperty(exports, "msgsDirectRequestFromJSON", {
|
|
4674
|
+
enumerable: true,
|
|
4675
|
+
get: function () { return chunkIEAKY5XG_js.msgsDirectRequestFromJSON; }
|
|
4676
|
+
});
|
|
4677
|
+
Object.defineProperty(exports, "msgsDirectRequestToJSON", {
|
|
4678
|
+
enumerable: true,
|
|
4679
|
+
get: function () { return chunkIEAKY5XG_js.msgsDirectRequestToJSON; }
|
|
4680
|
+
});
|
|
4681
|
+
Object.defineProperty(exports, "msgsRequestFromJSON", {
|
|
4682
|
+
enumerable: true,
|
|
4683
|
+
get: function () { return chunkIEAKY5XG_js.msgsRequestFromJSON; }
|
|
4684
|
+
});
|
|
4685
|
+
Object.defineProperty(exports, "msgsRequestToJSON", {
|
|
4686
|
+
enumerable: true,
|
|
4687
|
+
get: function () { return chunkIEAKY5XG_js.msgsRequestToJSON; }
|
|
4688
|
+
});
|
|
4689
|
+
Object.defineProperty(exports, "multiChainMsgFromJSON", {
|
|
4690
|
+
enumerable: true,
|
|
4691
|
+
get: function () { return chunkIEAKY5XG_js.multiChainMsgFromJSON; }
|
|
4692
|
+
});
|
|
4693
|
+
Object.defineProperty(exports, "multiChainMsgToJSON", {
|
|
4694
|
+
enumerable: true,
|
|
4695
|
+
get: function () { return chunkIEAKY5XG_js.multiChainMsgToJSON; }
|
|
4696
|
+
});
|
|
4697
|
+
Object.defineProperty(exports, "nextBlockingTransferFromJSON", {
|
|
4698
|
+
enumerable: true,
|
|
4699
|
+
get: function () { return chunkIEAKY5XG_js.nextBlockingTransferFromJSON; }
|
|
4700
|
+
});
|
|
4701
|
+
Object.defineProperty(exports, "nextBlockingTransferToJSON", {
|
|
4702
|
+
enumerable: true,
|
|
4703
|
+
get: function () { return chunkIEAKY5XG_js.nextBlockingTransferToJSON; }
|
|
4704
|
+
});
|
|
4705
|
+
Object.defineProperty(exports, "opInitTransferFromJSON", {
|
|
4706
|
+
enumerable: true,
|
|
4707
|
+
get: function () { return chunkIEAKY5XG_js.opInitTransferFromJSON; }
|
|
4708
|
+
});
|
|
4709
|
+
Object.defineProperty(exports, "opInitTransferInfoFromJSON", {
|
|
4710
|
+
enumerable: true,
|
|
4711
|
+
get: function () { return chunkIEAKY5XG_js.opInitTransferInfoFromJSON; }
|
|
4712
|
+
});
|
|
4713
|
+
Object.defineProperty(exports, "opInitTransferInfoToJSON", {
|
|
4714
|
+
enumerable: true,
|
|
4715
|
+
get: function () { return chunkIEAKY5XG_js.opInitTransferInfoToJSON; }
|
|
4716
|
+
});
|
|
4717
|
+
Object.defineProperty(exports, "opInitTransferToJSON", {
|
|
4718
|
+
enumerable: true,
|
|
4719
|
+
get: function () { return chunkIEAKY5XG_js.opInitTransferToJSON; }
|
|
4720
|
+
});
|
|
4721
|
+
Object.defineProperty(exports, "opInitTransferTransactionsFromJSON", {
|
|
4722
|
+
enumerable: true,
|
|
4723
|
+
get: function () { return chunkIEAKY5XG_js.opInitTransferTransactionsFromJSON; }
|
|
4724
|
+
});
|
|
4725
|
+
Object.defineProperty(exports, "opInitTransferTransactionsToJSON", {
|
|
4726
|
+
enumerable: true,
|
|
4727
|
+
get: function () { return chunkIEAKY5XG_js.opInitTransferTransactionsToJSON; }
|
|
4728
|
+
});
|
|
4729
|
+
Object.defineProperty(exports, "operationFromJSON", {
|
|
4730
|
+
enumerable: true,
|
|
4731
|
+
get: function () { return chunkIEAKY5XG_js.operationFromJSON; }
|
|
4732
|
+
});
|
|
4733
|
+
Object.defineProperty(exports, "operationToJSON", {
|
|
4734
|
+
enumerable: true,
|
|
4735
|
+
get: function () { return chunkIEAKY5XG_js.operationToJSON; }
|
|
4736
|
+
});
|
|
4737
|
+
Object.defineProperty(exports, "originAssetsRequestFromJSON", {
|
|
4738
|
+
enumerable: true,
|
|
4739
|
+
get: function () { return chunkIEAKY5XG_js.originAssetsRequestFromJSON; }
|
|
4740
|
+
});
|
|
4741
|
+
Object.defineProperty(exports, "originAssetsRequestToJSON", {
|
|
4742
|
+
enumerable: true,
|
|
4743
|
+
get: function () { return chunkIEAKY5XG_js.originAssetsRequestToJSON; }
|
|
4744
|
+
});
|
|
4745
|
+
Object.defineProperty(exports, "originAssetsResponseFromJSON", {
|
|
4746
|
+
enumerable: true,
|
|
4747
|
+
get: function () { return chunkIEAKY5XG_js.originAssetsResponseFromJSON; }
|
|
4748
|
+
});
|
|
4749
|
+
Object.defineProperty(exports, "originAssetsResponseToJSON", {
|
|
4750
|
+
enumerable: true,
|
|
4751
|
+
get: function () { return chunkIEAKY5XG_js.originAssetsResponseToJSON; }
|
|
4752
|
+
});
|
|
4753
|
+
Object.defineProperty(exports, "packetFromJSON", {
|
|
4754
|
+
enumerable: true,
|
|
4755
|
+
get: function () { return chunkIEAKY5XG_js.packetFromJSON; }
|
|
4756
|
+
});
|
|
4757
|
+
Object.defineProperty(exports, "packetToJSON", {
|
|
4758
|
+
enumerable: true,
|
|
4759
|
+
get: function () { return chunkIEAKY5XG_js.packetToJSON; }
|
|
4760
|
+
});
|
|
4761
|
+
Object.defineProperty(exports, "postHandlerFromJSON", {
|
|
4762
|
+
enumerable: true,
|
|
4763
|
+
get: function () { return chunkIEAKY5XG_js.postHandlerFromJSON; }
|
|
4764
|
+
});
|
|
4765
|
+
Object.defineProperty(exports, "postHandlerToJSON", {
|
|
4766
|
+
enumerable: true,
|
|
4767
|
+
get: function () { return chunkIEAKY5XG_js.postHandlerToJSON; }
|
|
4768
|
+
});
|
|
4769
|
+
Object.defineProperty(exports, "recommendAssetsRequestFromJSON", {
|
|
4770
|
+
enumerable: true,
|
|
4771
|
+
get: function () { return chunkIEAKY5XG_js.recommendAssetsRequestFromJSON; }
|
|
4772
|
+
});
|
|
4773
|
+
Object.defineProperty(exports, "recommendAssetsRequestToJSON", {
|
|
4774
|
+
enumerable: true,
|
|
4775
|
+
get: function () { return chunkIEAKY5XG_js.recommendAssetsRequestToJSON; }
|
|
4776
|
+
});
|
|
4777
|
+
Object.defineProperty(exports, "recommendAssetsResponseFromJSON", {
|
|
4778
|
+
enumerable: true,
|
|
4779
|
+
get: function () { return chunkIEAKY5XG_js.recommendAssetsResponseFromJSON; }
|
|
4780
|
+
});
|
|
4781
|
+
Object.defineProperty(exports, "recommendAssetsResponseToJSON", {
|
|
4782
|
+
enumerable: true,
|
|
4783
|
+
get: function () { return chunkIEAKY5XG_js.recommendAssetsResponseToJSON; }
|
|
4784
|
+
});
|
|
4785
|
+
Object.defineProperty(exports, "recommendationEntryFromJSON", {
|
|
4786
|
+
enumerable: true,
|
|
4787
|
+
get: function () { return chunkIEAKY5XG_js.recommendationEntryFromJSON; }
|
|
4788
|
+
});
|
|
4789
|
+
Object.defineProperty(exports, "recommendationEntryToJSON", {
|
|
4790
|
+
enumerable: true,
|
|
4791
|
+
get: function () { return chunkIEAKY5XG_js.recommendationEntryToJSON; }
|
|
4792
|
+
});
|
|
4793
|
+
Object.defineProperty(exports, "routeRequestFromJSON", {
|
|
4794
|
+
enumerable: true,
|
|
4795
|
+
get: function () { return chunkIEAKY5XG_js.routeRequestFromJSON; }
|
|
4796
|
+
});
|
|
4797
|
+
Object.defineProperty(exports, "routeRequestToJSON", {
|
|
4798
|
+
enumerable: true,
|
|
4799
|
+
get: function () { return chunkIEAKY5XG_js.routeRequestToJSON; }
|
|
4800
|
+
});
|
|
4801
|
+
Object.defineProperty(exports, "routeResponseFromJSON", {
|
|
4802
|
+
enumerable: true,
|
|
4803
|
+
get: function () { return chunkIEAKY5XG_js.routeResponseFromJSON; }
|
|
4804
|
+
});
|
|
4805
|
+
Object.defineProperty(exports, "routeResponseToJSON", {
|
|
4806
|
+
enumerable: true,
|
|
4807
|
+
get: function () { return chunkIEAKY5XG_js.routeResponseToJSON; }
|
|
4808
|
+
});
|
|
4809
|
+
Object.defineProperty(exports, "sendTokenTransactionsFromJSON", {
|
|
4810
|
+
enumerable: true,
|
|
4811
|
+
get: function () { return chunkIEAKY5XG_js.sendTokenTransactionsFromJSON; }
|
|
4812
|
+
});
|
|
4813
|
+
Object.defineProperty(exports, "sendTokenTransactionsToJSON", {
|
|
4814
|
+
enumerable: true,
|
|
4815
|
+
get: function () { return chunkIEAKY5XG_js.sendTokenTransactionsToJSON; }
|
|
4816
|
+
});
|
|
4817
|
+
Object.defineProperty(exports, "smartSwapExactCoinInFromJSON", {
|
|
4818
|
+
enumerable: true,
|
|
4819
|
+
get: function () { return chunkIEAKY5XG_js.smartSwapExactCoinInFromJSON; }
|
|
4820
|
+
});
|
|
4821
|
+
Object.defineProperty(exports, "smartSwapExactCoinInToJSON", {
|
|
4822
|
+
enumerable: true,
|
|
4823
|
+
get: function () { return chunkIEAKY5XG_js.smartSwapExactCoinInToJSON; }
|
|
4824
|
+
});
|
|
4825
|
+
Object.defineProperty(exports, "smartSwapOptionsFromJSON", {
|
|
4826
|
+
enumerable: true,
|
|
4827
|
+
get: function () { return chunkIEAKY5XG_js.smartSwapOptionsFromJSON; }
|
|
4828
|
+
});
|
|
4829
|
+
Object.defineProperty(exports, "smartSwapOptionsToJSON", {
|
|
4830
|
+
enumerable: true,
|
|
4831
|
+
get: function () { return chunkIEAKY5XG_js.smartSwapOptionsToJSON; }
|
|
4832
|
+
});
|
|
4833
|
+
Object.defineProperty(exports, "submitTxRequestFromJSON", {
|
|
4834
|
+
enumerable: true,
|
|
4835
|
+
get: function () { return chunkIEAKY5XG_js.submitTxRequestFromJSON; }
|
|
4836
|
+
});
|
|
4837
|
+
Object.defineProperty(exports, "submitTxRequestToJSON", {
|
|
4838
|
+
enumerable: true,
|
|
4839
|
+
get: function () { return chunkIEAKY5XG_js.submitTxRequestToJSON; }
|
|
4840
|
+
});
|
|
4841
|
+
Object.defineProperty(exports, "submitTxResponseFromJSON", {
|
|
4842
|
+
enumerable: true,
|
|
4843
|
+
get: function () { return chunkIEAKY5XG_js.submitTxResponseFromJSON; }
|
|
4844
|
+
});
|
|
4845
|
+
Object.defineProperty(exports, "submitTxResponseToJSON", {
|
|
4846
|
+
enumerable: true,
|
|
4847
|
+
get: function () { return chunkIEAKY5XG_js.submitTxResponseToJSON; }
|
|
4848
|
+
});
|
|
4849
|
+
Object.defineProperty(exports, "svmTxFromJSON", {
|
|
4850
|
+
enumerable: true,
|
|
4851
|
+
get: function () { return chunkIEAKY5XG_js.svmTxFromJSON; }
|
|
4852
|
+
});
|
|
4853
|
+
Object.defineProperty(exports, "svmTxToJSON", {
|
|
4854
|
+
enumerable: true,
|
|
4855
|
+
get: function () { return chunkIEAKY5XG_js.svmTxToJSON; }
|
|
4856
|
+
});
|
|
4857
|
+
Object.defineProperty(exports, "swapExactCoinInFromJSON", {
|
|
4858
|
+
enumerable: true,
|
|
4859
|
+
get: function () { return chunkIEAKY5XG_js.swapExactCoinInFromJSON; }
|
|
4860
|
+
});
|
|
4861
|
+
Object.defineProperty(exports, "swapExactCoinInToJSON", {
|
|
4862
|
+
enumerable: true,
|
|
4863
|
+
get: function () { return chunkIEAKY5XG_js.swapExactCoinInToJSON; }
|
|
4864
|
+
});
|
|
4865
|
+
Object.defineProperty(exports, "swapExactCoinOutFromJSON", {
|
|
4866
|
+
enumerable: true,
|
|
4867
|
+
get: function () { return chunkIEAKY5XG_js.swapExactCoinOutFromJSON; }
|
|
4868
|
+
});
|
|
4869
|
+
Object.defineProperty(exports, "swapExactCoinOutToJSON", {
|
|
4870
|
+
enumerable: true,
|
|
4871
|
+
get: function () { return chunkIEAKY5XG_js.swapExactCoinOutToJSON; }
|
|
4872
|
+
});
|
|
4873
|
+
Object.defineProperty(exports, "swapFromJSON", {
|
|
4874
|
+
enumerable: true,
|
|
4875
|
+
get: function () { return chunkIEAKY5XG_js.swapFromJSON; }
|
|
4876
|
+
});
|
|
4877
|
+
Object.defineProperty(exports, "swapOperationFromJSON", {
|
|
4878
|
+
enumerable: true,
|
|
4879
|
+
get: function () { return chunkIEAKY5XG_js.swapOperationFromJSON; }
|
|
4880
|
+
});
|
|
4881
|
+
Object.defineProperty(exports, "swapOperationToJSON", {
|
|
4882
|
+
enumerable: true,
|
|
4883
|
+
get: function () { return chunkIEAKY5XG_js.swapOperationToJSON; }
|
|
4884
|
+
});
|
|
4885
|
+
Object.defineProperty(exports, "swapRouteFromJSON", {
|
|
4886
|
+
enumerable: true,
|
|
4887
|
+
get: function () { return chunkIEAKY5XG_js.swapRouteFromJSON; }
|
|
4888
|
+
});
|
|
4889
|
+
Object.defineProperty(exports, "swapRouteToJSON", {
|
|
4890
|
+
enumerable: true,
|
|
4891
|
+
get: function () { return chunkIEAKY5XG_js.swapRouteToJSON; }
|
|
4892
|
+
});
|
|
4893
|
+
Object.defineProperty(exports, "swapToJSON", {
|
|
4894
|
+
enumerable: true,
|
|
4895
|
+
get: function () { return chunkIEAKY5XG_js.swapToJSON; }
|
|
4896
|
+
});
|
|
4897
|
+
Object.defineProperty(exports, "swapVenueFromJSON", {
|
|
4898
|
+
enumerable: true,
|
|
4899
|
+
get: function () { return chunkIEAKY5XG_js.swapVenueFromJSON; }
|
|
4900
|
+
});
|
|
4901
|
+
Object.defineProperty(exports, "swapVenueRequestFromJSON", {
|
|
4902
|
+
enumerable: true,
|
|
4903
|
+
get: function () { return chunkIEAKY5XG_js.swapVenueRequestFromJSON; }
|
|
4904
|
+
});
|
|
4905
|
+
Object.defineProperty(exports, "swapVenueRequestToJSON", {
|
|
4906
|
+
enumerable: true,
|
|
4907
|
+
get: function () { return chunkIEAKY5XG_js.swapVenueRequestToJSON; }
|
|
4908
|
+
});
|
|
4909
|
+
Object.defineProperty(exports, "swapVenueToJSON", {
|
|
4910
|
+
enumerable: true,
|
|
4911
|
+
get: function () { return chunkIEAKY5XG_js.swapVenueToJSON; }
|
|
4912
|
+
});
|
|
4913
|
+
Object.defineProperty(exports, "trackTxRequestFromJSON", {
|
|
4914
|
+
enumerable: true,
|
|
4915
|
+
get: function () { return chunkIEAKY5XG_js.trackTxRequestFromJSON; }
|
|
4916
|
+
});
|
|
4917
|
+
Object.defineProperty(exports, "trackTxRequestToJSON", {
|
|
4918
|
+
enumerable: true,
|
|
4919
|
+
get: function () { return chunkIEAKY5XG_js.trackTxRequestToJSON; }
|
|
4920
|
+
});
|
|
4921
|
+
Object.defineProperty(exports, "trackTxResponseFromJSON", {
|
|
4922
|
+
enumerable: true,
|
|
4923
|
+
get: function () { return chunkIEAKY5XG_js.trackTxResponseFromJSON; }
|
|
4924
|
+
});
|
|
4925
|
+
Object.defineProperty(exports, "trackTxResponseToJSON", {
|
|
4926
|
+
enumerable: true,
|
|
4927
|
+
get: function () { return chunkIEAKY5XG_js.trackTxResponseToJSON; }
|
|
4928
|
+
});
|
|
4929
|
+
Object.defineProperty(exports, "transferAssetReleaseFromJSON", {
|
|
4930
|
+
enumerable: true,
|
|
4931
|
+
get: function () { return chunkIEAKY5XG_js.transferAssetReleaseFromJSON; }
|
|
4932
|
+
});
|
|
4933
|
+
Object.defineProperty(exports, "transferAssetReleaseToJSON", {
|
|
4934
|
+
enumerable: true,
|
|
4935
|
+
get: function () { return chunkIEAKY5XG_js.transferAssetReleaseToJSON; }
|
|
4936
|
+
});
|
|
4937
|
+
Object.defineProperty(exports, "transferEventFromJSON", {
|
|
4938
|
+
enumerable: true,
|
|
4939
|
+
get: function () { return chunkIEAKY5XG_js.transferEventFromJSON; }
|
|
4940
|
+
});
|
|
4941
|
+
Object.defineProperty(exports, "transferEventToJSON", {
|
|
4942
|
+
enumerable: true,
|
|
4943
|
+
get: function () { return chunkIEAKY5XG_js.transferEventToJSON; }
|
|
4944
|
+
});
|
|
4945
|
+
Object.defineProperty(exports, "transferFromJSON", {
|
|
4946
|
+
enumerable: true,
|
|
4947
|
+
get: function () { return chunkIEAKY5XG_js.transferFromJSON; }
|
|
4948
|
+
});
|
|
4949
|
+
Object.defineProperty(exports, "transferInfoFromJSON", {
|
|
4950
|
+
enumerable: true,
|
|
4951
|
+
get: function () { return chunkIEAKY5XG_js.transferInfoFromJSON; }
|
|
4952
|
+
});
|
|
4953
|
+
Object.defineProperty(exports, "transferInfoToJSON", {
|
|
4954
|
+
enumerable: true,
|
|
4955
|
+
get: function () { return chunkIEAKY5XG_js.transferInfoToJSON; }
|
|
4956
|
+
});
|
|
4957
|
+
Object.defineProperty(exports, "transferStatusFromJSON", {
|
|
4958
|
+
enumerable: true,
|
|
4959
|
+
get: function () { return chunkIEAKY5XG_js.transferStatusFromJSON; }
|
|
4960
|
+
});
|
|
4961
|
+
Object.defineProperty(exports, "transferStatusToJSON", {
|
|
4962
|
+
enumerable: true,
|
|
4963
|
+
get: function () { return chunkIEAKY5XG_js.transferStatusToJSON; }
|
|
4964
|
+
});
|
|
4965
|
+
Object.defineProperty(exports, "transferToJSON", {
|
|
4966
|
+
enumerable: true,
|
|
4967
|
+
get: function () { return chunkIEAKY5XG_js.transferToJSON; }
|
|
4968
|
+
});
|
|
4969
|
+
Object.defineProperty(exports, "txFromJSON", {
|
|
4970
|
+
enumerable: true,
|
|
4971
|
+
get: function () { return chunkIEAKY5XG_js.txFromJSON; }
|
|
4972
|
+
});
|
|
4973
|
+
Object.defineProperty(exports, "txStatusRequestFromJSON", {
|
|
4974
|
+
enumerable: true,
|
|
4975
|
+
get: function () { return chunkIEAKY5XG_js.txStatusRequestFromJSON; }
|
|
4976
|
+
});
|
|
4977
|
+
Object.defineProperty(exports, "txStatusRequestToJSON", {
|
|
4978
|
+
enumerable: true,
|
|
4979
|
+
get: function () { return chunkIEAKY5XG_js.txStatusRequestToJSON; }
|
|
4980
|
+
});
|
|
4981
|
+
Object.defineProperty(exports, "txStatusResponseFromJSON", {
|
|
4982
|
+
enumerable: true,
|
|
4983
|
+
get: function () { return chunkIEAKY5XG_js.txStatusResponseFromJSON; }
|
|
4984
|
+
});
|
|
4985
|
+
Object.defineProperty(exports, "txStatusResponseToJSON", {
|
|
4986
|
+
enumerable: true,
|
|
4987
|
+
get: function () { return chunkIEAKY5XG_js.txStatusResponseToJSON; }
|
|
4988
|
+
});
|
|
4989
|
+
Object.defineProperty(exports, "txToJSON", {
|
|
4990
|
+
enumerable: true,
|
|
4991
|
+
get: function () { return chunkIEAKY5XG_js.txToJSON; }
|
|
4992
|
+
});
|
|
4993
|
+
exports.SKIP_API_URL = SKIP_API_URL;
|
|
4994
|
+
exports.SkipRouter = SkipRouter;
|