Articles on: New Web Checkout

How to Provide a Checkout Widget to Resellers / Referrer

Update Data-Config

Using this method will require you to have access to the data-config.

In your Ventrata dashboard, go to Resellers > Resellers
Select the reseller which should have access to your checkout widget.

Resellers > Resellers > Click on the desired reseller

On the Reseller detail, copy the value in the WEB REFERRERS field.

Please note: If the reseller does not contain a web referrer value, it needs to be filled in.

Web referrers value

Replace referrer in the data-config with the web referrer value.

Data-config structure: <button type="button" data-config='{"productID":"APIKEY", "referrer": "ventrataReseller"}' ventrata-checkout > Book Now </button>

You can specify the referrer value in the script or directly above the required button.

Add Reseller to Web Checkout

Use this method to provide access directly from the Ventrata dashboard.

In your Ventrata dashboard, go to Web Checkouts > Checkouts.
Select the checkout where the reseller should have access.

Web Checkout - Checkouts

Scroll down or search for 'Resellers' in the checkout form.

Reseller in Web Checkout settings

Select the required reseller.
Press the Update Checkout button.

Update Web Checkout

Dynamic Referrer Insertion Using URL

If your resellers do not have their own websites, but you want to allow them to make sales using your web checkout, you have the option to do so with the dynamic referrer parameter. The script below pulls the referrer value from the query parameter and inserts it into the script with the data-config attribute.

Therefore, if your URL contains, then the data-config attribute will contain a reference to the reseller, which is set to 'WEB REFERRERS = ventrataReseller'.

PLEASE NOTE: Insert the two scripts below one right after the other.

<script src='' type='module' data-config='{"apiKey":"<YOUR_APIKEY>"}'></script>

  function updateReferrerForScript() {
      let url = new URL(window.location.toString());
      let script = document.querySelector('script[src=""]');
      let referrerParam = decodeURIComponent(url.searchParams.get("referrer"));
      let config = JSON.parse(script.dataset.config);
      if (referrerParam) {
          config.referrer = referrerParam;
          script.dataset.config = JSON.stringify(config);


If you have set everything correctly your data-config for the script should look like this.

<script src='' type='module' data-config='{"apiKey":"<YOUR_APIKEY, "referrer": "ventrataReseller">"}'></script>

This code will change the script and the same reseller will be set on all products.

Updated on: 09/04/2024

Was this article helpful?

Share your feedback


Thank you!