|
1 | | -import { Chain, defineChain } from 'viem' |
2 | | - |
3 | | -export const SAPPHIRE_CHAIN_CONFIG = defineChain({ |
4 | | - id: 23294, |
5 | | - name: 'Oasis Sapphire', |
6 | | - network: 'sapphire', |
7 | | - nativeCurrency: { name: 'Sapphire Rose', symbol: 'ROSE', decimals: 18 }, |
8 | | - rpcUrls: { |
9 | | - default: { |
10 | | - http: ['https://sapphire.oasis.io'], |
11 | | - webSocket: ['wss://sapphire.oasis.io/ws'], |
12 | | - }, |
13 | | - }, |
14 | | - blockExplorers: { |
15 | | - default: { |
16 | | - name: 'Oasis Explorer', |
17 | | - url: 'https://explorer.oasis.io/mainnet/sapphire', |
18 | | - }, |
19 | | - }, |
20 | | - contracts: { |
21 | | - multicall3: { |
22 | | - address: '0xcA11bde05977b3631167028862bE2a173976CA11', |
23 | | - blockCreated: 734531, |
24 | | - }, |
25 | | - }, |
26 | | -}) |
27 | | - |
28 | | -export const SAPPHIRE_1RPC_CHAIN_CONFIG = defineChain({ |
29 | | - id: 23294, |
30 | | - name: 'Oasis Sapphire', |
31 | | - network: 'sapphire', |
32 | | - nativeCurrency: { name: 'Sapphire Rose', symbol: 'ROSE', decimals: 18 }, |
33 | | - rpcUrls: { |
34 | | - default: { |
35 | | - http: ['https://1rpc.io/oasis/sapphire'], |
36 | | - }, |
37 | | - }, |
38 | | - blockExplorers: { |
39 | | - default: { |
40 | | - name: 'Oasis Explorer', |
41 | | - url: 'https://explorer.oasis.io/mainnet/sapphire', |
42 | | - }, |
43 | | - }, |
44 | | - contracts: { |
45 | | - multicall3: { |
46 | | - address: '0xcA11bde05977b3631167028862bE2a173976CA11', |
47 | | - blockCreated: 734531, |
48 | | - }, |
49 | | - }, |
50 | | -}) |
51 | | - |
52 | | -export const SAPPHIRE_TESTNET_CHAIN_CONFIG = defineChain({ |
53 | | - id: 23295, |
54 | | - name: 'Oasis Sapphire Testnet', |
55 | | - network: 'sapphire-testnet', |
56 | | - nativeCurrency: { name: 'Sapphire Test Rose', symbol: 'TEST', decimals: 18 }, |
57 | | - rpcUrls: { |
58 | | - default: { |
59 | | - http: ['https://testnet.sapphire.oasis.dev'], |
60 | | - webSocket: ['wss://testnet.sapphire.oasis.dev/ws'], |
61 | | - }, |
62 | | - }, |
63 | | - blockExplorers: { |
64 | | - default: { |
65 | | - name: 'Oasis Explorer', |
66 | | - url: 'https://explorer.oasis.io/testnet/sapphire', |
67 | | - }, |
68 | | - }, |
69 | | - testnet: true, |
70 | | -}) |
| 1 | +import { Chain } from 'viem' |
| 2 | +import { sapphire, sapphireTestnet } from 'viem/chains' |
71 | 3 |
|
72 | 4 | export const SUPPORTED_CHAIN_IDS: Record<number, Chain> = { |
73 | | - [23294]: SAPPHIRE_1RPC_CHAIN_CONFIG, |
74 | | - [23295]: SAPPHIRE_TESTNET_CHAIN_CONFIG, |
| 5 | + [23294]: sapphire, |
| 6 | + [23295]: sapphireTestnet, |
75 | 7 | } |
76 | 8 |
|
77 | 9 | export const NEXUS_BASE_URL_CONFIG: Map<number, string> = new Map([ |
|
0 commit comments