Delete Webhook Endpoint
curl --request DELETE \
--url https://api.hopnow.io/v1/customers/{customer_id}/webhook-endpoints/{endpoint_id} \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.hopnow.io/v1/customers/{customer_id}/webhook-endpoints/{endpoint_id}"
headers = {"X-API-Key": "<api-key>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.hopnow.io/v1/customers/{customer_id}/webhook-endpoints/{endpoint_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.hopnow.io/v1/customers/{customer_id}/webhook-endpoints/{endpoint_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.hopnow.io/v1/customers/{customer_id}/webhook-endpoints/{endpoint_id}"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://api.hopnow.io/v1/customers/{customer_id}/webhook-endpoints/{endpoint_id}")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hopnow.io/v1/customers/{customer_id}/webhook-endpoints/{endpoint_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": "<string>",
"object": "<string>",
"deleted": true
}Webhooks
Delete Webhook Endpoint
Delete a webhook endpoint
DELETE
/
v1
/
customers
/
{customer_id}
/
webhook-endpoints
/
{endpoint_id}
Delete Webhook Endpoint
curl --request DELETE \
--url https://api.hopnow.io/v1/customers/{customer_id}/webhook-endpoints/{endpoint_id} \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.hopnow.io/v1/customers/{customer_id}/webhook-endpoints/{endpoint_id}"
headers = {"X-API-Key": "<api-key>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.hopnow.io/v1/customers/{customer_id}/webhook-endpoints/{endpoint_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.hopnow.io/v1/customers/{customer_id}/webhook-endpoints/{endpoint_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.hopnow.io/v1/customers/{customer_id}/webhook-endpoints/{endpoint_id}"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://api.hopnow.io/v1/customers/{customer_id}/webhook-endpoints/{endpoint_id}")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hopnow.io/v1/customers/{customer_id}/webhook-endpoints/{endpoint_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": "<string>",
"object": "<string>",
"deleted": true
}Deletion is a soft delete. The endpoint stops receiving events but remains visible in list results with a non-null
deleted_at. Subsequent get, update, or delete requests for the endpoint return 404 Not Found.Path Parameters
string
required
The customer’s external ID (starts with
cus_)string
required
The webhook endpoint’s external ID (starts with
wh_)Response
string
The deleted webhook endpoint ID
string
Always returns
"webhook_endpoint"boolean
Always returns
trueResponse Example
{
"id": "wh_1234567890abcdefghijklmn",
"object": "webhook_endpoint",
"deleted": true
}
⌘I