curl -X PATCH https://api.thinnest.ai/webhooks/endpoints/{endpoint_id} \
-H "Authorization: Bearer $THINNESTAI_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"url": "https://new-url.com/webhook",
"event_types": [
"agent.created",
"agent.deleted"
],
"is_active": true
}'
import requests
url = "https://api.thinnest.ai/webhooks/endpoints/{endpoint_id}"
headers = {
"Authorization": "Bearer " + "YOUR_THINNESTAI_API_KEY",
"Content-Type": "application/json",
}
payload = {
"url": "https://new-url.com/webhook",
"event_types": [
"agent.created",
"agent.deleted"
],
"is_active": true
}
response = requests.patch(url, headers=headers, json=payload)
print(response.json())
const response = await fetch("https://api.thinnest.ai/webhooks/endpoints/{endpoint_id}", {
method: "PATCH",
headers: {
"Authorization": "Bearer " + "YOUR_THINNESTAI_API_KEY",
"Content-Type": "application/json",
},
body: JSON.stringify({
"url": "https://new-url.com/webhook",
"event_types": [
"agent.created",
"agent.deleted"
],
"is_active": true
}),
});
const data = await response.json();
console.log(data);
package main
import (
"bytes"
"fmt"
"io"
"net/http"
)
func main() {
payload := []byte(`{
"url": "https://new-url.com/webhook",
"event_types": [
"agent.created",
"agent.deleted"
],
"is_active": true
}`)
req, _ := http.NewRequest("PATCH", "https://api.thinnest.ai/webhooks/endpoints/{endpoint_id}", bytes.NewBuffer(payload))
req.Header.Set("Authorization", "Bearer YOUR_THINNESTAI_API_KEY")
req.Header.Set("Content-Type", "application/json")
resp, err := http.DefaultClient.Do(req)
if err != nil { panic(err) }
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
}
{
"status": "success",
"endpoint_id": 1
}
Webhooks
Update Webhook Endpoint
Update an existing webhook endpoint’s configuration.
PATCH
/
webhooks
/
endpoints
/
{endpoint_id}
curl -X PATCH https://api.thinnest.ai/webhooks/endpoints/{endpoint_id} \
-H "Authorization: Bearer $THINNESTAI_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"url": "https://new-url.com/webhook",
"event_types": [
"agent.created",
"agent.deleted"
],
"is_active": true
}'
import requests
url = "https://api.thinnest.ai/webhooks/endpoints/{endpoint_id}"
headers = {
"Authorization": "Bearer " + "YOUR_THINNESTAI_API_KEY",
"Content-Type": "application/json",
}
payload = {
"url": "https://new-url.com/webhook",
"event_types": [
"agent.created",
"agent.deleted"
],
"is_active": true
}
response = requests.patch(url, headers=headers, json=payload)
print(response.json())
const response = await fetch("https://api.thinnest.ai/webhooks/endpoints/{endpoint_id}", {
method: "PATCH",
headers: {
"Authorization": "Bearer " + "YOUR_THINNESTAI_API_KEY",
"Content-Type": "application/json",
},
body: JSON.stringify({
"url": "https://new-url.com/webhook",
"event_types": [
"agent.created",
"agent.deleted"
],
"is_active": true
}),
});
const data = await response.json();
console.log(data);
package main
import (
"bytes"
"fmt"
"io"
"net/http"
)
func main() {
payload := []byte(`{
"url": "https://new-url.com/webhook",
"event_types": [
"agent.created",
"agent.deleted"
],
"is_active": true
}`)
req, _ := http.NewRequest("PATCH", "https://api.thinnest.ai/webhooks/endpoints/{endpoint_id}", bytes.NewBuffer(payload))
req.Header.Set("Authorization", "Bearer YOUR_THINNESTAI_API_KEY")
req.Header.Set("Content-Type", "application/json")
resp, err := http.DefaultClient.Do(req)
if err != nil { panic(err) }
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
}
{
"status": "success",
"endpoint_id": 1
}
curl -X PATCH https://api.thinnest.ai/webhooks/endpoints/{endpoint_id} \
-H "Authorization: Bearer $THINNESTAI_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"url": "https://new-url.com/webhook",
"event_types": [
"agent.created",
"agent.deleted"
],
"is_active": true
}'
import requests
url = "https://api.thinnest.ai/webhooks/endpoints/{endpoint_id}"
headers = {
"Authorization": "Bearer " + "YOUR_THINNESTAI_API_KEY",
"Content-Type": "application/json",
}
payload = {
"url": "https://new-url.com/webhook",
"event_types": [
"agent.created",
"agent.deleted"
],
"is_active": true
}
response = requests.patch(url, headers=headers, json=payload)
print(response.json())
const response = await fetch("https://api.thinnest.ai/webhooks/endpoints/{endpoint_id}", {
method: "PATCH",
headers: {
"Authorization": "Bearer " + "YOUR_THINNESTAI_API_KEY",
"Content-Type": "application/json",
},
body: JSON.stringify({
"url": "https://new-url.com/webhook",
"event_types": [
"agent.created",
"agent.deleted"
],
"is_active": true
}),
});
const data = await response.json();
console.log(data);
package main
import (
"bytes"
"fmt"
"io"
"net/http"
)
func main() {
payload := []byte(`{
"url": "https://new-url.com/webhook",
"event_types": [
"agent.created",
"agent.deleted"
],
"is_active": true
}`)
req, _ := http.NewRequest("PATCH", "https://api.thinnest.ai/webhooks/endpoints/{endpoint_id}", bytes.NewBuffer(payload))
req.Header.Set("Authorization", "Bearer YOUR_THINNESTAI_API_KEY")
req.Header.Set("Content-Type", "application/json")
resp, err := http.DefaultClient.Do(req)
if err != nil { panic(err) }
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
}
Path Parameters
Webhook endpoint ID
Request Body
All fields are optional — only include fields you want to change.New HTTPS URL
New list of event types
Enable/disable the endpoint
Updated description
Updated retry count (0–5)
Updated timeout
Response
{
"status": "success",
"endpoint_id": 1
}
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Body
application/json
Response
Successful Response
⌘I

