Delete a notification rule
DELETE /v1/notification-rules/{notification_rule_id}
Property Value Operation delete_notification_ruleGroup Notification rules Scope messages:writeRoute class controlIdempotency No Idempotency-Key Audit Audited channels.notification_rule.delete (mutation) Released in 1.60.0 Phase 0 host Served (the hosted api pins 1.65.0)
Request
Set VOCAL_API to the base URL of your API and VOCAL_API_KEY to an API key with the messages:write scope (Authentication and keys ). Replace each placeholder, such as agt_... or <name>, with your own value.
cURL Node.js Python
curl -X DELETE "$VOCAL_API/v1/notification-rules/ntr_..." \
-H "Authorization: Bearer $VOCAL_API_KEY" \
-H 'If-Match: "1"'const response = await fetch(`${process.env.VOCAL_API}/v1/notification-rules/ntr_...`, {
method: 'DELETE',
headers: {
Authorization: `Bearer ${process.env.VOCAL_API_KEY}`,
'If-Match': '"1"',
},
});
console.log(response.status, await response.text());import os
import requests
response = requests.delete(
f"{os.environ['VOCAL_API']}/v1/notification-rules/ntr_...",
headers={
"Authorization": f"Bearer {os.environ['VOCAL_API_KEY']}",
"If-Match": '"1"',
},
)
print(response.status_code, response.text)
Parameters
Name In Type Required Description notification_rule_idpath NotificationRuleId yes The id of a notification rule: ntr_ and the row's UUIDv7 in 26 Crockford base32 characters. Opaque and safe to log. if-matchheader string yes The revision the change was made against, quoted as the ETag returns it, or * to overwrite.
Responses
Fields of the 200 answer
The shape is NotificationRuleDeletion .