Skip to Content

WooCommerce Mirakl Integration — Import Orders from Mirakl Automatically

WooCommerce Mirakl integration built for WP Centric. Automatically imports orders from Mirakl to WooCommerce, downloads delivery invoices, and syncs DHL tracking back to Mirakl.

Completed: April 2026 Type: Portfolio Project
WooCommerce Mirakl Integration

Project Overview

This project is a complete WooCommerce Mirakl integration I built for WP Centric LLC — a fully automated Mirakl WooCommerce plugin that handles the entire order lifecycle between the Mirakl marketplace and WooCommerce. The plugin automatically imports orders from Mirakl to WooCommerce, downloads delivery invoices, and pushes DHL shipping tracking details back to Mirakl — all without any manual steps from the client’s team.

The client operated two Mirakl marketplace shops — one for Germany and one for Austria — and needed all incoming orders to flow into their existing WooCommerce infrastructure automatically. This WooCommerce Mirakl order sync eliminated a time-consuming daily manual process across both shops.

The Problem

The client was selling products through Mirakl marketplace WooCommerce — one of the world’s largest enterprise marketplace platforms used by major retailers across Europe. Every order placed on the marketplace existed only in Mirakl and had to be manually processed by their team each day:

  • Manually copying order and customer data from Mirakl into WooCommerce
  • Downloading delivery invoices (PDFs) from Mirakl one by one
  • Updating DHL tracking numbers back in Mirakl after each dispatch
  • Managing two separate Mirakl shops (Germany + Austria) independently

With growing order volumes across both shops, this manual process was becoming a serious operational bottleneck. They needed a reliable Mirakl WooCommerce plugin to automate everything end to end.

The Solution

I built a custom WooCommerce Mirakl integration plugin — WPC Import Orders from Mirakl (v1.18) — that automates the complete process using the official Mirakl Shop API WordPress SDK and WordPress cron jobs. The plugin connects directly to the Mirakl Shop API, fetches new orders, creates them in WooCommerce, downloads invoices, and syncs shipping status back to Mirakl automatically twice daily.

Key Features

1. Automated Order Import via WordPress Cron

The plugin runs automatically twice daily using WordPress’s built-in cron scheduler. It fetches all new orders from both Mirakl shops, creates corresponding WooCommerce orders, and stores the Mirakl order ID and shop ID as order meta for future WooCommerce Mirakl order sync operations.

2. Dual-Shop Support — Germany and Austria

This Mirakl WooCommerce plugin handles two separate Mirakl shop accounts simultaneously — Shop ID 2102 (Germany) and Shop ID 2240 (Austria). Country and state codes are resolved automatically using WooCommerce’s built-in country data, with per-shop fallback defaults when Mirakl returns incomplete address information.

3. Automatic Order Acceptance

When new orders arrive with WAITING_ACCEPTANCE status in Mirakl marketplace WooCommerce, the plugin automatically accepts all order lines via the Mirakl Shop API WordPress integration before creating the WooCommerce order — eliminating a manual approval step required for every incoming order.

4. Full Customer and Address Mapping

When importing orders from Mirakl to WooCommerce, the plugin maps complete customer data — billing address (name, company, street, postcode, city, country, state, phone, email) and shipping address — with fallback logic for cases where Mirakl returns partial address data.

5. SKU-Based Product Matching

Products from Mirakl order lines are matched to existing WooCommerce products by SKU. This ensures imported orders reference the correct WooCommerce products, preserving inventory records and reporting accuracy across the WooCommerce Mirakl integration.

6. Delivery Invoice PDF Download

After orders are imported, the Mirakl WooCommerce plugin fetches SYSTEM_DELIVERY_BILL documents from the Mirakl document API and downloads them as PDF files to a dedicated upload folder. Each invoice PDF is linked directly inside the WooCommerce order admin for one-click access by the team.

7. Mirakl Bill Column in WooCommerce Orders List

A custom “Mirakl Bill” column is added to the WooCommerce orders list screen. Whenever a delivery invoice PDF is available for an order, a direct download link appears in that column — giving the client immediate access to all Mirakl invoices without leaving WooCommerce.

8. DHL Tracking Push Back to Mirakl

When a DHL label is generated for an order, the WooCommerce Mirakl order sync automatically pushes the tracking number and carrier details back to Mirakl via the API. It then updates the Mirakl order status from SHIPPING to SHIPPED once confirmed, and sets the WooCommerce order status to Processing.

9. Automatic Order Completion Sync

When a WooCommerce order is marked as Completed, the Mirakl WooCommerce plugin automatically triggers a shipOrder call to the Mirakl Shop API — keeping the Mirakl marketplace WooCommerce order status in sync without any extra steps from the team.

10. Custom WooCommerce Order Status

A custom WooCommerce order status “SAE Shop” is registered to identify all Mirakl-imported orders within WooCommerce, making them easy to filter and manage separately from regular store orders. Orders with this status have their total automatically set to zero since pricing is managed within Mirakl.

11. Manual Import Admin Panel

A dedicated “Mirakl Orders” submenu page is added under WooCommerce in the WordPress admin. The team can manually trigger imports for any custom date range or specific order IDs — useful for re-importing missed orders without waiting for the automated cron to run.

Technical Stack

  • Language: PHP (OOP)
  • Platform: WordPress + WooCommerce
  • External API: Mirakl Shop API WordPress SDK (official)
  • HTTP Client: Guzzle (PSR-7 / PSR-18)
  • Automation: WordPress Cron (wp_schedule_event)
  • Architecture: 5 classes — Main, Orders, API Controller, Cron Manager, Admin
  • Shipping: DHL integration via pr_save_dhl_label_tracking action hook
  • Storage: WooCommerce order meta + WordPress uploads directory

Project Details

ClientWP Centric LLC
TimelineFebruary 2023 – March 2023
Plugin Version1.18
TypeCustom WooCommerce Mirakl Integration Plugin
MarketplaceMirakl (shopapotheke.mirakl.net)
Shops Integrated2 (Germany + Austria)

Results

The WooCommerce Mirakl integration eliminated all manual order handling between both platforms. Orders from the German and Austrian Mirakl shops now flow automatically into WooCommerce twice daily, delivery invoices are downloaded and attached instantly, and DHL tracking numbers sync back to Mirakl the moment a shipping label is generated — with zero manual steps required from the client’s team.

Need a Custom WooCommerce Mirakl Integration?

If your business sells on the Mirakl marketplace and needs a reliable WooCommerce Mirakl integration — whether it’s order imports, invoice downloads, shipping sync, or a full two-way API connection — I can build it. I’ve done it before, and I can do it for you.

Get a Free Estimate

Related Services

WordPress Plugin Customization Service

WordPress Plugin Development

WooCommerce Plugin Development