Summarize this documentation using AI
Overview
If you’re implementing Customer.io for retention, the “quick start” that matters isn’t spinning up a workspace—it’s getting app-side identity + events clean enough that your automations don’t misfire. If you want a second set of eyes on your tracking plan before you ship it (and before you build flows on shaky data), book a strategy call.
In most retention programs, the SDK is where wins (and problems) start: if you don’t stitch anonymous browsing to a known customer, your cart recovery and product browse flows will under-trigger, over-message, or attribute revenue incorrectly.
How It Works
Customer.io’s SDK instrumentation is basically two jobs: (1) tell Customer.io who the user is, and (2) send the behaviors you want to react to. The operational reality is that you’ll track a mix of anonymous sessions (pre-login) and identified users (post-login/checkout), and you need a consistent handoff between the two.
- SDK installation initializes a device/session context so events can be recorded immediately (even before you know the user’s email).
identifystitches identity by attaching a stable person identifier (and key attributes like email/phone) to the device/session. This is the moment where “browse” becomes “this person browsed.”tracksends events (e.g.,Product Viewed,Added to Cart,Checkout Started,Order Completed) with properties you’ll later use for segmentation and message personalization.- Segments and Journeys depend on event shape: if you don’t send consistent event names + properties, you’ll end up building brittle conditions (“contains” hacks, missing SKUs, mismatched currency) that break when the app changes.
D2C scenario: A customer opens your app, views two products, adds one to cart, then bounces. If you only identify at purchase, Customer.io sees anonymous events with no person to message—your cart recovery never fires. If you identify at email capture (or login) and merge that activity, you can trigger a push/email/SMS sequence with the exact SKU, price, and image they abandoned.
Step-by-Step Setup
The fastest path is to implement the minimum viable tracking that supports cart recovery and post-purchase, then expand into browse and reactivation. The key is to decide your identity rules up front so you don’t create duplicates you’ll spend months cleaning up.
- Create your Customer.io workspace and grab credentials (site/workspace keys depending on your SDK). Keep environments separate (dev/staging/prod) so test traffic doesn’t pollute segments.
- Install the Customer.io SDK in your app (iOS/Android/React Native/etc.) and initialize it on app start. Confirm the SDK can send at least one test event from a real device.
- Define your person identifier strategy before coding:
- Use a stable internal user ID as the primary identifier.
- Attach
emailand/orphoneas attributes when you have them. - Decide when a user becomes “known” (login, account creation, email capture, checkout step 1).
- Call
identifyas soon as the user is known (not just after purchase). Include attributes you’ll segment on later:email,phonefirst_namemarketing_opt_in(per channel if possible)customer_status(guest vs account)
- Track the retention-critical events with consistent naming. Start with:
Product Viewed(includesku,product_id,name,category,price,currency)Added to Cart(includecart_id, line items array, totals)Checkout Started(includecart_id, totals)Order Completed(includeorder_id, revenue, items, discount codes)
- Validate event delivery in Customer.io by checking a known test profile and confirming events appear with the properties you expect (especially arrays/JSON for line items).
- Create 2–3 segments that prove your data is usable:
- “Added to Cart, no Order Completed in 4 hours”
- “Order Completed in last 30 days”
- “Viewed Product 3+ times in 7 days, no purchase”
- Launch one workflow per outcome (cart recovery, post-purchase cross-sell, winback) and keep the logic simple until you trust the tracking.
When Should You Use This Feature
SDK-driven tracking is the right move when you need accurate, real-time behavior from the app (or web) to trigger retention messaging. It’s especially important when your most valuable actions happen inside the app and not on a traditional ecommerce storefront.
- Cart recovery with product-level personalization when you want the exact SKU, variant, and price in the message (and you want it within minutes, not hours).
- Repeat purchase orchestration for replenishment or usage cycles (e.g., “30 days after Order Completed, if no reorder, send reminder”).
- Browse-to-buy nudges like “viewed category X twice this week” → push with bestsellers, but only if the view events are reliably tied to the person.
- Reactivation based on app inactivity (e.g., no sessions/events for 21 days) where you need confidence that inactivity is real and not just an identity mismatch.
Operational Considerations
Most teams don’t fail on “sending messages”—they fail on data hygiene and orchestration. If your identity stitching is inconsistent, you’ll see duplicate profiles, missing carts, and segments that don’t match reality.
- Segmentation depends on event completeness: if
Added to Cartdoesn’t always includecart_idor line items, you can’t dedupe, suppress, or personalize reliably. - Identity stitching is the make-or-break: decide when you call
identify, and be consistent across platforms (iOS/Android/web). In practice, this tends to break when guest checkout exists on one platform but not another. - Data flow timing matters: cart recovery often needs a short delay (15–60 minutes) to avoid messaging people who are still checking out. That delay only works if events arrive quickly and in order.
- Orchestration across channels needs consent flags: store per-channel opt-in attributes so Journeys can branch cleanly (push vs email vs SMS) without manual suppression hacks.
- Testing needs real devices and real edge cases: airplane mode, app backgrounding, login after browsing, and uninstall/reinstall are where event duplication and identity gaps show up.
Implementation Checklist
If you want this to hold up once you start scaling flows, treat this like a tracking release—not a marketing task. The checklist below is the minimum to avoid “we built a great cart flow that only hits 40% of abandoners.”
- SDK installed and initialized on app launch (prod + staging separated)
- Stable person ID chosen (internal user ID) and used consistently
identifycalled at login/account creation/email capture (not just at purchase)- Anonymous-to-known behavior is stitched (validated with a test user journey)
- Core events implemented: Product Viewed, Added to Cart, Checkout Started, Order Completed
- Event properties standardized: SKU/product_id, price, currency, quantity, cart_id/order_id
- Consent attributes present for each channel you plan to use
- At least 3 “proof” segments built and validated against real behavior
- One cart recovery workflow launched with suppression/exit rules
Expert Implementation Tips
Once the basics are in, small operator decisions make a big difference in revenue and message quality. This is where you prevent over-messaging and unlock better personalization without rebuilding everything later.
- Track line items as structured JSON so you can render the cart in-message and also branch logic (e.g., suppress discounts on excluded categories).
- Send a single “Cart Updated” event pattern (with full cart state) rather than multiple partial events that are hard to reconcile. It makes “latest cart” logic dramatically cleaner.
- Use explicit revenue fields on purchase (subtotal, discounts, shipping, tax, total) so you can segment high-LTV customers and run margin-safe offers.
- Add a lightweight “Session Started” or “App Opened” event if reactivation matters. Otherwise you’ll rely on sparse commerce events and misclassify active browsers as inactive.
- Design for suppression early: include flags like
is_employee,is_test_account, and a globalholdout_groupto keep experiments clean.
Common Mistakes to Avoid
These are the issues that quietly kill performance: your dashboards look fine, but flows underperform because the audience definition is wrong.
- Identifying too late (only after purchase), which strands anonymous browse/cart events and breaks cart recovery.
- Using email as the primary ID when users can change emails or use Apple Private Relay—this creates duplicates and messy merges.
- Inconsistent event naming across platforms (e.g., iOS sends
add_to_cart, Android sendsAdded to Cart) which forces you into fragile segment logic. - Missing currency/price normalization, leading to bad personalization and incorrect revenue-based segments (especially for multi-currency brands).
- No exit criteria in cart flows: if you don’t exit on
Order Completed, you’ll keep sending “complete your purchase” after they bought. - Not separating staging from production, which pollutes segments and makes you distrust your own reporting.
Summary
If you’re serious about retention in Customer.io, the SDK setup is really an identity + event design project. Install is easy; stitching anonymous behavior to known users and standardizing event payloads is what makes cart recovery, repeat purchase, and winback actually work.
Use the quick start to get live fast, but don’t launch complex orchestration until your “proof segments” match what you see in the app.
Implement Quick Start Guide with Propel
Once your SDK events are flowing, the next step is making sure your segments and Journeys reflect how customers actually shop—guest checkout, delayed purchases, cross-device behavior, and channel consent included. That’s usually where teams either unlock compounding gains or end up patching logic every week.
If you’re building on Customer.io and want an operator-led implementation plan (tracking spec → identity stitching → first revenue workflows), book a strategy call.