Integrate DNSRadar with Zapier
Zapier is a workflow automation platform that connects to thousands of apps. By integrating DNSRadar with Zapier, you can automate responses to DNS changes with powerful multi-step workflows called "Zaps".
Architecture Overview
The integration works through webhooks:
- DNSRadar detects a DNS change
- DNSRadar sends webhook to Zapier
- Zapier workflow processes the event
- Zapier triggers downstream actions (notifications, tickets, API calls, etc.)
Setting Up the Integration
Step 1: Create a Zapier Webhook
In your Zapier account:
- Create a new Zap
- Search for and select Webhooks by Zapier as the trigger app
- Choose Catch Hook as the trigger event
- Click Continue
- Copy the Custom Webhook URL (e.g.,
https://hooks.zapier.com/hooks/catch/123456/abcdef/) - Leave the Zapier editor open to test the webhook
Step 2: Create DNSRadar Webhook
Create a webhook in DNSRadar pointing to your Zapier webhook:
curl -X POST https://api.dnsradar.dev/webhooks \
-H "X-API-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
}'const response = await fetch('https://api.dnsradar.dev/webhooks', {
method: 'POST',
headers: {
"X-API-Key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
})
});
const data = await response.json();import requests
response = requests.post(
'https://api.dnsradar.dev/webhooks',
headers={
'X-API-Key': 'YOUR_API_KEY',
'Content-Type': 'application/json'
},
json={
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
}
)require 'net/http'
require 'json'
uri = URI('https://api.dnsradar.dev/webhooks')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Post.new(uri)
request['X-API-Key'] = 'YOUR_API_KEY'
request['Content-Type'] = 'application/json'
request.body = {
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
}.to_json
response = http.request(request)package main
import (
"bytes"
"encoding/json"
"net/http"
)
data := {
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
}
jsonData, _ := json.Marshal(data)
req, _ := http.NewRequest("POST", "https://api.dnsradar.dev/webhooks", bytes.NewBuffer(jsonData))
req.Header.Set("X-API-Key", "YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
response, _ := client.Do(req)<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://api.dnsradar.dev/webhooks');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
$headers = [
'X-API-Key: YOUR_API_KEY',
'Content-Type: application/json'
];
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
$data = json_encode({
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
});
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
$response = curl_exec($ch);
curl_close($ch);import java.net.http.*;
import java.net.URI;
HttpClient client = HttpClient.newHttpClient();
String json = """{
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
}""";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.dnsradar.dev/webhooks"))
.header("X-API-Key", "YOUR_API_KEY")
.header("Content-Type", "application/json")
.method("POST", HttpRequest.BodyPublishers.ofString(json))
.build();
HttpResponse<String> response = client.send(request,
HttpResponse.BodyHandlers.ofString());using System.Net.Http;
using System.Text;
using System.Text.Json;
var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "YOUR_API_KEY");
var data = new
{
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
};
var json = JsonSerializer.Serialize(data);
var content = new StringContent(json, Encoding.UTF8, "application/json");
var response = await client.PostAsync(
"https://api.dnsradar.dev/webhooks",
content
);DNSRadar will use the secret to sign each request with HMAC SHA256, sending the signature in the X-DNSRadar-Signature header along with a X-Webhook-Timestamp header to prevent replay attacks.
Step 3: Test the Integration
Test your webhook to send a sample payload to Zapier:
curl -X POST https://api.dnsradar.dev/webhooks/wh_abc123/test \
-H "X-API-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{}'const response = await fetch('https://api.dnsradar.dev/webhooks/wh_abc123/test', {
method: 'POST',
headers: {
"X-API-Key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({})
});
const data = await response.json();import requests
response = requests.post(
'https://api.dnsradar.dev/webhooks/wh_abc123/test',
headers={
'X-API-Key': 'YOUR_API_KEY',
'Content-Type': 'application/json'
},
json={}
)require 'net/http'
require 'json'
uri = URI('https://api.dnsradar.dev/webhooks/wh_abc123/test')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Post.new(uri)
request['X-API-Key'] = 'YOUR_API_KEY'
request['Content-Type'] = 'application/json'
request.body = {}.to_json
response = http.request(request)package main
import (
"bytes"
"encoding/json"
"net/http"
)
data := {}
jsonData, _ := json.Marshal(data)
req, _ := http.NewRequest("POST", "https://api.dnsradar.dev/webhooks/wh_abc123/test", bytes.NewBuffer(jsonData))
req.Header.Set("X-API-Key", "YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
response, _ := client.Do(req)<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://api.dnsradar.dev/webhooks/wh_abc123/test');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
$headers = [
'X-API-Key: YOUR_API_KEY',
'Content-Type: application/json'
];
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
$data = json_encode({});
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
$response = curl_exec($ch);
curl_close($ch);import java.net.http.*;
import java.net.URI;
HttpClient client = HttpClient.newHttpClient();
String json = """{}""";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.dnsradar.dev/webhooks/wh_abc123/test"))
.header("X-API-Key", "YOUR_API_KEY")
.header("Content-Type", "application/json")
.method("POST", HttpRequest.BodyPublishers.ofString(json))
.build();
HttpResponse<String> response = client.send(request,
HttpResponse.BodyHandlers.ofString());using System.Net.Http;
using System.Text;
using System.Text.Json;
var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "YOUR_API_KEY");
var data = new
{};
var json = JsonSerializer.Serialize(data);
var content = new StringContent(json, Encoding.UTF8, "application/json");
var response = await client.PostAsync(
"https://api.dnsradar.dev/webhooks/wh_abc123/test",
content
);Return to Zapier and click Test trigger to see if the webhook was received. You should see the sample data appear in Zapier.
Understanding the Webhook Payload
DNSRadar sends this payload to Zapier:
{
"uuid": "req_abc123...",
"webhook_uuid": "wh_abc123...",
"created": "2026-01-08T10:35:22Z",
"event": {
"event_uuid": "evt_xyz789",
"monitor_uuid": "mon_abc123",
"domain": "piedpiper.com",
"subdomain": "www",
"record_type": "A",
"expected_value": ["1.2.3.4"],
"previous_value": ["1.2.3.4"],
"current_value": ["5.6.7.8"],
"old_state": "VALID",
"new_state": "MISMATCH",
"occurred": "2026-01-08T10:35:22Z",
"incidence_count": 1
}
}
Payload Structure
| Field | Description |
|---|---|
uuid | Unique webhook request identifier |
webhook_uuid | The webhook that sent this request |
created | When the webhook request was created (ISO 8601) |
event | The DNS change event details (nested object) |
Event Object Fields
All DNS change data is nested within the event object:
| Field | Description |
|---|---|
event_uuid | Unique event identifier |
monitor_uuid | Monitor that detected the change |
domain | Domain name (e.g., "piedpiper.com") |
subdomain | Subdomain (e.g., "www") |
record_type | DNS record type (A, AAAA, CNAME, MX, TXT, SPF, DMARC) |
expected_value | Expected DNS values (array) |
previous_value | Previous DNS values (array) |
current_value | Current DNS values (array) |
old_state | Previous monitor state |
new_state | Current monitor state |
occurred | When the DNS change occurred (ISO 8601) |
incidence_count | Total incident count for this monitor |
Access these values in Zapier using the field picker. For nested event fields, use Event prefix in Zapier (e.g., Event Domain, Event New State).
Example Zaps
1. Slack Notification
Goal: Send Slack message when DNS changes
Zap Setup:
- Trigger: Webhooks by Zapier - Catch Hook
- Action: Slack - Send Channel Message
Slack message configuration:
- Channel: #dns-alerts
- Message Text:
DNS Alert: {{event__domain}}.{{event__subdomain}}
Record Type: {{event__record_type}}
Expected: {{event__expected_value}}
Current: {{event__current_value}}
State: {{event__new_state}}
Time: {{event__occurred}}
Event ID: {{event__event_uuid}}
Request ID: {{uuid}}
Optional: Add a Filter step between trigger and action:
- Field: Event New State
- Condition: Exactly matches
- Value:
MISMATCH
2. Gmail Email Notification
Goal: Send email alerts for DNS changes
Zap Setup:
- Trigger: Webhooks by Zapier - Catch Hook
- Action: Gmail - Send Email
Email configuration:
- To: ops-team@company.com
- Subject:
DNS Change Alert - {{event__domain}} - Body:
A DNS change has been detected:
Domain: {{event__domain}}.{{event__subdomain}}
Record Type: {{event__record_type}}
Expected Value: {{event__expected_value}}
Previous Value: {{event__previous_value}}
Current Value: {{event__current_value}}
State: {{event__old_state}} → {{event__new_state}}
Incident Count: {{event__incidence_count}}
Occurred: {{event__occurred}}
Event ID: {{event__event_uuid}}
Monitor ID: {{event__monitor_uuid}}
Request ID: {{uuid}}
3. Google Sheets Logging
Goal: Track all DNS changes in a spreadsheet
Zap Setup:
- Trigger: Webhooks by Zapier - Catch Hook
- Action: Google Sheets - Create Spreadsheet Row
Spreadsheet columns:
- Request UUID:
{{uuid}} - Webhook UUID:
{{webhook_uuid}} - Created:
{{created}} - Event UUID:
{{event__event_uuid}} - Monitor UUID:
{{event__monitor_uuid}} - Domain:
{{event__domain}} - Subdomain:
{{event__subdomain}} - Record Type:
{{event__record_type}} - Expected Value:
{{event__expected_value}} - Current Value:
{{event__current_value}} - Old State:
{{event__old_state}} - New State:
{{event__new_state}} - Occurred:
{{event__occurred}} - Incident Count:
{{event__incidence_count}}
4. Jira Ticket Creation
Goal: Create Jira tickets for DNS changes
Zap Setup:
- Trigger: Webhooks by Zapier - Catch Hook
- Filter: Only continue if Event New State is
MISMATCH - Action: Jira - Create Issue
Jira issue configuration:
- Project: DNS-OPS
- Issue Type: Task
- Summary:
DNS Change - {{event__domain}}.{{event__subdomain}} - Description:
Domain: {{event__domain}}.{{event__subdomain}}
Record Type: {{event__record_type}}
Previous Value: {{event__previous_value}}
Current Value: {{event__current_value}}
State Change: {{event__old_state}} → {{event__new_state}}
Occurred: {{event__occurred}}
Event UUID: {{event__event_uuid}}
Monitor UUID: {{event__monitor_uuid}}
Request ID: {{uuid}}
- Priority: High (for
MISMATCH)
5. PagerDuty Incident
Goal: Create PagerDuty incidents for critical DNS issues
Zap Setup:
- Trigger: Webhooks by Zapier - Catch Hook
- Filter: Only continue if Event New State is
MISMATCH - Action: PagerDuty - Create Incident
PagerDuty configuration:
- Service: Your DNS on-call service
- Title:
DNS Mismatch: {{event__domain}}.{{event__subdomain}} - Urgency: High
- Body:
Domain: {{event__domain}}.{{event__subdomain}}
Record Type: {{event__record_type}}
Expected: {{event__expected_value}}
Current: {{event__current_value}}
State: {{event__new_state}}
Event: {{event__event_uuid}}
Request: {{uuid}}
6. Microsoft Teams Notification
Goal: Alert team in Microsoft Teams
Zap Setup:
- Trigger: Webhooks by Zapier - Catch Hook
- Action: Microsoft Teams - Send Channel Message
Teams message:
- Team: Operations
- Channel: DNS Monitoring
- Message:
**DNS Alert Detected**
**Domain**: {{event__domain}}.{{event__subdomain}}
**Record Type**: {{event__record_type}}
**State**: {{event__old_state}} → {{event__new_state}}
**Expected**: {{event__expected_value}}
**Current**: {{event__current_value}}
**Time**: {{event__occurred}}
**Event ID**: {{event__event_uuid}}
**Request ID**: {{uuid}}
7. Trello Card Creation
Goal: Track DNS changes as Trello cards
Zap Setup:
- Trigger: Webhooks by Zapier - Catch Hook
- Action: Trello - Create Card
Trello card configuration:
- Board: DNS Operations
- List: New Alerts
- Card Name:
DNS Change - {{event__domain}}.{{event__subdomain}} - Description:
Record Type: {{event__record_type}}
State: {{event__old_state}} → {{event__new_state}}
Expected: {{event__expected_value}}
Current: {{event__current_value}}
Occurred: {{event__occurred}}
Event: {{event__event_uuid}}
Request: {{uuid}}
- Labels: Based on Event New State (use Formatter to map states to label names)
8. Discord Notification
Goal: Send alerts to Discord server
Zap Setup:
- Trigger: Webhooks by Zapier - Catch Hook
- Action: Discord - Send Channel Message
Discord message:
- Channel: dns-alerts
- Message Text:
:warning: **DNS Change Detected**
**Domain**: {{event__domain}}.{{event__subdomain}}
**Type**: {{event__record_type}}
**Status**: {{event__new_state}}
**Expected**: `{{event__expected_value}}`
**Current**: `{{event__current_value}}`
**Time**: {{event__occurred}}
**Event ID**: {{event__event_uuid}}
Advanced Patterns
Multi-Path Workflows
Route events based on severity using Paths:
Zap Setup:
- Trigger: Webhooks by Zapier - Catch Hook
- Paths by Zapier:
- Path A (Critical): Event New State =
MISMATCH- Send to PagerDuty
- Send to Slack
- Path B (Warning): Event New State =
NOT_FOUND- Send to Email
- Create Jira ticket
- Path C (Info): Event New State =
TIMEOUT- Log to Google Sheets
- Path A (Critical): Event New State =
Adding Context with Formatter
Transform data before sending:
Example: Format domain display name
- Trigger: Webhooks by Zapier - Catch Hook
- Formatter by Zapier: Text - Replace
- Input:
{{event__domain}}.{{event__subdomain}} - Find: Empty subdomain text
- Replace: Clean format
- Input:
- Action: Send notification with formatted domain
Example: Create custom message based on state
- Trigger: Webhooks by Zapier - Catch Hook
- Formatter by Zapier: Utilities - Lookup Table
- Lookup Value:
{{event__new_state}} - Lookup Table:
MISMATCH→ Critical DNS mismatch detectedNOT_FOUND→ DNS record not foundTIMEOUT→ DNS query timeoutVALID→ DNS record restored to valid state
- Lookup Value:
- Action: Use formatted message
Combining Multiple Actions
Send to multiple channels for critical events:
Zap Setup:
- Trigger: Webhooks by Zapier - Catch Hook
- Filter: Event New State =
MISMATCH - Action 1: Slack - Send message
- Action 2: PagerDuty - Create incident
- Action 3: Gmail - Send email
- Action 4: Google Sheets - Log event
Delay and Digest Pattern
Batch alerts to prevent notification fatigue:
Zap Setup:
- Trigger: Webhooks by Zapier - Catch Hook
- Append Entry and Schedule Digest by Zapier:
- Digest Key: dns-alerts-hourly
- Schedule: Every 1 hour
- When digest fires, send summary to Slack with all events
Using Storage for Deduplication
Track recent alerts to avoid duplicates:
Zap Setup:
- Trigger: Webhooks by Zapier - Catch Hook
- Storage by Zapier: Get Value
- Key:
alert-{{event__monitor_uuid}}
- Key:
- Filter: Only continue if storage value is empty or old
- Action: Send alert
- Storage by Zapier: Set Value
- Key:
alert-{{event__monitor_uuid}} - Value:
{{event__occurred}}
- Key:
Webhook Security and Validation
Understanding DNSRadar Webhook Signatures
DNSRadar signs webhook requests using HMAC SHA256 for security:
curl -X POST https://api.dnsradar.dev/webhooks \
-H "X-API-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
}'const response = await fetch('https://api.dnsradar.dev/webhooks', {
method: 'POST',
headers: {
"X-API-Key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
})
});
const data = await response.json();import requests
response = requests.post(
'https://api.dnsradar.dev/webhooks',
headers={
'X-API-Key': 'YOUR_API_KEY',
'Content-Type': 'application/json'
},
json={
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
}
)require 'net/http'
require 'json'
uri = URI('https://api.dnsradar.dev/webhooks')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Post.new(uri)
request['X-API-Key'] = 'YOUR_API_KEY'
request['Content-Type'] = 'application/json'
request.body = {
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
}.to_json
response = http.request(request)package main
import (
"bytes"
"encoding/json"
"net/http"
)
data := {
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
}
jsonData, _ := json.Marshal(data)
req, _ := http.NewRequest("POST", "https://api.dnsradar.dev/webhooks", bytes.NewBuffer(jsonData))
req.Header.Set("X-API-Key", "YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
response, _ := client.Do(req)<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://api.dnsradar.dev/webhooks');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
$headers = [
'X-API-Key: YOUR_API_KEY',
'Content-Type: application/json'
];
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
$data = json_encode({
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
});
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
$response = curl_exec($ch);
curl_close($ch);import java.net.http.*;
import java.net.URI;
HttpClient client = HttpClient.newHttpClient();
String json = """{
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
}""";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.dnsradar.dev/webhooks"))
.header("X-API-Key", "YOUR_API_KEY")
.header("Content-Type", "application/json")
.method("POST", HttpRequest.BodyPublishers.ofString(json))
.build();
HttpResponse<String> response = client.send(request,
HttpResponse.BodyHandlers.ofString());using System.Net.Http;
using System.Text;
using System.Text.Json;
var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "YOUR_API_KEY");
var data = new
{
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"groups": [
"production-dns"
]
};
var json = JsonSerializer.Serialize(data);
var content = new StringContent(json, Encoding.UTF8, "application/json");
var response = await client.PostAsync(
"https://api.dnsradar.dev/webhooks",
content
);DNSRadar includes these security headers:
X-DNSRadar-Signature: HMAC SHA256 signature of the request bodyX-Webhook-Timestamp: UTC timestamp to prevent replay attacks
Validating Signatures in Zapier
Use Code by Zapier to verify the webhook signature:
Zap Setup:
- Trigger: Webhooks by Zapier - Catch Hook
- Code by Zapier: Run Python
import hmac
import hashlib
import json
from datetime import datetime, timezone
# Get headers and body
signature = input_data.get('headers', {}).get('X-Dnsradar-Signature', '')
timestamp = input_data.get('headers', {}).get('X-Webhook-Timestamp', '')
secret = 'your-secure-webhook-secret'
# Verify timestamp (prevent replay attacks - within 5 minutes)
try:
event_time = datetime.fromisoformat(timestamp.replace('Z', '+00:00'))
now = datetime.now(timezone.utc)
if (now - event_time).total_seconds() > 300:
raise Exception('Webhook request too old')
except:
raise Exception('Invalid timestamp')
# Verify signature
body = json.dumps(input_data).encode('utf-8')
expected_signature = hmac.new(
secret.encode('utf-8'),
body,
hashlib.sha256
).hexdigest()
if not hmac.compare_digest(signature, expected_signature):
raise Exception('Invalid webhook signature')
# Return data if validation passes
return input_data
- Continue with actions
Optional: Custom Headers
You can still add custom headers for additional authentication layers:
curl -X POST https://api.dnsradar.dev/webhooks \
-H "X-API-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"headers": {
"X-DNSRadar-Source": "production"
},
"groups": [
"production-dns"
]
}'const response = await fetch('https://api.dnsradar.dev/webhooks', {
method: 'POST',
headers: {
"X-API-Key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"headers": {
"X-DNSRadar-Source": "production"
},
"groups": [
"production-dns"
]
})
});
const data = await response.json();import requests
response = requests.post(
'https://api.dnsradar.dev/webhooks',
headers={
'X-API-Key': 'YOUR_API_KEY',
'Content-Type': 'application/json'
},
json={
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"headers": {
"X-DNSRadar-Source": "production"
},
"groups": [
"production-dns"
]
}
)require 'net/http'
require 'json'
uri = URI('https://api.dnsradar.dev/webhooks')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Post.new(uri)
request['X-API-Key'] = 'YOUR_API_KEY'
request['Content-Type'] = 'application/json'
request.body = {
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"headers": {
"X-DNSRadar-Source": "production"
},
"groups": [
"production-dns"
]
}.to_json
response = http.request(request)package main
import (
"bytes"
"encoding/json"
"net/http"
)
data := {
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"headers": {
"X-DNSRadar-Source": "production"
},
"groups": [
"production-dns"
]
}
jsonData, _ := json.Marshal(data)
req, _ := http.NewRequest("POST", "https://api.dnsradar.dev/webhooks", bytes.NewBuffer(jsonData))
req.Header.Set("X-API-Key", "YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
response, _ := client.Do(req)<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://api.dnsradar.dev/webhooks');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
$headers = [
'X-API-Key: YOUR_API_KEY',
'Content-Type: application/json'
];
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
$data = json_encode({
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"headers": {
"X-DNSRadar-Source": "production"
},
"groups": [
"production-dns"
]
});
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
$response = curl_exec($ch);
curl_close($ch);import java.net.http.*;
import java.net.URI;
HttpClient client = HttpClient.newHttpClient();
String json = """{
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"headers": {
"X-DNSRadar-Source": "production"
},
"groups": [
"production-dns"
]
}""";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.dnsradar.dev/webhooks"))
.header("X-API-Key", "YOUR_API_KEY")
.header("Content-Type", "application/json")
.method("POST", HttpRequest.BodyPublishers.ofString(json))
.build();
HttpResponse<String> response = client.send(request,
HttpResponse.BodyHandlers.ofString());using System.Net.Http;
using System.Text;
using System.Text.Json;
var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "YOUR_API_KEY");
var data = new
{
"url": "https://hooks.zapier.com/hooks/catch/123456/abcdef/",
"method": "POST",
"secret": "your-secure-webhook-secret",
"headers": {
"X-DNSRadar-Source": "production"
},
"groups": [
"production-dns"
]
};
var json = JsonSerializer.Serialize(data);
var content = new StringContent(json, Encoding.UTF8, "application/json");
var response = await client.PostAsync(
"https://api.dnsradar.dev/webhooks",
content
);Working with Arrays
DNSRadar sends expected_value, previous_value, and current_value as arrays within the event object. Handle them in Zapier:
Display Array Values
Use Formatter to join arrays:
- Formatter by Zapier: Text - Join
- Input:
{{event__expected_value}} - Separator:
, - Output: Use in subsequent steps
- Input:
Compare Array Values
Use Code by Zapier for complex comparisons:
event = input_data.get('event', {})
expected = event.get('expected_value', [])
current = event.get('current_value', [])
if set(expected) == set(current):
result = "Match"
else:
result = "Mismatch"
return {'comparison': result, 'details': f"Expected: {expected}, Got: {current}"}
Troubleshooting
Webhook Not Triggering
Check these items:
- Zapier webhook URL is correct in DNSRadar
- Webhook is enabled in DNSRadar
- Zap is turned ON (not paused)
- Check Zapier's Zap History for errors
Test Your Webhook
From DNSRadar, send a test event:
curl -X POST https://api.dnsradar.dev/webhooks/wh_abc123/test \
-H "X-API-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{}'const response = await fetch('https://api.dnsradar.dev/webhooks/wh_abc123/test', {
method: 'POST',
headers: {
"X-API-Key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({})
});
const data = await response.json();import requests
response = requests.post(
'https://api.dnsradar.dev/webhooks/wh_abc123/test',
headers={
'X-API-Key': 'YOUR_API_KEY',
'Content-Type': 'application/json'
},
json={}
)require 'net/http'
require 'json'
uri = URI('https://api.dnsradar.dev/webhooks/wh_abc123/test')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Post.new(uri)
request['X-API-Key'] = 'YOUR_API_KEY'
request['Content-Type'] = 'application/json'
request.body = {}.to_json
response = http.request(request)package main
import (
"bytes"
"encoding/json"
"net/http"
)
data := {}
jsonData, _ := json.Marshal(data)
req, _ := http.NewRequest("POST", "https://api.dnsradar.dev/webhooks/wh_abc123/test", bytes.NewBuffer(jsonData))
req.Header.Set("X-API-Key", "YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
response, _ := client.Do(req)<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://api.dnsradar.dev/webhooks/wh_abc123/test');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
$headers = [
'X-API-Key: YOUR_API_KEY',
'Content-Type: application/json'
];
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
$data = json_encode({});
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
$response = curl_exec($ch);
curl_close($ch);import java.net.http.*;
import java.net.URI;
HttpClient client = HttpClient.newHttpClient();
String json = """{}""";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.dnsradar.dev/webhooks/wh_abc123/test"))
.header("X-API-Key", "YOUR_API_KEY")
.header("Content-Type", "application/json")
.method("POST", HttpRequest.BodyPublishers.ofString(json))
.build();
HttpResponse<String> response = client.send(request,
HttpResponse.BodyHandlers.ofString());using System.Net.Http;
using System.Text;
using System.Text.Json;
var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "YOUR_API_KEY");
var data = new
{};
var json = JsonSerializer.Serialize(data);
var content = new StringContent(json, Encoding.UTF8, "application/json");
var response = await client.PostAsync(
"https://api.dnsradar.dev/webhooks/wh_abc123/test",
content
);Check Zapier's Zap History to see if it was received.
Missing Data in Zapier
If fields aren't appearing:
- Send a test webhook from DNSRadar
- In Zapier, click "Retest trigger" to refresh sample data
- Verify the field names match the webhook payload
- Check if the field contains data in the sample
Zap Not Continuing
Common causes:
- Filter blocking execution: Check filter conditions
- Required field empty: Ensure all required action fields have data
- Authentication failed: Reconnect the app account
- Rate limits: Check if you've hit API rate limits
View Zap History
Check execution logs:
- Open your Zap
- Click "Zap History" tab
- Review recent runs for errors
- Click individual runs to see detailed logs
Debug with Formatter
Add a Formatter step to inspect data:
- Formatter by Zapier: Utilities - Line Item to Text
- Input: All webhook data
- Email by Zapier: Send yourself the formatted output
- Review what data is actually being received
Best Practices
Security
Implement webhook signature validation:
- Always provide a
secretwhen creating webhooks - Add signature validation using Code by Zapier
- Verify timestamps to prevent replay attacks
- Store webhook secrets in environment variables or secure storage
Error Handling
Set up error notifications:
- In Zap settings, enable "Send Zap error emails"
- Create a separate error-handling Zap
- Use try-catch in Code steps
Testing
Before going live:
- Test with DNSRadar webhook test endpoint
- Verify all actions complete successfully
- Check that notifications arrive correctly
- Validate formatting and data accuracy
Performance
Optimize your Zaps:
- Use Filters early to avoid unnecessary actions
- Consider digest patterns for high-volume events
- Use multi-step Zaps instead of multiple single-step Zaps
- Monitor task usage to stay within plan limits
Next Steps
- Configure Webhooks
- Test Webhooks
- View Webhook Request History
- N8n Integration (alternative automation platform)