Complete guide to implement Lomadee Global Pixel for advanced conversion tracking
sendOrder()
method<head>
section, before the closing </head>
tag:
</body>
tag:
sendOrder()
method only on the purchase confirmation page, after payment is approved. Important: Do not send on checkout or cart pages.
subItems
object stores order information such as shipping, items, discounts, and other values not directly related to products. Important notes:
Items
must reflect the final price of each product after applying discountsprice
subItems
using the Discounts
keysubItems
using a key with the discount name and valueprice
field. For example, if a product has a 10% discount, the price
should be 90% of the listPrice
.
subItems
with the key “Discount”. This discount should also be applied to the final product value. For example, if a 5% discount is applied for using a specific payment method, it should be applied to the final price of each product in the order.
price
), not the total order value after general discounts, for commission calculation. Therefore, it’s crucial that product-specific discounts are correctly reflected in each item’s price
. For example, if a 5% discount is applied for using a specific payment method, it should be applied to each item’s price
.
metadata
field is an array that allows sending custom information for specific contexts. It can be used at different levels of the order structure:
order.metadata
)customer.metadata
)items[].metadata
)items[].categories[].metadata
)metadata
array must follow the key
and value
structure:
metadata
is optional at all levelspixel.js
sendOrder()
Complete Verification List
<head>
sendOrder()
called ONLY on confirmation pageorderId
is unique for each orderprice
represents final value after discountslistPrice
is original price without discountquantity
is an integerPixel not initializing
<head>
async
temporarilyConversions not being sent
sendOrder()
doesn’t generate Network requestssendOrder()
on correct pageIncorrect data being sent
price
has final value after discountssubItems.Items
is sum of all productsorderId
multiple timessendOrder()
only ONCE per
order. Implement checks to avoid multiple sends of the same orderId
.sendOrder()