Integrations · Shops and payments
Shopify, paid orders from your webhook.
Paid Shopify orders from the orders/paid webhook, joined to the buyer’s visit through the SDK with the address and browser Shopify keeps. Test orders left out.
- PurchasePaid orders
- Test ordersLeft out
From the orders/paid webhook, through the SDK.
Illustration
At a glance
Sales from your webhook, joined to the visit.
What the SDK does with a paid order.
A few lines
One helper turns the webhook into a sale.
Joined to the visit
With the buyer’s address and browser, the sale joins their visit.
Counted once
Each sale carries an id, so a webhook sent again isn’t a second sale.
Any other app
Send a name, revenue, address and browser from anything else.
What is counted
Paid orders, joined to the visit.
Hand each orders/paid webhook to the SDK.
Where it shows
Where you see it.
Sales sent through the SDK show next to the rest of the stats.
Revenue
Revenue and conversion rate in the key numbers.
Goals and events
Each sale as an event, with revenue.
Paths to conversion
Sources, campaigns and pages that lead to sales.
Sources and campaigns
Revenue per source and per campaign.
All sites
Every website’s revenue together.
Reports and portal
In email reports and the client portal.
In your app
One helper in your webhook.
In your orders/paid webhook handler, fromShopify turns the order into a sale with the buyer’s address and browser, so it joins their visit.
- Test orders are left out
- fromShopify sets each event’s id for you
- Works with Next.js, Node.js and any server
import { fromShopify } from 'nahnu-analytics-sdk';
// Shopify orders/paid webhook
const sale = fromShopify(order); // the buyer's IP and browser; test orders → null
if (sale) await stats.events.send(website.id, sale);Not tied to a request
Renewals, imports and other apps.
A cron job or an import sends one event or a list. For any other app, send a name, revenue, the buyer’s address and browser: with them the sale joins the visit, without them it still counts.
- Give every event an id, such as the order number
- The answer says how many were accepted, rejected and duplicates
- The SDK can then retry safely
// A cron job or an import: one event or a list (up to 50).
await stats.events.send(website.id, {
name: 'Renewal',
id: invoice.id, // the same id within three days counts once
revenue: { amount: 49, currency: 'USD' },
});Is there a Shopify app?
No. You add a few lines to your own orders/paid webhook handler, through the SDK.
Are test orders counted?
No. fromShopify leaves them out.
Can a webhook sent twice count twice?
No. fromShopify sets each event’s id, so the same order is counted once.
Does the sale get its source?
Yes. Shopify keeps the buyer’s IP address and browser, so the sale joins their visit.
Try it on every client site.
Unlimited websites, every feature, one license.