Delete Webhook URL

Removes a custom webhook URL from a WhatsApp instance. The system webhook cannot be deleted. (Paid users only)

DELETE
https://api.wawp.net/v2/webhook/delete?access_token=YOUR_ACCESS_TOKEN&instance_id=Your_Instance_ID&url=https%3A%2F%2Fmy-app.com%2Fwebhook

Authentication Required

Login to swap the placeholders with your real Instance ID and Access Token.

Log In
Test /v2/webhook/delete endpoint
DELETE
DELETE

No query parameters required

This endpoint doesn't expect data in the URL.

Best practices

  • Double-check the URL before deleting to avoid accidentally removing a live integration.

  • If you only need to pause deliveries, consider disabling the webhook via /v2/webhook/update instead.

  • After deletion, confirm the remaining webhook list with /v2/session/webhook (GET).

Delete Webhook URL: /v2/webhook/delete

The /v2/webhook/delete endpoint removes a single custom webhook URL from the instance. The system webhook (https://app.wawp.net/api/webhook/{token}) is protected and cannot be deleted; use /v2/webhook/update to disable it instead.

[!IMPORTANT] This endpoint is only available for paid subscription accounts (Unlimited tiers). Free tier users will receive a 403 Forbidden error with code subscription_required.


🎯 When to Use This Endpoint

Use this endpoint when you want to:

  • Permanently remove a custom webhook URL you no longer need.
  • Clean up old or broken endpoints that keep failing deliveries.
  • Offboard a third-party integration without resetting the whole webhook list.

📦 Request Parameters

  • url (required): The exact custom webhook URL to remove. Can be sent in the request body or as a query parameter.
  • instance_id and access_token: Required credentials, accepted in the body or query string.

� Request Samples

cURL (body)

curl -X DELETE "https://api.wawp.net/v2/webhook/delete"   -H "Content-Type: application/json"   -d '{
    "access_token": "YOUR_ACCESS_TOKEN",
    "instance_id": "Your_Instance_ID",
    "url": "https://my-app.com/webhook"
  }'

cURL (query parameter)

curl -X DELETE "https://api.wawp.net/v2/webhook/delete?access_token=YOUR_ACCESS_TOKEN&instance_id=Your_Instance_ID&url=https%3A%2F%2Fmy-app.com%2Fwebhook"

JavaScript (Fetch)

const res = await fetch('https://api.wawp.net/v2/webhook/delete', {
  method: 'DELETE',
  headers: { 'Content-Type': 'application/json' },
  body: JSON.stringify({
    access_token: 'YOUR_ACCESS_TOKEN',
    instance_id: 'Your_Instance_ID',
    url: 'https://my-app.com/webhook'
  })
});
const data = await res.json();
console.log(data);

�🛡️ Protected System Webhook

The engine maintains one system webhook for inbox syncing, push notifications, and automation. If you attempt to delete that URL, the API returns error code system_webhook_protected with HTTP 400.

To stop receiving system events, either:

  • Set is_active to 0 via /v2/webhook/update.
  • Remove all events from the system webhook's event list.

Request Parameters

Configure the parameters required to interact with this endpoint. All query and body arguments are listed below with their details.

Request Body

Sent as a JSON object
string

The 12-character ID of the instance

Example:
string

Your API Access Token

Example:
string

The exact custom webhook URL to remove

Example:

Request Samples

Use these ready-to-go code snippets to integrate our API into your project quickly and efficiently. Choose your preferred language and library.

1const baseUrl = "https://api.wawp.net";
2const endpoint = "/v2/webhook/delete";
3const params = new URLSearchParams({
4 "instance_id": "Your_Instance_ID",
5 "access_token": "YOUR_ACCESS_TOKEN",
6 "url": "https://my-app.com/webhook"
7}).toString();
8
9
10fetch(`${baseUrl}${endpoint}${params ? '?' + params : ''}`, {
11 method: "DELETE",
12 headers: { "Content-Type": "application/json" },
13
14})
15 .then(async (response) => {
16 if (response.ok) {
17 const data = await response.json();
18 console.log("Success:", data);
19 return data;
20 }
21
22 // Error Handling
23 if (response.status === 400) {
24 console.error("Error 400: Bad Request - Missing Required Parameter(s)");
25 }
26 if (response.status === 400) {
27 console.error("Error 400: Bad Request (XML Format)");
28 }
29 if (response.status === 400) {
30 console.error("Error 400: Bad Request (Plain Text)");
31 }
32 if (response.status === 401) {
33 console.error("Error 401: Unauthorized - Invalid or Missing Access Token");
34 }
35 if (response.status === 401) {
36 console.error("Error 401: Unauthorized (XML Format)");
37 }
38 if (response.status === 404) {
39 console.error("Error 404: Not Found - Session Does Not Exist");
40 }
41 if (response.status === 404) {
42 console.error("Error 404: Not Found (XML Format)");
43 }
44 if (response.status === 500) {
45 console.error("Error 500: Internal Server Error - Unexpected Failure");
46 }
47 if (response.status === 500) {
48 console.error("Error 500: Internal Server Error (HTML)");
49 }
50 if (response.status === 502) {
51 console.error("Error 502: Bad Gateway - Connection Failed to Upstream");
52 }
53 if (response.status === 502) {
54 console.error("Error 502: Bad Gateway (XML Format)");
55 }
56
57 const errorText = await response.text();
58 console.error(`Error ${response.status}: ${errorText}`);
59 })
60 .catch((error) => console.error("Network Error:", error));
Interactive Samples
Ln 60, Col 1javascript

Expected Responses

Explore all possible responses and outcomes from the server. We have documented each status code with data examples to make success and error handling easier.

Success - Webhook Deleted
Type:
application/json
string *
string *
object *

Example

{
"status": "success",
"message": "Webhook deleted successfully.",
"removed": {
  "url": "https://my-app.com/webhook",
  "events": {
    "0": "message",
    "1": "message.ack"
    },
  "is_active": 1,
  "enabled": true,
  "retries": {
    "delay": 2,
    "attempts": 15
    }
  }
}
Bad Request - Missing Required Parameter(s)
Unauthorized - Invalid or Missing Access Token
Not Found - Session Does Not Exist
Internal Server Error - Unexpected Failure
Bad Gateway - Connection Failed to Upstream
Previous TopicUpdate Webhook
Next TopicSession Status Change

Command Palette

Search for a command to run...