Why connect purchase data to customer profiles
Section titled βWhy connect purchase data to customer profilesβCommerce knows what customers buy. ODP knows who customers are across every channel. When these two systems operate independently, you lose the ability to personalize based on purchase behavior. A customer who just bought a laptop should see accessories, not another laptop. A high-value repeat buyer should see loyalty pricing, not first-time-buyer promotions.
Connecting Commerce purchase events to ODP creates a unified customer profile that combines browsing behavior, purchase history, email engagement, and support interactions. This profile powers segments that drive personalized experiences across your storefront, email campaigns, and advertising.
Architecture overview
Section titled βArchitecture overviewβββββββββββββββββββββββββββββββββββββββββββββββββββββββββ Commerce Platform ββ Orders, returns, cart events, product views βββββββββββββββββ¬βββββββββββββββββββββββββββββββββββββββ β purchase events, cart events βΌββββββββββββββββββββββββββββββββββββββββββββββββββββββββ Optimizely Data Platform (ODP) ββ Unified profiles, segments, predictive scores βββββββββββββ¬ββββββββββββββββββββββ¬βββββββββββββββββββββ β segments β recommendations βΌ βΌββββββββββββββββββββ βββββββββββββββββββββββββββββ Personalization β β Email / Ads / Storefront ββ Visitor groups β β Personalized content ββ Content blocks β β Product suggestions βββββββββββββββββββββ ββββββββββββββββββββββββββββStep 1: Send purchase events to ODP
Section titled βStep 1: Send purchase events to ODPβConfigure Commerce to send order events to ODP when a purchase completes. Each event should include the customer identifier, product details, order value, and transaction metadata.
Key events to track:
| Event | When fired | Data included |
|---|---|---|
product_viewed | Product detail page | Product ID, category, price |
added_to_cart | Add to cart action | Product ID, quantity, cart value |
order_completed | Order confirmation | Order ID, line items, total, payment method |
order_returned | Return processed | Order ID, returned items, refund amount |
Use the ODP Events API or SDK to send events with customer identity (email or ODP customer ID) so they attach to the right profile.
Step 2: Build behavioral segments in ODP
Section titled βStep 2: Build behavioral segments in ODPβWith purchase data flowing into ODP, create segments based on buying patterns.
| Segment | Definition | Use case |
|---|---|---|
| High-value customers | Lifetime spend > $1,000 | VIP treatment, early access |
| Repeat buyers | 3+ orders in 90 days | Loyalty pricing, reorder prompts |
| Cart abandoners | Cart created, no purchase in 48h | Recovery emails, incentive offers |
| Category affinity | 60%+ purchases in one category | Category-specific recommendations |
| At-risk customers | No purchase in 180+ days after active period | Win-back campaigns |
| New customers | First purchase in last 30 days | Onboarding content, review requests |
Configure these segments in the ODP dashboard using the purchase events you set up in Step 1. Segments update in real time as new events arrive.
Step 3: Personalize the storefront with segments
Section titled βStep 3: Personalize the storefront with segmentsβUse ODP segments in CMS visitor groups to show different content blocks to different customer types.
High-value customer: Show loyalty tier status, early access to new products, and VIP support contact.
New customer: Show getting-started guides, popular products, and first-purchase incentives.
Category-affinity customer: Show recommendations from their preferred category, new arrivals in that category, and complementary products.
Connect visitor groups to CMS content areas so product pages, home pages, and category pages adapt automatically based on the visitorβs ODP segment.
Step 4: Drive product recommendations
Section titled βStep 4: Drive product recommendationsβUse purchase history and browsing data to generate product recommendations that go beyond generic βbestsellers.β
| Recommendation type | Data source | Display location |
|---|---|---|
| βCustomers also boughtβ | Purchase co-occurrence | Product detail page |
| βComplete the setβ | Category + purchase gaps | Cart page |
| βReorder favoritesβ | Individual purchase history | Account dashboard |
| βNew in your categoryβ | Category affinity + catalog date | Home page |
| βBack in stockβ | Wishlist + inventory events | Email notification |
Feed these recommendation models with ODP profile data so they reflect each customerβs actual behavior rather than aggregate popularity.
When to use this pattern
Section titled βWhen to use this patternβThis pattern delivers the most value when you have returning customers whose purchase behavior varies meaningfully. If your products are one-time purchases (homes, cars) or your customer base is primarily anonymous, the segmentation value is lower. Focus on cart abandonment and browse-to-purchase segments for those scenarios.