From f96f560d1140649337b984dcdc666c185e7a8d33 Mon Sep 17 00:00:00 2001 From: haycarlitos Date: Tue, 22 Aug 2023 08:54:15 -0600 Subject: [PATCH 1/2] added rskMainnet and rskTestnet --- packages/chains/README.md | 2 ++ packages/chains/src/index.ts | 2 ++ packages/chains/src/rskMainnet.ts | 30 ++++++++++++++++++++++++++++++ packages/chains/src/rskTestnet.ts | 30 ++++++++++++++++++++++++++++++ 4 files changed, 64 insertions(+) create mode 100644 packages/chains/src/rskMainnet.ts create mode 100644 packages/chains/src/rskTestnet.ts diff --git a/packages/chains/README.md b/packages/chains/README.md index 23ddd6f4..a58ef93f 100644 --- a/packages/chains/README.md +++ b/packages/chains/README.md @@ -79,6 +79,8 @@ const { chains, provider } = configureChains( - `polygonMumbai` - `pulsechain` - `pulsechainV4` +- `rskMainnet` +- `rskTestnet` - `skaleBlockBrawlers` - `skaleCalypso` - `skaleCalypsoTestnet` diff --git a/packages/chains/src/index.ts b/packages/chains/src/index.ts index 297e07ff..cdd92ee4 100644 --- a/packages/chains/src/index.ts +++ b/packages/chains/src/index.ts @@ -93,6 +93,8 @@ export { qTestnet } from './qTestnet' export { rollux } from './rollux' export { rolluxTestnet } from './rolluxTestnet' export { ronin } from './ronin' +export { rskMainnet } from './rskMainnet' +export { rskTestnet } from './rskTestnet' export { saigon } from './saigon' export { scrollSepolia } from './scrollSepolia' export { scrollTestnet } from './scrollTestnet' diff --git a/packages/chains/src/rskMainnet.ts b/packages/chains/src/rskMainnet.ts new file mode 100644 index 00000000..595750c1 --- /dev/null +++ b/packages/chains/src/rskMainnet.ts @@ -0,0 +1,30 @@ +import { Chain } from './types' + +export const rskMainnet = { + id: 30, + name: 'RSK Mainnet', + network: 'rsk', + nativeCurrency: { + decimals: 18, + name: 'RSK Mainnet', + symbol: 'RBTC', + }, + rpcUrls: { + public: { + http: ['https://public-node.rsk.co'], + }, + default: { + http: ['https://public-node.rsk.co'], + }, + }, + blockExplorers: { + etherscan: { + name: 'RSK Explorer', + url: 'https://explorer.rsk.co', + }, + default: { + name: 'RSK Explorer', + url: 'https://explorer.rsk.co', + }, + }, +} as const satisfies Chain diff --git a/packages/chains/src/rskTestnet.ts b/packages/chains/src/rskTestnet.ts new file mode 100644 index 00000000..874fabbf --- /dev/null +++ b/packages/chains/src/rskTestnet.ts @@ -0,0 +1,30 @@ +import { Chain } from './types' + +export const rskTestnet = { + id: 31, + name: 'RSK Testnet', + network: 'rsktestnet', + nativeCurrency: { + decimals: 18, + name: 'RSK Testnet', + symbol: 'tRBTC', + }, + rpcUrls: { + public: { + http: ['https://public-node.testnet.rsk.co'], + }, + default: { + http: ['https://public-node.testnet.rsk.co'], + }, + }, + blockExplorers: { + etherscan: { + name: 'RSK Testnet Explorer', + url: 'https://explorer.testnet.rsk.co', + }, + default: { + name: 'RSK Testnet Explorer', + url: 'https://explorer.testnet.rsk.co', + }, + }, +} as const satisfies Chain From e4de667fffcf939c54993a5cb1a44328bfb91d59 Mon Sep 17 00:00:00 2001 From: haycarlitos Date: Tue, 22 Aug 2023 09:01:10 -0600 Subject: [PATCH 2/2] added rskMainnet and rskTestnet multicall --- packages/chains/src/rskMainnet.ts | 6 ++++++ packages/chains/src/rskTestnet.ts | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/packages/chains/src/rskMainnet.ts b/packages/chains/src/rskMainnet.ts index 595750c1..6284c615 100644 --- a/packages/chains/src/rskMainnet.ts +++ b/packages/chains/src/rskMainnet.ts @@ -27,4 +27,10 @@ export const rskMainnet = { url: 'https://explorer.rsk.co', }, }, + contracts: { + multicall3: { + address: '0xca11bde05977b3631167028862be2a173976ca11', + blockCreated: 4249540, + }, + }, } as const satisfies Chain diff --git a/packages/chains/src/rskTestnet.ts b/packages/chains/src/rskTestnet.ts index 874fabbf..ca047bb1 100644 --- a/packages/chains/src/rskTestnet.ts +++ b/packages/chains/src/rskTestnet.ts @@ -27,4 +27,10 @@ export const rskTestnet = { url: 'https://explorer.testnet.rsk.co', }, }, + contracts: { + multicall3: { + address: '0xcA11bDe05977B3631167028862BE2A173976cA11', + blockCreated: 2771150, + }, + }, } as const satisfies Chain