post
https://api.vcita.biz/v2/coupons
Overview
Creates a new coupon for the business. Available for Staff tokens.
Coupon Code
If the code field is left blank, a random alphanumeric code will be auto-generated. Coupon codes must be between 5 and 15 characters long and may only contain letters, numbers, and underscores.
Validation Rules
nameis required and must be unique among active coupons.coupon_typeis required and must be eitherfixedorpercent.amountis required and must be a non-negative number.starts_atis required. The date and time when the coupon becomes active.expires_atis required. Must be a future date and must be at least 6 hours later thanstarts_at.codemust be unique among active coupons (if provided).- For
percenttype coupons,amountrepresents the percentage discount (e.g., 50 means 50% off). - For
fixedtype coupons,amountrepresents the fixed monetary discount in the business currency.
