Skip to main content

Magento Integration

Connect your Magento 2 store using the Joryio Connect extension. Sync products, orders, customers, and carts, track storefront behavior, and recover abandoned carts.

Features

  • Composer-installed extension - Native Magento 2 module, no OAuth needed
  • Automatic sync - Products, orders, customers, and carts stream to Joryio every minute
  • Historical import - Existing products, customers, and orders (last 90 days by default) are imported on connect
  • Abandoned cart recovery - Detect abandoned carts and send recovery links that restore the cart
  • Storefront tracking - Page views, product views, add-to-cart, and checkout events
  • Identity capture - Automatically identify customers from login, newsletter signup, and checkout
  • Revenue attribution - Orders are attributed to the campaign or journey that drove them
  • Catalog triggers - Stock and price updates power back-in-stock and price-drop triggers

Prerequisites

  • Magento Open Source or Adobe Commerce 2.4.x
  • Command-line access to your Magento server with Composer
  • Magento cron configured and running - the extension delivers events via cron, so this is required
  • Outbound HTTPS access from your Magento server to Joryio

Setup Steps

Step 1: Get Your Server URL and API Key

  1. In Joryio, go to Settings → Integrations → Magento
  2. Copy the Server URL
  3. Click Generate API Key and copy the key (starts with jry_mg_)

Step 2: Install the Extension

Download the extension zip (joryio-connect-magento2.zip) with the Download Extension button on the Magento integration page in your dashboard, extract it, then run these commands from your Magento root:

composer config repositories.joryio path /path/to/joryio-connect
composer require joryio/module-connect
bin/magento module:enable Joryio_Connect
bin/magento setup:upgrade
bin/magento setup:di:compile
bin/magento cache:flush

Alternatively (no composer): extract the zip into app/code/Joryio/Connect and run the same bin/magento commands.

Step 3: Connect

  1. In Magento admin, go to Stores → Configuration → Joryio
  2. Paste the Server URL and API key from Step 1
  3. Click Connect

The extension automatically creates a Magento integration access token and shares it securely with Joryio - you don't need to create any tokens by hand. Joryio validates the connection and immediately starts a full historical sync (products, then customers, then orders - the last 90 days by default).

When it finishes, the status shows Connected in both the Magento admin page and the Joryio dashboard.

What Gets Synced

DataHowWhen
ProductsHistorical import + real-time updates (including stock and price changes)On connect, then continuously
CustomersHistorical import + real-time updatesOn connect, then continuously
OrdersHistorical import (last 90 days by default) + real-time updatesOn connect, then continuously
CartsReal-time tracking + abandonment detectionContinuously
IdentityLogin, newsletter signup, checkout emailContinuously

Real-time updates are queued locally in your store and delivered to Joryio by a once-a-minute cron job - so a healthy Magento cron is essential. Stock and price updates also feed catalog triggers (back in stock, price drop).

Storefront Tracking

The extension adds a lightweight tracking snippet to your storefront (enabled by default - you can turn it off in Stores → Configuration → Joryio). It tracks:

EventDescription
Page ViewEvery page visit
Product ViewedWhen a product page is viewed
Add to CartItems added to cart
Checkout StartedWhen checkout begins
IdentifyEmail capture

The snippet also captures UTM parameters and Joryio click IDs from your campaign links, so orders are attributed back to the campaign or journey that drove the sale. See Revenue Attribution.

Abandoned Cart Recovery

  1. The extension tracks carts as customers shop
  2. After 60 minutes of inactivity (configurable), the cart is marked abandoned
  3. Joryio receives the cart with a recovery URL
  4. Use a journey to send recovery messages with the restore link

When a customer clicks the recovery link (https://your-store.com/joryio/cart/restore?token=...), their cart is restored with all items and they can check out immediately.

Troubleshooting

Events stuck / nothing arriving in Joryio

This is almost always Magento cron not running. The extension queues events locally and a per-minute cron delivers them - with no cron, nothing is sent.

  • Verify cron is set up: bin/magento cron:install (or check your crontab)
  • Run it manually to test: bin/magento cron:run
  • Check var/log/joryio.log in your Magento root for delivery errors

"Invalid API key" / key mismatch

  • The key must start with jry_mg_ and match the one currently shown in Settings → Integrations → Magento in Joryio
  • Generating a new key invalidates the old one - re-paste the latest key in Magento admin and click Connect again
  • Double-check the Server URL was copied exactly

Historical data missing

  • Orders older than the sync window (90 days by default) are not imported
  • Historical sync runs in order: products, then customers, then orders - give a large store some time to finish

Tracking not working

  • Check the tracking snippet toggle is enabled in Stores → Configuration → Joryio
  • Run bin/magento cache:flush after changing the toggle (full-page cache can serve stale pages)
  • Verify the snippet loads in your browser's developer tools