Skip to main content
All CollectionsWeb CheckoutManuals
How to Provide a Checkout Widget to Resellers / Referrer
How to Provide a Checkout Widget to Resellers / Referrer

Allow resellers to sell products using your web checkout, while maintaining control over reseller permissions and tracking.

Lucia Burin Sestakova avatar
Written by Lucia Burin Sestakova
Updated this week

How it Works

Ventrata provides three methods to grant resellers access to your web checkout:

Ventrata automatically extracts the referrer value from either:

  • the data-config attribute (method 1)

  • the URL query parameter (method 3)

  • or stores the referrer value in Session Storage, see Dynamic Referrer Insertion (method 3)

Once extracted, the referrer value is stored in the Request Header (the Octo-Referrer field), allowing Ventrata to track reseller sales on the backend.

πŸ“— TIP

A request header is metadata sent from a user's browser to the server when making a request (such as loading a webpage or submitting a form).

1. Update Data-Config

This method requires access to the data-config attribute. See the Implementation Guide for more information.

How to Implement

  1. In your Ventrata dashboard, go to Resellers > Resellers.

    Resellers

  2. Select the reseller that should have access to your checkout widget.

  3. On the Reseller detail, copy the value in the 'Web referrers' field.
    ​


    πŸ“’ NOTE

    If the reseller does not contain a web referrer value, you must enter one.
    ​


    Reseller Detail - Web Referrers

  4. Modify the data-config attribute to include the reseller's referrer value:

    <button type="button" data-config='{"productID":"[YOUR_APIKEY]", "referrer": "[REFERRER_VALUE]"}' ventrata-checkout > Book Now </button>

    ​



    πŸ“’ NOTE

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


Once the referrer value is present in the data-config, Ventrata extracts it and stores it in the Request Header. For more details, read how it works.

2. Add Reseller to Web Checkout

This method allows you to assign a reseller to the checkout directly from the Ventrata dashboard. Using this method, there is no additional action required on your part.

How to Set up

  1. In your Ventrata dashboard, go to Web Checkouts > Checkouts.

  2. Select the checkout where the reseller should have access.
    ​

    Web Checkouts

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

    Reseller in Web Checkout settings

    Reseller


    πŸ“’ NOTE

    If the reseller does not contain a web referrer value, you must enter one. See step 3 of the above section.
    ​


  4. Select the required reseller.

  5. Press the Update Checkout button.
    ​

    Update Web Checkout

    Update Checkout

3. Dynamic Referrer Insertion

If your resellers do not have their own websites, you can allow them to sell using your web checkout by dynamically inserting a referrer value from the URL query parameters.

There are two ways to dynamically insert referrer on from the URL query parameters:

1. Session Storage

This method ensures that the referrer value persists after being extracted from the URL, data-config or manual insertion.

Even if the referrer is no longer present in the URL, Session Storage keeps it active for as long as the browser tab remains open.

πŸ“— TIP

A session is a temporary storage mechanism that holds user-related data while they navigate a website. Once the user closes the browser tab or quits the browser, the session storage is cleared.

2. Query Parameter from the URL

When a reseller shares a URL like:

Ventrata automatically extracts the ventrataReseller value from the URL and stores it in two locations:

  • Request Header

  • Session Storage

For more details, read how it works.


Verify Referrer Insertion

To verify that the referrer value is stored,

  1. Open the developer tools in your browser (F12 or right click anywhere on the page > select Inspect).

  2. Navigate to the Network tab.

  3. Select a resource in the 'Name' column.

  4. On the right-hand side, check the Headers tab.

  5. If necessary scroll down the page until the 'Request Headers' section.

  6. The 'Octo-Referrer' field should contain the web referrer value associated with the reseller.

    Request Headers - Octo-Referrer

Did this answer your question?