Problem
The client was facing an issue with data mismatch, specifically related to inventory and pricing, between Magento and Shopify.
This led to challenges in managing backorders effectively and inaccurate pricing across the platform.
Client Requirement
The client, operating B2B and B2C eCommerce stores on Magento Open Source, wanted to add another store using Shopify as the platform.
However, they required the new Shopify store to share the same catalog data sourced from their existing ERP system, which was already integrated with Magento.
The proposed solution was to use Magento as a bridge between the ERP system and Shopify to ensure seamless synchronization.
Solutions
After a thorough analysis of the client’s requirements, we devised a strategy that utilized existing resources while introducing new functionalities:
Key features implemented
We developed a custom module in Magento that dynamically syncs price and promotion data from middleware using cron scheduling. This customization also provided the ability to configure the middleware API. For Shopify, the platform only supports single pricing, which was addressed by using the lowest price from the middleware, in line with the business rules defined by the client. We integrated this price update logic with Shopify, ensuring the system followed the client’s pricing rules.
Extension for Magento-ERP-Shopify Integration
We recommended and implemented a robust extension capable of handling default synchronization between Magento and Shopify for entities such as products, prices, inventories, and promotions.
Customization for Existing Magento Features
The Magento store had several client-specific customizations to support both B2B and B2C workflows, such as custom promotion rules and multi-source inventory handling. We carefully adapted the extension to fit these requirements, making sure Shopify could deliver the same functionality and business logic as the existing Magento setup, without disrupting day-to-day operations.
Source Location Management for Shopify
To simplify inventory management, we configured Shopify to enable only two source locations. This approach streamlined the syncing process between Magento and Shopify while maintaining accurate inventory tracking.
Leveraging Magento as the Central Hub
Magento continued to act as the single source of truth, syncing data between the ERP system and Shopify for catalog management, order fulfillment, and other operations.
Inventory Data
The inventory was managed in different warehouses, each referencing a specific code for each store. Since Magento’s version 2.4.2 did not have the multi-store inventory feature, we created a custom solution to maintain inventory separately for each warehouse and store. This feature updates inventory and work exactly same as Magento’s multi stock inventory.
Price Data
Tier Pricing: We received price data from the middleware and updated it in Magento. Since the client had both B2B and B2C stores, we manipulated the price data accordingly. This ensured that prices were updated based on different units of sale for B2B and B2C
Promotion Pricing: The client used promotions that impacted tier prices. We fetched promotion data from the middleware and updated it in Magento daily, ensuring accurate pricing based on promotional rules.