Example How do I test an interface without real data going out?
Without a lock, a copy reports test orders through webhooks and apps to the real ERP. With the lock you first see what would go out, then let it through to a test system on purpose.
Test orders must not arrive in the warehouse.
ERP, marketplace, shipping provider and accounting are connected to the shop through apps, webhooks or plugins of their own. An unprotected copy sends them every test order, and the warehouse packs what was never ordered.
The plugin separates shop id and apps with an app server from the live shop and blocks every call by default. The log still shows where it would have gone: exactly what you want to know when testing an interface.
Step by step in the administration.
- 1Build locked
In the tab "Protection", "Calls of apps and webhooks" stays on "Block and log". Build.
- 2Trigger
Order in the copy, change order states, edit products: everything the interface should move. Switch payments to the provider's sandbox first.
- 3Read the log
On the dashboard of the copy, card "Outgoing requests": every call with time, channel, destination and handling.
- 4Point to a test system
Install the app anew in the copy and register it against the vendor's test account. If the ERP fetches orders through the API, create an integration of its own in the copy.
- 5Let through on purpose
Only then "Let through and log": calls go out and still appear in the log.
More on this:Emails and callsServices and plugins
What the lock covers.
- It covers Shopware's app and webhook calls. Switch off plugins that connect to their own service in the copy, or point them to a test account.
- Apps registered with their vendor for the live shop are removed from the copy by Shopware. For the test you install and register the app there anew, ideally against a test account.
- Scheduled tasks stay off as long as "Switch off scheduled tasks" is on; a nightly sync therefore does not run in the copy by itself.
What shop owners ask about it.
Does the ERP see the copy as a second shop?
The copy gets a new shop id, and Shopware removes apps with an app server from it, so no app server takes the copy for the live shop. An app you need in the copy you install and register there anew, ideally against a test account.
Is the log kept when I let calls through?
Yes. "Let through and log" sends calls out and still writes each one into the log. Only "As the live shop (without log)" writes nothing.
Can I see the content of a blocked call?
Not the content. The log shows time, channel (app or webhook), destination address and handling of every call; that tells you which system would have been called and when.
More examples
-
The Shopware update
The update in the copy first, in maintenance mode if you like, and only then in the live shop.
-
Testing a new plugin
Set up a new plugin or theme calmly; the comparison shows what you have to repeat live.
-
Access for the agency
Address, password and an admin login of its own, only for the copy and only until the agreed date.
-
The daily copy
A schedule refreshes the data every night; in the morning you test with the state of the day before.
-
Documents with real orders
Design invoices and delivery notes on real, anonymized orders.