A workspace can require a second person to approve every broadcast before it is queued. The campaign is frozen at the moment of the request. It cannot be sent from the waiting state.
Settings
GET /api/practices/{id}/approval-settings returns:
{ "required": true, "approver_email": "freigabe@example.com", "ttl_hours": 72 }
PUT the same shape to change it. When required is true, approver_email
must be set. ttl_hours is between 1 and 720. locale is de, en or empty
for the workspace default. The approver must be a different mailbox than the
creator.
Per-list overrides
A list can override the workspace policy:
GET /api/practices/{id}/approval-overridesGET|PUT|DELETE /api/practices/{id}/approval-overrides/{listID}
An override replaces required, approver, TTL and locale for campaigns sent to that list. Deleting it falls back to the workspace policy.
Flow
- The creator starts or schedules a campaign.
- Werkmail sets the campaign to
pending_approvaland stores a SHA-256 of subject, text, HTML and From. - The approver receives a mail with the campaign name, subject, recipient count, expiry in Europe/Vienna time and a link to the confirmation page.
- The page has two POST actions: approve and reject. A GET never decides.
- Approve rechecks the content hash, then queues the campaign. Reject sets
rejectedand the campaign is never sent. - If the content changed after the request, approval is refused and a new request is required.
- The creator gets a transactional decision mail with the result, the approver and the rejection reason. It goes only to the stored creator.
- In the last quarter of the lifetime, and at most 24 hours before expiry, the approver gets a reminder with a fresh link. The old link stops working when the token is rotated. A 2-hour request is reminded after 1.5 hours, not immediately.
The token is random, single use, stored only as a hash, and expires after the configured TTL. A second click or a second approver cannot send twice.
An expired request never sends. The campaign stays in pending_approval.
Start a new approval request, or create a new campaign, after the expiry.
Settings require settings.edit. The public approve and reject routes accept
only the token. A missing, expired or already used token returns 400.
API
GET /api/practices/{id}/broadcasts/{campaignID}/approvalreturns the pending request or{"status":"none"}.GET /api/practices/{id}/broadcasts/{campaignID}/approvalsreturns the full history.POST /api/practices/{id}/broadcasts/{campaignID}/approval/resendrotates the token and sends the link again. An expired request is replaced.POST /api/public/approvals/{token}/approveapproves.POST /api/public/approvals/{token}/rejectrejects, with optional{"reason":"..."}.GET /approval/{token}is the human confirmation page.
Webhooks
campaign.approval_requestedcampaign.approvedcampaign.rejected
Each payload carries campaign_id, campaign_name, subject, approval_id,
approver_email, requested_by, recipient_count, status and reason.
Safety rules
- The creator and the approver must be different mailboxes. The API rejects the same address when the creator is known.
- No approver or an expired request means the campaign stays unsent.
- Rejection is terminal. The creator must create a new campaign or a new approval request.
- The approval mail is transactional and does not count against marketing frequency caps.
- The creator gets the decision by transactional mail and the workspace gets the webhook.