Tracking storefront events
Nucleo learns from what shoppers do on your storefront: what they search, which products they view, what they put in the cart and what they buy. An installation connects one storefront to Nucleo. It gives you a public key and a snippet to paste into your theme. For Shopify stores, server-side webhooks add carts, checkouts and orders sent by Shopify itself.
Installations live in Catalog > Settings > Search > Installations. What they send shows up in Signal, in shopper profiles and in Queries. Only Owners and Admins can manage installations.
Create an installation
Steps
- In Nucleo, go to Catalog > Settings > Search > Installations.
- Click New installation.
- In Name, type a name that says where it will live, such as the name of your store.
- In Allowed domains, list the domains the storefront runs on, one per line or separated by commas. Use lowercase hosts without a port;
*.example.comis allowed. At least one domain is required. - In Locales, select the languages the installation works in.
- Click Create.
The installation appears with its public key and its storefront snippet, ready to install.
Install the snippet on your storefront
Steps
- In Nucleo, go to Catalog > Settings > Search > Installations, and find the installation.
- In Storefront snippet, copy the code.
- In your storefront's theme, paste the code just before the closing
</body>tag, and publish the theme. - Check the installation end to end in Test events.
The line under the snippet shows the address the events are sent to. Once events arrive, the installation shows how many were stored, how many were rejected, and when it was last seen.
Change domains, languages and Web Pixel events
In Catalog > Settings > Search > Installations, each installation card has these settings:
| Setting | What it does |
|---|---|
| Products & prices | The sales channel the installation reads sellability and prices from. It's shown for information: an installation never has prices of its own. |
| Locales | The languages the installation works in. Click a language to add or remove it; changes save at once. |
| Allowed domains | Events from other domains are refused. Edit the list, and then click Save domains in the Unsaved changes bar, or Discard to undo. At least one domain is required. |
| Accept Shopify Web Pixel events | Checkout pages don't run your theme's code, so the checkout start and purchase events come from a Shopify Web Pixel. Turn this on to accept them; with it off, those two events are refused. |
Pause or resume an installation
Pausing stops an installation without removing the snippet from your theme.
Steps
- In Nucleo, go to Catalog > Settings > Search > Installations, and find the installation.
- Click Pause. The status changes to Paused: the storefront's events are refused and nothing is stored.
- To start again, click Resume. The status changes back to Active.
Rotate the public key
Rotate the key if you want to invalidate the one in your theme, for example after moving to a new storefront.
Steps
- In Nucleo, go to Catalog > Settings > Search > Installations, and find the installation.
- Next to Public key, click Rotate key.
- Click Rotate key again to confirm.
- Copy the new snippet and paste it into your theme in place of the old one.
Delete an installation
Steps
- In Nucleo, go to Catalog > Settings > Search > Installations, and find the installation.
- Click the trash icon.
- Click Delete installation to confirm.
Connect Shopify webhooks
A browser script can be blocked or closed before it sends anything. Shopify webhooks can't: Shopify sends carts, checkouts and orders from its own server, signed, as they happen. They're also what ties a visitor to a customer at checkout. The Server-side (Shopify webhooks) panel, at the bottom of the Installations tab, manages them.
Steps
- In Nucleo, go to Catalog > Settings > Search > Installations.
- In Server-side (Shopify webhooks), check that App secret shows Set and Shopify credentials shows Connected. Both are needed.
- Click Register webhooks, and then click Register to confirm.
Nucleo subscribes to the cart, checkout and order topics on your Shopify store, pointing at the Callback URL shown in the panel. Subscriptions already in place are kept, and Shopify starts sending right away. The registration runs in the background: the outcome appears in the panel within a few seconds, and the badge changes to Subscribed with how many topics point at Nucleo.
| Part of the panel | What it shows |
|---|---|
| Subscriptions on Shopify | Every webhook subscription on your store, marked Nucleo or Other app. A subscription marked Orphan · old Nucleo address points at an address Nucleo no longer uses. Remove Nucleo webhooks doesn't touch it: ask Nucleo support to remove it. |
| Received, last 7 days | What arrived per topic, when the last one arrived, and how many were processed or failed. |
To stop, click Remove Nucleo webhooks and confirm. The removal is queued and its outcome appears in the panel within a few seconds. Only the subscriptions pointing at Nucleo are removed; other apps aren't touched, and what was already received is kept.
Considerations for event tracking
- Installations collect events; they don't put Nucleo's search on your storefront. Site search isn't reachable from the storefront yet.
- If demo mode is on, a Simulated installation appears. It has no key and no snippet, and it disappears when you turn demo mode off. See Preview Signal with demo mode.
- Use a test code to check your own browsing without writing it into your real data.