> ## Documentation Index
> Fetch the complete documentation index at: https://razorpay-881012b3.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Subscribe to Webhooks

> Subscribe to various webhook events related to QR Codes to receive instant notifications.

<div style={{display:"flex",flexWrap:"wrap",alignItems:"center",gap:"0.35rem 0.9rem",border:"1px solid rgba(128,128,128,0.28)",borderRadius:"0.5rem",padding:"0.45rem 0.75rem",margin:"0 0 1.25rem",fontSize:"0.875rem"}}>
  <span style={{fontWeight:600}}>Available in</span>
  <span>🇮🇳 India</span>
</div>

Follow these steps to subscribe to webhook events:

1. Log in to the Dashboard.
2. Navigate to **Account & Settings** → **Webhooks** to subscribe to any of the events mentioned in the following section.

## Webhook Events and Descriptions

| Webhook Events     | Description                                       |
| ------------------ | ------------------------------------------------- |
| `qr_code.created`  | Triggered when a QR Code is created.              |
| `qr_code.credited` | Triggered when a payment is made using a QR Code. |
| `qr_code.closed`   | Triggered when a QR Code is closed.               |

### Signature Validation

If you need to validate QR Code webhook payloads, please use the following Node.js code:

```javascript Node.js theme={null}
const {validateWebhookSignature} = require('razorpay/dist/utils/razorpay-utils')

webhookBodyNew = JSON.stringify(webhookBody).replace(/\//g, "\\/") 

validateWebhookSignature(webhookBodyNew, webhookSignature, webhookSecret)
```

Know more about [Webhooks](/docs/webhooks) and check the [sample payloads](/docs/webhooks/qr-codes).

### Related Information

* [QR Code States](/docs/payments/qr-codes/states)
* [QR Code APIs](/docs/payments/qr-codes/apis)
