This page documents the canonical HTTP contract for this endpoint.
Soft-deletes the template by setting is_archived: true. Archived templates are excluded from list results.
Authorization: you can delete templates you created (scope user) or any team template in your organization (scope team).
Path parameters
template_idrequiredstring
The prompt template ID to delete.
| Name | Type | Description |
|---|---|---|
| template_idrequired | string | The prompt template ID to delete. |
Errors
| Status | Meaning |
|---|---|
| 401 | Invalid API key or missing auth. |
| 403 | Missing prompts:write scope or not authorized to delete this template. |
| 400 | The template_id is not a valid ObjectId. |
| 404 | Prompt template not found or already archived. |
