v1.0.0-alpha · Premium

OCart v1.0.0-alpha

A WooCommerce conversion and funnel engine: custom checkout layouts, order bumps, one-click post-purchase upsells, abandoned-cart recovery sequences, and native Bayesian A/B testing. Twelve database tables, idempotent gateway charges, REST + WP-CLI surface, native suite integration with OMailer, OConvert, OIntel.

WordPress plugin WP 6.4+ · PHP 8.1+ WooCommerce 8.0+ GPL-2.0+ v1.0.0-alpha · alpha
01 · Overview

What OCart does

OCart sits on top of WooCommerce. It replaces the default checkout with configurable funnel layouts, layers order bumps and post-purchase upsells on top, recovers abandoned carts through email and SMS sequences, and ships native A/B testing for every surface.

🛒
Checkout layouts
One-step, two-step, three-step. HPOS and cart-checkout blocks compatible
Order bumps
Add-on offers on the checkout page itself, with targeting rules
Post-purchase upsells
One-click upsells with idempotent charges. UNIQUE key prevents double-bill
↩️
Downsells
Auto-trigger on upsell decline. Different SKU or different price
📧
Cart recovery
Email + SMS sequences with delivery tracking and suppression
🧪
A/B testing
Bayesian, frequentist, or multi-armed bandit. Sample size calculator built in
🪝
Event bus
Typed dispatch over do_action. Hook every commerce event without forking
🧭
REST + WP-CLI
Full ocart/v1 namespace and 8 wp ocart commands
🔌
Suite integration
First-party bridges to OMailer (transactional), OConvert (CRO), OIntel (analytics)
🔐
Capability scoped
Per-area capabilities so funnels, offers, recovery, tests can be split between roles
🧾
Audit log
Every admin action recorded with diff, user, IP, timestamp
📥
Migration importer
CartFlows / FunnelKit funnel + offer importer (alpha)
02 · Installation

Getting installed

⚠️
Alpha release. Run OCart in shadow mode for one full week (capture data, do not modify checkout) before flipping it on for live shoppers. The shadow toggle ships in the box at general.replace_woo_checkout = false.
1
Install and activate WooCommerce 8.0+. OCart guards on WooCommerce being present and exits gracefully if it is not.
2
Upload the ocart folder to /wp-content/plugins/ and activate via Plugins → Installed Plugins.
3
On activation: creates 12 custom database tables (all prefixed {prefix}ocart_), registers capabilities, declares HPOS and cart-checkout-blocks compatibility via WooCommerce's FeaturesUtil.
4
Open OCart → Dashboard in wp-admin. Default settings are sensible for shadow mode.

Requirements

WordPress
6.4+
PHP
8.1+
8.2+ recommended
WooCommerce
8.0+
Tested up to 9.5
Database
MySQL 5.7+
MariaDB 10.3+
03 · Quick Start

First funnel in 5 minutes

From fresh activation to a live two-step checkout with one bump and one post-purchase upsell.

1
Open OCart → Funnels and click + New Funnel. Pick the two_step layout.
2
Add a checkout step (auto-added), then add a bump step. Pick a product, set fixed_addon pricing of $24, save.
3
Add an upsell step. Pick a product, set discount_pct: 50, save. The default branch fires after parent capture.
4
Drop the shortcode [ocart_checkout funnel="your-slug"] into a page, or set the funnel as the default checkout in Settings.
5
Run wp ocart cart list --status=active to confirm carts are flowing in.
04 · File Structure

Plugin architecture

ocart/ ├── ocart.php Plugin bootstrap, HPOS guard, WC dependency guard ├── uninstall.php Drop tables on plugin delete ├── includes/ │ ├── class-ocart-bootstrap.php Wires every engine after WooCommerce loads │ ├── class-ocart-db.php 12 table schemas, dbDelta migrations │ ├── class-ocart-events.php Typed event bus over do_action │ ├── class-ocart-settings.php Single options row with typed accessors │ ├── class-ocart-capabilities.php 5 area capabilities (manage / funnels / offers / recovery / tests) │ ├── class-ocart-admin.php Top-level menu + 11 submenus │ ├── class-ocart-rest.php /ping /info /openapi at ocart/v1 │ ├── class-ocart-rest-dashboard.php Dashboard reports endpoint │ ├── class-ocart-logger.php Structured leveled logger │ ├── checkout/ Checkout engine, capture, shortcode │ ├── bumps/ Bump rules, REST routes │ ├── upsells/ Post-purchase upsells, idempotent charge, gateway tokens │ ├── recovery/ Sequences, runs, deliverability, suppression │ ├── tests/ A/B test runner, allocation, results │ ├── funnels/ Funnel + funnel_steps repository │ ├── offers/ Bump + upsell + downsell repository │ ├── orders/ Parent / child order linkage, HPOS-aware │ ├── gateways/ Stripe + PayPal token storage and charge │ ├── tax/ Tax recompute on bumps and upsells │ ├── sms/ Recovery SMS dispatch (Twilio) │ ├── templates/ Funnel templates library │ ├── migration/ CartFlows / FunnelKit importers │ ├── integrations/ OMailer, OConvert, OIntel suite bridges │ ├── cli/class-ocart-cli.php 8 wp ocart commands │ └── tests/ Bayesian + frequentist stats ├── lib/orravo-core/ Mini-core, steps aside if full Orravo Core present ├── admin/ Admin templates and assets ├── templates/ Frontend funnel templates ├── assets/css/admin-v2.css Scoped to #ocart-wrap, OMailer-derived └── assets/js/admin.js React admin app, wp-api-fetch + wp-element
05 · Database Tables

12 database tables

All prefixed with {prefix}ocart_. Created on activation through dbDelta. Hot queries are indexed: find active funnel for cart, find pending recovery runs, look up idempotency keys for in-flight charges.

TablePurpose
ocart_funnelsFunnel records: name, status (draft / active / archived), trigger_rules, settings (theme + layout)
ocart_funnel_stepsPer-funnel steps: type (checkout / bump / upsell / downsell / thank_you / custom), position, branch (default / accepted / declined)
ocart_cartsCart sessions: session_token (UNIQUE), email, phone, items + totals JSON, status (active / abandoned / converted / expired)
ocart_recovery_sequencesRecovery sequence templates: trigger_type (cart_abandoned / checkout_abandoned / browse_abandoned), steps JSON
ocart_recovery_runsOne row per cart entering a sequence: current_step, status (pending / running / converted / stopped), revenue_recovered
ocart_offersBump / upsell / downsell records: pricing_rule, targeting_rules, display_config (all JSON)
ocart_offer_eventsEvery offer surface event. idempotency_key CHAR(36) is UNIQUE; gateway charges replay-safe
ocart_testsA/B tests: surface (checkout / bump / upsell / recovery_email / recovery_sms), method (frequentist / bayesian / bandit), winner_variant
ocart_test_assignmentsPer-cart variant assignment with conversion + revenue, used to compute results
ocart_suppressionEmail + phone suppression list. Reasons: bounce / complaint / unsubscribe / manual / winback_failed
ocart_deliverability_eventsSend / open / click / bounce / complaint events for email + SMS recovery
ocart_audit_logEvery admin action with diff, user, object, IP, timestamp
06 · Admin Interface

Admin interface

Top-level menu OCart with eleven submenus. Built with wp-element (React) and wp-api-fetch for first-party WordPress feel.

SubmenuSlugCapability
Dashboardocartocart_manage
Funnelsocart-funnelsocart_manage_funnels
Checkoutocart-checkoutocart_manage_funnels
Bumpsocart-bumpsocart_manage_offers
Upsellsocart-upsellsocart_manage_offers
Recoveryocart-recoveryocart_manage_recovery
Testsocart-testsocart_manage_tests
Templatesocart-templatesocart_manage_funnels
Migrationocart-migrationocart_run_migration
Reportsocart-reportsocart_view_reports
Integrationsocart-integrationsocart_manage
Settingsocart-settingsocart_manage
07 · Settings Reference

Settings reference

All settings stored in wp_options under key ocart_settings as a single nested array. Access via OCart_Settings::get('group.key').

general

KeyDefaultDescription
enabledtrueMaster kill-switch
replace_woo_checkoutfalseForce-replace the Woo checkout. Default false (shadow mode)
log_levelwarningdebug / info / warning / error

recovery

KeyDefaultDescription
capture_email_debounce_ms800Debounce for capturing checkout email keystrokes
consent_requiredtrueRequire explicit consent for recovery dispatch
cart_retention_days90Cart row retention window
test_assignment_days365Assignment row retention
deliverability_days180Deliverability events retention

upsells

KeyDefaultDescription
one_click_token_ttl_min30One-click token lifetime, in minutes
order_strategy_defaultAA = child order, B = merge (with fallback)
merge_cutoff_min5Strategy B falls back to A after this many minutes
sca_modal_enabledtrueRender SCA modal inline when 3DS challenge fires

tests

KeyDefaultDescription
method_defaultbayesianfrequentist / bayesian / bandit
mde_relative0.10Default minimum detectable effect
power_target0.80Default statistical power
significance0.95Default significance threshold
srm_threshold0.02Sample-ratio mismatch alert threshold
08 · Checkout layouts

Checkout layouts

Drop-in replacement for the Woo checkout. Three layouts ship in alpha (one_step, two_step, three_step) and the layout is a per-funnel setting, not a per-site setting.

ℹ️
HPOS (custom order tables) and cart-checkout blocks are both declared compatible via FeaturesUtil::declare_compatibility(). OCart works with classic shortcode checkout, the cart-checkout blocks, and HPOS.

Render

[ocart_checkout funnel="holiday-2026"]
// or pick the layout explicitly
[ocart_checkout funnel="holiday-2026" layout="two_step"]
09 · Order bumps

Order bumps

Add-on offers shown on the checkout page itself. Position is configurable (above payment, in shipping, in summary) and targeting rules accept cart total, product-in-cart, and category-in-cart predicates.

Pricing rule shapes

typeFieldsExample
fixed_addonamountAdd $24 once
percent_addonvalueAdd 10% of cart subtotal
free_giftproduct_idFree product if cart_min_total met
10 · Post-purchase upsells

Post-purchase upsells

After the parent order is captured, OCart issues a one-click upsell. If accepted, an idempotent charge fires against the saved gateway token. The idempotency_key column on ocart_offer_events is UNIQUE; replays of the same key never double-bill.

1
Parent order captured (Stripe payment_intent.succeeded or PayPal capture). OCart mints an idempotency key for this customer + offer pair.
2
Upsell rendered with the matching variant assignment (if A/B test is bound). One-click token issued via POST /upsells/issue-token.
3
On accept, POST /upsells/{id}/accept writes the offer_event row inside a transaction. UNIQUE constraint on idempotency_key returns 409 on replay.
4
Order strategy A: a child order is written with parent_order_id set. Strategy B: the parent order is amended (with a 5-minute cutoff that falls back to A).
11 · Cart recovery

Cart recovery

Sequences fire when carts hit the abandoned threshold. Email and SMS channels with full delivery tracking, suppression list, and DKIM / SPF deliverability checks built in.

Sequence step shape

{
  "channel":   "email",      // email | sms
  "delay_min": 30,           // minutes after trigger
  "template":  "cart_nudge_1",
  "discount":  10,           // optional, percent
  "ab_test":   123           // optional, bind to test id
}

Trigger types

  • cart_abandoned: cart sits idle past recovery.abandoned_threshold_min
  • checkout_abandoned: cart reached checkout step but did not complete
  • browse_abandoned: viewed product, did not add to cart (requires browse capture)
12 · A/B testing

Native A/B testing

Tests bind to any surface (checkout / bump / upsell / recovery_email / recovery_sms). Three methods: frequentist (z-test), Bayesian (Beta-Binomial posterior), or multi-armed bandit (Thompson sampling).

Test record fields

FieldTypeNotes
methodenumfrequentist / bayesian / bandit
mde_relativedecimal(5,4)Minimum detectable effect, e.g. 0.05 = 5% relative lift
power_targetdecimal(3,2)Statistical power target (default 0.80)
significancedecimal(3,2)Significance threshold (default 0.95)
winner_variantvarchar(64)Set on conclusion; null while running
13 · WooCommerce integration

WooCommerce integration hooks

OCart is a WooCommerce-first plugin. The bootstrap guards on WooCommerce being loaded; if missing, OCart self-disables with an admin notice.

WC hookOCart usage
before_woocommerce_initDeclare HPOS + cart-checkout-blocks compatibility
woocommerce_checkout_order_processedCapture parent order, mint idempotency keys, queue upsell render
woocommerce_thankyouRender post-purchase upsell page
woocommerce_payment_completeWrite recovery_run conversion if cart was in active sequence
woocommerce_cart_updatedSnapshot cart to ocart_carts for recovery
14 · HPOS + blocks

HPOS + blocks

High-Performance Order Storage and the cart-checkout blocks are both declared compatible via WooCommerce's FeaturesUtil. OCart writes to wp_wc_orders through Woo's data store layer, never raw SQL on order tables.

add_action('before_woocommerce_init', function () {
    if (class_exists(\Automattic\WooCommerce\Utilities\FeaturesUtil::class)) {
        \Automattic\WooCommerce\Utilities\FeaturesUtil::declare_compatibility(
            'custom_order_tables', __FILE__, true
        );
        \Automattic\WooCommerce\Utilities\FeaturesUtil::declare_compatibility(
            'cart_checkout_blocks', __FILE__, true
        );
    }
});
15 · Gateways & idempotency

Gateways & idempotency

Stripe and PayPal in alpha. The gateway adapter exposes capture_with_token($order, $amount, $idempotency_key). The UNIQUE column on ocart_offer_events.idempotency_key enforces replay safety at the database layer.

Idempotency keys are minted at parent-order-capture time and persist for the upsell window. Network double-clicks, browser back-button taps, and webhook replays all collapse to the same offer_event row, never to a duplicate charge.
16 · Shortcodes

Shortcodes

[ocart_checkout]
Renders an OCart checkout. Layout, theme, and step count come from the funnel record.
[ocart_checkout funnel="holiday-2026"]
[ocart_checkout funnel="holiday-2026" layout="two_step"]
[ocart_cart_count]
Renders the live cart item count. Updates via the suite bridge for OMailer + OConvert.
[ocart_cart_count]
[ocart_cart_icon]
Renders the cart icon with badge count.
[ocart_cart_icon]
17 · REST API

REST API

All routes namespaced under ocart/v1. The OpenAPI spec is served at /wp-json/ocart/v1/openapi.

MethodRoutePurpose
GET/ocart/v1/pingHealth check
GET/ocart/v1/infoPlugin version + active engines
GET/ocart/v1/openapiOpenAPI 3.1 spec
GET/ocart/v1/reports/dashboardDashboard rollups (orders, AOV, conv, recovery)
GET / POST / PATCH / DELETE/ocart/v1/bumps + /{id}Bump CRUD
POST/ocart/v1/bumps/{id}/acceptRecord bump acceptance + write offer_event
POST/ocart/v1/bumps/{id}/declineRecord bump decline
GET/ocart/v1/bumps/eligibleBumps eligible for the current cart
GET / POST / PATCH / DELETE/ocart/v1/upsells + /{id}Upsell CRUD
POST/ocart/v1/upsells/{id}/acceptOne-click accept; idempotent
POST/ocart/v1/upsells/{id}/declineDecline; triggers downsell branch if configured
POST/ocart/v1/upsells/issue-tokenMint a one-click upsell token
POST/ocart/v1/upsells/confirmSCA / 3DS confirmation callback
GET/ocart/v1/gatewaysActive gateway adapters
GET / POST/ocart/v1/recovery/sequencesRecovery sequence CRUD
GET/ocart/v1/recovery/runsRecovery runs list
POST/ocart/v1/recovery/runs/{id}/stopStop a running recovery
GET/ocart/v1/recovery/deliverabilityDeliverability events feed
POST/ocart/v1/recovery/dns-checkDKIM + SPF check for sender domain
GET / POST / DELETE/ocart/v1/recovery/suppressionSuppression list management
GET / POST / PATCH / DELETE/ocart/v1/tests + /{id}A/B test CRUD
POST/ocart/v1/tests/{id}/startStart a test
POST/ocart/v1/tests/{id}/stopStop a test
GET/ocart/v1/tests/{id}/resultsLive test results (variant conv, prob_b_wins)
GET/ocart/v1/tests/{id}/sample-sizeSample-size calculator output
POST/ocart/v1/checkout/captureCapture checkout email + cart for recovery
18 · Developer hooks

Developer hooks

OCart routes every event through OCart_Events::dispatch(), which mirrors to do_action. Hook with the standard add_action; payload reaches you regardless of whether the dispatcher or the WP action wakes first.

HookArgsFired
ocart/booted(none)After every engine has registered
ocart/cart/created$cartNew cart row written
ocart/cart/abandoned$cartCart crossed the abandoned threshold
ocart/cart/converted$cart, $order_idCart marked converted on order capture
ocart/bump/shown$offer_eventBump rendered to a shopper
ocart/bump/accepted$offer_eventBump accepted
ocart/upsell/before_charge$ctxJust before idempotent gateway charge fires
ocart/upsell/accepted$offer_eventUpsell accepted, child order written
ocart/upsell/declined$offer_eventUpsell declined; downsell branch evaluates next
ocart/recovery/dispatched$run, $stepRecovery channel dispatched (email or SMS)
ocart/recovery/converted$run, $order_idRecovery sequence converted
ocart/test/assigned$test_id, $variant, $cart_idVariant chosen for a cart
ocart/test/concluded$test_id, $winnerTest reached significance + winner set
19 · Helper functions

Helper functions

A small global surface for the most-used reads and writes. Everything else is on the namespaced OCart\\ classes.

FunctionReturnsNotes
ocart_log($msg, $ctx = [])voidStructured log at info level
ocart_user_has_purchased($user_id, $product_id)boolChecks Woo orders + ocart child orders
ocart_active_funnel_for_cart($cart_id)?FunnelResolves a cart to its active funnel
ocart_get_setting($path, $default = null)mixedSugar over OCart_Settings::get()
ocart_dispatch($event, ...$args)voidSugar over OCart_Events::dispatch()
20 · WP-CLI

WP-CLI

Eight namespaced commands. Useful in CI, deploys, and for quick spot checks during incident response.

CommandPurpose
wp ocart funnelFunnel CRUD + activate / archive
wp ocart cartList, show, mark converted / abandoned
wp ocart recoverySequence CRUD, dispatch, suppression
wp ocart testTest CRUD + start / stop / results
wp ocart migrationImport from CartFlows / FunnelKit
wp ocart gatewayGateway adapter status + token rotation
wp ocart templateFunnel template install / list
wp ocart exportExport funnels, offers, sequences as JSON
wp ocart cart list --status=abandoned --since=24h
wp ocart test 7 results
wp ocart recovery dispatch --dry-run
wp ocart migration import --from=cartflows
21 · Capabilities

Capabilities

Five area capabilities so OCart areas can be split between roles. Granted to administrator on activation. Other roles inherit nothing.

CapabilityGrants
ocart_manageTop-level access; settings, integrations
ocart_manage_funnelsFunnel + checkout + templates CRUD
ocart_manage_offersBump + upsell + downsell CRUD
ocart_manage_recoveryRecovery sequences, suppression, deliverability
ocart_manage_testsA/B tests CRUD + start / stop
ocart_view_reportsRead-only access to reports
ocart_run_migrationRun migration importers (destructive)
22 · Suite integration

Suite integration

First-party bridges to the rest of the Orravo suite. Each bridge auto-detects the partner plugin; if missing, it stays inert.

PluginWhat OCart sends
OMailerRecovery sequence dispatch goes through OMailer's transactional queue with full deliverability events.
OConvertCart events feed OConvert's CRO triggers (exit-intent on checkout, progress nudges).
OIntelEvery commerce event mirrors to OIntel's event sink for warehouse export.
OEngageOptional XP awards on conversion; opt-in per funnel.
23 · Comparison

Comparison

CartFlows, FunnelKit, and the WooCommerce add-on stack each cover a slice of OCart's scope. OCart is the whole funnel and recovery layer in one install.

CapabilityCartFlowsFunnelKitWC + add-onsOCart
Custom checkout layoutsno
Order bumpsno
Post-purchase upsellsno
Idempotent gateway chargespartialpartialno
Email + SMS recoverypaid add-onpaid add-onno
Bayesian + bandit A/Bnonono
Suppression + deliverabilitynonono
HPOS + blocks declared
REST + WP-CLI surfacepartialpartialno
Audit lognonono
Price$249/yr$249+/yr stackfree + addons$99 once
24 · Pricing

Plans & pricing

One-time alpha pricing locks in lifetime updates through the v1.0 stable release and every release after.

Single · alpha
$99
once · lifetime updates
  • 1 production WooCommerce store
  • All 12 tables, all surfaces
  • Full REST + WP-CLI
  • Email support · 48hr
Unlimited · alpha
$599
once · lifetime updates
  • Unlimited production sites
  • All features
  • Same-day priority support
  • Recovery + A/B starter pack
  • Custom integration sprint
25 · Changelog

What's shipped

v1.0.0-alpha.1 2026-05 · Alpha release
  • Custom checkout layouts: one_step, two_step, three_step
  • Visual funnel builder with steps + branches (default / accepted / declined)
  • Order bumps with cart_min_total, product_in_cart, category_in_cart targeting
  • Post-purchase upsells with idempotent gateway charges (Stripe + PayPal)
  • Post-purchase downsells on upsell decline
  • Cart recovery sequences (email + SMS) with delivery tracking
  • Suppression list (bounce / complaint / unsubscribe / manual / winback_failed)
  • Deliverability events log with DKIM + SPF check endpoint
  • A/B testing: frequentist, Bayesian (Beta-Binomial), multi-armed bandit (Thompson)
  • Sample-size calculator endpoint per test
  • HPOS + cart-checkout blocks compatibility declared via FeaturesUtil
  • Typed event bus (OCart_Events) over do_action
  • Capability-scoped admin (5 area capabilities)
  • REST surface under ocart/v1 with OpenAPI spec
  • WP-CLI: 8 wp ocart commands
  • Audit log of every admin action
  • CartFlows + FunnelKit migration importer (alpha quality)
  • Suite bridges: OMailer (transactional), OConvert (CRO), OIntel (analytics)
  • 12 custom DB tables, full uninstall cleanup
v1.0.0 (planned) Stable release · 2026-Q3 target
  • Visual funnel builder polish
  • CartFlows + FunnelKit importer hardening (round-trip safe)
  • Apple Pay + Google Pay one-click
  • Subscription-aware recovery (works alongside OSubscribe)
  • Multi-currency pricing rules
  • Per-funnel role assignment
  • Documentation: full PHP-Doc surface coverage
✦ Need help?

Got a question about OCart?

Reach out directly. Kenneth replies within 24 hours.