Enable and Disable Webhooks
Webhooks can be temporarily disabled without deleting their configuration. This is useful for maintenance, debugging, or when you need to pause notifications temporarily.
Disabling a Webhook
Send a POST request to /webhooks/{uuid}/disable:
curl -X POST https://api.dnsradar.dev/webhooks/wh_abc123/disable \
-H "X-API-Key: YOUR_API_KEY"const response = await fetch('https://api.dnsradar.dev/webhooks/wh_abc123/disable', {
method: 'POST',
headers: {
"X-API-Key": "YOUR_API_KEY"
}
});
const data = await response.json();import requests
response = requests.post(
'https://api.dnsradar.dev/webhooks/wh_abc123/disable',
headers={
'X-API-Key': 'YOUR_API_KEY',
}
)require 'net/http'
require 'json'
uri = URI('https://api.dnsradar.dev/webhooks/wh_abc123/disable')
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'
response = http.request(request)package main
import (
"bytes"
"encoding/json"
"net/http"
)
req, _ := http.NewRequest("POST", "https://api.dnsradar.dev/webhooks/wh_abc123/disable", nil)
req.Header.Set("X-API-Key", "YOUR_API_KEY")
client := &http.Client{}
response, _ := client.Do(req)<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://api.dnsradar.dev/webhooks/wh_abc123/disable');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
$headers = [
'X-API-Key: YOUR_API_KEY',
];
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
$response = curl_exec($ch);
curl_close($ch);import java.net.http.*;
import java.net.URI;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.dnsradar.dev/webhooks/wh_abc123/disable"))
.header("X-API-Key", "YOUR_API_KEY")
.method("POST", HttpRequest.BodyPublishers.noBody())
.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 response = await client.PostAsync("https://api.dnsradar.dev/webhooks/wh_abc123/disable");The webhook is immediately disabled and stops receiving notifications.
Enabling a Webhook
Send a POST request to /webhooks/{uuid}/enable:
curl -X POST https://api.dnsradar.dev/webhooks/wh_abc123/enable \
-H "X-API-Key: YOUR_API_KEY"const response = await fetch('https://api.dnsradar.dev/webhooks/wh_abc123/enable', {
method: 'POST',
headers: {
"X-API-Key": "YOUR_API_KEY"
}
});
const data = await response.json();import requests
response = requests.post(
'https://api.dnsradar.dev/webhooks/wh_abc123/enable',
headers={
'X-API-Key': 'YOUR_API_KEY',
}
)require 'net/http'
require 'json'
uri = URI('https://api.dnsradar.dev/webhooks/wh_abc123/enable')
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'
response = http.request(request)package main
import (
"bytes"
"encoding/json"
"net/http"
)
req, _ := http.NewRequest("POST", "https://api.dnsradar.dev/webhooks/wh_abc123/enable", nil)
req.Header.Set("X-API-Key", "YOUR_API_KEY")
client := &http.Client{}
response, _ := client.Do(req)<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://api.dnsradar.dev/webhooks/wh_abc123/enable');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
$headers = [
'X-API-Key: YOUR_API_KEY',
];
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
$response = curl_exec($ch);
curl_close($ch);import java.net.http.*;
import java.net.URI;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.dnsradar.dev/webhooks/wh_abc123/enable"))
.header("X-API-Key", "YOUR_API_KEY")
.method("POST", HttpRequest.BodyPublishers.noBody())
.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 response = await client.PostAsync("https://api.dnsradar.dev/webhooks/wh_abc123/enable");The webhook is re-enabled and resumes receiving notifications. Any error states are cleared.
API Response
Both endpoints return the updated webhook object:
{
"uuid": "wh_abc123",
"created": "2026-01-08T10:30:00Z",
"url": "https://api.service.com/webhooks/dnsradar",
"method": "POST",
"headers": {
"Authorization": "Bearer token123"
},
"is_active": false,
"last_error": null,
"last_executed": "2026-01-08T15:22:10Z"
}
Note the is_active field reflects the webhook's current state.
Automatic Disabling
DNSRadar automatically disables webhooks after repeated failures:
Auto-Disable: Webhooks are automatically disabled after 9 failed retry attempts over 24 hours. You'll be notified when this happens.
Re-enabling After Auto-Disable
When a webhook is auto-disabled:
- Fix the underlying issue (endpoint availability, authentication, etc.)
- Use the enable endpoint to reactivate
- The
last_errorfield is cleared upon re-enabling
curl -X POST https://api.dnsradar.dev/webhooks/wh_abc123/enable \
-H "X-API-Key: YOUR_API_KEY"const response = await fetch('https://api.dnsradar.dev/webhooks/wh_abc123/enable', {
method: 'POST',
headers: {
"X-API-Key": "YOUR_API_KEY"
}
});
const data = await response.json();import requests
response = requests.post(
'https://api.dnsradar.dev/webhooks/wh_abc123/enable',
headers={
'X-API-Key': 'YOUR_API_KEY',
}
)require 'net/http'
require 'json'
uri = URI('https://api.dnsradar.dev/webhooks/wh_abc123/enable')
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'
response = http.request(request)package main
import (
"bytes"
"encoding/json"
"net/http"
)
req, _ := http.NewRequest("POST", "https://api.dnsradar.dev/webhooks/wh_abc123/enable", nil)
req.Header.Set("X-API-Key", "YOUR_API_KEY")
client := &http.Client{}
response, _ := client.Do(req)<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://api.dnsradar.dev/webhooks/wh_abc123/enable');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
$headers = [
'X-API-Key: YOUR_API_KEY',
];
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
$response = curl_exec($ch);
curl_close($ch);import java.net.http.*;
import java.net.URI;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.dnsradar.dev/webhooks/wh_abc123/enable"))
.header("X-API-Key", "YOUR_API_KEY")
.method("POST", HttpRequest.BodyPublishers.noBody())
.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 response = await client.PostAsync("https://api.dnsradar.dev/webhooks/wh_abc123/enable");Checking Webhook Status
Via API
Get webhook details to check status:
curl -X GET https://api.dnsradar.dev/webhooks/wh_abc123 \
-H "X-API-Key: YOUR_API_KEY"const response = await fetch('https://api.dnsradar.dev/webhooks/wh_abc123', {
method: 'GET',
headers: {
"X-API-Key": "YOUR_API_KEY"
}
});
const data = await response.json();import requests
response = requests.get(
'https://api.dnsradar.dev/webhooks/wh_abc123',
headers={
'X-API-Key': 'YOUR_API_KEY',
}
)require 'net/http'
require 'json'
uri = URI('https://api.dnsradar.dev/webhooks/wh_abc123')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Get.new(uri)
request['X-API-Key'] = 'YOUR_API_KEY'
response = http.request(request)package main
import (
"bytes"
"encoding/json"
"net/http"
)
req, _ := http.NewRequest("GET", "https://api.dnsradar.dev/webhooks/wh_abc123", nil)
req.Header.Set("X-API-Key", "YOUR_API_KEY")
client := &http.Client{}
response, _ := client.Do(req)<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://api.dnsradar.dev/webhooks/wh_abc123');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
$headers = [
'X-API-Key: YOUR_API_KEY',
];
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
$response = curl_exec($ch);
curl_close($ch);import java.net.http.*;
import java.net.URI;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.dnsradar.dev/webhooks/wh_abc123"))
.header("X-API-Key", "YOUR_API_KEY")
.method("GET", HttpRequest.BodyPublishers.noBody())
.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 response = await client.GetAsync("https://api.dnsradar.dev/webhooks/wh_abc123");And ensure that the response's body contains the appropriate is_active property, set to true.