You may have come across the aforementioned error when creating a new account from the storefront.
The reason? the commerce engine is trying to create a customer in Commerce and the domain you have created for Storefront is not available in Commerce.
The customers in commerce are mapped to the domain and if the domain is not found or matched with what is configured in Storefront this error will come.
So how to resolve this?
Say your Storefront is mapped to use the default environment i.e. HabitatShops.
Follow steps below resolve the issue
- Open PlugIn.Habitat.CommerceAuthoring-1.0.0.json and find the CustomerPropertiesPolicy
- You may see the list of Domains default being, Storefront, extranet and CommerceUsers
Add the domain you have configured in your storefront in this list e.g.:- HabitatStorefront
- Add the same domain to PlugIn.Habitat.CommerceShops-1.0.0.json
- Ensure the domain is created and mapped in the Storefront correctly
Bootstrap Habitat Environment using Postman and now you should see the domain in the list whilst creating a customer
You should now able to see the domain in the list whilst creating a customer in business tool
Should also allow to create a customer with the new domain-
Hope this helps.
References
- Know more about Assurex’s services
- Know more about Sitecore Commerce