NueForm

Webhooks Overview

जानें कि NueForm webhooks form responses submit होने पर real-time notifications कैसे deliver करते हैं, जिसमें per-form और global webhook configuration शामिल है।

Webhooks आपके application को NueForm में कुछ होने पर real-time HTTP notifications receive करने देते हैं। नए responses के लिए API poll करने की बजाय, NueForm form submit होने के moment data आपके server पर push करता है।

Webhooks Pro plan ($29/mo) और उससे ऊपर पर उपलब्ध हैं। Entrepreneur (free) plan users को webhooks उपयोग करने के लिए upgrade करना होगा।

Webhooks कैसे काम करते हैं

जब respondent form submit करता है, NueForm तुरंत आपके configured प्रत्येक webhook URL पर HTTP POST request भेजता है। Request body में event type, form details, और submitted answers के साथ signed JSON payload होता है।

Flow इस प्रकार है:

  1. Respondent आपका form complete और submit करता है।
  2. NueForm answers validate करता है और response store करता है।
  3. NueForm event data युक्त JSON payload construct करता है।
  4. NueForm HMAC-SHA256 उपयोग करके आपके webhook secret से payload sign करता है।
  5. NueForm payload को POST request के रूप में प्रत्येक configured URL पर भेजता है।
  6. आपका server request receive करता है, signature verify करता है, और data process करता है।

Webhook delivery fire-and-forget और non-blocking है। Webhook failures कभी submission flow को affect नहीं करते --- respondents हमेशा successful submission देखते हैं चाहे आपका webhook endpoint reachable हो या नहीं।

Per-Form बनाम Global Webhooks

NueForm दो प्रकार के webhook configuration support करता है:

Per-Form Webhooks

प्रत्येक form का अपना dedicated webhook URL हो सकता है। यह तब उपयोगी है जब आप चाहते हैं कि different forms different systems को notify करें --- उदाहरण के लिए, support form submissions को अपने helpdesk पर और feedback form submissions को अपनी analytics pipeline पर भेजना।

आप per-form webhook URL इनके माध्यम से set कर सकते हैं:

  • NueForm Dashboard --- अपने form की settings खोलें और webhook URL enter करें।
  • API --- URL programmatically set या update करने के लिए Webhooks API उपयोग करें।
bash
curl -X PUT https://app.nueform.com/api/v1/webhooks/form/FORM_ID \
  -H "Authorization: Bearer nf_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{ "url": "https://your-server.com/webhooks/nueform" }'

Global Webhooks

Global webhooks आपके account में हर form के लिए fire होते हैं। ये centralized logging, analytics, या CRM integrations के लिए उपयोगी हैं जिन्हें सभी submissions process करनी होती हैं चाहे वे किसी भी form से आएं।

आप 5 global webhooks तक configure कर सकते हैं, और प्रत्येक को individually enable या disable किया जा सकता है।

bash
curl -X PUT https://app.nueform.com/api/v1/webhooks/global \
  -H "Authorization: Bearer nf_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "webhooks": [
      { "url": "https://analytics.example.com/nueform", "enabled": true },
      { "url": "https://crm.example.com/inbound", "enabled": true },
      { "url": "https://staging.example.com/test", "enabled": false }
    ]
  }'

Delivery Order

जब form submit होता है, NueForm सभी applicable URLs को parallel में webhooks dispatch करता है:

  1. Form का per-form webhook URL (यदि set है)।
  2. सभी enabled global webhook URLs।

प्रत्येक target को same payload same signature के साथ receive होता है।

Webhooks कब Fire होते हैं

वर्तमान में, webhooks single event पर fire होते हैं:

EventTrigger
form.submittedRespondent complete response submit करता है

Incremental submission enabled forms के लिए, webhook केवल तब fire होता है जब response complete के रूप में mark होता है --- partial saves webhooks trigger नहीं करते।

Full event reference और planned future events के लिए Events देखें।

Webhook Security

प्रत्येक webhook request में X-NueForm-Signature header शामिल होता है जिसमें request body का HMAC-SHA256 hex digest होता है। Webhook data process करने से पहले आपको हमेशा इस signature को verify करना चाहिए ताकि सुनिश्चित हो कि request वास्तव में NueForm से आई है।

आपका webhook secret पहली बार access करने पर स्वचालित रूप से generate होता है और API या dashboard के माध्यम से किसी भी समय regenerate किया जा सकता है।

Implementation details और code samples के लिए Verification देखें।

Delivery Characteristics

PropertyValue
HTTP methodPOST
Content typeapplication/json
Timeout5 seconds
Retry policyकोई automatic retries नहीं (fire-and-forget)
Signature headerX-NueForm-Signature
Signing algorithmHMAC-SHA256 (hex digest)

NueForm वर्तमान में 5-second timeout और कोई automatic retries के साथ fire-and-forget delivery model उपयोग करता है। यदि आपका endpoint unreachable है या error return करता है, webhook delivery silently drop हो जाती है। अपने integration को occasional missed deliveries handle करने के लिए design करें --- उदाहरण के लिए, Responses API के माध्यम से periodically reconcile करके।

Quick Start

Webhooks receive करना शुरू करने के लिए:

  1. अपना webhook secret प्राप्त करें --- GET /api/v1/webhooks/secret call करें या अपने dashboard में Developer settings में खोजें। यदि आपके पास अभी तक secret नहीं है तो NueForm auto-generate करता है।
  2. Webhook URL set करें --- Per-form URL configure करें या global webhook add करें।
  3. अपना endpoint implement करें --- एक HTTP endpoint build करें जो POST requests accept करे, signature verify करे, और payload process करे।
  4. Test करें --- Production में जाने से पहले delivery verify करने के लिए webhook.site या ngrok जैसे tool उपयोग करें। Detailed instructions के लिए Testing Webhooks देखें।

Next Steps

  • Events --- Webhook event types के बारे में जानें
  • Payloads --- पूर्ण payload schema और examples देखें
  • Verification --- HMAC-SHA256 signature verification implement करें
  • Testing --- Local development के दौरान webhooks test करें
अंतिम अपडेट: 6 अप्रैल 2026