curl --request PUT \
--url https://api.sendx.io/api/v1/rest/webhook/{identifier} \
--header 'Content-Type: application/json' \
--header 'X-Team-ApiKey: <api-key>' \
--data '
{
"url": "https://api.example.com/webhooks/sendx",
"enabled": true,
"unsubscribed": false,
"dropped": false,
"bounced": false,
"markedSpam": false,
"clicked": false,
"opened": false,
"contactCreated": false
}
'import requests
url = "https://api.sendx.io/api/v1/rest/webhook/{identifier}"
payload = {
"url": "https://api.example.com/webhooks/sendx",
"enabled": True,
"unsubscribed": False,
"dropped": False,
"bounced": False,
"markedSpam": False,
"clicked": False,
"opened": False,
"contactCreated": False
}
headers = {
"X-Team-ApiKey": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'X-Team-ApiKey': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
url: 'https://api.example.com/webhooks/sendx',
enabled: true,
unsubscribed: false,
dropped: false,
bounced: false,
markedSpam: false,
clicked: false,
opened: false,
contactCreated: false
})
};
fetch('https://api.sendx.io/api/v1/rest/webhook/{identifier}', 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.sendx.io/api/v1/rest/webhook/{identifier}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'url' => 'https://api.example.com/webhooks/sendx',
'enabled' => true,
'unsubscribed' => false,
'dropped' => false,
'bounced' => false,
'markedSpam' => false,
'clicked' => false,
'opened' => false,
'contactCreated' => false
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-Team-ApiKey: <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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.sendx.io/api/v1/rest/webhook/{identifier}"
payload := strings.NewReader("{\n \"url\": \"https://api.example.com/webhooks/sendx\",\n \"enabled\": true,\n \"unsubscribed\": false,\n \"dropped\": false,\n \"bounced\": false,\n \"markedSpam\": false,\n \"clicked\": false,\n \"opened\": false,\n \"contactCreated\": false\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("X-Team-ApiKey", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.sendx.io/api/v1/rest/webhook/{identifier}")
.header("X-Team-ApiKey", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"url\": \"https://api.example.com/webhooks/sendx\",\n \"enabled\": true,\n \"unsubscribed\": false,\n \"dropped\": false,\n \"bounced\": false,\n \"markedSpam\": false,\n \"clicked\": false,\n \"opened\": false,\n \"contactCreated\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sendx.io/api/v1/rest/webhook/{identifier}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["X-Team-ApiKey"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"url\": \"https://api.example.com/webhooks/sendx\",\n \"enabled\": true,\n \"unsubscribed\": false,\n \"dropped\": false,\n \"bounced\": false,\n \"markedSpam\": false,\n \"clicked\": false,\n \"opened\": false,\n \"contactCreated\": false\n}"
response = http.request(request)
puts response.read_bodyUpdate webhook
Updates webhook configuration.
curl --request PUT \
--url https://api.sendx.io/api/v1/rest/webhook/{identifier} \
--header 'Content-Type: application/json' \
--header 'X-Team-ApiKey: <api-key>' \
--data '
{
"url": "https://api.example.com/webhooks/sendx",
"enabled": true,
"unsubscribed": false,
"dropped": false,
"bounced": false,
"markedSpam": false,
"clicked": false,
"opened": false,
"contactCreated": false
}
'import requests
url = "https://api.sendx.io/api/v1/rest/webhook/{identifier}"
payload = {
"url": "https://api.example.com/webhooks/sendx",
"enabled": True,
"unsubscribed": False,
"dropped": False,
"bounced": False,
"markedSpam": False,
"clicked": False,
"opened": False,
"contactCreated": False
}
headers = {
"X-Team-ApiKey": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'X-Team-ApiKey': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
url: 'https://api.example.com/webhooks/sendx',
enabled: true,
unsubscribed: false,
dropped: false,
bounced: false,
markedSpam: false,
clicked: false,
opened: false,
contactCreated: false
})
};
fetch('https://api.sendx.io/api/v1/rest/webhook/{identifier}', 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.sendx.io/api/v1/rest/webhook/{identifier}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'url' => 'https://api.example.com/webhooks/sendx',
'enabled' => true,
'unsubscribed' => false,
'dropped' => false,
'bounced' => false,
'markedSpam' => false,
'clicked' => false,
'opened' => false,
'contactCreated' => false
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-Team-ApiKey: <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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.sendx.io/api/v1/rest/webhook/{identifier}"
payload := strings.NewReader("{\n \"url\": \"https://api.example.com/webhooks/sendx\",\n \"enabled\": true,\n \"unsubscribed\": false,\n \"dropped\": false,\n \"bounced\": false,\n \"markedSpam\": false,\n \"clicked\": false,\n \"opened\": false,\n \"contactCreated\": false\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("X-Team-ApiKey", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.sendx.io/api/v1/rest/webhook/{identifier}")
.header("X-Team-ApiKey", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"url\": \"https://api.example.com/webhooks/sendx\",\n \"enabled\": true,\n \"unsubscribed\": false,\n \"dropped\": false,\n \"bounced\": false,\n \"markedSpam\": false,\n \"clicked\": false,\n \"opened\": false,\n \"contactCreated\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sendx.io/api/v1/rest/webhook/{identifier}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["X-Team-ApiKey"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"url\": \"https://api.example.com/webhooks/sendx\",\n \"enabled\": true,\n \"unsubscribed\": false,\n \"dropped\": false,\n \"bounced\": false,\n \"markedSpam\": false,\n \"clicked\": false,\n \"opened\": false,\n \"contactCreated\": false\n}"
response = http.request(request)
puts response.read_body- Endpoint URL
- Enabled/disabled status
- Event subscriptions
- URL changes take effect immediately
- Disabling pauses all deliveries
- Event changes apply to future events only
- Change endpoint URL
- Enable/disable specific events
- Temporarily pause webhook
- Add new event types
Authorizations
Team API key for authentication. Find your API key in SendX Settings → Team API Key.
Example:
X-Team-ApiKey: your_team_api_key_here
Path Parameters
Webhook identifier to update
^(webhook_)?[a-zA-Z0-9]{22}$Body
Webhook endpoint URL
"https://api.example.com/webhooks/sendx"
Whether webhook is enabled
Trigger webhook when a contact unsubscribes
Trigger webhook when an email is dropped
Trigger webhook when an email bounces
Trigger webhook when an email is marked as spam
Trigger webhook when a link in the email is clicked
Trigger webhook when an email is opened
Trigger webhook when a new contact is created
Response
✅ Webhook updated successfully
"webhook_9l154iiXlZoPo7vngmamee"
Webhook endpoint URL
"https://api.example.com/webhooks/sendx"
Whether webhook is enabled
Trigger webhook when a contact unsubscribes
Trigger webhook when an email is dropped
Trigger webhook when an email bounces
Trigger webhook when an email is marked as spam
Trigger webhook when a link in the email is clicked
Trigger webhook when an email is opened
Trigger webhook when a new contact is created
Was this page helpful?