Delete a WebHook
The Delete WebHook API removes a WebHook registration. Once deleted, no further detection events are posted to its address, and the delivery statistics collected for that hook are discarded along with it.
Prefer
disabled for a temporary pauseDeleting throws away the hookId. If you only want to stop delivery for a while — a maintenance window, a receiver migration — save the hook with "disabled": true instead. It keeps the id and the whole configuration, and re-enabling is a one-field change. See Create or Update a WebHook.
API Endpoint
- HTTP Method:
DELETE - Endpoint:
/api/v1/settings/web-hooks/{hookId} - Private Server Base URL:
https://10.0.0.123:5022 - Cloud Server Base URL:
https://customername.econnectcloud.com/eventsbridge
Authentication
This API call requires authentication with a JWT token, which must be passed in the header of the request.
Path Parameter
- hookId: The unique ID of the WebHook to delete, in GUID/UUID format.
Code Examples
- C#
- Curl
- PowerShell
using eConnect.EventsBridge.Sdk;
using eConnect.EventsBridge.Sdk.Client;
// Assuming sdk is already initialized with authentication
var hookId = Guid.Parse("e1bce9b4-5589-4d6e-b765-8f446a8a5c10");
// Removes the registration and its delivery statistics. This cannot be undone.
await sdk.WebHookRemoveAsync(hookId);
Console.WriteLine($"Deleted WebHook {hookId}");
// If you only want to stop delivery temporarily, save the hook with
// Disabled = true instead of deleting it.
# Define variables
API_URL="https://your-domain.com/eventsbridge"
TOKEN="your_token"
HOOK_ID="e1bce9b4-5589-4d6e-b765-8f446a8a5c10"
# Removes the registration and its delivery statistics. This cannot be undone.
curl -X DELETE "$API_URL/api/v1/settings/web-hooks/$HOOK_ID" \
-H "Authorization: Bearer $TOKEN"
# If you only want to stop delivery temporarily, PUT the hook back
# with "disabled": true instead of deleting it.
# Define variables
$API_URL = "https://your-domain.com/eventsbridge"
$TOKEN = "your_token"
$HOOK_ID = "e1bce9b4-5589-4d6e-b765-8f446a8a5c10"
# Removes the registration and its delivery statistics. This cannot be undone.
Invoke-RestMethod -Uri "$API_URL/api/v1/settings/web-hooks/$HOOK_ID" -Method Delete -Headers @{ "Authorization" = "Bearer $TOKEN" }
Write-Output "Deleted WebHook $HOOK_ID"
# If you only want to stop delivery temporarily, PUT the hook back
# with disabled = $true instead of deleting it.
Raw Sample
Here's an example of how to use the DELETE method to remove a WebHook:
Request
DELETE https://10.0.0.123:5022/api/v1/settings/web-hooks/e1bce9b4-5589-4d6e-b765-8f446a8a5c10
Authorization: Bearer <your_jwt_token>
Response
- 200 OK: The WebHook was deleted. The response has no body.
- 401 Unauthorized: Missing or invalid JWT token.
- 500 Internal Server Error: An issue occurred on the server side.
Additional Notes
- This cannot be undone. Recreating a deleted hook means a new registration, and any queued-but-undelivered payloads for a
resilienthook go with it. - After deleting, drop the
hookIdfrom your own storage. A later save against that id creates a brand new registration rather than restoring the old one. - Use Get All WebHooks to find registrations you no longer recognise — a common source of duplicates is an integration that calls Create a New WebHook Template on every run instead of reusing a stored
hookId.