@hyperlane-xyz/sdk 1.3.8 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/consts/chainMetadata.d.ts +73 -304
- package/dist/consts/chainMetadata.d.ts.map +1 -1
- package/dist/consts/chainMetadata.js +169 -204
- package/dist/consts/chainMetadata.js.map +1 -1
- package/dist/consts/environments/index.d.ts +34 -18
- package/dist/consts/environments/index.d.ts.map +1 -1
- package/dist/consts/environments/index.js.map +1 -1
- package/dist/consts/environments/mainnet.json +18 -18
- package/dist/consts/environments/testnet.json +19 -17
- package/dist/core/HyperlaneCoreChecker.d.ts.map +1 -1
- package/dist/core/HyperlaneCoreChecker.js +11 -1
- package/dist/core/HyperlaneCoreChecker.js.map +1 -1
- package/dist/gas/token-prices.d.ts +56 -2
- package/dist/gas/token-prices.d.ts.map +1 -1
- package/dist/gas/token-prices.js.map +1 -1
- package/dist/index.d.ts +6 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +30 -22
- package/dist/index.js.map +1 -1
- package/dist/metadata/agentConfig.d.ts +344 -0
- package/dist/metadata/agentConfig.d.ts.map +1 -0
- package/dist/metadata/agentConfig.js +77 -0
- package/dist/metadata/agentConfig.js.map +1 -0
- package/dist/metadata/chainMetadata.test.d.ts.map +1 -0
- package/dist/metadata/chainMetadata.test.js +43 -0
- package/dist/metadata/chainMetadata.test.js.map +1 -0
- package/dist/metadata/chainMetadataTypes.d.ts +242 -0
- package/dist/metadata/chainMetadataTypes.d.ts.map +1 -0
- package/dist/metadata/chainMetadataTypes.js +170 -0
- package/dist/metadata/chainMetadataTypes.js.map +1 -0
- package/dist/metadata/deploymentArtifacts.d.ts +249 -0
- package/dist/metadata/deploymentArtifacts.d.ts.map +1 -0
- package/dist/metadata/deploymentArtifacts.js +20 -0
- package/dist/metadata/deploymentArtifacts.js.map +1 -0
- package/dist/middleware/account/InterchainAccountDeployer.js +1 -1
- package/dist/middleware/account/InterchainAccountDeployer.js.map +1 -1
- package/dist/providers/MultiProvider.d.ts +2 -2
- package/dist/providers/MultiProvider.d.ts.map +1 -1
- package/dist/providers/MultiProvider.js +9 -8
- package/dist/providers/MultiProvider.js.map +1 -1
- package/dist/utils/wagmi.d.ts +3 -1
- package/dist/utils/wagmi.d.ts.map +1 -1
- package/dist/utils/wagmi.js +6 -3
- package/dist/utils/wagmi.js.map +1 -1
- package/package.json +4 -4
- package/dist/agents/types.d.ts +0 -57
- package/dist/agents/types.d.ts.map +0 -1
- package/dist/agents/types.js +0 -37
- package/dist/agents/types.js.map +0 -1
- package/dist/consts/chainMetadata.test.d.ts.map +0 -1
- package/dist/consts/chainMetadata.test.js +0 -41
- package/dist/consts/chainMetadata.test.js.map +0 -1
- /package/dist/{consts → metadata}/chainMetadata.test.d.ts +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"token-prices.d.ts","sourceRoot":"","sources":["../../src/gas/token-prices.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"token-prices.d.ts","sourceRoot":"","sources":["../../src/gas/token-prices.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,eAAe,CAAC;AAMtC,OAAO,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAE/C,MAAM,WAAW,gBAAgB;IAC/B,aAAa,CAAC,KAAK,EAAE,SAAS,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;IACjD,oBAAoB,CAAC,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,SAAS,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;CAC1E;AAED,oBAAY,kBAAkB,GAAG,IAAI,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;AAC3D,oBAAY,wBAAwB,GAAG,SAAS,CAAC,QAAQ,CAAC,CAAC;AAC3D,oB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A2Bd,gBAAgB;CAe/B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"token-prices.js","sourceRoot":"","sources":["../../src/gas/token-prices.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,kEAAsC;AAEtC,gDAA4C;AAE5C,
|
|
1
|
+
{"version":3,"file":"token-prices.js","sourceRoot":"","sources":["../../src/gas/token-prices.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,kEAAsC;AAEtC,gDAA4C;AAE5C,2DAAgF;AAChF,6CAA2D;AAqB3D,MAAM,eAAe;IAKnB,YAAY,YAAY,GAAG,EAAE,EAAE,eAAe,GAAG,CAAC,GAAG,EAAE,GAAG,EAAE;QAC1D,IAAI,CAAC,KAAK,GAAG,IAAI,GAAG,EAAmC,CAAC;QACxD,IAAI,CAAC,YAAY,GAAG,YAAY,CAAC;QACjC,IAAI,CAAC,eAAe,GAAG,eAAe,CAAC;IACzC,CAAC;IAED,GAAG,CAAC,KAAgB,EAAE,KAAa;QACjC,MAAM,GAAG,GAAG,IAAI,IAAI,EAAE,CAAC;QACvB,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,KAAK,EAAE,EAAE,SAAS,EAAE,GAAG,EAAE,KAAK,EAAE,CAAC,CAAC;IACnD,CAAC;IAED,OAAO,CAAC,KAAgB;QACtB,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;QACpC,IAAI,CAAC,KAAK;YAAE,OAAO,KAAK,CAAC;QAEzB,MAAM,UAAU,GAAG,IAAI,IAAI,CACzB,KAAK,CAAC,SAAS,CAAC,OAAO,EAAE,GAAG,IAAI,GAAG,IAAI,CAAC,YAAY,CACrD,CAAC;QACF,MAAM,GAAG,GAAG,IAAI,IAAI,EAAE,CAAC;QACvB,OAAO,GAAG,GAAG,UAAU,CAAC;IAC1B,CAAC;IAED,KAAK,CAAC,KAAgB;QACpB,MAAM,KAAK,GAAG,IAAI,CAAC,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AAM,GAAG,GAAG,MAAM,CAAC,GAAG,CACpB,CAAC,KAAK,EAAE,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,sBAAsB,IAAI,KAAK,CAChE,CAAC;YACF,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,KAAK,CAAC;gBACjD,GAAG;gBACH,aAAa,EAAE,CAAC,QAAQ,CAAC;aAC1B,CAAC,CAAC;YACH,MAAM,MAAM,GAAG,GAAG,CAAC,GAAG,CAAC,CAAC,EAAE,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC;YAC5D,iDAAiD;YACjD,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,CAAC,EAAE,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAC7D,CAAC;KAAA;CACF;AA7ED,8DA6EC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
export { HyperlaneApp } from './HyperlaneApp';
|
|
2
|
-
export {
|
|
3
|
-
export { ChainMetadata, ChainMetadataSchema, ExplorerFamily, ExplorerFamilyType, ProtocolType, RpcPaginationOptions, chainIdToMetadata, chainMetadata, isValidChainMetadata, mainnetChainsMetadata, testnetChainsMetadata, wagmiChainMetadata, getDomainId, } from './consts/chainMetadata';
|
|
2
|
+
export { chainIdToMetadata, chainMetadata, mainnetChainsMetadata, testnetChainsMetadata, } from './consts/chainMetadata';
|
|
4
3
|
export { AllChains, AllDeprecatedChains, Chains, CoreChainName, DeprecatedChains, Mainnets, TestChains, Testnets, } from './consts/chains';
|
|
5
4
|
export { hyperlaneContractAddresses, hyperlaneEnvironments, } from './consts/environments';
|
|
6
5
|
export { defaultMultisigIsmConfigs } from './consts/multisigIsm';
|
|
@@ -27,6 +26,9 @@ export { GasOracleContractType, IgpBeneficiaryViolation, IgpConfig, IgpGasOracle
|
|
|
27
26
|
export { HyperlaneIsmFactory, collectValidators, } from './ism/HyperlaneIsmFactory';
|
|
28
27
|
export { HyperlaneIsmFactoryDeployer } from './ism/HyperlaneIsmFactoryDeployer';
|
|
29
28
|
export { AggregationIsmConfig, DeployedIsm, IsmConfig, ModuleType, MultisigIsmConfig, RoutingIsmConfig, } from './ism/types';
|
|
29
|
+
export { AgentChainSetup, AgentChainSetupBase, AgentConfig, AgentConnection, AgentConnectionType, AgentMetadataExtSchema, AgentMetadataExtension, AgentSigner, ChainMetadataForAgent, ChainMetadataForAgentSchema, buildAgentConfig, buildAgentConfigDeprecated, } from './metadata/agentConfig';
|
|
30
|
+
export { ChainMetadata, ChainMetadataSchema, ExplorerFamily, ExplorerFamilyValue, ProtocolSmallestUnit, ProtocolType, ProtocolTypeValue, getDomainId, isValidChainMetadata, } from './metadata/chainMetadataTypes';
|
|
31
|
+
export { ChainMetadataWithArtifacts, ChainMetadataWithArtifactsSchema, HyperlaneDeploymentArtifacts, HyperlaneDeploymentArtifactsSchema, } from './metadata/deploymentArtifacts';
|
|
30
32
|
export { InterchainAccount } from './middleware/account/InterchainAccount';
|
|
31
33
|
export { InterchainAccountChecker } from './middleware/account/InterchainAccountChecker';
|
|
32
34
|
export { InterchainAccountConfig, InterchainAccountDeployer, } from './middleware/account/InterchainAccountDeployer';
|
|
@@ -44,7 +46,7 @@ export { GasRouterDeployer } from './router/GasRouterDeployer';
|
|
|
44
46
|
export { HyperlaneRouterChecker } from './router/HyperlaneRouterChecker';
|
|
45
47
|
export { HyperlaneRouterDeployer } from './router/HyperlaneRouterDeployer';
|
|
46
48
|
export { GasRouterApp, Router, RouterApp } from './router/RouterApps';
|
|
47
|
-
export { ConnectionClientViolation, ConnectionClientViolationType, GasRouterConfig, RouterConfig, } from './router/types';
|
|
49
|
+
export { ConnectionClientViolation, ConnectionClientViolationType, GasConfig, GasRouterConfig, RouterConfig, } from './router/types';
|
|
48
50
|
export { createRouterConfigMap, deployTestIgpsAndGetRouterConfig, } from './test/testUtils';
|
|
49
51
|
export { ChainMap, ChainName, Connection, NameOrDomain, TestChainNames, } from './types';
|
|
50
52
|
export { MultiGeneric } from './utils/MultiGeneric';
|
|
@@ -53,5 +55,5 @@ export { multisigIsmVerificationCost } from './utils/ism';
|
|
|
53
55
|
export { bigToFixed, convertDecimalValue, fixedToBig, mulBigAndFixed, } from './utils/number';
|
|
54
56
|
export { objFilter, objMap, objMapEntries, objMerge, pick, promiseObjAll, } from './utils/objects';
|
|
55
57
|
export { delay } from './utils/time';
|
|
56
|
-
export { chainMetadataToWagmiChain } from './utils/wagmi';
|
|
58
|
+
export { chainMetadataToWagmiChain, wagmiChainMetadata } from './utils/wagmi';
|
|
57
59
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EACL,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EACL,iBAAiB,EACjB,aAAa,EACb,qBAAqB,EACrB,qBAAqB,GACtB,MAAM,wBAAwB,CAAC;AAChC,OAAO,EACL,SAAS,EACT,mBAAmB,EACnB,MAAM,EACN,aAAa,EACb,gBAAgB,EAChB,QAAQ,EACR,UAAU,EACV,QAAQ,GACT,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACL,0BAA0B,EAC1B,qBAAqB,GACtB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,yBAAyB,EAAE,MAAM,sBAAsB,CAAC;AACjE,OAAO,EACL,kBAAkB,EAClB,qBAAqB,EACrB,k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AAE,MAAM,cAAc,CAAC;AACrC,OAAO,EAAE,yBAAyB,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -23,24 +23,15 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
23
23
|
return result;
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
-
exports.collectValidators = exports.HyperlaneIsmFactory = exports.IgpViolationType = exports.GasOracleContractType = exports.CoinGeckoTokenPriceGetter = exports.HyperlaneIgpDeployer = exports.HyperlaneIgpChecker = exports.HyperlaneIgp = exports.verificationUtils = exports.ContractVerifier = exports.ViolationType = exports.HyperlaneDeployer = exports.HyperlaneAppChecker = exports.CoreViolationType = exports.coreFactories = exports.TestCoreDeployer = exports.TestCoreApp = exports.HyperlaneCoreDeployer = exports.HyperlaneCoreChecker = exports.HyperlaneCore = exports.serializeContractsMap = exports.serializeContracts = exports.filterAddressesMap = exports.connectContractsMap = exports.connectContracts = exports.attachContractsMap = exports.attachContracts = exports.defaultMultisigIsmConfigs = exports.hyperlaneEnvironments = exports.hyperlaneContractAddresses = exports.Testnets = exports.TestChains = exports.Mainnets = exports.DeprecatedChains = exports.Chains = exports.AllDeprecatedChains = exports.AllChains = exports.
|
|
27
|
-
exports.chainMetadataToWagmiChain = exports.delay = exports.promiseObjAll = exports.pick = exports.objMerge = exports.objMapEntries = exports.objMap = exports.objFilter = exports.mulBigAndFixed = exports.fixedToBig = exports.convertDecimalValue = exports.bigToFixed = exports.multisigIsmVerificationCost = exports.evmId = exports.canonizeId = exports.MultiGeneric = exports.deployTestIgpsAndGetRouterConfig = exports.createRouterConfigMap = exports.ConnectionClientViolationType = exports.RouterApp = exports.GasRouterApp = exports.HyperlaneRouterDeployer = exports.HyperlaneRouterChecker = exports.GasRouterDeployer = exports.RetryJsonRpcProvider = exports.defaultProviderBuilder = exports.MultiProvider = exports.interchainQueryFactories = exports.InterchainQueryDeployer = exports.InterchainQueryChecker = exports.InterchainQuery = exports.liquidityLayerFactories = exports.LiquidityLayerDeployer = exports.BridgeAdapterType = exports.LiquidityLayerApp = exports.interchainAccountFactories = exports.InterchainAccountDeployer = exports.InterchainAccountChecker = exports.InterchainAccount = exports.
|
|
26
|
+
exports.ChainMetadataSchema = exports.buildAgentConfigDeprecated = exports.buildAgentConfig = exports.ChainMetadataForAgentSchema = exports.AgentMetadataExtSchema = exports.AgentConnectionType = exports.ModuleType = exports.HyperlaneIsmFactoryDeployer = exports.collectValidators = exports.HyperlaneIsmFactory = exports.IgpViolationType = exports.GasOracleContractType = exports.CoinGeckoTokenPriceGetter = exports.HyperlaneIgpDeployer = exports.HyperlaneIgpChecker = exports.HyperlaneIgp = exports.verificationUtils = exports.ContractVerifier = exports.ViolationType = exports.HyperlaneDeployer = exports.HyperlaneAppChecker = exports.CoreViolationType = exports.coreFactories = exports.TestCoreDeployer = exports.TestCoreApp = exports.HyperlaneCoreDeployer = exports.HyperlaneCoreChecker = exports.HyperlaneCore = exports.serializeContractsMap = exports.serializeContracts = exports.filterAddressesMap = exports.connectContractsMap = exports.connectContracts = exports.attachContractsMap = exports.attachContracts = exports.defaultMultisigIsmConfigs = exports.hyperlaneEnvironments = exports.hyperlaneContractAddresses = exports.Testnets = exports.TestChains = exports.Mainnets = exports.DeprecatedChains = exports.Chains = exports.AllDeprecatedChains = exports.AllChains = exports.testnetChainsMetadata = exports.mainnetChainsMetadata = exports.chainMetadata = exports.chainIdToMetadata = exports.HyperlaneApp = void 0;
|
|
27
|
+
exports.wagmiChainMetadata = exports.chainMetadataToWagmiChain = exports.delay = exports.promiseObjAll = exports.pick = exports.objMerge = exports.objMapEntries = exports.objMap = exports.objFilter = exports.mulBigAndFixed = exports.fixedToBig = exports.convertDecimalValue = exports.bigToFixed = exports.multisigIsmVerificationCost = exports.evmId = exports.canonizeId = exports.MultiGeneric = exports.deployTestIgpsAndGetRouterConfig = exports.createRouterConfigMap = exports.ConnectionClientViolationType = exports.RouterApp = exports.GasRouterApp = exports.HyperlaneRouterDeployer = exports.HyperlaneRouterChecker = exports.GasRouterDeployer = exports.RetryJsonRpcProvider = exports.defaultProviderBuilder = exports.MultiProvider = exports.interchainQueryFactories = exports.InterchainQueryDeployer = exports.InterchainQueryChecker = exports.InterchainQuery = exports.liquidityLayerFactories = exports.LiquidityLayerDeployer = exports.BridgeAdapterType = exports.LiquidityLayerApp = exports.interchainAccountFactories = exports.InterchainAccountDeployer = exports.InterchainAccountChecker = exports.InterchainAccount = exports.HyperlaneDeploymentArtifactsSchema = exports.ChainMetadataWithArtifactsSchema = exports.isValidChainMetadata = exports.getDomainId = exports.ProtocolType = exports.ProtocolSmallestUnit = exports.ExplorerFamily = void 0;
|
|
28
28
|
var HyperlaneApp_1 = require("./HyperlaneApp");
|
|
29
29
|
Object.defineProperty(exports, "HyperlaneApp", { enumerable: true, get: function () { return HyperlaneApp_1.HyperlaneApp; } });
|
|
30
|
-
var types_1 = require("./agents/types");
|
|
31
|
-
Object.defineProperty(exports, "AgentConnectionType", { enumerable: true, get: function () { return types_1.AgentConnectionType; } });
|
|
32
|
-
Object.defineProperty(exports, "buildAgentConfig", { enumerable: true, get: function () { return types_1.buildAgentConfig; } });
|
|
33
30
|
var chainMetadata_1 = require("./consts/chainMetadata");
|
|
34
|
-
Object.defineProperty(exports, "ChainMetadataSchema", { enumerable: true, get: function () { return chainMetadata_1.ChainMetadataSchema; } });
|
|
35
|
-
Object.defineProperty(exports, "ExplorerFamily", { enumerable: true, get: function () { return chainMetadata_1.ExplorerFamily; } });
|
|
36
|
-
Object.defineProperty(exports, "ProtocolType", { enumerable: true, get: function () { return chainMetadata_1.ProtocolType; } });
|
|
37
31
|
Object.defineProperty(exports, "chainIdToMetadata", { enumerable: true, get: function () { return chainMetadata_1.chainIdToMetadata; } });
|
|
38
32
|
Object.defineProperty(exports, "chainMetadata", { enumerable: true, get: function () { return chainMetadata_1.chainMetadata; } });
|
|
39
|
-
Object.defineProperty(exports, "isValidChainMetadata", { enumerable: true, get: function () { return chainMetadata_1.isValidChainMetadata; } });
|
|
40
33
|
Object.defineProperty(exports, "mainnetChainsMetadata", { enumerable: true, get: function () { return chainMetadata_1.mainnetChainsMetadata; } });
|
|
41
34
|
Object.defineProperty(exports, "testnetChainsMetadata", { enumerable: true, get: function () { return chainMetadata_1.testnetChainsMetadata; } });
|
|
42
|
-
Object.defineProperty(exports, "wagmiChainMetadata", { enumerable: true, get: function () { return chainMetadata_1.wagmiChainMetadata; } });
|
|
43
|
-
Object.defineProperty(exports, "getDomainId", { enumerable: true, get: function () { return chainMetadata_1.getDomainId; } });
|
|
44
35
|
var chains_1 = require("./consts/chains");
|
|
45
36
|
Object.defineProperty(exports, "AllChains", { enumerable: true, get: function () { return chains_1.AllChains; } });
|
|
46
37
|
Object.defineProperty(exports, "AllDeprecatedChains", { enumerable: true, get: function () { return chains_1.AllDeprecatedChains; } });
|
|
@@ -74,14 +65,14 @@ var TestCoreDeployer_1 = require("./core/TestCoreDeployer");
|
|
|
74
65
|
Object.defineProperty(exports, "TestCoreDeployer", { enumerable: true, get: function () { return TestCoreDeployer_1.TestCoreDeployer; } });
|
|
75
66
|
var contracts_2 = require("./core/contracts");
|
|
76
67
|
Object.defineProperty(exports, "coreFactories", { enumerable: true, get: function () { return contracts_2.coreFactories; } });
|
|
77
|
-
var
|
|
78
|
-
Object.defineProperty(exports, "CoreViolationType", { enumerable: true, get: function () { return
|
|
68
|
+
var types_1 = require("./core/types");
|
|
69
|
+
Object.defineProperty(exports, "CoreViolationType", { enumerable: true, get: function () { return types_1.CoreViolationType; } });
|
|
79
70
|
var HyperlaneAppChecker_1 = require("./deploy/HyperlaneAppChecker");
|
|
80
71
|
Object.defineProperty(exports, "HyperlaneAppChecker", { enumerable: true, get: function () { return HyperlaneAppChecker_1.HyperlaneAppChecker; } });
|
|
81
72
|
var HyperlaneDeployer_1 = require("./deploy/HyperlaneDeployer");
|
|
82
73
|
Object.defineProperty(exports, "HyperlaneDeployer", { enumerable: true, get: function () { return HyperlaneDeployer_1.HyperlaneDeployer; } });
|
|
83
|
-
var
|
|
84
|
-
Object.defineProperty(exports, "ViolationType", { enumerable: true, get: function () { return
|
|
74
|
+
var types_2 = require("./deploy/types");
|
|
75
|
+
Object.defineProperty(exports, "ViolationType", { enumerable: true, get: function () { return types_2.ViolationType; } });
|
|
85
76
|
var ContractVerifier_1 = require("./deploy/verify/ContractVerifier");
|
|
86
77
|
Object.defineProperty(exports, "ContractVerifier", { enumerable: true, get: function () { return ContractVerifier_1.ContractVerifier; } });
|
|
87
78
|
exports.verificationUtils = __importStar(require("./deploy/verify/utils"));
|
|
@@ -93,16 +84,32 @@ var HyperlaneIgpDeployer_1 = require("./gas/HyperlaneIgpDeployer");
|
|
|
93
84
|
Object.defineProperty(exports, "HyperlaneIgpDeployer", { enumerable: true, get: function () { return HyperlaneIgpDeployer_1.HyperlaneIgpDeployer; } });
|
|
94
85
|
var token_prices_1 = require("./gas/token-prices");
|
|
95
86
|
Object.defineProperty(exports, "CoinGeckoTokenPriceGetter", { enumerable: true, get: function () { return token_prices_1.CoinGeckoTokenPriceGetter; } });
|
|
96
|
-
var
|
|
97
|
-
Object.defineProperty(exports, "GasOracleContractType", { enumerable: true, get: function () { return
|
|
98
|
-
Object.defineProperty(exports, "IgpViolationType", { enumerable: true, get: function () { return
|
|
87
|
+
var types_3 = require("./gas/types");
|
|
88
|
+
Object.defineProperty(exports, "GasOracleContractType", { enumerable: true, get: function () { return types_3.GasOracleContractType; } });
|
|
89
|
+
Object.defineProperty(exports, "IgpViolationType", { enumerable: true, get: function () { return types_3.IgpViolationType; } });
|
|
99
90
|
var HyperlaneIsmFactory_1 = require("./ism/HyperlaneIsmFactory");
|
|
100
91
|
Object.defineProperty(exports, "HyperlaneIsmFactory", { enumerable: true, get: function () { return HyperlaneIsmFactory_1.HyperlaneIsmFactory; } });
|
|
101
92
|
Object.defineProperty(exports, "collectValidators", { enumerable: true, get: function () { return HyperlaneIsmFactory_1.collectValidators; } });
|
|
102
93
|
var HyperlaneIsmFactoryDeployer_1 = require("./ism/HyperlaneIsmFactoryDeployer");
|
|
103
94
|
Object.defineProperty(exports, "HyperlaneIsmFactoryDeployer", { enumerable: true, get: function () { return HyperlaneIsmFactoryDeployer_1.HyperlaneIsmFactoryDeployer; } });
|
|
104
|
-
var
|
|
105
|
-
Object.defineProperty(exports, "ModuleType", { enumerable: true, get: function () { return
|
|
95
|
+
var types_4 = require("./ism/types");
|
|
96
|
+
Object.defineProperty(exports, "ModuleType", { enumerable: true, get: function () { return types_4.ModuleType; } });
|
|
97
|
+
var agentConfig_1 = require("./metadata/agentConfig");
|
|
98
|
+
Object.defineProperty(exports, "AgentConnectionType", { enumerable: true, get: function () { return agentConfig_1.AgentConnectionType; } });
|
|
99
|
+
Object.defineProperty(exports, "AgentMetadataExtSchema", { enumerable: true, get: function () { return agentConfig_1.AgentMetadataExtSchema; } });
|
|
100
|
+
Object.defineProperty(exports, "ChainMetadataForAgentSchema", { enumerable: true, get: function () { return agentConfig_1.ChainMetadataForAgentSchema; } });
|
|
101
|
+
Object.defineProperty(exports, "buildAgentConfig", { enumerable: true, get: function () { return agentConfig_1.buildAgentConfig; } });
|
|
102
|
+
Object.defineProperty(exports, "buildAgentConfigDeprecated", { enumerable: true, get: function () { return agentConfig_1.buildAgentConfigDeprecated; } });
|
|
103
|
+
var chainMetadataTypes_1 = require("./metadata/chainMetadataTypes");
|
|
104
|
+
Object.defineProperty(exports, "ChainMetadataSchema", { enumerable: true, get: function () { return chainMetadataTypes_1.ChainMetadataSchema; } });
|
|
105
|
+
Object.defineProperty(exports, "ExplorerFamily", { enumerable: true, get: function () { return chainMetadataTypes_1.ExplorerFamily; } });
|
|
106
|
+
Object.defineProperty(exports, "ProtocolSmallestUnit", { enumerable: true, get: function () { return chainMetadataTypes_1.ProtocolSmallestUnit; } });
|
|
107
|
+
Object.defineProperty(exports, "ProtocolType", { enumerable: true, get: function () { return chainMetadataTypes_1.ProtocolType; } });
|
|
108
|
+
Object.defineProperty(exports, "getDomainId", { enumerable: true, get: function () { return chainMetadataTypes_1.getDomainId; } });
|
|
109
|
+
Object.defineProperty(exports, "isValidChainMetadata", { enumerable: true, get: function () { return chainMetadataTypes_1.isValidChainMetadata; } });
|
|
110
|
+
var deploymentArtifacts_1 = require("./metadata/deploymentArtifacts");
|
|
111
|
+
Object.defineProperty(exports, "ChainMetadataWithArtifactsSchema", { enumerable: true, get: function () { return deploymentArtifacts_1.ChainMetadataWithArtifactsSchema; } });
|
|
112
|
+
Object.defineProperty(exports, "HyperlaneDeploymentArtifactsSchema", { enumerable: true, get: function () { return deploymentArtifacts_1.HyperlaneDeploymentArtifactsSchema; } });
|
|
106
113
|
var InterchainAccount_1 = require("./middleware/account/InterchainAccount");
|
|
107
114
|
Object.defineProperty(exports, "InterchainAccount", { enumerable: true, get: function () { return InterchainAccount_1.InterchainAccount; } });
|
|
108
115
|
var InterchainAccountChecker_1 = require("./middleware/account/InterchainAccountChecker");
|
|
@@ -140,8 +147,8 @@ Object.defineProperty(exports, "HyperlaneRouterDeployer", { enumerable: true, ge
|
|
|
140
147
|
var RouterApps_1 = require("./router/RouterApps");
|
|
141
148
|
Object.defineProperty(exports, "GasRouterApp", { enumerable: true, get: function () { return RouterApps_1.GasRouterApp; } });
|
|
142
149
|
Object.defineProperty(exports, "RouterApp", { enumerable: true, get: function () { return RouterApps_1.RouterApp; } });
|
|
143
|
-
var
|
|
144
|
-
Object.defineProperty(exports, "ConnectionClientViolationType", { enumerable: true, get: function () { return
|
|
150
|
+
var types_5 = require("./router/types");
|
|
151
|
+
Object.defineProperty(exports, "ConnectionClientViolationType", { enumerable: true, get: function () { return types_5.ConnectionClientViolationType; } });
|
|
145
152
|
var testUtils_1 = require("./test/testUtils");
|
|
146
153
|
Object.defineProperty(exports, "createRouterConfigMap", { enumerable: true, get: function () { return testUtils_1.createRouterConfigMap; } });
|
|
147
154
|
Object.defineProperty(exports, "deployTestIgpsAndGetRouterConfig", { enumerable: true, get: function () { return testUtils_1.deployTestIgpsAndGetRouterConfig; } });
|
|
@@ -168,4 +175,5 @@ var time_1 = require("./utils/time");
|
|
|
168
175
|
Object.defineProperty(exports, "delay", { enumerable: true, get: function () { return time_1.delay; } });
|
|
169
176
|
var wagmi_1 = require("./utils/wagmi");
|
|
170
177
|
Object.defineProperty(exports, "chainMetadataToWagmiChain", { enumerable: true, get: function () { return wagmi_1.chainMetadataToWagmiChain; } });
|
|
178
|
+
Object.defineProperty(exports, "wagmiChainMetadata", { enumerable: true, get: function () { return wagmi_1.wagmiChainMetadata; } });
|
|
171
179
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+CAA8C;AAArC,4GAAA,YAAY,OAAA;AACrB,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+CAA8C;AAArC,4GAAA,YAAY,OAAA;AACrB,wDAKgC;AAJ9B,kHAAA,iBAAiB,OAAA;AACjB,8GAAA,aAAa,OAAA;AACb,sHAAA,qBAAqB,OAAA;AACrB,sHAAA,qBAAqB,OAAA;AAEvB,0CASyB;AARvB,mGAAA,SAAS,OAAA;AACT,6GAAA,mBAAmB,OAAA;AACnB,gGAAA,MAAM,OAAA;AAEN,0GAAA,gBAAgB,OAAA;AAChB,kGAAA,QAAQ,OAAA;AACR,oGAAA,UAAU,OAAA;AACV,kGAAA,QAAQ,OAAA;AAEV,sDAG+B;AAF7B,0HAAA,0BAA0B,OAAA;AAC1B,qHAAA,qBAAqB,OAAA;AAEvB,oDAAiE;AAAxD,wHAAA,yBAAyB,OAAA;AAClC,yCAaqB;AAPnB,4GAAA,eAAe,OAAA;AACf,+GAAA,kBAAkB,OAAA;AAClB,6GAAA,gBAAgB,O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;AAAjD,kHAAA,2BAA2B,OAAA;AACpC,yCAKwB;AAJtB,oGAAA,UAAU,OAAA;AACV,6GAAA,mBAAmB,OAAA;AACnB,oGAAA,UAAU,OAAA;AACV,wGAAA,cAAc,OAAA;AAEhB,2CAOyB;AANvB,oGAAA,SAAS,OAAA;AACT,iGAAA,MAAM,OAAA;AACN,wGAAA,aAAa,OAAA;AACb,mGAAA,QAAQ,OAAA;AACR,+FAAA,IAAI,OAAA;AACJ,wGAAA,aAAa,OAAA;AAEf,qCAAqC;AAA5B,6FAAA,KAAK,OAAA;AACd,uCAA8E;AAArE,kHAAA,yBAAyB,OAAA;AAAE,2GAAA,kBAAkB,OAAA"}
|
|
@@ -0,0 +1,344 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { MultiProvider } from '../providers/MultiProvider';
|
|
3
|
+
import { ChainMap, ChainName } from '../types';
|
|
4
|
+
import { ProtocolType } from './chainMetadataTypes';
|
|
5
|
+
import { HyperlaneDeploymentArtifacts } from './deploymentArtifacts';
|
|
6
|
+
/**
|
|
7
|
+
* New agent config shape that extends the existing chain metadata with agent-specific fields.
|
|
8
|
+
*/
|
|
9
|
+
export declare enum AgentConnectionType {
|
|
10
|
+
Http = "http",
|
|
11
|
+
Ws = "ws",
|
|
12
|
+
HttpQuorum = "httpQuorum",
|
|
13
|
+
HttpFallback = "httpFallback"
|
|
14
|
+
}
|
|
15
|
+
export declare const AgentMetadataExtSchema: z.ZodObject<{
|
|
16
|
+
rpcConsensusType: z.ZodDefault<z.ZodNativeEnum<typeof AgentConnectionType>>;
|
|
17
|
+
overrideRpcUrls: z.ZodOptional<z.ZodString>;
|
|
18
|
+
index: z.ZodObject<{
|
|
19
|
+
from: z.ZodOptional<z.ZodDefault<z.ZodNumber>>;
|
|
20
|
+
chunk: z.ZodOptional<z.ZodDefault<z.ZodNumber>>;
|
|
21
|
+
}, "strip", z.ZodTypeAny, {
|
|
22
|
+
from?: number | undefined;
|
|
23
|
+
chunk?: number | undefined;
|
|
24
|
+
}, {
|
|
25
|
+
from?: number | undefined;
|
|
26
|
+
chunk?: number | undefined;
|
|
27
|
+
}>;
|
|
28
|
+
}, "strip", z.ZodTypeAny, {
|
|
29
|
+
index: {
|
|
30
|
+
from?: number | undefined;
|
|
31
|
+
chunk?: number | undefined;
|
|
32
|
+
};
|
|
33
|
+
rpcConsensusType: AgentConnectionType;
|
|
34
|
+
overrideRpcUrls?: string | undefined;
|
|
35
|
+
}, {
|
|
36
|
+
index: {
|
|
37
|
+
from?: number | undefined;
|
|
38
|
+
chunk?: number | undefined;
|
|
39
|
+
};
|
|
40
|
+
rpcConsensusType?: AgentConnectionType | undefined;
|
|
41
|
+
overrideRpcUrls?: string | undefined;
|
|
42
|
+
}>;
|
|
43
|
+
export declare type AgentMetadataExtension = z.infer<typeof AgentMetadataExtSchema>;
|
|
44
|
+
export declare const ChainMetadataForAgentSchema: z.ZodObject<{
|
|
45
|
+
name: z.ZodString;
|
|
46
|
+
chainId: z.ZodNumber;
|
|
47
|
+
protocol: z.ZodNativeEnum<typeof ProtocolType>;
|
|
48
|
+
interchainSecurityModule: z.ZodOptional<z.ZodString>;
|
|
49
|
+
interchainGasPaymaster: z.ZodString;
|
|
50
|
+
mailbox: z.ZodString;
|
|
51
|
+
domainId: z.ZodOptional<z.ZodNumber>;
|
|
52
|
+
displayName: z.ZodOptional<z.ZodString>;
|
|
53
|
+
displayNameShort: z.ZodOptional<z.ZodString>;
|
|
54
|
+
logoURI: z.ZodOptional<z.ZodString>;
|
|
55
|
+
nativeToken: z.ZodOptional<z.ZodObject<{
|
|
56
|
+
name: z.ZodString;
|
|
57
|
+
symbol: z.ZodString;
|
|
58
|
+
decimals: z.ZodNumber;
|
|
59
|
+
}, "strip", z.ZodTypeAny, {
|
|
60
|
+
symbol: string;
|
|
61
|
+
name: string;
|
|
62
|
+
decimals: number;
|
|
63
|
+
}, {
|
|
64
|
+
symbol: string;
|
|
65
|
+
name: string;
|
|
66
|
+
decimals: number;
|
|
67
|
+
}>>;
|
|
68
|
+
rpcUrls: z.ZodArray<z.ZodObject<{
|
|
69
|
+
http: z.ZodString;
|
|
70
|
+
webSocket: z.ZodOptional<z.ZodString>;
|
|
71
|
+
pagination: z.ZodOptional<z.ZodObject<{
|
|
72
|
+
maxBlockRange: z.ZodOptional<z.ZodNumber>;
|
|
73
|
+
minBlockNumber: z.ZodOptional<z.ZodNumber>;
|
|
74
|
+
maxBlockAge: z.ZodOptional<z.ZodNumber>;
|
|
75
|
+
}, "strip", z.ZodTypeAny, {
|
|
76
|
+
maxBlockRange?: number | undefined;
|
|
77
|
+
minBlockNumber?: number | undefined;
|
|
78
|
+
maxBlockAge?: number | undefined;
|
|
79
|
+
}, {
|
|
80
|
+
maxBlockRange?: number | undefined;
|
|
81
|
+
minBlockNumber?: number | undefined;
|
|
82
|
+
maxBlockAge?: number | undefined;
|
|
83
|
+
}>>;
|
|
84
|
+
retry: z.ZodOptional<z.ZodObject<{
|
|
85
|
+
maxRequests: z.ZodNumber;
|
|
86
|
+
baseRetryMs: z.ZodNumber;
|
|
87
|
+
}, "strip", z.ZodTypeAny, {
|
|
88
|
+
maxRequests: number;
|
|
89
|
+
baseRetryMs: number;
|
|
90
|
+
}, {
|
|
91
|
+
maxRequests: number;
|
|
92
|
+
baseRetryMs: number;
|
|
93
|
+
}>>;
|
|
94
|
+
}, "strip", z.ZodTypeAny, {
|
|
95
|
+
http: string;
|
|
96
|
+
webSocket?: string | undefined;
|
|
97
|
+
pagination?: {
|
|
98
|
+
maxBlockRange?: number | undefined;
|
|
99
|
+
minBlockNumber?: number | undefined;
|
|
100
|
+
maxBlockAge?: number | undefined;
|
|
101
|
+
} | undefined;
|
|
102
|
+
retry?: {
|
|
103
|
+
maxRequests: number;
|
|
104
|
+
baseRetryMs: number;
|
|
105
|
+
} | undefined;
|
|
106
|
+
}, {
|
|
107
|
+
http: string;
|
|
108
|
+
webSocket?: string | undefined;
|
|
109
|
+
pagination?: {
|
|
110
|
+
maxBlockRange?: number | undefined;
|
|
111
|
+
minBlockNumber?: number | undefined;
|
|
112
|
+
maxBlockAge?: number | undefined;
|
|
113
|
+
} | undefined;
|
|
114
|
+
retry?: {
|
|
115
|
+
maxRequests: number;
|
|
116
|
+
baseRetryMs: number;
|
|
117
|
+
} | undefined;
|
|
118
|
+
}>, "atleastone">;
|
|
119
|
+
blockExplorers: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
120
|
+
name: z.ZodString;
|
|
121
|
+
url: z.ZodString;
|
|
122
|
+
apiUrl: z.ZodString;
|
|
123
|
+
apiKey: z.ZodOptional<z.ZodString>;
|
|
124
|
+
family: z.ZodOptional<z.ZodNativeEnum<typeof import("./chainMetadataTypes").ExplorerFamily>>;
|
|
125
|
+
}, "strip", z.ZodTypeAny, {
|
|
126
|
+
url: string;
|
|
127
|
+
name: string;
|
|
128
|
+
apiUrl: string;
|
|
129
|
+
apiKey?: string | undefined;
|
|
130
|
+
family?: import("./chainMetadataTypes").ExplorerFamily | undefined;
|
|
131
|
+
}, {
|
|
132
|
+
url: string;
|
|
133
|
+
name: string;
|
|
134
|
+
apiUrl: string;
|
|
135
|
+
apiKey?: string | undefined;
|
|
136
|
+
family?: import("./chainMetadataTypes").ExplorerFamily | undefined;
|
|
137
|
+
}>, "many">>;
|
|
138
|
+
blocks: z.ZodOptional<z.ZodObject<{
|
|
139
|
+
confirmations: z.ZodNumber;
|
|
140
|
+
reorgPeriod: z.ZodOptional<z.ZodNumber>;
|
|
141
|
+
estimateBlockTime: z.ZodOptional<z.ZodNumber>;
|
|
142
|
+
}, "strip", z.ZodTypeAny, {
|
|
143
|
+
confirmations: number;
|
|
144
|
+
reorgPeriod?: number | undefined;
|
|
145
|
+
estimateBlockTime?: number | undefined;
|
|
146
|
+
}, {
|
|
147
|
+
confirmations: number;
|
|
148
|
+
reorgPeriod?: number | undefined;
|
|
149
|
+
estimateBlockTime?: number | undefined;
|
|
150
|
+
}>>;
|
|
151
|
+
transactionOverrides: z.ZodOptional<z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>>;
|
|
152
|
+
gasCurrencyCoinGeckoId: z.ZodOptional<z.ZodString>;
|
|
153
|
+
gnosisSafeTransactionServiceUrl: z.ZodOptional<z.ZodString>;
|
|
154
|
+
isTestnet: z.ZodOptional<z.ZodBoolean>;
|
|
155
|
+
validatorAnnounce: z.ZodString;
|
|
156
|
+
rpcConsensusType: z.ZodDefault<z.ZodNativeEnum<typeof AgentConnectionType>>;
|
|
157
|
+
overrideRpcUrls: z.ZodOptional<z.ZodString>;
|
|
158
|
+
index: z.ZodObject<{
|
|
159
|
+
from: z.ZodOptional<z.ZodDefault<z.ZodNumber>>;
|
|
160
|
+
chunk: z.ZodOptional<z.ZodDefault<z.ZodNumber>>;
|
|
161
|
+
}, "strip", z.ZodTypeAny, {
|
|
162
|
+
from?: number | undefined;
|
|
163
|
+
chunk?: number | undefined;
|
|
164
|
+
}, {
|
|
165
|
+
from?: number | undefined;
|
|
166
|
+
chunk?: number | undefined;
|
|
167
|
+
}>;
|
|
168
|
+
}, "strip", z.ZodTypeAny, {
|
|
169
|
+
index: {
|
|
170
|
+
from?: number | undefined;
|
|
171
|
+
chunk?: number | undefined;
|
|
172
|
+
};
|
|
173
|
+
name: string;
|
|
174
|
+
chainId: number;
|
|
175
|
+
protocol: ProtocolType;
|
|
176
|
+
interchainGasPaymaster: string;
|
|
177
|
+
mailbox: string;
|
|
178
|
+
rpcUrls: [{
|
|
179
|
+
http: string;
|
|
180
|
+
webSocket?: string | undefined;
|
|
181
|
+
pagination?: {
|
|
182
|
+
maxBlockRange?: number | undefined;
|
|
183
|
+
minBlockNumber?: number | undefined;
|
|
184
|
+
maxBlockAge?: number | undefined;
|
|
185
|
+
} | undefined;
|
|
186
|
+
retry?: {
|
|
187
|
+
maxRequests: number;
|
|
188
|
+
baseRetryMs: number;
|
|
189
|
+
} | undefined;
|
|
190
|
+
}, ...{
|
|
191
|
+
http: string;
|
|
192
|
+
webSocket?: string | undefined;
|
|
193
|
+
pagination?: {
|
|
194
|
+
maxBlockRange?: number | undefined;
|
|
195
|
+
minBlockNumber?: number | undefined;
|
|
196
|
+
maxBlockAge?: number | undefined;
|
|
197
|
+
} | undefined;
|
|
198
|
+
retry?: {
|
|
199
|
+
maxRequests: number;
|
|
200
|
+
baseRetryMs: number;
|
|
201
|
+
} | undefined;
|
|
202
|
+
}[]];
|
|
203
|
+
validatorAnnounce: string;
|
|
204
|
+
rpcConsensusType: AgentConnectionType;
|
|
205
|
+
interchainSecurityModule?: string | undefined;
|
|
206
|
+
domainId?: number | undefined;
|
|
207
|
+
displayName?: string | undefined;
|
|
208
|
+
displayNameShort?: string | undefined;
|
|
209
|
+
logoURI?: string | undefined;
|
|
210
|
+
nativeToken?: {
|
|
211
|
+
symbol: string;
|
|
212
|
+
name: string;
|
|
213
|
+
decimals: number;
|
|
214
|
+
} | undefined;
|
|
215
|
+
blockExplorers?: {
|
|
216
|
+
url: string;
|
|
217
|
+
name: string;
|
|
218
|
+
apiUrl: string;
|
|
219
|
+
apiKey?: string | undefined;
|
|
220
|
+
family?: import("./chainMetadataTypes").ExplorerFamily | undefined;
|
|
221
|
+
}[] | undefined;
|
|
222
|
+
blocks?: {
|
|
223
|
+
confirmations: number;
|
|
224
|
+
reorgPeriod?: number | undefined;
|
|
225
|
+
estimateBlockTime?: number | undefined;
|
|
226
|
+
} | undefined;
|
|
227
|
+
transactionOverrides?: {} | undefined;
|
|
228
|
+
gasCurrencyCoinGeckoId?: string | undefined;
|
|
229
|
+
gnosisSafeTransactionServiceUrl?: string | undefined;
|
|
230
|
+
isTestnet?: boolean | undefined;
|
|
231
|
+
overrideRpcUrls?: string | undefined;
|
|
232
|
+
}, {
|
|
233
|
+
index: {
|
|
234
|
+
from?: number | undefined;
|
|
235
|
+
chunk?: number | undefined;
|
|
236
|
+
};
|
|
237
|
+
name: string;
|
|
238
|
+
chainId: number;
|
|
239
|
+
protocol: ProtocolType;
|
|
240
|
+
interchainGasPaymaster: string;
|
|
241
|
+
mailbox: string;
|
|
242
|
+
rpcUrls: [{
|
|
243
|
+
http: string;
|
|
244
|
+
webSocket?: string | undefined;
|
|
245
|
+
pagination?: {
|
|
246
|
+
maxBlockRange?: number | undefined;
|
|
247
|
+
minBlockNumber?: number | undefined;
|
|
248
|
+
maxBlockAge?: number | undefined;
|
|
249
|
+
} | undefined;
|
|
250
|
+
retry?: {
|
|
251
|
+
maxRequests: number;
|
|
252
|
+
baseRetryMs: number;
|
|
253
|
+
} | undefined;
|
|
254
|
+
}, ...{
|
|
255
|
+
http: string;
|
|
256
|
+
webSocket?: string | undefined;
|
|
257
|
+
pagination?: {
|
|
258
|
+
maxBlockRange?: number | undefined;
|
|
259
|
+
minBlockNumber?: number | undefined;
|
|
260
|
+
maxBlockAge?: number | undefined;
|
|
261
|
+
} | undefined;
|
|
262
|
+
retry?: {
|
|
263
|
+
maxRequests: number;
|
|
264
|
+
baseRetryMs: number;
|
|
265
|
+
} | undefined;
|
|
266
|
+
}[]];
|
|
267
|
+
validatorAnnounce: string;
|
|
268
|
+
interchainSecurityModule?: string | undefined;
|
|
269
|
+
domainId?: number | undefined;
|
|
270
|
+
displayName?: string | undefined;
|
|
271
|
+
displayNameShort?: string | undefined;
|
|
272
|
+
logoURI?: string | undefined;
|
|
273
|
+
nativeToken?: {
|
|
274
|
+
symbol: string;
|
|
275
|
+
name: string;
|
|
276
|
+
decimals: number;
|
|
277
|
+
} | undefined;
|
|
278
|
+
blockExplorers?: {
|
|
279
|
+
url: string;
|
|
280
|
+
name: string;
|
|
281
|
+
apiUrl: string;
|
|
282
|
+
apiKey?: string | undefined;
|
|
283
|
+
family?: import("./chainMetadataTypes").ExplorerFamily | undefined;
|
|
284
|
+
}[] | undefined;
|
|
285
|
+
blocks?: {
|
|
286
|
+
confirmations: number;
|
|
287
|
+
reorgPeriod?: number | undefined;
|
|
288
|
+
estimateBlockTime?: number | undefined;
|
|
289
|
+
} | undefined;
|
|
290
|
+
transactionOverrides?: {} | undefined;
|
|
291
|
+
gasCurrencyCoinGeckoId?: string | undefined;
|
|
292
|
+
gnosisSafeTransactionServiceUrl?: string | undefined;
|
|
293
|
+
isTestnet?: boolean | undefined;
|
|
294
|
+
rpcConsensusType?: AgentConnectionType | undefined;
|
|
295
|
+
overrideRpcUrls?: string | undefined;
|
|
296
|
+
}>;
|
|
297
|
+
export declare type ChainMetadataForAgent = z.infer<typeof ChainMetadataForAgentSchema>;
|
|
298
|
+
export declare function buildAgentConfig(chains: ChainName[], multiProvider: MultiProvider, addresses: ChainMap<HyperlaneDeploymentArtifacts>, startBlocks: ChainMap<number>): ChainMap<ChainMetadataForAgent>;
|
|
299
|
+
/**
|
|
300
|
+
* Deprecated agent config shapes.
|
|
301
|
+
* See https://github.com/hyperlane-xyz/hyperlane-monorepo/issues/2215
|
|
302
|
+
*/
|
|
303
|
+
export interface AgentSigner {
|
|
304
|
+
key: string;
|
|
305
|
+
type: string;
|
|
306
|
+
}
|
|
307
|
+
export declare type AgentConnection = {
|
|
308
|
+
type: AgentConnectionType.Http;
|
|
309
|
+
url: string;
|
|
310
|
+
} | {
|
|
311
|
+
type: AgentConnectionType.Ws;
|
|
312
|
+
url: string;
|
|
313
|
+
} | {
|
|
314
|
+
type: AgentConnectionType.HttpQuorum;
|
|
315
|
+
urls: string;
|
|
316
|
+
} | {
|
|
317
|
+
type: AgentConnectionType.HttpFallback;
|
|
318
|
+
urls: string;
|
|
319
|
+
};
|
|
320
|
+
export interface AgentChainSetupBase {
|
|
321
|
+
name: ChainName;
|
|
322
|
+
domain: number;
|
|
323
|
+
signer?: AgentSigner;
|
|
324
|
+
finalityBlocks: number;
|
|
325
|
+
addresses: HyperlaneDeploymentArtifacts;
|
|
326
|
+
protocol: ProtocolType;
|
|
327
|
+
connection?: AgentConnection;
|
|
328
|
+
index?: {
|
|
329
|
+
from: number;
|
|
330
|
+
};
|
|
331
|
+
}
|
|
332
|
+
export interface AgentChainSetup extends AgentChainSetupBase {
|
|
333
|
+
signer: AgentSigner;
|
|
334
|
+
connection: AgentConnection;
|
|
335
|
+
}
|
|
336
|
+
export interface AgentConfig {
|
|
337
|
+
chains: Partial<ChainMap<AgentChainSetupBase>>;
|
|
338
|
+
tracing?: {
|
|
339
|
+
level?: string;
|
|
340
|
+
fmt?: 'json';
|
|
341
|
+
};
|
|
342
|
+
}
|
|
343
|
+
export declare function buildAgentConfigDeprecated(chains: ChainName[], multiProvider: MultiProvider, addresses: ChainMap<HyperlaneDeploymentArtifacts>, startBlocks: ChainMap<number>): AgentConfig;
|
|
344
|
+
//# sourceMappingURL=agentConfig.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agentConfig.d.ts","sourceRoot":"","sources":["../../src/metadata/agentConfig.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAC3D,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAE/C,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AACpD,OAAO,EAEL,4BAA4B,EAC7B,MAAM,uBAAuB,CAAC;AAE/B;;GAEG;AAEH,oBAAY,mBAAmB;IAC7B,IAAI,SAAS;IACb,EAAE,OAAO;IACT,UAAU,eAAe;IACzB,YAAY,iBAAiB;CAC9B;AAED,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;EAyBjC,CAAC;AAEH,oBAAY,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AAE5E,eAAO,MAAM,2BAA2B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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B,SAAQ,mBAAmB;IAC1D,MAAM,EAAE,WAAW,CAAC;IACpB,UAAU,EAAE,eAAe,CAAC;CAC7B;AAED,MAAM,WAAW,WAAW;IAC1B,MAAM,EAAE,OAAO,CAAC,QAAQ,CAAC,mBAAmB,CAAC,CAAC,CAAC;IAC/C,OAAO,CAAC,EAAE;QACR,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,GAAG,CAAC,EAAE,MAAM,CAAC;KACd,CAAC;CACH;AAED,wBAAgB,0BAA0B,CACxC,MAAM,EAAE,SAAS,EAAE,EACnB,aAAa,EAAE,aAAa,EAC5B,SAAS,EAAE,QAAQ,CAAC,4BAA4B,CAAC,EACjD,WAAW,EAAE,QAAQ,CAAC,MAAM,CAAC,GAC5B,WAAW,CA0Bb"}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.buildAgentConfigDeprecated = exports.buildAgentConfig = exports.ChainMetadataForAgentSchema = exports.AgentMetadataExtSchema = exports.AgentConnectionType = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const deploymentArtifacts_1 = require("./deploymentArtifacts");
|
|
6
|
+
/**
|
|
7
|
+
* New agent config shape that extends the existing chain metadata with agent-specific fields.
|
|
8
|
+
*/
|
|
9
|
+
var AgentConnectionType;
|
|
10
|
+
(function (AgentConnectionType) {
|
|
11
|
+
AgentConnectionType["Http"] = "http";
|
|
12
|
+
AgentConnectionType["Ws"] = "ws";
|
|
13
|
+
AgentConnectionType["HttpQuorum"] = "httpQuorum";
|
|
14
|
+
AgentConnectionType["HttpFallback"] = "httpFallback";
|
|
15
|
+
})(AgentConnectionType = exports.AgentConnectionType || (exports.AgentConnectionType = {}));
|
|
16
|
+
exports.AgentMetadataExtSchema = zod_1.z.object({
|
|
17
|
+
rpcConsensusType: zod_1.z
|
|
18
|
+
.nativeEnum(AgentConnectionType)
|
|
19
|
+
.default(AgentConnectionType.HttpFallback)
|
|
20
|
+
.describe('The consensus type to use when multiple RPCs are configured. `fallback` will use the first RPC that returns a result, `quorum` will require a majority of RPCs to return the same result. Different consumers may choose to default to different values here, i.e. validators may want to default to `quorum` while relayers may want to default to `fallback`.'),
|
|
21
|
+
overrideRpcUrls: zod_1.z
|
|
22
|
+
.string()
|
|
23
|
+
.optional()
|
|
24
|
+
.describe('Used to allow for a comma-separated list of RPC URLs to be specified without a complex `path` in the agent configuration scheme. Agents should check for the existence of this field first and use that in conjunction with `rpcConsensusType` if it exists, otherwise fall back to `rpcUrls`.'),
|
|
25
|
+
index: zod_1.z.object({
|
|
26
|
+
from: zod_1.z
|
|
27
|
+
.number()
|
|
28
|
+
.default(1999)
|
|
29
|
+
.optional()
|
|
30
|
+
.describe('The starting block from which to index events.'),
|
|
31
|
+
chunk: zod_1.z
|
|
32
|
+
.number()
|
|
33
|
+
.default(1000)
|
|
34
|
+
.optional()
|
|
35
|
+
.describe('The number of blocks to index per chunk.'),
|
|
36
|
+
}),
|
|
37
|
+
});
|
|
38
|
+
exports.ChainMetadataForAgentSchema = deploymentArtifacts_1.ChainMetadataWithArtifactsSchema.merge(exports.AgentMetadataExtSchema);
|
|
39
|
+
function buildAgentConfig(chains, multiProvider, addresses, startBlocks) {
|
|
40
|
+
const configs = {};
|
|
41
|
+
for (const chain of [...chains].sort()) {
|
|
42
|
+
const metadata = multiProvider.getChainMetadata(chain);
|
|
43
|
+
const config = Object.assign(Object.assign({}, metadata), { rpcConsensusType: AgentConnectionType.HttpFallback, mailbox: addresses[chain].mailbox, interchainGasPaymaster: addresses[chain].interchainGasPaymaster, validatorAnnounce: addresses[chain].validatorAnnounce, index: {
|
|
44
|
+
from: startBlocks[chain],
|
|
45
|
+
} });
|
|
46
|
+
configs[chain] = config;
|
|
47
|
+
}
|
|
48
|
+
return configs;
|
|
49
|
+
}
|
|
50
|
+
exports.buildAgentConfig = buildAgentConfig;
|
|
51
|
+
function buildAgentConfigDeprecated(chains, multiProvider, addresses, startBlocks) {
|
|
52
|
+
var _a, _b;
|
|
53
|
+
const agentConfig = {
|
|
54
|
+
chains: {},
|
|
55
|
+
};
|
|
56
|
+
for (const chain of [...chains].sort()) {
|
|
57
|
+
const metadata = multiProvider.getChainMetadata(chain);
|
|
58
|
+
const chainConfig = {
|
|
59
|
+
name: chain,
|
|
60
|
+
domain: metadata.chainId,
|
|
61
|
+
addresses: {
|
|
62
|
+
mailbox: addresses[chain].mailbox,
|
|
63
|
+
interchainGasPaymaster: addresses[chain].interchainGasPaymaster,
|
|
64
|
+
validatorAnnounce: addresses[chain].validatorAnnounce,
|
|
65
|
+
},
|
|
66
|
+
protocol: metadata.protocol,
|
|
67
|
+
finalityBlocks: (_b = (_a = metadata.blocks) === null || _a === void 0 ? void 0 : _a.reorgPeriod) !== null && _b !== void 0 ? _b : 1,
|
|
68
|
+
};
|
|
69
|
+
chainConfig.index = {
|
|
70
|
+
from: startBlocks[chain],
|
|
71
|
+
};
|
|
72
|
+
agentConfig.chains[chain] = chainConfig;
|
|
73
|
+
}
|
|
74
|
+
return agentConfig;
|
|
75
|
+
}
|
|
76
|
+
exports.buildAgentConfigDeprecated = buildAgentConfigDeprecated;
|
|
77
|
+
//# sourceMappingURL=agentConfig.js.map
|