From c6e6c432574a0b7e55c300ab3e470aafdace28b3 Mon Sep 17 00:00:00 2001 From: Richard Moore Date: Wed, 24 Jan 2024 22:39:05 -0500 Subject: [PATCH] Added holesky network and related end-points for supporting providers. --- src.ts/_tests/test-providers-data.ts | 2 +- src.ts/providers/network.ts | 3 +-- src.ts/providers/provider-etherscan.ts | 14 +++++++++----- src.ts/providers/provider-quicknode.ts | 5 +++-- 4 files changed, 14 insertions(+), 10 deletions(-) diff --git a/src.ts/_tests/test-providers-data.ts b/src.ts/_tests/test-providers-data.ts index 1089175f3d..69b227c1a9 100644 --- a/src.ts/_tests/test-providers-data.ts +++ b/src.ts/_tests/test-providers-data.ts @@ -230,7 +230,7 @@ describe("Test Provider Transaction operations", function() { describe("Test Networks", function() { const networks = [ - "mainnet", "goerli", "sepolia", + "mainnet", "goerli", "sepolia", "holesky", "arbitrum", "arbitrum-goerli", "arbitrum-sepolia", "base", "base-goerli", "base-sepolia", "bnb", "bnbt", diff --git a/src.ts/providers/network.ts b/src.ts/providers/network.ts index 0977a1c27b..e37e3f27d7 100644 --- a/src.ts/providers/network.ts +++ b/src.ts/providers/network.ts @@ -388,8 +388,7 @@ function injectCommonNetworks(): void { registerEth("goerli", 5, { ensNetwork: 5 }); registerEth("kovan", 42, { ensNetwork: 42 }); registerEth("sepolia", 11155111, { ensNetwork: 11155111 }); - - + registerEth("holesky", 17000, { ensNetwork: 17000 }); registerEth("classic", 61, { }); registerEth("classicKotti", 6, { }); diff --git a/src.ts/providers/provider-etherscan.ts b/src.ts/providers/provider-etherscan.ts index c6b00dd730..250de7bfd6 100644 --- a/src.ts/providers/provider-etherscan.ts +++ b/src.ts/providers/provider-etherscan.ts @@ -8,8 +8,11 @@ * - Ethereum Mainnet (``mainnet``) * - Goerli Testnet (``goerli``) * - Sepolia Testnet (``sepolia``) + * - Sepolia Testnet (``holesky``) * - Arbitrum (``arbitrum``) * - Arbitrum Goerli Testnet (``arbitrum-goerli``) + * - BNB Smart Chain Mainnet (``bnb``) + * - BNB Smart Chain Testnet (``bnbt``) * - Optimism (``optimism``) * - Optimism Goerli Testnet (``optimism-goerli``) * - Polygon (``matic``) @@ -160,11 +163,17 @@ export class EtherscanProvider extends AbstractProvider { return "https:/\/api-goerli.etherscan.io"; case "sepolia": return "https:/\/api-sepolia.etherscan.io"; + case "holesky": + return "https:/\/api-holesky.etherscan.io"; case "arbitrum": return "https:/\/api.arbiscan.io"; case "arbitrum-goerli": return "https:/\/api-goerli.arbiscan.io"; + case "bnb": + return "http:/\/api.bscscan.com"; + case "bnbt": + return "http:/\/api-testnet.bscscan.com"; case "matic": return "https:/\/api.polygonscan.com"; case "matic-mumbai": @@ -174,11 +183,6 @@ export class EtherscanProvider extends AbstractProvider { case "optimism-goerli": return "https:/\/api-goerli-optimistic.etherscan.io"; - case "bnb": - return "http:/\/api.bscscan.com"; - case "bnbt": - return "http:/\/api-testnet.bscscan.com"; - default: } diff --git a/src.ts/providers/provider-quicknode.ts b/src.ts/providers/provider-quicknode.ts index abc30a6521..71bb83b6e8 100644 --- a/src.ts/providers/provider-quicknode.ts +++ b/src.ts/providers/provider-quicknode.ts @@ -7,6 +7,7 @@ * - Ethereum Mainnet (``mainnet``) * - Goerli Testnet (``goerli``) * - Sepolia Testnet (``sepolia``) + * - Holesky Testnet (``holesky``) * - Arbitrum (``arbitrum``) * - Arbitrum Goerli Testnet (``arbitrum-goerli``) * - Arbitrum Sepolia Testnet (``arbitrum-sepolia``) @@ -47,7 +48,8 @@ function getHost(name: string): string { return "ethers.ethereum-goerli.quiknode.pro"; case "sepolia": return "ethers.ethereum-sepolia.quiknode.pro"; - + case "holesky": + return "ethers.ethereum-holesky.quiknode.pro"; case "arbitrum": return "ethers.arbitrum-mainnet.quiknode.pro"; @@ -89,7 +91,6 @@ function getHost(name: string): string { are EVM compatible and work with ethers http://ethers.matic-amoy.quiknode.pro - http://ethers.ethereum-holesky.quiknode.pro http://ethers.avalanche-mainnet.quiknode.pro http://ethers.avalanche-testnet.quiknode.pro