> ## Documentation Index
> Fetch the complete documentation index at: https://docs.wappfy.io/llms.txt
> Use this file to discover all available pages before exploring further.

# त्वरित शुरुआत

> 5 मिनट से कम समय में अपना पहला WhatsApp message भेजें।

# त्वरित शुरुआत

यह guide आपको एक instance बनाने, उसे connect करने, और अपना पहला message भेजने की प्रक्रिया बताती है।

## आवश्यकताएं

* एक Wappfy account ([sign up करें](https://app.wappfy.io/register))
* Connect करने के लिए एक WhatsApp number
* एक API key या Supabase JWT token

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

```bash theme={null}
curl -X POST https://api.wappfy.io/api/api-keys \
  -H "Authorization: Bearer YOUR_SUPABASE_JWT" \
  -H "Content-Type: application/json" \
  -d '{ "name": "My First Key" }'
```

<Warning>
  लौटाए गए `key` value को सुरक्षित रखें — यह केवल एक बार दिखाया जाता है।
</Warning>

## Step 2: एक instance बनाएं

```bash theme={null}
curl -X POST https://api.wappfy.io/api/instances \
  -H "X-Api-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Production WhatsApp",
    "instance_type": "waha"
  }'
```

लौटाए गए `id` को save करें — आप इसे सभी अगले requests में उपयोग करेंगे।

## Step 3: QR code से connect करें

```bash theme={null}
# Connection शुरू करें
curl -X POST https://api.wappfy.io/api/instances/INSTANCE_ID/connect \
  -H "X-Api-Key: YOUR_API_KEY"

# QR code प्राप्त करें
curl https://api.wappfy.io/api/instances/INSTANCE_ID/qr \
  -H "X-Api-Key: YOUR_API_KEY"
```

अपने phone पर WhatsApp खोलें, **Linked Devices** में जाएं, और `qr` field में लौटाए गए QR code (base64 image) को scan करें।

## Step 4: एक message भेजें

जब instance का status `connected` हो जाए, तब आप अपना पहला message भेज सकते हैं:

<CodeGroup>
  ```bash cURL theme={null}
  curl -X POST https://api.wappfy.io/api/instances/INSTANCE_ID/messages/send \
    -H "X-Api-Key: YOUR_API_KEY" \
    -H "Content-Type: application/json" \
    -d '{
      "to": "5511999999999",
      "type": "text",
      "body": "Hello from Wappfy!"
    }'
  ```

  ```javascript Node.js theme={null}
  const response = await fetch(
    `https://api.wappfy.io/api/instances/${instanceId}/messages/send`,
    {
      method: 'POST',
      headers: {
        'X-Api-Key': 'YOUR_API_KEY',
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
        to: '5511999999999',
        type: 'text',
        body: 'Hello from Wappfy!',
      }),
    }
  );
  const data = await response.json();
  console.log(data.data.jobId);
  ```

  ```python Python theme={null}
  import requests

  response = requests.post(
      f"https://api.wappfy.io/api/instances/{instance_id}/messages/send",
      headers={"X-Api-Key": "YOUR_API_KEY"},
      json={
          "to": "5511999999999",
          "type": "text",
          "body": "Hello from Wappfy!",
      },
  )
  print(response.json()["data"]["jobId"])
  ```
</CodeGroup>

## Response

```json theme={null}
{
  "success": true,
  "data": {
    "message": "Message queued for delivery",
    "jobId": "12345"
  },
  "meta": {
    "requestId": "req_abc123",
    "timestamp": "2026-02-10T12:00:00.000Z"
  }
}
```

## अगले कदम

<CardGroup cols={2}>
  <Card title="सभी message types भेजें" icon="paper-plane" href="/hi/guides/sending-messages">
    Images, videos, polls, contacts, और बहुत कुछ
  </Card>

  <Card title="Webhooks सेट अप करें" icon="webhook" href="/hi/guides/webhooks">
    Incoming messages और delivery status प्राप्त करें
  </Card>
</CardGroup>
