Transactions
Sending purchases and returns from e-commerce and stores to Open Loyalty so members earn — with the API calls, webhooks and checks for each step.
Transactions are purchases and returns. When one reaches Open Loyalty and matches a member, purchase or return campaigns decide what the member earns or loses. This page covers sending them reliably from e-commerce and stores.
For non-purchase activity — reading an article, scanning a code, registering a device — use custom events instead. For the Admin Panel side, see Transactions and the purchase transaction campaign trigger.
Who does what
Admin Panel
Channels, purchase and return campaigns, transaction item filters for SKU or category rules
Integration layer
Turns orders and receipts into transactions, sends them once, retries safely, sends returns linked to the original sale, matches guest orders later
E-commerce platform / POS
Reports completed orders, receipts and returns with the customer's identifier
CRM / marketing automation
Receives balance changes through webhooks and tells the member what they earned
Design decisions
When to send a purchase
At order placement, payment, shipment or after the return window
Send it when the order can no longer be cancelled without a return — usually at payment or shipment. If returns are frequent, consider the wallet's unit pending method so points become spendable only after the return window.
Document number
Order ID, invoice number, receipt number
A number that is unique per tenant across all channels. If two channels can produce the same number, prefix it (WEB-1001, STORE12-1001).
How much item detail
Totals only, or every line with SKU, category, maker
Send lines with SKU and category if any campaign rewards specific products, now or later.
Guest purchases
Ignore, or send unmatched and match later
Send them unmatched; the member can claim them after registering.
Earning on returns
Leave points, or deduct them
Configure return campaigns that mirror your purchase campaigns.
Recommended flow
Configure (Admin Panel)
Create a channel per sales channel (web shop, app, each store group) and note their IDs. Set up purchase campaigns and, if points should be taken back, matching return campaigns.
Match guest purchases
Send guest orders without member identifiers; they're stored as Not matched. When the customer registers or logs in and claims the order, call POST /api/{storeCode}/transaction/assign with the transactionDocumentNumber and the member's identifier. Campaigns run at that point. See Matching transactions with members.
Sequence diagrams



Go-live checklist
Admin Panel
Integration layer
Channels and CRM
Validation
Key endpoints
POST /api/{storeCode}/transaction— Add a transactionPOST /api/{storeCode}/transaction/assign— Match the transactionGET /api/{storeCode}/transaction— Get transactions list, filtered e.g. bycustomerData:loyaltyCardNumberGET /api/{storeCode}/transaction/{transaction}— Get transaction's details
Webhooks: TransactionRegistered, TransactionAssignedToCustomer, WalletBalanceUpdated
Last updated
Was this helpful?

