'Prevent Registration Email From Being Send If Customer Is Registered Using The REST API In Shopware 6

How can I prevent the registration email from being send if a customer is registered using the REST API (storeurl/store-api/account/register)? I already did try to set the flag "acceptedDataProtection" to true.

I am trying to register our customers from another database to shopware, therefor they already have accepted the data protection and should not be receiving an email telling them that they have to opt-in again.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source