---
updatedAt: 2025-09-18T22:38:55.000Z
agentTools:
  projectIndex: https://docs.nodereal.io/llms.txt
---

# net_peerCountByType

Returns the number of connected nodes by type and the total number of connected nodes with key/value pairs.

**NOTE**: This API is effective after Klaytn v1.8.0

> 📘 Supported on Klaytn (mainnet) only.

## Parameters

**Request**

None

**Result**

| Type        | Description                                                                           |
| ----------- | ------------------------------------------------------------------------------------- |
| JSON string | The number of connected peers by type as well as the total number of connected peers. |

## API Endpoint

The format of a Klaytn API endpoint is\
`https://open-platform.nodereal.io/{{apiKey}}/klaytn/`

Here is an example:\
`https://open-platform.nodereal.io/4c0a1c23661a4e26bcbcwed461e34ea9/klaytn/`

## Example

```shell
// Request
curl https://open-platform.nodereal.io/{{apiKey}}/klaytn/ \
  -X POST \
  -H "Content-Type: application/json" \
  --data '{"jsonrpc":"2.0","method":"net_peerCountByType","params":[],"id":74}' 

// Result
{
    "id":74,
    "jsonrpc": "2.0",
    "result": {"en":3,"pn":2,"total":5}
}
```