- static-nodes.json + permissions-nodes.toml: add enodes for 192.168.11.237–238 - deploy-besu-node-lists-to-all.sh / restart-besu-reload-node-lists.sh: tighten Besu deploy/restart flow - CHAIN2138_WALLET_CONFIG_VALIDATION.md, METAMASK_NETWORK_CONFIG_2138.json - Cross-links: CHAIN138 wallet validation, MASTER_INDEX, runbook, meta fixes - NEXT_STEPS_INDEX + TODOS_CONSOLIDATED: 2026-03-28 completable + operator run note Made-with: Cursor
79 lines
2.4 KiB
Markdown
79 lines
2.4 KiB
Markdown
# Chain 2138 – Wallet & SDK Config (Defi Oracle Meta Testnet)
|
||
|
||
**Last Updated:** 2026-03-27
|
||
**Document Version:** 1.0
|
||
**Status:** Active Documentation
|
||
|
||
---
|
||
|
||
**Purpose:** Wallet and SDK settings for **Defi Oracle Meta Testnet** (chain ID **2138**).
|
||
**RPC (public, chainlist):** `https://rpc.public-2138.defi-oracle.io`
|
||
**WS (chainlist):** `wss://rpc.public-2138.defi-oracle.io`
|
||
**Explorer (chainlist):** `https://public-2138.defi-oracle.io`
|
||
**Chain ID:** 2138 (`0x85a`)
|
||
**CAIP-2:** `eip155:2138`
|
||
|
||
Use LAN or staging RPC in place of the public URLs when testing privately.
|
||
|
||
---
|
||
|
||
## 1. MetaMask (custom network)
|
||
|
||
| Field | Value |
|
||
|-------|--------|
|
||
| **Network name** | Defi Oracle Meta Testnet |
|
||
| **RPC URL** | `https://rpc.public-2138.defi-oracle.io` (or your node) |
|
||
| **Chain ID** | `2138` |
|
||
| **Currency symbol** | tETH |
|
||
| **Block explorer** | `https://public-2138.defi-oracle.io` |
|
||
|
||
**JSON** (programmatic add): `docs/04-configuration/metamask/METAMASK_NETWORK_CONFIG_2138.json`.
|
||
|
||
---
|
||
|
||
## 2. ethers.js (v6 example)
|
||
|
||
```javascript
|
||
const chain2138Testnet = {
|
||
chainId: 2138,
|
||
name: "Defi Oracle Meta Testnet",
|
||
nativeCurrency: { name: "testEther", symbol: "tETH", decimals: 18 },
|
||
rpcUrls: {
|
||
default: { http: ["https://rpc.public-2138.defi-oracle.io"] },
|
||
},
|
||
blockExplorers: {
|
||
default: { name: "Quorum Explorer", url: "https://public-2138.defi-oracle.io" },
|
||
},
|
||
};
|
||
|
||
import { JsonRpcProvider } from "ethers";
|
||
const provider = new JsonRpcProvider("https://rpc.public-2138.defi-oracle.io");
|
||
const chainId = await provider.getNetwork().then((n) => Number(n.chainId)); // 2138
|
||
```
|
||
|
||
---
|
||
|
||
## 3. Frontend DApp (Vite)
|
||
|
||
- Enable the chain in Wagmi: `VITE_ENABLE_CHAIN2138=true` or `1`
|
||
- Optional overrides: `VITE_RPC_URL_2138`, `VITE_EXPLORER_URL_2138`
|
||
- Trustless bridge L2 side: `VITE_TRUSTLESS_L2_CHAIN_ID=2138` plus lockbox/token env vars (see `smom-dbis-138/frontend-dapp/.env.example`)
|
||
|
||
---
|
||
|
||
## 4. Quick verification
|
||
|
||
```bash
|
||
curl -s -X POST https://rpc.public-2138.defi-oracle.io -H "Content-Type: application/json" \
|
||
-d '{"jsonrpc":"2.0","method":"eth_chainId","params":[],"id":1}'
|
||
# Expected: result "0x85a"
|
||
```
|
||
|
||
---
|
||
|
||
## 5. References
|
||
|
||
- **Testnet runbook**: `docs/testnet/DEFI_ORACLE_META_TESTNET_2138_RUNBOOK.md`
|
||
- **Mainnet (138) wallet doc**: `docs/04-configuration/CHAIN138_WALLET_CONFIG_VALIDATION.md`
|
||
- **Chain list (this repo)**: `pr-workspace/chains/_data/chains/eip155-2138.json`
|