Delete an email campaign
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.
Pass the API token in the Api-Token header
Unique identifier of the email campaign
4567The email campaign was deleted. No response body.
No content
Authentication failed — missing or invalid API token.
The API token does not have permission to access this resource.
The requested email campaign was not found.
The request was rejected due to validation errors.
Too many requests. The public API is rate limited to 150 requests per 10 seconds per
API token. Retry after the window resets (see the x-ratelimit-reset header).
curl -X DELETE "https://mailtrap.io/api/email_campaigns/4567" \
-H 'Api-Token: YOUR_API_KEY'
No content
Last updated
Was this helpful?

