Skip to main content

Mage2Plenty v3.11 - Bidirectional Bundle Orders

· 5 min read
Soft Commerce Team
Mage2Plenty Development Team

Mage2Plenty v3.11 teaches the order sync to speak bundles in both directions. PlentyONE sets now import as native Magento bundle products, Magento bundle orders now export as proper PlentyONE sets (parent + linked components), and the pricing is mirrored from each side's model so mixed component VAT is preserved and totals never double-count. Set-export is now on by default for new profiles. The release also ships three targeted fixes for Adobe Commerce staging and property-group export.

Bundle Orders

Until now a bundle was the one order shape the connector couldn't represent faithfully. A PlentyONE "set" arrives as a bundle parent line plus separate component lines linked by a bundle reference; a Magento bundle is a parent product with child selections. The two models are mirror images, and the old sync flattened them — which broke imports outright and exported bundles as unrelated line items. v3.11 maps them properly, both ways.

Importing PlentyONE sets as Magento bundles

A PlentyONE set comes in as a TYPE_BUNDLE parent (itemVariationId of the set) plus one TYPE_BUNDLE_COMPONENT line per component. The importer now reconstructs the Magento bundle instead of trying to add each line as a standalone product:

  • The bundle parent is resolved to its Magento bundle product and added with a proper bundle_option buy request, so Magento creates the child selection items itself.
  • Component lines are consumed into that bundle rather than added as separate top-level products.
  • An order can contain more than one bundle — each component is grouped under its owning bundle by selection membership (the bundle whose Magento selections contain that product).

This also retires a long-standing failure: the importer used to reject a legitimately zero-priced component line as "missing price data". Bundle components are supposed to be zero on the side that doesn't carry the price — that's no longer an error.

Exporting Magento bundles as PlentyONE sets

A Magento bundle order now leaves as a real PlentyONE set rather than a flat list of variation lines:

  • The parent is sent as ITEM_TYPE_BUNDLE in the order POST.
  • The components are sent as ITEM_TYPE_BUNDLE_COMPONENT and linked back to the parent with a bundle reference (referenceOrderItemId).

Because a component's referenceOrderItemId can only point at an order item that already exists, this is a two-step flow: the order POST creates the parent, then a follow-up batch PUT /rest/orders/{orderId} adds the components with their references. The client order is then refreshed from the PUT response (order items only) so the local mirror reflects the linked set without disturbing the address and comment data captured at creation time.

Price-type mirroring (no lost VAT)

PlentyONE accepts the price on either side of a set, and so does Magento via its bundle price_type. v3.11 keeps the two consistent:

Magento bundlePlentyONE setPrice lives on
Fixed priceparent-pricedthe bundle parent; components are 0
Dynamic pricecomponent-pricedthe components; the parent is 0

Exactly one side ever carries the price, so order, invoice and credit-memo totals never double-count. Crucially, the dynamic / component-priced path preserves per-component VAT — a zero-rated item inside an otherwise standard-rated bundle keeps its own rate instead of being collapsed onto a single bundle rate. On import the connector mirrors whichever side PlentyONE priced; on export it mirrors the Magento price_type.

Set-export on by default

The Export Bundle Components profile setting now defaults to enabled, so new order-export profiles produce proper sets out of the box. Existing profiles are deliberately left untouched — the value is stored per profile, and no data patch is shipped, so a live store keeps its current behaviour until you opt in by toggling the setting. Set-export is gated behind this toggle, so turning it off restores the previous single-line behaviour.

Bug Fixes

  • Property group export with null languagegetLocaleLanguages now skips a null language entry, fixing property group export where a missing locale aborted the run.
  • Item mapping CLI on Adobe Commerce staging — the item mapping command is now staging-aware, so it resolves the correct entity rows on Commerce installations that use catalog staging.
  • Stock mapping CLI on Adobe Commerce staging — the stock mapping command is likewise staging-aware.

Release Summary

ModuleVersionBumpKey Changes
module-plenty-order2.2.1 → 2.3.0minorOrder-item bundle-reference support; export Magento bundle orders to PlentyONE as linked sets
module-plenty-order-profile2.7.1 → 2.8.0minorImport PlentyONE bundle orders as Magento bundles; export bundles as linked sets; Export Bundle Components on by default
module-plenty-client2.1.5 → 2.1.6patchSkip null language in getLocaleLanguages to fix property group export
module-plenty-item-profile3.5.0 → 3.5.1patchMake item mapping CLI Adobe Commerce staging aware
module-plenty-stock-profile2.6.0 → 2.6.1patchMake stock mapping CLI Adobe Commerce staging aware

Metapackage: softcommerce/mage2plenty-os 3.10.0 → 3.11.0

Upgrade Guide

composer require softcommerce/mage2plenty-os:^3.11

bin/magento setup:upgrade
bin/magento setup:di:compile
bin/magento cache:flush

This release ships no schema changes — bundle linkage travels over the PlentyONE API and reuses the existing order mirror tables. setup:di:compile is required because the export pipeline gains a new batch generator.

Behaviours worth noting on upgrade:

  • Export Bundle Components defaults to on for new profiles only. Existing profiles keep their saved setting; enable the toggle on an order-export profile to adopt set-export there.
  • Bundle import is automatic — inbound PlentyONE sets rebuild as Magento bundles, provided the matching bundle product (and its selections) exist in Magento.
  • One caveat: if a single inbound order ever contains two bundles that share the same component SKU, the importer reports it clearly rather than guessing the assignment.

Resources


Questions about the upgrade? Reach out to us at support@byte8.io.