---
title: "Ethereum RPC क्विकस्टार्ट"
description: "API key प्राप्त करें, HTTP पर अपना पहला Ethereum JSON-RPC request भेजें, और ERPC के साथ WebSocket पर events के लिए subscribe करें।"
canonical: "https://erpc.global/hi/doc/ethereum-rpc/quickstart/"
locale: "hi"
---

# Ethereum RPC क्विकस्टार्ट

## Ethereum RPC क्विकस्टार्ट

यह गाइड आपको ERPC के साथ शून्य से आपकी पहली Ethereum JSON-RPC प्रतिक्रिया तक ले जाता है।

### 1. अपनी API key प्राप्त करें

आप अपनी API key ERPC Web Dashboard पर प्राप्त और verify कर सकते हैं: [ERPC Web Dashboard](https://dashboard.erpc.global/hi)

क्या आप पहले से Solana के लिए ERPC इस्तेमाल कर रहे हैं? आप वही RPC key इस्तेमाल कर सकते हैं जो Solana के लिए इस्तेमाल होती है।

### 2. अपना पहला Request भेजें

अपनी API key `api-key` parameter में देकर, JSON-RPC 2.0 request को HTTP POST के रूप में भेजें:

```bash
curl https://edge.erpc.global/eth?api-key=<YOUR_API_KEY> --header 'Content-Type: application/json' --data '{
  "jsonrpc":"2.0","id":1,
  "method":"eth_blockNumber"
}'
```

Response में नवीनतम block number hexadecimal में मिलता है:

```json
{ "jsonrpc": "2.0", "id": 1, "result": "0x..." }
```

आप `eth_chainId` से यह जांच सकते हैं कि endpoint किस chain को serve करता है:

```bash
curl https://edge.erpc.global/eth?api-key=<YOUR_API_KEY> --header 'Content-Type: application/json' --data '{
  "jsonrpc":"2.0","id":1,
  "method":"eth_chainId"
}'
```

### 3. WebSocket पर Subscribe करें

WebSocket endpoint मानक `eth_subscribe` subscriptions स्वीकार करता है:

```bash
wscat -c "wss://edge.erpc.global/eth?api-key=<YOUR_API_KEY>"
# After connected, send:
{"jsonrpc":"2.0","id":1,"method":"eth_subscribe","params":["newHeads"]}
```

उपलब्ध subscription types के लिए, नीचे लिंक की गई आधिकारिक Ethereum JSON-RPC documentation देखें।

### 4. Batch में कई calls भेजें

आप एक ही HTTP request में 256 तक JSON-RPC calls भेज सकते हैं। batch में हर call को अपने खुद के call के रूप में मीटर किया जाता है।

```bash
curl https://edge.erpc.global/eth?api-key=<YOUR_API_KEY> --header 'Content-Type: application/json' --data '[
  {"jsonrpc":"2.0","id":1,"method":"eth_blockNumber"},
  {"jsonrpc":"2.0","id":2,"method":"eth_gasPrice"}
]'
```

### अगले चरण

- Endpoints, मीटरिंग और status codes: [Ethereum RPC Endpoint दस्तावेज़](https://erpc.global/hi/doc/ethereum-rpc/general/)
- Request और response shapes के साथ पूरी method सूची: [Ethereum RPC API संदर्भ](https://erpc.global/hi/api-doc/ethereum/)
- आधिकारिक Ethereum JSON-RPC documentation: [https://ethereum.org/en/developers/docs/apis/json-rpc/](https://ethereum.org/en/developers/docs/apis/json-rpc/)
