Checkout

Check out button.

You can integrate Checkout in as little as a single line of client-side code. As we release new Havanao features, we'll automatically roll them out to your existing Checkout integration, so that you will always be using our latest technology without needing to change a thing.

Simple: The simple integration provides a green Pay with mobile with Card button as shown above. Upon completion of the payment form and receipt of the token, Checkout stores the token within a hidden input in your payment form and automatically submits the form for server-side use. The simple integration uses a script tag inside your payment form to render the blue Checkout button. Upon completion of the Checkout process, Checkout will submit your form to your server, passing along a stripeToken as well as any elements your form contains.

     <form method="GET" class="havanao-form" name="havanaoForm" action="/">
          <script src="https://api.havanao.com/js/checkout.js" class="havanao-button"
          data-key="okwyZ55iNRhYbxg6dkdEWrtpFX9V8ezPMfC7Fw3ZKrEXpm5bGQ1aKynHfwa5"
          data-image="http://www.wpclipart.com/buildings/shop.png"
          data-name="My shop"
          data-description="Testing havanao checkout form."
          data-amount="100">
          </script>
    </form>

Above code generates below button, click and see how it goes

We've placed a random API key in the code. Replace it with your actual publishable API key to test this code through your Havano account.

The above code will build a green button on your webpage, PAYMENT BUTTON and once that green payment form is clicked on, below popup will show up on your web page the user can process the payment.

PAYMENT FORM

Note: Checkout must be loaded directly from https://api.havanao.com/js/checkout.js. Using a local copy of Checkout is unsupported, and may result in user-visible errors.

How do you know if someone has done a payment ?

When check out has been confirmed, and the client has allowed the money to debited from his account, then checkout will add the auto generated transaction id and attach it to the form then it submit it automatically with the generated transaction id.

We advise to use Purchase status API by providing the auto generated transactionid in your backend to confirm that the status of the transaction.