Update a webhook
curl --request PATCH \
--url https://app.tikk.chat/api/v1/webhooks/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"active": true
}'const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({active: true})
};
fetch('https://app.tikk.chat/api/v1/webhooks/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.tikk.chat/api/v1/webhooks/{id}"
payload = { "active": True }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.tikk.chat/api/v1/webhooks/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'active' => true
]),
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;
}{
"data": {
"id": 1830219341,
"url": "https://yourapp.com/tikk/webhooks",
"events": [
"booking.requested"
],
"status": "active",
"disabled_reason": "manual",
"consecutive_failures": 0,
"signing_secret_source": "subscription",
"last_success_at": "2023-11-07T05:31:56Z",
"last_failure_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"signing_secret": "tikk_whsec_4f8Kd02LmQx7Rz1VbN6cT9yHs3Ue5Wa"
}
}Webhooks
Update a webhook
Changes the URL or events, or switches the webhook off and on. Switching on a webhook that was switched off after failed deliveries also clears its failure count.
Scopes: webhooks.write and bookings.read · Plan: Pro
PATCH
/
webhooks
/
{id}
Update a webhook
curl --request PATCH \
--url https://app.tikk.chat/api/v1/webhooks/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"active": true
}'const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({active: true})
};
fetch('https://app.tikk.chat/api/v1/webhooks/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.tikk.chat/api/v1/webhooks/{id}"
payload = { "active": True }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.tikk.chat/api/v1/webhooks/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'active' => true
]),
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;
}{
"data": {
"id": 1830219341,
"url": "https://yourapp.com/tikk/webhooks",
"events": [
"booking.requested"
],
"status": "active",
"disabled_reason": "manual",
"consecutive_failures": 0,
"signing_secret_source": "subscription",
"last_success_at": "2023-11-07T05:31:56Z",
"last_failure_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"signing_secret": "tikk_whsec_4f8Kd02LmQx7Rz1VbN6cT9yHs3Ue5Wa"
}
}Authorizations
An API key from Settings → API Keys (starts with tikk_sk_), or an
OAuth access token for a partner app. Both carry scopes; each endpoint
lists the one it needs.
Path Parameters
The webhook id, as returned by POST /webhooks.
Body
application/json
Maximum string length:
2048Minimum array length:
1Available options:
booking.requested, booking.confirmed, booking.declined, booking.cancelled, booking.rescheduled false switches the webhook off; true switches it back on and clears its failure count.
Response
The updated webhook.
Show child attributes
Show child attributes