<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Blogs]]></title><description><![CDATA[Blogs]]></description><link>https://unfoldcro.hashnode.dev</link><generator>RSS for Node</generator><lastBuildDate>Thu, 26 Nov 2026 11:53:06 GMT</lastBuildDate><atom:link href="https://unfoldcro.hashnode.dev/rss.xml" rel="self" type="application/rss+xml"/><language><![CDATA[en]]></language><ttl>60</ttl><item><title><![CDATA[Debugging Missing Meta Purchase Events: A Developer's Checklist]]></title><description><![CDATA[A developer's checklist for missing Meta Purchase events: reproduce with Test Events, check the confirmation page, redirects, consent]]></description><link>https://unfoldcro.hashnode.dev/debugging-missing-meta-purchase-events-a-developer-s-checklist</link><guid isPermaLink="true">https://unfoldcro.hashnode.dev/debugging-missing-meta-purchase-events-a-developer-s-checklist</guid><category><![CDATA[debugging]]></category><category><![CDATA[Meta]]></category><category><![CDATA[analytics]]></category><category><![CDATA[JavaScript]]></category><category><![CDATA[shopify]]></category><dc:creator><![CDATA[UnfoldCRO]]></dc:creator><pubDate>Wed, 25 Nov 2026 11:53:39 GMT</pubDate><content:encoded><![CDATA[<p>"Meta shows add-to-carts but almost no purchases" is one of the most common tracking tickets on ecommerce sites. It's rarely random. There are five usual causes, and each leaves a trace.</p>
<h2>Reproduce first</h2>
<p>Open <strong>Test Events</strong> in Events Manager and place a real order. The result tells you where to look:</p>
<ul>
<li><strong>Nothing arrives:</strong> the event isn't being sent.</li>
<li><strong>Browser only:</strong> there's no server-side path.</li>
<li><strong>Arrives, then filtered:</strong> the problem is further down the line.</li>
</ul>
<h2>Cause 1: the Pixel never fires on the confirmation page</h2>
<p>On single-page apps, a client-side route change can skip the code that fires <code>Purchase</code>. Elsewhere, the confirmation template doesn't include it, or an earlier JS error halts execution.</p>
<p><strong>Check:</strong> open DevTools on the confirmation page, look in the Network tab for the outbound request to Meta, and check the Console for errors before it.</p>
<h2>Cause 2: the checkout redirects off-domain</h2>
<p>If payment happens on a third-party page, the browser completing the transaction is on a page you don't control. On standard Shopify checkout you can't freely add scripts to the payment step. A thank-you page Pixel helps only partly, because return journeys from payment providers are inconsistent.</p>
<h2>Cause 3: consent and blockers</h2>
<p>A consent banner holds the Pixel until the shopper agrees. Ad blockers drop the request entirely. Both are browser-side, so front-end fixes can't fully remove them.</p>
<p><strong>Check:</strong> repeat the test order with consent declined, then again with a blocker on, to measure the browser-side loss.</p>
<h2>Cause 4: deduplication discarding good events</h2>
<p>When Purchase goes out from browser and server, Meta removes duplicates that share <code>event_name</code> and <code>event_id</code>. A mismatched name, IDs generated separately on each side, or a server event with no ID can drop events or count them inconsistently.</p>
<p><strong>Check:</strong> both events carry one identical <code>event_id</code> and <code>event_name</code>.</p>
<h2>Cause 5: validation failures</h2>
<p>A Purchase without <code>value</code> and <code>currency</code>, malformed parameters, or customer data that isn't hashed and normalised correctly can be rejected. The <strong>Issues</strong> tab in Events Manager flags these.</p>
<h2>The durable fix</h2>
<p>Four of the five causes are browser problems. So send <code>Purchase</code> from the server through the Conversions API when the order is created. It doesn't depend on the confirmation page loading, survives the payment redirect, and isn't blocked by ad blockers.</p>
<p>Pair it with the browser event rather than replacing it, using a shared <code>event_id</code> so the two deduplicate cleanly.</p>
<p>How much it recovers depends on how much of your loss is browser-side, so measure your own gap before and after rather than trusting a promised number.</p>
<p>Each cause in more depth: <a href="https://unfoldcro.com/blog/why-meta-purchases-go-missing-in-events-manager">why Meta purchases go missing in Events Manager</a></p>
]]></content:encoded></item><item><title><![CDATA[Designing an Odoo ↔ Shopify Integration: Data Flow First, Code Second]]></title><description><![CDATA[Plan an Odoo and Shopify integration before writing code: which objects sync, which way each flows, connector vs middleware vs custom API]]></description><link>https://unfoldcro.hashnode.dev/designing-an-odoo-shopify-integration-data-flow-first-code-second</link><guid isPermaLink="true">https://unfoldcro.hashnode.dev/designing-an-odoo-shopify-integration-data-flow-first-code-second</guid><category><![CDATA[Odoo]]></category><category><![CDATA[shopify]]></category><category><![CDATA[api]]></category><category><![CDATA[integration]]></category><category><![CDATA[ERP]]></category><dc:creator><![CDATA[UnfoldCRO]]></dc:creator><pubDate>Wed, 25 Nov 2026 11:46:58 GMT</pubDate><content:encoded><![CDATA[<p>Most broken Odoo–Shopify integrations weren't badly coded. They were badly planned. Nobody decided which system owns which data, so both systems edit the same records and overwrite each other.</p>
<p>Here's the planning step that prevents most of that, plus the build options.</p>
<h2>Step 1: list the objects</h2>
<p>An Odoo–Shopify integration usually syncs five things:</p>
<ul>
<li><strong>Products and variants:</strong> titles, SKUs, barcodes, prices, images</li>
<li><strong>Inventory:</strong> stock per SKU, ideally per location (the most time-sensitive object)</li>
<li><strong>Orders:</strong> Shopify orders become Odoo sales orders, with line items, discounts, shipping and tax</li>
<li><strong>Customers:</strong> contacts and addresses, deduplicated</li>
<li><strong>Fulfilment and accounting:</strong> tracking back to Shopify; invoices, payments and credit notes in Odoo</li>
</ul>
<h2>Step 2: give every object one direction</h2>
<table>
<thead>
<tr>
<th>Object</th>
<th>Direction</th>
</tr>
</thead>
<tbody><tr>
<td>Catalogue</td>
<td>Odoo → Shopify</td>
</tr>
<tr>
<td>Inventory</td>
<td>Odoo → Shopify</td>
</tr>
<tr>
<td>Orders</td>
<td>Shopify → Odoo</td>
</tr>
<tr>
<td>Fulfilment status</td>
<td>Odoo → Shopify</td>
</tr>
</tbody></table>
<p>One system is the master for each object, and changes flow one way. Get operations and finance to sign this off before anyone writes code.</p>
<h2>Step 3: pick the approach</h2>
<p><strong>Native connector.</strong> Odoo has a built-in Shopify connector, and there are third-party ones in the Odoo app store. Fastest and cheapest to start. Fine for a simple catalogue, one warehouse and standard tax. Limited control when your rules don't match its assumptions.</p>
<p><strong>Middleware.</strong> Sits between the two, maps fields visually, and adds retries, error logs and queues so failures don't vanish silently. A recurring cost and another vendor.</p>
<p><strong>Custom API integration.</strong> Shopify's Admin API and webhooks on one side, Odoo's external API over XML-RPC or JSON-RPC on the other. The most work to own, but often the only thing that holds up with bundles, kits, multi-location stock or marketplace sales. Treat it as a product: version control, a staging store, monitoring.</p>
<h2>Where it breaks in production</h2>
<ul>
<li><strong>SKU mismatches.</strong> A missing SKU or a case/whitespace difference means records silently fail to match. Reconcile SKUs first and make SKU the key.</li>
<li><strong>Inventory race conditions.</strong> If stock syncs every few minutes, two orders can both buy the last unit. Use real-time webhooks for stock decrements, pick one authoritative stock source, and keep a buffer for fast movers.</li>
<li><strong>GST invoicing (India).</strong> HSN codes, CGST/SGST/IGST splits by ship-to state, sequential invoice numbers. Shopify tax fields rarely map cleanly to Odoo's tax engine, so map and test it explicitly.</li>
<li><strong>Partial refunds.</strong> A refund should create a credit note and restock where relevant. Partials are where most integrations quietly break.</li>
<li><strong>Multiple warehouses.</strong> Inventory and fulfilment must be location-aware on both sides.</li>
</ul>
<h2>Rollout</h2>
<ol>
<li>Map objects and directions, and get sign-off.</li>
<li>Clean SKUs and customers in both systems.</li>
<li>Build on a staging Shopify store and an Odoo test database.</li>
<li>Pilot with a few SKUs and real orders, and watch the error logs daily.</li>
<li>Add alerts so a broken sync reaches a human.</li>
<li>Document the mapping and recovery steps.</li>
</ol>
<p>Full guide: <a href="https://unfoldcro.com/blog/odoo-and-shopify-integration-practical-guide">Odoo and Shopify integration</a></p>
]]></content:encoded></item><item><title><![CDATA[Building a Sticky Add to Cart Bar in a Shopify Theme Without an App]]></title><description><![CDATA[Build a lightweight sticky add to cart bar in a Shopify Online Store 2.0 theme with Liquid and IntersectionObserver, plus variant handling.]]></description><link>https://unfoldcro.hashnode.dev/building-a-sticky-add-to-cart-bar-in-a-shopify-theme-without-an-app</link><guid isPermaLink="true">https://unfoldcro.hashnode.dev/building-a-sticky-add-to-cart-bar-in-a-shopify-theme-without-an-app</guid><category><![CDATA[shopify]]></category><category><![CDATA[liquid]]></category><category><![CDATA[JavaScript]]></category><category><![CDATA[webdev]]></category><category><![CDATA[ecommerce]]></category><dc:creator><![CDATA[UnfoldCRO]]></dc:creator><pubDate>Tue, 24 Nov 2026 12:40:48 GMT</pubDate><content:encoded><![CDATA[<p>A sticky add to cart bar keeps the price and buy button visible while a shopper scrolls a long product page. It's a common request, and it's often solved with an app. You usually don't need one.</p>
<p>On an Online Store 2.0 theme, the bar can be a small section. The core idea: watch the main add to cart button, and show the bar only when that button is off screen.</p>
<h2>The minimal version</h2>
<pre><code class="language-liquid">&lt;div class="sticky-atc" data-sticky-atc hidden&gt;
  &lt;span class="sticky-atc__title"&gt;{{ product.title }}&lt;/span&gt;
  &lt;span class="sticky-atc__price"&gt;{{ product.price | money }}&lt;/span&gt;
  &lt;button form="product-form-{{ section.id }}" type="submit"&gt;Add to cart&lt;/button&gt;
&lt;/div&gt;

&lt;script&gt;
  const bar = document.querySelector('[data-sticky-atc]');
  const main = document.querySelector('.product-form__buttons');
  new IntersectionObserver(function (entries) {
    bar.hidden = entries[0].isIntersecting;
  }).observe(main);
&lt;/script&gt;
</code></pre>
<p>Two details make this work:</p>
<ul>
<li><strong>The button uses the</strong> <code>form</code> <strong>attribute</strong> to submit the existing product form, so you're not duplicating cart logic.</li>
<li><code>IntersectionObserver</code> hides the bar whenever the main button is visible, so the two never show at once.</li>
</ul>
<p>The selectors depend on your theme. Check your product form's ID and button wrapper class before you drop this in.</p>
<h2>Keep it light</h2>
<p>The point of building it in the theme is speed. An extra app script on the product page can cost you more in performance than the bar earns in conversions. Measure Core Web Vitals before and after either way.</p>
<p>Also check that the bar doesn't cover sticky navigation or a cookie notice.</p>
<h2>Handling variants</h2>
<p>This is where most implementations go wrong. If a shopper hasn't chosen a size or colour, the bar can't just add to cart. Two clean options:</p>
<ol>
<li>Include a compact variant picker in the bar itself.</li>
<li>Have the bar scroll the shopper back to the main selector when a variant is still required.</li>
</ol>
<p>Never let the bar silently add a default variant the shopper didn't pick. It turns into returns and support tickets.</p>
<h2>What to put in it</h2>
<p>Title, price, one button, and a variant picker only if needed. Leave out descriptions, extra buttons and countdown timers. On mobile, keep it to one row with the button as the largest tap target.</p>
<h2>Test before you trust it</h2>
<p>Split traffic evenly between the current page and the page with the bar, and measure the whole funnel: add to cart, then checkout, then purchase, then returns. Segment by device. The bar usually helps on mobile and long pages and does little on short desktop pages, and a blended number can hide that.</p>
<p>More on when it helps and when it doesn't: <a href="https://unfoldcro.com/blog/sticky-add-to-cart-does-it-actually-increase-conversions-data-inside">does a sticky add to cart bar increase conversions?</a></p>
]]></content:encoded></item><item><title><![CDATA[One event_id, Two Signals: Deduplicating Meta Pixel and Conversions API Events]]></title><description><![CDATA[How to deduplicate Meta Pixel and Conversions API events with one shared event_id: where to generate it, the bugs that break matching.]]></description><link>https://unfoldcro.hashnode.dev/one-event-id-two-signals-deduplicating-meta-pixel-and-conversions-api-events</link><guid isPermaLink="true">https://unfoldcro.hashnode.dev/one-event-id-two-signals-deduplicating-meta-pixel-and-conversions-api-events</guid><category><![CDATA[JavaScript]]></category><category><![CDATA[analytics]]></category><category><![CDATA[Meta]]></category><category><![CDATA[tracking]]></category><category><![CDATA[ecommerce]]></category><dc:creator><![CDATA[UnfoldCRO]]></dc:creator><pubDate>Tue, 24 Nov 2026 12:35:56 GMT</pubDate><content:encoded><![CDATA[<p>If you send the same Purchase from both the Meta Pixel (browser) and the Conversions API (server), Meta needs a way to know they're the same action. Otherwise every order counts twice.</p>
<p>The mechanism is simple. Meta compares two fields across the browser and server events:</p>
<ul>
<li><code>event_name</code>: must be identical. <code>Purchase</code> and <code>purchase</code> are different events.</li>
<li><code>event_id</code>: a unique ID for that single occurrence. Same value on both sides means one action.</li>
</ul>
<p>When both match, Meta keeps one event and drops the other.</p>
<h2>The bug almost everyone ships first</h2>
<p>The most common mistake is generating the ID in two places:</p>
<ul>
<li>the browser creates its own ID when the Pixel fires</li>
<li>the server creates its own ID when it posts to the Conversions API</li>
</ul>
<p>Two independently generated values never match. No deduplication happens, and every event is counted twice.</p>
<h2>Generate once, pass everywhere</h2>
<p>The correct pattern is to create one value at the moment the event happens and make it available to both paths:</p>
<ol>
<li>Create a unique value when the order is confirmed.</li>
<li>Pass it to the Pixel as the event's ID.</li>
<li>Send the same value in the <code>event_id</code> field of the server event.</li>
<li>Keep <code>event_name</code> identical on both sides.</li>
</ol>
<p>Illustratively, the browser side looks like this:</p>
<pre><code class="language-js">// orderEventId is generated once per order and also sent to your server
fbq('track', 'Purchase',
  { value: orderTotal, currency: 'INR' },
  { eventID: orderEventId }
);
</code></pre>
<p>And the server event carries the same value in its <code>event_id</code> field. The exact code depends on your stack. What matters is that it's the same value, created once.</p>
<h2>Three more ways matching breaks</h2>
<p><strong>Per-render IDs.</strong> If the ID is generated on every page render instead of per event occurrence, a reload or a retry produces a new value and the match fails.</p>
<p><strong>Missing</strong> <code>event_id</code> <strong>on the server.</strong> Meta can sometimes fall back to the <code>fbp</code> browser cookie, but that's much weaker. A server event without an ID is a quiet cause of inflated conversion counts.</p>
<p><strong>Timing gaps.</strong> Meta only compares events within a limited window, documented as around 48 hours. Firing the browser event live but batching server events overnight, or retrying them much later, can push the twin outside that window.</p>
<p>Timestamps themselves don't need to match. The ID and name are the keys.</p>
<h2>Verify with real orders</h2>
<ul>
<li>Open <strong>Test Events</strong> in Events Manager and place a real order.</li>
<li>Confirm both events arrive with the same <code>event_id</code> and <code>event_name</code>.</li>
<li>Check the data source overview for the deduplication status.</li>
</ul>
<p>Two separate events for one action, or a warning that events aren't deduplicating, means your keys don't line up. Test with live orders, not just staging.</p>
<p>Full write-up with FAQs: <a href="https://unfoldcro.com/blog/event-deduplication-for-meta-pixel-and-conversions-api">Meta Pixel and CAPI event deduplication</a></p>
]]></content:encoded></item></channel></rss>