Home Plugins wemono abandoned cart recovery for woocommerce
Wemono Abandoned Cart Recovery for WooCommerce logo

Wemono Abandoned Cart Recovery for WooCommerce

by wemono on WordPress.org

Saves WooCommerce cart items to the database, restores them when sessions expire, and exposes REST API endpoints for abandoned checkout reporting.

(0)

Wemono Abandoned Cart Recovery for WooCommerce helps recover potentially lost sales by tracking abandoned checkouts and restoring carts when users return. The plugin works automatically after activation and also provides REST API endpoints that let you fetch abandoned checkout lists and summary statistics for integration with your CRM, marketing, or notification tools.

Key features:
– Abandoned cart tracking for guests and logged-in users
– Automatic cart persistence and restoration across sessions
– WooCommerce REST API–authenticated endpoints to fetch cart data and statistics
– Lightweight and privacy‑aware: stores cart data in your site’s database

For more information, visit Wemono.
For documentation, visit Wemono Documentation.

Configuration

The plugin works out‑of‑the‑box without configuration. Defaults:
– Abandoned timeout: 2 hours (a cart is considered abandoned if not updated for 2 hours)
– Pagination: _offset=0, _limit=200 for REST responses

These can be overridden per request via REST API query parameters (see Usage). Server‑side defaults are defined in includes/WemonoRestAPIConfig.php.

Usage

After activation, cart tracking is automatic. To integrate with external systems, use the REST API.

Generate WooCommerce API keys

  1. Go to WooCommerce > Settings > Advanced > REST API.
  2. Click Add key, give it a description, select a user with manage_woocommerce capability (e.g., Administrator), and choose Read or Read/Write as needed.
  3. Copy the Consumer Key and Consumer Secret.

REST API base

All endpoints are under:
https://yourstore.com/wp-json/wc-wemono/v1/

Authentication: Use the WooCommerce REST API Consumer Key and Secret via Basic Auth over HTTPS or as query parameters (ck_…/cs_…). Endpoints require authentication and proper capability. Requests without valid credentials will be rejected.

Quick testing scenarios

Use these simple steps to manually test the plugin end‑to‑end.

1) Verify abandoned checkouts endpoint with timeout=0 (for testing)
– Log in to your shop (optional), add a few products to the cart, but do not place an order.
– Call the endpoint with _timeout=0 to treat any idle cart as abandoned for testing:

curl -u ck_your_key:cs_your_secret \
“https://yourstore.com/wp-json/wc-wemono/v1/abandoned-checkouts?_timeout=0&_limit=10”

Expected: a JSON array with at least one record for your current cart. Each record includes enriched products, totals, and an abandoned_checkout_url.

2) Check cart recovery after WooCommerce session close
– Logged‑in user: Log in, add items to cart, then log out (or clear cookies woocommerce_cart_hash, woocommerce_items_in_cart, wp_woocommerce_session_*). Log back in and open the cart page. Expected: previous cart contents are restored.
– Guest user: In a private window, add items to cart. Close the private window (deleting the session). Open a new private window and revisit the store. Expected: the previous cart may be restored based on session behavior, and the cart will appear via the API.

Optional API checks:
– Before closing the session:

curl -u ck_your_key:cs_your_secret \
“https://yourstore.com/wp-json/wc-wemono/v1/abandoned-checkouts?_timeout=0&_limit=5”

  • After recovery or after completing checkout, show completed carts:

curl -u ck_your_key:cs_your_secret \
“https://yourstore.com/wp-json/wc-wemono/v1/abandoned-checkouts?is_completed=true&_limit=5”

Notes: _timeout overrides the default 2‑hour threshold for testing. Always use HTTPS in production when sending API keys.

Endpoints

1) GET /abandoned-checkouts
– Returns a list of abandoned checkouts with enriched product details and cart summary.
– Query parameters:
– _order_dir: ASC or DESC (default: DESC by updated_at)
– _offset: integer, default 0
– _limit: integer, default 200
– _min_id: integer, filter records with id > value
– _max_updated_at: unix timestamp, include records updated before this time
– _min_created_at: unix timestamp, include records created after this time
– _timeout: seconds, override abandoned timeout (default 7200 seconds)
– has_phone: true/false, only results with a customer phone when true
– is_completed: true/false/all (default: false). By default only non‑completed checkouts are returned.

2) GET /abandoned-checkouts/with-phone
– Same as /abandoned-checkouts but automatically filters to results that include a phone number.

3) GET /cart-statistics
– Returns aggregate statistics about abandoned carts (e.g., totals, carts with phone, last 24h, average age).

Example requests

Curl with Basic Auth (recommended over HTTPS):

Fetch latest 50 non‑completed abandoned checkouts:

curl -u ck_your_key:cs_your_secret \
“https://yourstore.com/wp-json/wc-wemono/v1/abandoned-checkouts?_limit=50”

Fetch checkouts with a phone updated before a timestamp:

curl -u ck_your_key:cs_your_secret \
“https://yourstore.com/wp-json/wc-wemono/v1/abandoned-checkouts?has_phone=true&_max_updated_at=1730000000”

Fetch statistics:

curl -u ck_your_key:cs_your_secret \
“https://yourstore.com/wp-json/wc-wemono/v1/cart-statistics”

If you prefer query parameter authentication (ensure HTTPS):

https://yourstore.com/wp-json/wc-wemono/v1/abandoned-checkouts?consumer_key=ck_your_key&consumer_secret=cs_your_secret

Active installations0+
Weekly downloads
17
Version1.0.6
Last updated11/3/2025
WordPress version5.0
Tested up to6.8.3
PHP version7.4
Tags
abandoned cartcart recoverymarketingNotificationswoocommerce