diff --git a/data/addresses.mainnet.json b/data/addresses.mainnet.json index dca80bdb..eb796466 100644 --- a/data/addresses.mainnet.json +++ b/data/addresses.mainnet.json @@ -57,7 +57,8 @@ "category": "omnichain", "chain_id": 7000, "chain_name": "zeta_testnet", - "coin_type": "ZRC20", + "type": "ZRC20", + "coin_type": "ERC20", "decimals": 18, "symbol": "ZetaChain ZRC20 USDC on BSC" }, @@ -77,39 +78,21 @@ "category": "omnichain", "chain_id": 7000, "chain_name": "zeta_testnet", - "coin_type": "ZRC20", + "type": "ZRC20", + "coin_type": "ERC20", "decimals": 18, "symbol": "ZetaChain ZRC20 USDC on ETH" }, - { - "address": "", - "category": "omnichain", - "chain_id": "8332", - "chain_name": "btc_mainnet", - "coin_type": "Gas", - "decimals": 8, - "symbol": "BTC.BTC", - "zrc20": "0x13A0c5930C028511Dc02665E7285134B6d11A5f4" - }, { "address": "0x13A0c5930C028511Dc02665E7285134B6d11A5f4", "asset": "", "category": "omnichain", "chain_id": 7000, "chain_name": "zeta_testnet", - "coin_type": "ZRC20", - "decimals": 18, - "symbol": "ZetaChain ZRC20 BTC-btc_mainnet" - }, - { - "address": "", - "category": "omnichain", - "chain_id": "56", - "chain_name": "bsc_mainnet", + "type": "ZRC20", "coin_type": "Gas", "decimals": 18, - "symbol": "BNB.BSC", - "zrc20": "0x48f80608B672DC30DC7e3dbBd0343c5F02C738Eb" + "symbol": "ZetaChain ZRC20 BTC-btc_mainnet" }, { "address": "0x48f80608B672DC30DC7e3dbBd0343c5F02C738Eb", @@ -117,7 +100,8 @@ "category": "omnichain", "chain_id": 7000, "chain_name": "zeta_testnet", - "coin_type": "ZRC20", + "type": "ZRC20", + "coin_type": "Gas", "decimals": 18, "symbol": "ZetaChain ZRC20 BNB-bsc_mainnet" }, @@ -137,7 +121,8 @@ "category": "omnichain", "chain_id": 7000, "chain_name": "zeta_testnet", - "coin_type": "ZRC20", + "type": "ZRC20", + "coin_type": "ERC20", "decimals": 18, "symbol": "ZetaChain ZRC20 USDT on ETH" }, @@ -157,27 +142,19 @@ "category": "omnichain", "chain_id": 7000, "chain_name": "zeta_testnet", - "coin_type": "ZRC20", + "type": "ZRC20", + "coin_type": "ERC20", "decimals": 18, "symbol": "ZetaChain ZRC20 USDT on BSC" }, - { - "address": "", - "category": "omnichain", - "chain_id": "1", - "chain_name": "eth_mainnet", - "coin_type": "Gas", - "decimals": 18, - "symbol": "ETH.ETH", - "zrc20": "0xd97B1de3619ed2c6BEb3860147E30cA8A7dC9891" - }, { "address": "0xd97B1de3619ed2c6BEb3860147E30cA8A7dC9891", "asset": "", "category": "omnichain", "chain_id": 7000, "chain_name": "zeta_testnet", - "coin_type": "ZRC20", + "type": "ZRC20", + "coin_type": "Gas", "decimals": 18, "symbol": "ZetaChain ZRC20 ETH-eth_mainnet" }, @@ -252,17 +229,17 @@ "type": "erc20Custody" }, { - "address": "0xaeB6dDB7708467814D557e340283248be8E43124", + "address": "0xaf28a257D292e7f0E531073f70a175b57E0261a8", "category": "omnichain", - "chain_id": "1", - "chain_name": "eth_mainnet", + "chain_id": "56", + "chain_name": "bsc_mainnet", "type": "tssUpdater" }, { - "address": "0xaf28a257D292e7f0E531073f70a175b57E0261a8", + "address": "0xaeB6dDB7708467814D557e340283248be8E43124", "category": "omnichain", - "chain_id": "56", - "chain_name": "bsc_mainnet", + "chain_id": "1", + "chain_name": "eth_mainnet", "type": "tssUpdater" }, { diff --git a/data/addresses.testnet.json b/data/addresses.testnet.json index 0105c7f9..6fc61bce 100644 --- a/data/addresses.testnet.json +++ b/data/addresses.testnet.json @@ -57,39 +57,21 @@ "category": "omnichain", "chain_id": 7001, "chain_name": "zeta_testnet", - "coin_type": "ZRC20", + "type": "ZRC20", + "coin_type": "ERC20", "decimals": 18, "symbol": "USDC-goerli_testnet" }, - { - "address": "", - "category": "omnichain", - "chain_id": "5", - "chain_name": "goerli_testnet", - "coin_type": "Gas", - "decimals": 18, - "symbol": "gETH", - "zrc20": "0x13A0c5930C028511Dc02665E7285134B6d11A5f4" - }, { "address": "0x13A0c5930C028511Dc02665E7285134B6d11A5f4", "asset": "", "category": "omnichain", "chain_id": 7001, "chain_name": "zeta_testnet", - "coin_type": "ZRC20", - "decimals": 18, - "symbol": "ETH-goerli_testnet" - }, - { - "address": "", - "category": "omnichain", - "chain_id": "80001", - "chain_name": "mumbai_testnet", + "type": "ZRC20", "coin_type": "Gas", "decimals": 18, - "symbol": "tMATIC", - "zrc20": "0x48f80608B672DC30DC7e3dbBd0343c5F02C738Eb" + "symbol": "ETH-goerli_testnet" }, { "address": "0x48f80608B672DC30DC7e3dbBd0343c5F02C738Eb", @@ -97,27 +79,19 @@ "category": "omnichain", "chain_id": 7001, "chain_name": "zeta_testnet", - "coin_type": "ZRC20", + "type": "ZRC20", + "coin_type": "Gas", "decimals": 18, "symbol": "MATIC-mumbai_testnet" }, - { - "address": "", - "category": "omnichain", - "chain_id": "18332", - "chain_name": "btc_testnet", - "coin_type": "Gas", - "decimals": 8, - "symbol": "tBTC", - "zrc20": "0x65a45c57636f9BcCeD4fe193A602008578BcA90b" - }, { "address": "0x65a45c57636f9BcCeD4fe193A602008578BcA90b", "asset": "", "category": "omnichain", "chain_id": 7001, "chain_name": "zeta_testnet", - "coin_type": "ZRC20", + "type": "ZRC20", + "coin_type": "Gas", "decimals": 18, "symbol": "BTC-btc_testnet-btc_testnet" }, @@ -137,7 +111,8 @@ "category": "omnichain", "chain_id": 7001, "chain_name": "zeta_testnet", - "coin_type": "ZRC20", + "type": "ZRC20", + "coin_type": "ERC20", "decimals": 18, "symbol": "USDC-bsc_testnet" }, @@ -157,27 +132,19 @@ "category": "omnichain", "chain_id": 7001, "chain_name": "zeta_testnet", - "coin_type": "ZRC20", + "type": "ZRC20", + "coin_type": "ERC20", "decimals": 18, "symbol": "USDC-mumbai_testnet" }, - { - "address": "", - "category": "omnichain", - "chain_id": "97", - "chain_name": "bsc_testnet", - "coin_type": "Gas", - "decimals": 18, - "symbol": "tBNB", - "zrc20": "0xd97B1de3619ed2c6BEb3860147E30cA8A7dC9891" - }, { "address": "0xd97B1de3619ed2c6BEb3860147E30cA8A7dC9891", "asset": "", "category": "omnichain", "chain_id": 7001, "chain_name": "zeta_testnet", - "coin_type": "ZRC20", + "type": "ZRC20", + "coin_type": "Gas", "decimals": 18, "symbol": "BNB-bsc_testnet" }, @@ -210,45 +177,45 @@ "type": "fungibleModule" }, { - "address": "0x0000c304d2934c00db1d51995b9f6996affd17c0", + "address": "0x0000c9ec4042283e8139c74f4c64bcd1e0b9b54f", "category": "messaging", - "chain_id": "5", - "chain_name": "goerli_testnet", + "chain_id": "80001", + "chain_name": "mumbai_testnet", "type": "zetaToken" }, { - "address": "0x00005e3125aba53c5652f9f0ce1a4cf91d8b15ea", + "address": "0x0000ecb8cdd25a18f12daa23f6422e07fbf8b9e1", "category": "messaging", - "chain_id": "5", - "chain_name": "goerli_testnet", + "chain_id": "80001", + "chain_name": "mumbai_testnet", "type": "connector" }, { - "address": "0x000047f11c6e42293f433c82473532e869ce4ec5", + "address": "0x0000a7db254145767262c6a81a7ee1650684258e", "category": "omnichain", - "chain_id": "5", - "chain_name": "goerli_testnet", + "chain_id": "80001", + "chain_name": "mumbai_testnet", "type": "erc20Custody" }, { - "address": "0x0000c9ec4042283e8139c74f4c64bcd1e0b9b54f", + "address": "0x0000c304d2934c00db1d51995b9f6996affd17c0", "category": "messaging", - "chain_id": "80001", - "chain_name": "mumbai_testnet", + "chain_id": "5", + "chain_name": "goerli_testnet", "type": "zetaToken" }, { - "address": "0x0000ecb8cdd25a18f12daa23f6422e07fbf8b9e1", + "address": "0x00005e3125aba53c5652f9f0ce1a4cf91d8b15ea", "category": "messaging", - "chain_id": "80001", - "chain_name": "mumbai_testnet", + "chain_id": "5", + "chain_name": "goerli_testnet", "type": "connector" }, { - "address": "0x0000a7db254145767262c6a81a7ee1650684258e", + "address": "0x000047f11c6e42293f433c82473532e869ce4ec5", "category": "omnichain", - "chain_id": "80001", - "chain_name": "mumbai_testnet", + "chain_id": "5", + "chain_name": "goerli_testnet", "type": "erc20Custody" }, { diff --git a/tasks/addresses.ts b/tasks/addresses.ts index f93a9edd..9580d01f 100644 --- a/tasks/addresses.ts +++ b/tasks/addresses.ts @@ -96,23 +96,26 @@ const fetchForeignCoinsData = async (chains: any, addresses: any, network: Netwo const foreignCoinsResponse: AxiosResponse = await axios.get(URL); if (foreignCoinsResponse.status === 200) { foreignCoinsResponse.data.foreignCoins.forEach((token: any) => { - addresses.push({ - address: token.asset, - category: "omnichain", - chain_id: token.foreign_chain_id, - chain_name: chains.find((c: any) => c.chain_id === token.foreign_chain_id)?.chain_name, - coin_type: token.coin_type, - decimals: token.decimals, - symbol: token.symbol, - zrc20: token.zrc20_contract_address, // TODO: dynamically fetch from contract (to verify) - }); + if (token.coin_type !== "Gas") { + addresses.push({ + address: token.asset, + category: "omnichain", + chain_id: token.foreign_chain_id, + chain_name: chains.find((c: any) => c.chain_id === token.foreign_chain_id)?.chain_name, + coin_type: token.coin_type, + decimals: token.decimals, + symbol: token.symbol, + zrc20: token.zrc20_contract_address, // TODO: dynamically fetch from contract (to verify) + }); + } addresses.push({ address: token.zrc20_contract_address, asset: token.asset, category: "omnichain", chain_id, chain_name: "zeta_testnet", - coin_type: "ZRC20", + type: "ZRC20", + coin_type: token.coin_type, decimals: 18, symbol: token.name, // TODO: dynamically fetch from contract });