Discount history and audit on Vareons
Discount history shows at /dashboard/discounts/[id]/history the coupon change timeline from Coupon.data.audit.changeHistory, plus create, update, status-change, and delete events reflected on /dashboard/activity.
Last verified: 2026-09-19
History opens from the discount row via View History or directly at /dashboard/discounts/[id]/history, showing who changed what and when: name, code, type, value, dates, limits, and the Draft, Active, Paused, Archived, and Expired lifecycle states.
Every POST create, PUT update, PATCH status change, and DELETE records audit.createdBy and audit.changeHistory[], while deny-paths block direct edits to audit, analytics, and redemptions. Events also emit as discount ActivityEvent rows via buildDiscountActivityEmitParts, appearing on /dashboard/activity with links to /dashboard/discounts.
Use history to troubleshoot: why a code suddenly stopped, who activated a promotion before a campaign, whether auto-expire or a manual pause ended it, and what the previous value was before an edit.
Setup steps in Vareons
Open the coupon history
From /dashboard/discounts click View History on the row or open /dashboard/discounts/[id]/history.
Review the timeline
Read changeHistory newest-first: changed field, before/after values, actor, and timestamp.
Cross-check the activity feed
Open /dashboard/activity and review discount created, updated, and status events for the same context.
Pinpoint the stop cause
Distinguish auto-expire expiry from manual Pause, Delete, and Eligibility rule changes.
Fix and reactivate
Edit from /dashboard/discounts/[id]/edit, then Activate via PATCH status and retest checkout with the same code.
Frequently asked questions
Where do I find discount change history?
At /dashboard/discounts/[id]/history via View History; the source is Coupon.data.audit.changeHistory.
Does discount history appear in activity?
Yes. Create, update, and delete events emit as ActivityEvent rows visible on /dashboard/activity.
How do I know who stopped a promotion?
Look in changeHistory for the status event to Paused or Archived with audit.createdBy and timestamp.
Does history keep previous values?
Yes. It shows the field with before and after values for comparison and rollback.
Are old orders affected by editing a discount?
No. Edits affect future orders only; saved orders keep their original data.discounts[] lines.
Troubleshooting
1) If history is empty, confirm you opened the correct [id] and that the coupon was created through the official POST that records audit. 2) For an unexpected stop, look for an auto-expire event versus a manual Pause. 3) If a delete event is missing, check /dashboard/activity because deletes also emit there. 4) To roll back, copy the previous value from history into /dashboard/discounts/[id]/edit and save.
Important limitations
• History shows coupon changes; it does not rewrite old orders. • The audit, analytics, and redemptions fields are protected from direct edits. • Deleting removes the coupon but past orders stay unchanged.