The createProduct() API of wix-stores-backend is not working properly. Is there any alternate?

If we use the createProduct API, it is creating the product with only few fields. Although Name, Description, Price and a Variants are getting assigned properly, these fields are not getting assigned:

  1. Visible

  2. MainImage

  3. TrackInventory

  4. QuantityInStock

I tried running this code:

Hi! I’m having the same issue. Did you find a solution?