Client-side API

Sometimes it's important to validate a promo code or promotion on the client-side, e.g., you want to calculate and display a discounted price on the fly. That's why Voucherify comes with client-side features build in Voucherify JS SDK - an open-source JavaScript library which enables you to query the API.

Among other features it delivers Voucherify React Widgets

React Widget

Voucherify JS SDK offers many client-side features:

  • validate widget which enables your customers to validate their codes and check its validity in a given context.
  • redeem widget which enables your customers to redeem the promo codes.
  • publish widget which enables your customers to a unique voucher from a given campaign in exchange for providing an email address.
  • subscribe widget which adds a customer to Voucherify. You can then use one of the automatic delivery channels to send him/her a coupon.
    Read more here.

Installation & reference

Visit Github repository to get the up-to-date documentation.


Domain white list

To use Voucherify client-side features you have to white-list your domain in the Client-side Settings.

Domain Settings


Enable client-side features

You have to activate particular client-side options in the Project Settings.

Client-Side Settings