Delete a coupon
DELETE
https://api-v2.test.eldowallet.fr/coupons/:id/passes/:instanceId
Permanently deletes a sent coupon. On a multiple-instance template, this call deletes the whole template and all its coupons (see below).
Good to know
- On a multiple-instance template (
isMultipleInstance: true), this call deletes the whole template: every coupon sent from it and the template itself; the response is then the deleted template. On a single-instance template, only the targeted coupon is deleted and returned. Deletion is permanent.
Request
path parameters
idstring requiredCoupon template ID.instanceIdstring requiredInstance ID of the coupon to delete (the client ID for a single-instance template).
header parameters
x-langstringLanguage for responsesenum:en,frdefault:"en"
Responses
- 200
- 401
- 403
- 404
- 500
- 503
Schema
application/jsonUNAUTHORIZED
Schema
application/jsonmessagestring requiredexample:Promo code already existserrorCodestring requiredexample:400:PROMO_CODE_ALREADY_EXISTSpathstring requiredexample:/couponsdatestring <date-time> requireddetailsobjectvalidationErrorsobject[]fieldstringexample:emailmessagestringexample:email must be an email
FORBIDDEN
Schema
application/jsonmessagestring requiredexample:Promo code already existserrorCodestring requiredexample:400:PROMO_CODE_ALREADY_EXISTSpathstring requiredexample:/couponsdatestring <date-time> requireddetailsobjectvalidationErrorsobject[]fieldstringexample:emailmessagestringexample:email must be an email
COUPON_TEMPLATE_NOT_FOUND · MODEL_NOT_FOUND
Schema
application/jsonmessagestring requiredexample:Promo code already existserrorCodestring requiredexample:400:PROMO_CODE_ALREADY_EXISTSpathstring requiredexample:/couponsdatestring <date-time> requireddetailsobjectvalidationErrorsobject[]fieldstringexample:emailmessagestringexample:email must be an email
UNKNOWN_ERROR
Schema
application/jsonmessagestring requiredexample:Promo code already existserrorCodestring requiredexample:400:PROMO_CODE_ALREADY_EXISTSpathstring requiredexample:/couponsdatestring <date-time> requireddetailsobjectvalidationErrorsobject[]fieldstringexample:emailmessagestringexample:email must be an email
PASS_BUILDER_ERROR
Schema
application/jsonmessagestring requiredexample:Promo code already existserrorCodestring requiredexample:400:PROMO_CODE_ALREADY_EXISTSpathstring requiredexample:/couponsdatestring <date-time> requireddetailsobjectvalidationErrorsobject[]fieldstringexample:emailmessagestringexample:email must be an email