diff --git a/.changeset/shiny-weeks-marry.md b/.changeset/shiny-weeks-marry.md new file mode 100644 index 00000000..8d0d7a85 --- /dev/null +++ b/.changeset/shiny-weeks-marry.md @@ -0,0 +1,5 @@ +--- +'@wagmi/chains': patch +--- + +Added Moonbeam, Moonriver, & Moonbase Alpha chains. diff --git a/packages/chains/README.md b/packages/chains/README.md index ed878d98..0bddb4df 100644 --- a/packages/chains/README.md +++ b/packages/chains/README.md @@ -52,6 +52,9 @@ const { chains, provider } = configureChains( - `mainnet` - `metis` - `metisGoerli` +- `moonbaseAlpha` +- `moonbeam` +- `moonriver` - `okc` - `optimism` - `optimismGoerli` diff --git a/packages/chains/src/index.ts b/packages/chains/src/index.ts index 006b5ea5..d97671ce 100644 --- a/packages/chains/src/index.ts +++ b/packages/chains/src/index.ts @@ -32,6 +32,9 @@ export { localhost } from './localhost' export { mainnet } from './mainnet' export { metis } from './metis' export { metisGoerli } from './metisGoerli' +export { moonbaseAlpha } from './moonbaseAlpha' +export { moonbeam } from './moonbeam' +export { moonriver } from './moonriver' export { okc } from './okc' export { optimism } from './optimism' export { optimismGoerli } from './optimismGoerli' diff --git a/packages/chains/src/moonbaseAlpha.ts b/packages/chains/src/moonbaseAlpha.ts new file mode 100644 index 00000000..235236cb --- /dev/null +++ b/packages/chains/src/moonbaseAlpha.ts @@ -0,0 +1,39 @@ +import { Chain } from './types' + +export const moonbaseAlpha = { + id: 1287, + name: 'Moonbase Alpha', + network: 'moonbase-alpha', + nativeCurrency: { + decimals: 18, + name: 'DEV', + symbol: 'DEV', + }, + rpcUrls: { + default: { + http: ['https://rpc.api.moonbase.moonbeam.network'], + webSocket: ['wss://wss.api.moonbase.moonbeam.network'], + }, + public: { + http: ['https://rpc.api.moonbase.moonbeam.network'], + webSocket: ['wss://wss.api.moonbase.moonbeam.network'], + }, + }, + blockExplorers: { + default: { + name: 'Moonscan', + url: 'https://moonbase.moonscan.io', + }, + etherscan: { + name: 'Moonscan', + url: 'https://moonbase.moonscan.io', + }, + }, + contracts: { + multicall3: { + address: '0xcA11bde05977b3631167028862bE2a173976CA11', + blockCreated: 1850686, + }, + }, + testnet: true, +} as const satisfies Chain diff --git a/packages/chains/src/moonbeam.ts b/packages/chains/src/moonbeam.ts new file mode 100644 index 00000000..8c53588d --- /dev/null +++ b/packages/chains/src/moonbeam.ts @@ -0,0 +1,39 @@ +import { Chain } from './types' + +export const moonbeam = { + id: 1284, + name: 'Moonbeam', + network: 'moonbeam', + nativeCurrency: { + decimals: 18, + name: 'GLMR', + symbol: 'GLMR', + }, + rpcUrls: { + public: { + http: ['https://moonbeam.public.blastapi.io'], + webSocket: ['wss://moonbeam.public.blastapi.io'], + }, + default: { + http: ['https://moonbeam.public.blastapi.io'], + webSocket: ['wss://moonbeam.public.blastapi.io'], + }, + }, + blockExplorers: { + default: { + name: 'Moonscan', + url: 'https://moonscan.io', + }, + etherscan: { + name: 'Moonscan', + url: 'https://moonscan.io', + }, + }, + contracts: { + multicall3: { + address: '0xcA11bde05977b3631167028862bE2a173976CA11', + blockCreated: 609002, + }, + }, + testnet: false, +} as const satisfies Chain diff --git a/packages/chains/src/moonriver.ts b/packages/chains/src/moonriver.ts new file mode 100644 index 00000000..0a7aebad --- /dev/null +++ b/packages/chains/src/moonriver.ts @@ -0,0 +1,39 @@ +import { Chain } from './types' + +export const moonriver = { + id: 1285, + name: 'Moonriver', + network: 'moonriver', + nativeCurrency: { + decimals: 18, + name: 'MOVR', + symbol: 'MOVR', + }, + rpcUrls: { + public: { + http: ['https://moonriver.public.blastapi.io'], + webSocket: ['wss://moonriver.public.blastapi.io'], + }, + default: { + http: ['https://moonriver.public.blastapi.io'], + webSocket: ['wss://moonriver.public.blastapi.io'], + }, + }, + blockExplorers: { + default: { + name: 'Moonscan', + url: 'https://moonriver.moonscan.io', + }, + etherscan: { + name: 'Moonscan', + url: 'https://moonriver.moonscan.io', + }, + }, + contracts: { + multicall3: { + address: '0xcA11bde05977b3631167028862bE2a173976CA11', + blockCreated: 1597904, + }, + }, + testnet: false, +} as const satisfies Chain