Create notification webhook
curl --request PUT \
--url https://api.wirespeed.co/v1/notification/webhook \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"url": "<string>",
"enabled": true,
"notificationTypes": []
}
'import requests
url = "https://api.wirespeed.co/v1/notification/webhook"
payload = {
"name": "<string>",
"url": "<string>",
"enabled": True,
"notificationTypes": []
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({name: '<string>', url: '<string>', enabled: true, notificationTypes: []})
};
fetch('https://api.wirespeed.co/v1/notification/webhook', 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.wirespeed.co/v1/notification/webhook",
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([
'name' => '<string>',
'url' => '<string>',
'enabled' => true,
'notificationTypes' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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.wirespeed.co/v1/notification/webhook"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"enabled\": true,\n \"notificationTypes\": []\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.wirespeed.co/v1/notification/webhook")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"enabled\": true,\n \"notificationTypes\": []\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.wirespeed.co/v1/notification/webhook")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"enabled\": true,\n \"notificationTypes\": []\n}"
response = http.request(request)
puts response.read_body{
"secret": "<string>",
"webhook": {
"id": "<string>",
"teamId": "<string>",
"name": "<string>",
"url": "<string>",
"enabled": true,
"createdAt": "<string>",
"updatedAt": "<string>",
"notificationTypes": []
}
}{
"message": "<string>",
"statusCode": 123
}Notification
Create notification webhook
Creates a webhook destination and returns the generated signing secret. The secret is shown only once.
PUT
/
v1
/
notification
/
webhook
Create notification webhook
curl --request PUT \
--url https://api.wirespeed.co/v1/notification/webhook \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"url": "<string>",
"enabled": true,
"notificationTypes": []
}
'import requests
url = "https://api.wirespeed.co/v1/notification/webhook"
payload = {
"name": "<string>",
"url": "<string>",
"enabled": True,
"notificationTypes": []
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({name: '<string>', url: '<string>', enabled: true, notificationTypes: []})
};
fetch('https://api.wirespeed.co/v1/notification/webhook', 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.wirespeed.co/v1/notification/webhook",
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([
'name' => '<string>',
'url' => '<string>',
'enabled' => true,
'notificationTypes' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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.wirespeed.co/v1/notification/webhook"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"enabled\": true,\n \"notificationTypes\": []\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.wirespeed.co/v1/notification/webhook")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"enabled\": true,\n \"notificationTypes\": []\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.wirespeed.co/v1/notification/webhook")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"enabled\": true,\n \"notificationTypes\": []\n}"
response = http.request(request)
puts response.read_body{
"secret": "<string>",
"webhook": {
"id": "<string>",
"teamId": "<string>",
"name": "<string>",
"url": "<string>",
"enabled": true,
"createdAt": "<string>",
"updatedAt": "<string>",
"notificationTypes": []
}
}{
"message": "<string>",
"statusCode": 123
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
application/json
Human-readable label for this webhook destination
URL to POST notification payloads to
Notification types that trigger this webhook. Null/omitted means all types.
Available options:
NEW_CASE_ESCALATION, NEW_SECURITY_EVENT, NEW_CRITICAL_DEFECT, ACCOUNT_SUMMARY, INTEGRATION_HEALTH ⌘I

