🚨

Critical Security Migration

The luigisbox.com domain is compromised. Immediate action is required.

1. Update API Base URLs

Replace the base URL for all API requests (Search, Recommendations, Analytics):

https://live.luigisbox.com
➡️ https://live.luigisbox.tech

2. Replace Frontend Script

The .com script is no longer safe. Replace it with the secure version immediately:

[OLD - Delete from site]
<script async src="https://scripts.luigisbox.com/LBX-123.js"></script>
[NEW - Secure Version]
<script async src="https://scripts.luigisbox.tech/LBX-123.js"></script>

3. Update CSP & Firewalls

If you use a Content Security Policy, whitelist the new domain to prevent the browser from blocking the connection.

script-src https://scripts.luigisbox.tech;
connect-src https://live.luigisbox.tech;
⚠️
Emergency Action: If you cannot update the code right now, remove the existing Luigi's Box script until the migration is complete to prevent unauthorized code execution.

Support: support@luigisbox.net MODIFIED: 12/17/2025

Single page applications (SPAs)

You are reading about requirements for the integration done by the Luigi's Box team. You can safely skip this part of the documentation if you are integrating yourself using either API or Luigi's Box frontend libraries.

If your website is written as a Single page application you need to take an extra step to make it compatible with Luigi's Box integration via the LBX script.

How to know if your website is a Single page application?

  • It is written in React
  • It is written in Vue.js
  • It is written in Angular

To be 100% sure, consult your developers to confirm.

Page load events

The SPAs are avoiding a regular page loading mechanism by design. If you navigate the website, e.g. click into a category listing or view a product detail, the browser is not reloading the page, instead the page loading is handled by the application.

To notify Luigi's Box that a page has been loaded, emit a JavaScript event called lbx:page:load. You can use the sample code below.

const event = new Event("lbx:page:load");
document.dispatchEvent(event);

You have to emit this event for every page "load" where the contens of the page change.

You only have to do this if your website is written as a Single page application.