It is just a matter of creating the database to store the voucher information and creating the back end to administer it.
Then you can add a recordset and filter based on voucher codes to store the information for a given voucher into session variables.
Then use those session variables in creating a discount rule or rules.