Delete AI Prompt-Decorator Preset
Endpoint
DELETE /apiops/settings/ai-prompt-decorator-presets/{presetName}/
Authentication
Requires a Personal API Access Token with admin privileges.
Header
Authorization: Bearer YOUR_TOKEN
Request
Headers
| Header | Value | Required |
|---|---|---|
| Authorization | Bearer {token} | Yes |
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| presetName | string | Yes | Name of the preset to delete (case-insensitive) |
Query Parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| projectId | string | No | admin | Scope the preset lives in. Omit for the admin/global scope. |
Response
Success Response (200 OK)
{
"status": "SUCCESS"
}
Error Response (400 Bad Request)
Returned when the name is empty, no preset with that name is visible in the scope, the target is a built-in preset, or the caller lacks the ADMIN role.
{
"status": "FAILURE",
"resultMessage": "Built-in presets cannot be deleted"
}
Error Response (401 Unauthorized)
{
"status": "FAILURE",
"resultMessage": "Token is not valid!"
}
cURL Example
curl -X DELETE \
"https://demo.apinizer.com/apiops/settings/ai-prompt-decorator-presets/support-tone/" \
-H "Authorization: Bearer YOUR_TOKEN"
Notes and Warnings
- Built-in Presets:
- Seeded rows (
builtIn: true) cannot be deleted — the call is rejected rather than silently ignored
- Seeded rows (
- Bound Blocks Are Localized, Not Broken:
- Blocks bound to this preset are detached (localized) as part of the delete: each keeps its current position, role and content and goes on working. No block is removed from any policy and no redeploy is required — only the catalog link is dropped.
- Admin Only:
- A project-scoped
AI_DEVELOPMENTtoken is not sufficient on this surface; use the project endpoint to delete a preset the project owns
- A project-scoped
Related Documentation
- List AI Prompt-Decorator Presets - List all presets
- Create AI Prompt-Decorator Preset - Create or upsert a preset
- AI Prompt-Decorator Presets API - Resource overview