Developer Hub
Build on MAGNE L1 and M Hash L2. Get network configuration, developer tools, and documentation.
Network Configuration
Current configuration parameters for MAGNE L1 and M Hash L2 testnets
MAGNE L1 Testnet
Testnet Live| Chain ID | 20250810 |
| Token | MHA |
| RPC | https://rpc.testnet.magicalhash.com |
| Explorer | explorer.testnet.magicalhash.com |
M Hash L2 Testnet
Testnet Live| Chain ID | 20250827 |
| Token | MHA |
| RPC | https://l2-rpc.testnet.magicalhash.com |
| Explorer | l2-explorer.testnet.magicalhash.com |
Quick Start
Four steps to start building on MAGNE
Add Network to Wallet
Add MAGNE L1 or M Hash L2 testnet to MetaMask or your preferred Web3 wallet using the network configuration above.
Chain ID: 20250810 (L1) / 20250827 (L2)
Get Testnet MHA
Visit the faucet to get testnet MHA tokens for development and testing.
Faucet in dev — contact @MagneAI
Deploy Contracts
Deploy smart contracts to the testnet using Hardhat, Foundry, or your preferred development framework.
npx hardhat run scripts/deploy.js --network magne-l1
Build DApp
Connect your DApp to the MAGNE network using ethers.js, web3.js, or viem.
ethers.JsonRpcProvider('https://rpc.testnet.magicalhash.com')
Developer Tools
Tools and services needed for building on the MAGNE network
Code Examples
Common integration examples
ethers.js Connection
const { ethers } = require('ethers');
const provider = new ethers.JsonRpcProvider(
'https://rpc.testnet.magicalhash.com'
);
const wallet = new ethers.Wallet(
process.env.TESTNET_PRIVATE_KEY,
provider
);
const balance = await provider.getBalance(wallet.address);
console.log('Balance:', ethers.formatEther(balance), 'MHA');
// Security: use a dedicated test wallet.
// Never expose private keys in frontend code or public repos.
Hardhat Configuration
// hardhat.config.js
module.exports = {
networks: {
'magne-l1': {
url: 'https://rpc.testnet.magicalhash.com',
chainId: 20250810,
},
'magne-l2': {
url: 'https://l2-rpc.testnet.magicalhash.com',
chainId: 20250827,
},
},
};
Agent Pay Integration Reference
Understand the target integration architecture for MAGNE Agent Pay, testnet environment, currently disclosed evidence, and development boundaries.