From 0966d64c0a55401d22cca3b1f1d8650cd969fa08 Mon Sep 17 00:00:00 2001 From: Maciej Walusiak Date: Thu, 13 Aug 2026 10:02:55 +0200 Subject: [PATCH] MT-22401: correct the campaign delete precondition to draft-only Decisions: - The backend allows deleting only a campaign in the draft state, not merely a non-sending one, so the previous wording understated the constraint - Mirror the update operation's phrasing, which already documents the same rule - Point at cancel/reset as the way back to draft from scheduled; a started campaign has no path back and can no longer be deleted --- specs/email-campaigns.openapi.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/specs/email-campaigns.openapi.yml b/specs/email-campaigns.openapi.yml index c8fa698..0f26dc5 100644 --- a/specs/email-campaigns.openapi.yml +++ b/specs/email-campaigns.openapi.yml @@ -190,8 +190,12 @@ paths: operationId: deleteEmailCampaign summary: Delete an email campaign description: |- - Soft-deletes an email campaign. The campaign must not be in a sending state. - Returns `204 No Content` on success. + Soft-deletes an email campaign. Returns `204 No Content` on success. + + Only `draft` campaigns can be deleted — deleting a campaign that is already + scheduled/sending returns `422`. A campaign that has been started never returns to + `draft`, so it can no longer be deleted. A `scheduled` campaign can be returned to + `draft` first via the `cancel` or `reset` action endpoints. tags: - Email Campaigns parameters: