During the Create flow, a voucher that has been started but not validated can be deleted simply by abandoning the create flow. Once the Voucher has been validated and submitted to the server, additional steps must be taken.

To delete a validated Voucher, use the deleteVoucherWithId:onCompletion: method available in our VOVoucherManager interface. An example can be seen below.

[self.voucherManager deleteVoucherWithId:self.voucher.voucherId onCompletion:^(NSError * _Nullable error) {
    if (error) {
        //handle error
    } else {
        //voucher successfully deleted
    }
}];
voucherManager.deleteVoucher(withId: voucher.voucherId, onCompletion: { error in
    if error != nil {
        //handle error
    } else {
        //voucher successfully deleted
    }
})