How ERP export works
This page is for you if your ERP or external fulfilment system imports orders from Shopware. It explains when an order becomes ready for the ERP, how long it waits and what a configuration change or deactivating the extension does. To set up ERP export, see Set up ERP export. For what your ERP partner needs to know, see ERP export reference for your ERP partner.
When an order is ready
Because an accepted offer adds an add-on item to an order that the customer has already placed, the order is ready for the ERP only when an offer can no longer change it.
While an order waits, it does not appear for the integration or the user account selected for the ERP. Other Administration users and all other API credentials keep their access to the order. The extension does not use a separate order status for the wait. When the order is ready, the ERP can import it on its next run.
The following table shows when an order placed in the storefront waits and when it becomes ready for the selected integration or user account:
| Point in time | What happens | ERP readiness |
|---|---|---|
| Customer places the order | Shopware stores the order. The extension checks the campaign conditions. | Waiting during this check. |
| No campaign qualifies | The customer sees no offer. | Ready immediately, as usual. |
| A campaign qualifies, but no usable offer product is found | The offer search on the order confirmation page ends without an offer. | Ready after that search. |
| Offer is open | The customer can accept or decline. | Waiting. |
| Customer declines | The offer can no longer change the order. | Ready for the next run. |
| Offer and any pending quick confirmation with the payment provider end | The offer can no longer change the order. | Ready for the next run. |
| Customer accepts | The order waits while Shopware processes the accepted offer. Shopware adds the add-on item and, where needed, collects the add-on amount. | Ready after processing completes. |
Orders created in the Administration receive no offer and never wait.
How long an order waits
When the order is placed, the extension checks the campaign conditions without loading the offer source. It selects an offer product only when the customer reaches the order confirmation page. Even if the offer source is empty, the order therefore waits until the customer reaches that page.
If the customer never reaches that page, for example because they do not return from their payment provider, the wait ends after the time set in Offer link validity (minutes) plus 60 minutes. With the default of 30 minutes, that is 90 minutes. The order is then ready for the ERP without a scheduled task having to run.
With an unused offer, the order waits until the offer link expires. If the campaign sets Countdown (minutes) and every Add-on offer element of its layout shows the countdown (Show countdown, off by default), the shorter of Countdown (minutes) and Offer link validity (minutes) applies.
If the customer has started the quick confirmation with the payment provider, which exists only for PayPal wallet orders without a saved payment, the order waits until that confirmation ends. The order waits at most until 60 minutes after the offer window ends.
With an accepted offer, the Waiting until column on the ERP Export tab shows the expected end of processing, usually 15 minutes after it starts. Shopware extends this time while processing runs. If processing has not finished by then, the order shows Review needed and waits until you allow its import. See Allow an import after review.
Configuration changes
A change to one of the following settings ends open offers before the new setting takes effect:
- Wait until the order is ready before the ERP can import it
- Integration the ERP uses to import orders
- User account the ERP uses to import orders
Ended offers can no longer change their orders.
A change under All Sales Channels ends open offers in every sales channel. A change for one sales channel ends only the open offers in that sales channel.
Orders placed before you turned on the setting Wait until the order is ready before the ERP can import it never wait. Turning it on ends their open offers in the affected sales channels, so that those offers cannot change an order that is already ready for the ERP.
Deactivating the extension ends the open offers in every sales channel. Waiting orders are then ready for the ERP.
If an order shows Completing the accepted offer or Review needed, Shopware rejects the save for the order's sales channel and under All Sales Channels. Shopware then also stops the deactivation of the extension, regardless of the order's sales channel. See Save a rejected configuration change.