From b5c83bf3f0b6fbe2541aa40116959d0509d102fe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Ogle?= Date: Sat, 17 Jun 2023 14:48:55 +0200 Subject: [PATCH 1/2] Add testnet flag to chains --- chains/arbitrum-goerli-testnet.json | 1 + chains/arbitrum-nova.json | 1 + chains/arbitrum.json | 1 + chains/aurora-testnet.json | 1 + chains/aurora.json | 1 + chains/avalanche-testnet.json | 1 + chains/avalanche.json | 1 + chains/boba-avalanche.json | 1 + chains/boba-bnb.json | 1 + chains/boba-ethereum.json | 1 + chains/bsc-testnet.json | 1 + chains/bsc.json | 1 + chains/ethereum-goerli-testnet.json | 1 + chains/ethereum-sepolia-testnet.json | 1 + chains/ethereum.json | 1 + chains/fantom-testnet.json | 1 + chains/fantom.json | 1 + chains/gnosis-testnet.json | 1 + chains/gnosis.json | 1 + chains/godwoken-testnet.json | 1 + chains/godwoken.json | 1 + chains/metis-goerli-testnet.json | 1 + chains/metis.json | 1 + chains/milkomeda-c1-testnet.json | 1 + chains/milkomeda-c1.json | 1 + chains/moonbeam-testnet.json | 1 + chains/moonbeam.json | 1 + chains/moonriver.json | 1 + chains/optimism-goerli-testnet.json | 1 + chains/optimism.json | 1 + chains/polygon-testnet.json | 1 + chains/polygon-zkevm-goerli-testnet.json | 1 + chains/polygon-zkevm.json | 1 + chains/polygon.json | 1 + chains/rsk-testnet.json | 1 + chains/rsk.json | 1 + chains/sx-testnet.json | 1 + chains/sx.json | 1 + chains/zksync-goerli-testnet.json | 1 + chains/zksync.json | 1 + src/generated/chains.ts | 40 ++++++++++++++++++++++++ src/types.ts | 1 + 42 files changed, 81 insertions(+) diff --git a/chains/arbitrum-goerli-testnet.json b/chains/arbitrum-goerli-testnet.json index fa721971..15c19501 100644 --- a/chains/arbitrum-goerli-testnet.json +++ b/chains/arbitrum-goerli-testnet.json @@ -3,6 +3,7 @@ "alias": "arbitrum-goerli-testnet", "id": "421613", "symbol": "testETH", + "testnet": true, "providerUrl": "https://goerli-rollup.arbitrum.io/rpc", "explorer": { "api": { diff --git a/chains/arbitrum-nova.json b/chains/arbitrum-nova.json index 82c7ec54..a3968293 100644 --- a/chains/arbitrum-nova.json +++ b/chains/arbitrum-nova.json @@ -3,6 +3,7 @@ "alias": "arbitrum-nova", "id": "42170", "symbol": "ETH", + "testnet": false, "providerUrl": "https://nova.arbitrum.io/rpc", "explorer": { "api": { diff --git a/chains/arbitrum.json b/chains/arbitrum.json index 3a5a8ba0..34399778 100644 --- a/chains/arbitrum.json +++ b/chains/arbitrum.json @@ -3,6 +3,7 @@ "alias": "arbitrum", "id": "42161", "symbol": "ETH", + "testnet": false, "providerUrl": "https://arb1.arbitrum.io/rpc", "explorer": { "api": { diff --git a/chains/aurora-testnet.json b/chains/aurora-testnet.json index 22715867..532bd266 100644 --- a/chains/aurora-testnet.json +++ b/chains/aurora-testnet.json @@ -3,6 +3,7 @@ "alias": "aurora-testnet", "id": "1313161555", "symbol": "testETH", + "testnet": true, "providerUrl": "https://testnet.aurora.dev/", "explorer": { "api": { diff --git a/chains/aurora.json b/chains/aurora.json index 04ddb756..76830cdb 100644 --- a/chains/aurora.json +++ b/chains/aurora.json @@ -3,6 +3,7 @@ "alias": "aurora", "id": "1313161554", "symbol": "ETH", + "testnet": false, "providerUrl": "https://mainnet.aurora.dev/", "explorer": { "api": { diff --git a/chains/avalanche-testnet.json b/chains/avalanche-testnet.json index ad5b4301..fb55b4e0 100644 --- a/chains/avalanche-testnet.json +++ b/chains/avalanche-testnet.json @@ -3,6 +3,7 @@ "alias": "avalanche-testnet", "id": "43113", "symbol": "testAVAX", + "testnet": true, "providerUrl": "https://api.avax-test.network/ext/bc/C/rpc", "explorer": { "api": { diff --git a/chains/avalanche.json b/chains/avalanche.json index bc963bad..5c727bfd 100644 --- a/chains/avalanche.json +++ b/chains/avalanche.json @@ -3,6 +3,7 @@ "alias": "avalanche", "id": "43114", "symbol": "AVAX", + "testnet": false, "providerUrl": "https://api.avax.network/ext/bc/C/rpc", "explorer": { "api": { diff --git a/chains/boba-avalanche.json b/chains/boba-avalanche.json index 3ce8c9b8..c406d28e 100644 --- a/chains/boba-avalanche.json +++ b/chains/boba-avalanche.json @@ -3,6 +3,7 @@ "alias": "boba-avalanche", "id": "43288", "symbol": "BOBA", + "testnet": false, "providerUrl": "https://replica.avax.boba.network/", "explorer": { "api": { diff --git a/chains/boba-bnb.json b/chains/boba-bnb.json index bfe0fd01..a9571d79 100644 --- a/chains/boba-bnb.json +++ b/chains/boba-bnb.json @@ -3,6 +3,7 @@ "alias": "boba-bnb", "id": "56288", "symbol": "BOBA", + "testnet": false, "providerUrl": "https://replica.bnb.boba.network/", "explorer": { "api": { diff --git a/chains/boba-ethereum.json b/chains/boba-ethereum.json index 881f3c2f..21cd17e8 100644 --- a/chains/boba-ethereum.json +++ b/chains/boba-ethereum.json @@ -3,6 +3,7 @@ "alias": "boba-ethereum", "id": "288", "symbol": "BOBA", + "testnet": false, "providerUrl": "https://lightning-replica.boba.network/", "explorer": { "api": { diff --git a/chains/bsc-testnet.json b/chains/bsc-testnet.json index 61d0ec20..df3d2f49 100644 --- a/chains/bsc-testnet.json +++ b/chains/bsc-testnet.json @@ -3,6 +3,7 @@ "alias": "bsc-testnet", "id": "97", "symbol": "testBNB", + "testnet": true, "providerUrl": "https://data-seed-prebsc-1-s3.binance.org:8545/", "explorer": { "api": { diff --git a/chains/bsc.json b/chains/bsc.json index 9a07a7da..80b6a965 100644 --- a/chains/bsc.json +++ b/chains/bsc.json @@ -3,6 +3,7 @@ "alias": "bsc", "id": "56", "symbol": "BNB", + "testnet": false, "providerUrl": "https://rpc.ankr.com/bsc", "explorer": { "api": { diff --git a/chains/ethereum-goerli-testnet.json b/chains/ethereum-goerli-testnet.json index 52bb00d3..b50944ab 100644 --- a/chains/ethereum-goerli-testnet.json +++ b/chains/ethereum-goerli-testnet.json @@ -3,6 +3,7 @@ "alias": "ethereum-goerli-testnet", "id": "5", "symbol": "testETH", + "testnet": true, "providerUrl": "https://rpc.ankr.com/eth_goerli", "explorer": { "api": { diff --git a/chains/ethereum-sepolia-testnet.json b/chains/ethereum-sepolia-testnet.json index bd3cf906..16dc1b05 100644 --- a/chains/ethereum-sepolia-testnet.json +++ b/chains/ethereum-sepolia-testnet.json @@ -3,6 +3,7 @@ "alias": "ethereum-sepolia-testnet", "id": "11155111", "symbol": "testETH", + "testnet": true, "providerUrl": "https://rpc-sepolia.rockx.com", "explorer": { "api": { diff --git a/chains/ethereum.json b/chains/ethereum.json index 3f214697..b53563fc 100644 --- a/chains/ethereum.json +++ b/chains/ethereum.json @@ -3,6 +3,7 @@ "alias": "ethereum", "id": "1", "symbol": "ETH", + "testnet": false, "providerUrl": "https://eth.llamarpc.com", "explorer": { "api": { diff --git a/chains/fantom-testnet.json b/chains/fantom-testnet.json index 746cfb69..c99f5e47 100644 --- a/chains/fantom-testnet.json +++ b/chains/fantom-testnet.json @@ -3,6 +3,7 @@ "alias": "fantom-testnet", "id": "4002", "symbol": "testFTM", + "testnet": true, "providerUrl": "https://rpc.ankr.com/fantom_testnet", "explorer": { "api": { diff --git a/chains/fantom.json b/chains/fantom.json index c7f2ab37..ec9531c0 100644 --- a/chains/fantom.json +++ b/chains/fantom.json @@ -3,6 +3,7 @@ "alias": "fantom", "id": "250", "symbol": "FTM", + "testnet": false, "providerUrl": "https://rpcapi.fantom.network/", "explorer": { "api": { diff --git a/chains/gnosis-testnet.json b/chains/gnosis-testnet.json index d625bfcf..2f6c31a7 100644 --- a/chains/gnosis-testnet.json +++ b/chains/gnosis-testnet.json @@ -3,6 +3,7 @@ "alias": "gnosis-testnet", "id": "10200", "symbol": "testxDAI", + "testnet": true, "providerUrl": "https://rpc.chiadochain.net", "explorer": { "api": { diff --git a/chains/gnosis.json b/chains/gnosis.json index 8ba7e895..88431bac 100644 --- a/chains/gnosis.json +++ b/chains/gnosis.json @@ -3,6 +3,7 @@ "alias": "gnosis", "id": "100", "symbol": "xDAI", + "testnet": false, "providerUrl": "https://rpc.gnosischain.com", "explorer": { "api": { diff --git a/chains/godwoken-testnet.json b/chains/godwoken-testnet.json index 83813a00..3c487154 100644 --- a/chains/godwoken-testnet.json +++ b/chains/godwoken-testnet.json @@ -3,6 +3,7 @@ "alias": "godwoken-testnet", "id": "71401", "symbol": "testpCKB", + "testnet": true, "providerUrl": "https://v1.testnet.godwoken.io/rpc", "explorer": { "browserUrl": "https://v1.testnet.gwscan.com/" diff --git a/chains/godwoken.json b/chains/godwoken.json index 7784b9b0..a48ef6ca 100644 --- a/chains/godwoken.json +++ b/chains/godwoken.json @@ -3,6 +3,7 @@ "alias": "godwoken", "id": "71402", "symbol": "pCKB", + "testnet": false, "providerUrl": "https://v1.mainnet.godwoken.io/rpc", "explorer": { "browserUrl": "https://v1.gwscan.com/" diff --git a/chains/metis-goerli-testnet.json b/chains/metis-goerli-testnet.json index e04ef587..0a3f971b 100644 --- a/chains/metis-goerli-testnet.json +++ b/chains/metis-goerli-testnet.json @@ -3,6 +3,7 @@ "alias": "metis-goerli-testnet", "id": "599", "symbol": "testMETIS", + "testnet": true, "providerUrl": "https://goerli.gateway.metisdevops.link", "explorer": { "api": { diff --git a/chains/metis.json b/chains/metis.json index a6009805..ac2dc070 100644 --- a/chains/metis.json +++ b/chains/metis.json @@ -3,6 +3,7 @@ "alias": "metis", "id": "1088", "symbol": "METIS", + "testnet": false, "providerUrl": "https://andromeda.metis.io/?owner=1088", "explorer": { "api": { diff --git a/chains/milkomeda-c1-testnet.json b/chains/milkomeda-c1-testnet.json index 7d39ebf9..7317709d 100644 --- a/chains/milkomeda-c1-testnet.json +++ b/chains/milkomeda-c1-testnet.json @@ -3,6 +3,7 @@ "alias": "milkomeda-c1-testnet", "id": "200101", "symbol": "testmilkADA", + "testnet": true, "providerUrl": "https://rpc-devnet-cardano-evm.c1.milkomeda.com", "explorer": { "api": { diff --git a/chains/milkomeda-c1.json b/chains/milkomeda-c1.json index 430f1414..d5f94648 100644 --- a/chains/milkomeda-c1.json +++ b/chains/milkomeda-c1.json @@ -3,6 +3,7 @@ "alias": "milkomeda-c1", "id": "2001", "symbol": "milkADA", + "testnet": false, "providerUrl": "https://rpc-mainnet-cardano-evm.c1.milkomeda.com", "explorer": { "api": { diff --git a/chains/moonbeam-testnet.json b/chains/moonbeam-testnet.json index 208528bf..8658cd36 100644 --- a/chains/moonbeam-testnet.json +++ b/chains/moonbeam-testnet.json @@ -3,6 +3,7 @@ "alias": "moonbeam-testnet", "id": "1287", "symbol": "testGLMR", + "testnet": true, "providerUrl": "https://rpc.api.moonbase.moonbeam.network", "explorer": { "api": { diff --git a/chains/moonbeam.json b/chains/moonbeam.json index c62c74a3..e161d3b9 100644 --- a/chains/moonbeam.json +++ b/chains/moonbeam.json @@ -3,6 +3,7 @@ "alias": "moonbeam", "id": "1284", "symbol": "GLMR", + "testnet": false, "providerUrl": "https://rpc.api.moonbeam.network", "explorer": { "api": { diff --git a/chains/moonriver.json b/chains/moonriver.json index 1ee88d27..0bdce688 100644 --- a/chains/moonriver.json +++ b/chains/moonriver.json @@ -3,6 +3,7 @@ "alias": "moonriver", "id": "1285", "symbol": "MOVR", + "testnet": false, "providerUrl": "https://rpc.api.moonriver.moonbeam.network", "explorer": { "api": { diff --git a/chains/optimism-goerli-testnet.json b/chains/optimism-goerli-testnet.json index 2a5c0ddc..ab31f0a2 100644 --- a/chains/optimism-goerli-testnet.json +++ b/chains/optimism-goerli-testnet.json @@ -3,6 +3,7 @@ "alias": "optimism-goerli-testnet", "id": "420", "symbol": "testETH", + "testnet": true, "providerUrl": "https://goerli.optimism.io", "explorer": { "api": { diff --git a/chains/optimism.json b/chains/optimism.json index 095e9797..1e55bb1c 100644 --- a/chains/optimism.json +++ b/chains/optimism.json @@ -3,6 +3,7 @@ "alias": "optimism", "id": "10", "symbol": "ETH", + "testnet": false, "providerUrl": "https://mainnet.optimism.io", "explorer": { "api": { diff --git a/chains/polygon-testnet.json b/chains/polygon-testnet.json index 8e03ade8..338a2d53 100644 --- a/chains/polygon-testnet.json +++ b/chains/polygon-testnet.json @@ -3,6 +3,7 @@ "alias": "polygon-testnet", "id": "80001", "symbol": "testMATIC", + "testnet": true, "providerUrl": "https://rpc.ankr.com/polygon_mumbai", "explorer": { "api": { diff --git a/chains/polygon-zkevm-goerli-testnet.json b/chains/polygon-zkevm-goerli-testnet.json index 7699a1ea..693fccd1 100644 --- a/chains/polygon-zkevm-goerli-testnet.json +++ b/chains/polygon-zkevm-goerli-testnet.json @@ -3,6 +3,7 @@ "alias": "polygon-zkevm-goerli-testnet", "id": "1442", "symbol": "testETH", + "testnet": true, "providerUrl": "https://rpc.public.zkevm-test.net", "explorer": { "api": { diff --git a/chains/polygon-zkevm.json b/chains/polygon-zkevm.json index 1dc5b200..6422cc9a 100644 --- a/chains/polygon-zkevm.json +++ b/chains/polygon-zkevm.json @@ -3,6 +3,7 @@ "alias": "polygon-zkevm", "id": "1101", "symbol": "ETH", + "testnet": false, "providerUrl": "https://zkevm-rpc.com", "explorer": { "api": { diff --git a/chains/polygon.json b/chains/polygon.json index a2dd2038..44b41de6 100644 --- a/chains/polygon.json +++ b/chains/polygon.json @@ -3,6 +3,7 @@ "alias": "polygon", "id": "137", "symbol": "MATIC", + "testnet": false, "providerUrl": "https://rpc.ankr.com/polygon", "explorer": { "api": { diff --git a/chains/rsk-testnet.json b/chains/rsk-testnet.json index ebfd334f..8a7aa3af 100644 --- a/chains/rsk-testnet.json +++ b/chains/rsk-testnet.json @@ -3,6 +3,7 @@ "alias": "rsk-testnet", "id": "31", "symbol": "testRBTC", + "testnet": true, "providerUrl": "https://public-node.testnet.rsk.co", "explorer": { "browserUrl": "https://explorer.testnet.rsk.co/" diff --git a/chains/rsk.json b/chains/rsk.json index f2f22e06..b5505505 100644 --- a/chains/rsk.json +++ b/chains/rsk.json @@ -3,6 +3,7 @@ "alias": "rsk", "id": "30", "symbol": "RBTC", + "testnet": false, "providerUrl": "https://mainnet.sovryn.app/rpc", "explorer": { "browserUrl": "https://explorer.rsk.co/" diff --git a/chains/sx-testnet.json b/chains/sx-testnet.json index 373cccee..95f736ba 100644 --- a/chains/sx-testnet.json +++ b/chains/sx-testnet.json @@ -3,6 +3,7 @@ "alias": "sx-testnet", "id": "647", "symbol": "testSX", + "testnet": true, "providerUrl": "https://rpc.toronto.sx.technology", "explorer": { "api": { diff --git a/chains/sx.json b/chains/sx.json index d06a39d8..2406ba82 100644 --- a/chains/sx.json +++ b/chains/sx.json @@ -3,6 +3,7 @@ "alias": "sx", "id": "416", "symbol": "SX", + "testnet": false, "providerUrl": "https://rpc.sx.technology", "explorer": { "api": { diff --git a/chains/zksync-goerli-testnet.json b/chains/zksync-goerli-testnet.json index 718d67c7..18bda5e9 100644 --- a/chains/zksync-goerli-testnet.json +++ b/chains/zksync-goerli-testnet.json @@ -3,6 +3,7 @@ "alias": "zksync-goerli-testnet", "id": "280", "symbol": "testETH", + "testnet": true, "providerUrl": "https://testnet.era.zksync.dev", "explorer": { "browserUrl": "https://goerli.explorer.zksync.io/" diff --git a/chains/zksync.json b/chains/zksync.json index 0f6d0c2f..41cd9615 100644 --- a/chains/zksync.json +++ b/chains/zksync.json @@ -3,6 +3,7 @@ "alias": "zksync", "id": "324", "symbol": "ETH", + "testnet": false, "providerUrl": "https://mainnet.era.zksync.io", "explorer": { "browserUrl": "https://explorer.zksync.io/" diff --git a/src/generated/chains.ts b/src/generated/chains.ts index 37ac6580..b37e6a21 100644 --- a/src/generated/chains.ts +++ b/src/generated/chains.ts @@ -13,6 +13,7 @@ export const CHAINS: Chain[] = [ alias: 'arbitrum-goerli-testnet', id: '421613', symbol: 'testETH', + testnet: true, providerUrl: 'https://goerli-rollup.arbitrum.io/rpc', explorer: { api: { @@ -27,6 +28,7 @@ export const CHAINS: Chain[] = [ alias: 'arbitrum-nova', id: '42170', symbol: 'ETH', + testnet: false, providerUrl: 'https://nova.arbitrum.io/rpc', explorer: { api: { url: 'https://api-nova.arbiscan.io/api', key: { required: true } }, @@ -38,6 +40,7 @@ export const CHAINS: Chain[] = [ alias: 'arbitrum', id: '42161', symbol: 'ETH', + testnet: false, providerUrl: 'https://arb1.arbitrum.io/rpc', explorer: { api: { url: 'https://api.arbiscan.io/api', key: { required: true, hardhatEtherscanAlias: 'arbitrumOne' } }, @@ -49,6 +52,7 @@ export const CHAINS: Chain[] = [ alias: 'aurora-testnet', id: '1313161555', symbol: 'testETH', + testnet: true, providerUrl: 'https://testnet.aurora.dev/', explorer: { api: { @@ -63,6 +67,7 @@ export const CHAINS: Chain[] = [ alias: 'aurora', id: '1313161554', symbol: 'ETH', + testnet: false, providerUrl: 'https://mainnet.aurora.dev/', explorer: { api: { @@ -77,6 +82,7 @@ export const CHAINS: Chain[] = [ alias: 'avalanche-testnet', id: '43113', symbol: 'testAVAX', + testnet: true, providerUrl: 'https://api.avax-test.network/ext/bc/C/rpc', explorer: { api: { @@ -91,6 +97,7 @@ export const CHAINS: Chain[] = [ alias: 'avalanche', id: '43114', symbol: 'AVAX', + testnet: false, providerUrl: 'https://api.avax.network/ext/bc/C/rpc', explorer: { api: { url: 'https://api.snowtrace.io/api', key: { required: true, hardhatEtherscanAlias: 'avalanche' } }, @@ -102,6 +109,7 @@ export const CHAINS: Chain[] = [ alias: 'boba-avalanche', id: '43288', symbol: 'BOBA', + testnet: false, providerUrl: 'https://replica.avax.boba.network/', explorer: { api: { url: 'https://blockexplorer.avax.boba.network/api', key: { required: false } }, @@ -113,6 +121,7 @@ export const CHAINS: Chain[] = [ alias: 'boba-bnb', id: '56288', symbol: 'BOBA', + testnet: false, providerUrl: 'https://replica.bnb.boba.network/', explorer: { api: { url: 'https://blockexplorer.bnb.boba.network/api', key: { required: false } }, @@ -124,6 +133,7 @@ export const CHAINS: Chain[] = [ alias: 'boba-ethereum', id: '288', symbol: 'BOBA', + testnet: false, providerUrl: 'https://lightning-replica.boba.network/', explorer: { api: { url: 'https://api.bobascan.com/api', key: { required: true } }, @@ -146,6 +156,7 @@ export const CHAINS: Chain[] = [ alias: 'bsc-testnet', id: '97', symbol: 'testBNB', + testnet: true, providerUrl: 'https://data-seed-prebsc-1-s3.binance.org:8545/', explorer: { api: { url: 'https://api-testnet.bscscan.com/api', key: { required: true, hardhatEtherscanAlias: 'bscTestnet' } }, @@ -157,6 +168,7 @@ export const CHAINS: Chain[] = [ alias: 'bsc', id: '56', symbol: 'BNB', + testnet: false, providerUrl: 'https://rpc.ankr.com/bsc', explorer: { api: { url: 'https://api.bscscan.com/api', key: { required: true, hardhatEtherscanAlias: 'bsc' } }, @@ -168,6 +180,7 @@ export const CHAINS: Chain[] = [ alias: 'ethereum-goerli-testnet', id: '5', symbol: 'testETH', + testnet: true, providerUrl: 'https://rpc.ankr.com/eth_goerli', explorer: { api: { url: 'https://api-goerli.etherscan.io/api', key: { required: true, hardhatEtherscanAlias: 'goerli' } }, @@ -179,6 +192,7 @@ export const CHAINS: Chain[] = [ alias: 'ethereum-sepolia-testnet', id: '11155111', symbol: 'testETH', + testnet: true, providerUrl: 'https://rpc-sepolia.rockx.com', explorer: { api: { url: 'https://api-sepolia.etherscan.io/api', key: { required: true, hardhatEtherscanAlias: 'sepolia' } }, @@ -190,6 +204,7 @@ export const CHAINS: Chain[] = [ alias: 'ethereum', id: '1', symbol: 'ETH', + testnet: false, providerUrl: 'https://eth.llamarpc.com', explorer: { api: { url: 'https://api.etherscan.io/api', key: { required: true, hardhatEtherscanAlias: 'mainnet' } }, @@ -201,6 +216,7 @@ export const CHAINS: Chain[] = [ alias: 'fantom-testnet', id: '4002', symbol: 'testFTM', + testnet: true, providerUrl: 'https://rpc.ankr.com/fantom_testnet', explorer: { api: { url: 'https://api-testnet.ftmscan.com/api', key: { required: true, hardhatEtherscanAlias: 'ftmTestnet' } }, @@ -212,6 +228,7 @@ export const CHAINS: Chain[] = [ alias: 'fantom', id: '250', symbol: 'FTM', + testnet: false, providerUrl: 'https://rpcapi.fantom.network/', explorer: { api: { url: 'https://api.ftmscan.com/api', key: { required: true, hardhatEtherscanAlias: 'opera' } }, @@ -223,6 +240,7 @@ export const CHAINS: Chain[] = [ alias: 'gnosis-testnet', id: '10200', symbol: 'testxDAI', + testnet: true, providerUrl: 'https://rpc.chiadochain.net', explorer: { api: { url: 'https://blockscout.chiadochain.net/api', key: { required: false, hardhatEtherscanAlias: 'chiado' } }, @@ -234,6 +252,7 @@ export const CHAINS: Chain[] = [ alias: 'gnosis', id: '100', symbol: 'xDAI', + testnet: false, providerUrl: 'https://rpc.gnosischain.com', explorer: { api: { url: 'https://api.gnosisscan.io/api', key: { required: true, hardhatEtherscanAlias: 'gnosis' } }, @@ -245,6 +264,7 @@ export const CHAINS: Chain[] = [ alias: 'godwoken-testnet', id: '71401', symbol: 'testpCKB', + testnet: true, providerUrl: 'https://v1.testnet.godwoken.io/rpc', explorer: { browserUrl: 'https://v1.testnet.gwscan.com/' }, }, @@ -253,6 +273,7 @@ export const CHAINS: Chain[] = [ alias: 'godwoken', id: '71402', symbol: 'pCKB', + testnet: false, providerUrl: 'https://v1.mainnet.godwoken.io/rpc', explorer: { browserUrl: 'https://v1.gwscan.com/' }, }, @@ -261,6 +282,7 @@ export const CHAINS: Chain[] = [ alias: 'metis-goerli-testnet', id: '599', symbol: 'testMETIS', + testnet: true, providerUrl: 'https://goerli.gateway.metisdevops.link', explorer: { api: { url: 'https://goerli.explorer.metisdevops.link/api', key: { required: false } }, @@ -272,6 +294,7 @@ export const CHAINS: Chain[] = [ alias: 'metis', id: '1088', symbol: 'METIS', + testnet: false, providerUrl: 'https://andromeda.metis.io/?owner=1088', explorer: { api: { url: 'https://andromeda-explorer.metis.io/api', key: { required: false } }, @@ -283,6 +306,7 @@ export const CHAINS: Chain[] = [ alias: 'milkomeda-c1-testnet', id: '200101', symbol: 'testmilkADA', + testnet: true, providerUrl: 'https://rpc-devnet-cardano-evm.c1.milkomeda.com', explorer: { api: { url: 'https://explorer-devnet-cardano-evm.c1.milkomeda.com/api', key: { required: false } }, @@ -294,6 +318,7 @@ export const CHAINS: Chain[] = [ alias: 'milkomeda-c1', id: '2001', symbol: 'milkADA', + testnet: false, providerUrl: 'https://rpc-mainnet-cardano-evm.c1.milkomeda.com', explorer: { api: { url: 'https://explorer-mainnet-cardano-evm.c1.milkomeda.com/api', key: { required: false } }, @@ -305,6 +330,7 @@ export const CHAINS: Chain[] = [ alias: 'moonbeam-testnet', id: '1287', symbol: 'testGLMR', + testnet: true, providerUrl: 'https://rpc.api.moonbase.moonbeam.network', explorer: { api: { @@ -319,6 +345,7 @@ export const CHAINS: Chain[] = [ alias: 'moonbeam', id: '1284', symbol: 'GLMR', + testnet: false, providerUrl: 'https://rpc.api.moonbeam.network', explorer: { api: { url: 'https://api-moonbeam.moonscan.io/api', key: { required: true, hardhatEtherscanAlias: 'moonbeam' } }, @@ -330,6 +357,7 @@ export const CHAINS: Chain[] = [ alias: 'moonriver', id: '1285', symbol: 'MOVR', + testnet: false, providerUrl: 'https://rpc.api.moonriver.moonbeam.network', explorer: { api: { @@ -344,6 +372,7 @@ export const CHAINS: Chain[] = [ alias: 'optimism-goerli-testnet', id: '420', symbol: 'testETH', + testnet: true, providerUrl: 'https://goerli.optimism.io', explorer: { api: { @@ -358,6 +387,7 @@ export const CHAINS: Chain[] = [ alias: 'optimism', id: '10', symbol: 'ETH', + testnet: false, providerUrl: 'https://mainnet.optimism.io', explorer: { api: { @@ -372,6 +402,7 @@ export const CHAINS: Chain[] = [ alias: 'polygon-testnet', id: '80001', symbol: 'testMATIC', + testnet: true, providerUrl: 'https://rpc.ankr.com/polygon_mumbai', explorer: { api: { @@ -386,6 +417,7 @@ export const CHAINS: Chain[] = [ alias: 'polygon-zkevm-goerli-testnet', id: '1442', symbol: 'testETH', + testnet: true, providerUrl: 'https://rpc.public.zkevm-test.net', explorer: { api: { url: 'https://api-testnet-zkevm.polygonscan.com/api', key: { required: true } }, @@ -397,6 +429,7 @@ export const CHAINS: Chain[] = [ alias: 'polygon-zkevm', id: '1101', symbol: 'ETH', + testnet: false, providerUrl: 'https://zkevm-rpc.com', explorer: { api: { url: 'https://api-zkevm.polygonscan.com/api', key: { required: true } }, @@ -408,6 +441,7 @@ export const CHAINS: Chain[] = [ alias: 'polygon', id: '137', symbol: 'MATIC', + testnet: false, providerUrl: 'https://rpc.ankr.com/polygon', explorer: { api: { url: 'https://api.polygonscan.com/api', key: { required: true, hardhatEtherscanAlias: 'polygon' } }, @@ -419,6 +453,7 @@ export const CHAINS: Chain[] = [ alias: 'rsk-testnet', id: '31', symbol: 'testRBTC', + testnet: true, providerUrl: 'https://public-node.testnet.rsk.co', explorer: { browserUrl: 'https://explorer.testnet.rsk.co/' }, }, @@ -427,6 +462,7 @@ export const CHAINS: Chain[] = [ alias: 'rsk', id: '30', symbol: 'RBTC', + testnet: false, providerUrl: 'https://mainnet.sovryn.app/rpc', explorer: { browserUrl: 'https://explorer.rsk.co/' }, }, @@ -435,6 +471,7 @@ export const CHAINS: Chain[] = [ alias: 'sx-testnet', id: '647', symbol: 'testSX', + testnet: true, providerUrl: 'https://rpc.toronto.sx.technology', explorer: { api: { url: 'https://explorer.toronto.sx.technology/api', key: { required: false } }, @@ -446,6 +483,7 @@ export const CHAINS: Chain[] = [ alias: 'sx', id: '416', symbol: 'SX', + testnet: false, providerUrl: 'https://rpc.sx.technology', explorer: { api: { url: 'https://explorer.sx.technology/api', key: { required: false } }, @@ -457,6 +495,7 @@ export const CHAINS: Chain[] = [ alias: 'zksync-goerli-testnet', id: '280', symbol: 'testETH', + testnet: true, providerUrl: 'https://testnet.era.zksync.dev', explorer: { browserUrl: 'https://goerli.explorer.zksync.io/' }, }, @@ -465,6 +504,7 @@ export const CHAINS: Chain[] = [ alias: 'zksync', id: '324', symbol: 'ETH', + testnet: false, providerUrl: 'https://mainnet.era.zksync.io', explorer: { browserUrl: 'https://explorer.zksync.io/' }, }, diff --git a/src/types.ts b/src/types.ts index b270d3b6..9675b5d9 100644 --- a/src/types.ts +++ b/src/types.ts @@ -24,6 +24,7 @@ export const chainSchema = z.object({ id: z.string().regex(/^\d+$/), providerUrl: z.string().url(), symbol: z.string(), + testnet: z.boolean(), explorer: chainExplorerSchema, }); From ea4a268776cf6ecbb99e781e09f9c7ed10d35005 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Ogle?= Date: Sat, 17 Jun 2023 14:49:33 +0200 Subject: [PATCH 2/2] Add testnet flag to chains --- chains/boba-moonbeam.json | 1 + src/generated/chains.ts | 1 + 2 files changed, 2 insertions(+) diff --git a/chains/boba-moonbeam.json b/chains/boba-moonbeam.json index 82a02f34..62bf4e16 100644 --- a/chains/boba-moonbeam.json +++ b/chains/boba-moonbeam.json @@ -3,6 +3,7 @@ "alias": "boba-moonbeam", "id": "1294", "symbol": "BOBA", + "testnet": false, "providerUrl": "https://replica.bobabeam.boba.network/", "explorer": { "api": { diff --git a/src/generated/chains.ts b/src/generated/chains.ts index b37e6a21..a1ec02bf 100644 --- a/src/generated/chains.ts +++ b/src/generated/chains.ts @@ -145,6 +145,7 @@ export const CHAINS: Chain[] = [ alias: 'boba-moonbeam', id: '1294', symbol: 'BOBA', + testnet: false, providerUrl: 'https://replica.bobabeam.boba.network/', explorer: { api: { url: 'https://blockexplorer.bobabase.boba.network/api', key: { required: false } },