net_peerCount - Manta RPC Method
Get number of connected peers on Manta Pacific.
Returns number of peers currently connected to Manta Pacific client.
Request Parameters
This method accepts no parameters.
Response Body
Number of connected peers (hexadecimal)
Code Examples
curl -X POST https://api-manta-pacific-archive.n.dwellir.com/YOUR_API_KEY \
-H "Content-Type: application/json" \
-d '{
"jsonrpc": "2.0",
"method": "net_peerCount",
"params": [],
"id": 1
}'import { JsonRpcProvider } from 'ethers';
const provider = new JsonRpcProvider('https://api-manta-pacific-archive.n.dwellir.com/YOUR_API_KEY');
const peerCount = await provider.send('net_peerCount', []);
console.log('Peer count:', parseInt(peerCount, 16));Related Methods
net_listening- Check if listening