I'm working on moving my store into Zoho Commerce, and have a SAML integration to my website already setup. I am running into a problem where the storefront won't allow a user to log in if they aren't already registered as a user in Zoho Commerce.
So the flow goes like this:
- First time user comes from my website over to the store. (They have not previously placed an order)
- User places item into cart.
- User begins checkout process.
- User clicks "Sign In / Sign Up".
- User is redirected to SAML login page.
- User enters their username/password and is authenticated by my website.
- User is returned to the storefront portal.
- Portal shows an error message: "New users should register before using the SAML Authentication. Please check with your administrator."
Obviously, the Storefront is assuming that anyone who logs in will already have a user entry in Zoho, but this is a problem when using SAML authentication because they technically do already have an account at my site; they shouldn't have to register for anything at the store. The system SHOULD create a user entry in Zoho when someone successfully authenticates via SAML if there is no existing user with that email address in the portal already.
So my main question is this: Is there a way via the Commerce API to create a user programmatically? There are ways to do this with other service APIs (Subscriptions for example), but I can't find any way to do this in the Commerce APIs.
If this were added to the API, I'd be able to programmatically create a user for them at the time they create an account on my website. Then, when they come over to the Zoho storefront, there's already a user entry for them, and they'd be able to log in successfully when placing their first order.