Posted on 01/07/2025 19:25:05
							
							
						 
						Hi Nicolai and Dmitrij,
I might have a workaround for Catia's issue but wanted to share what I am seeing.
Catia was doing a ajax call to the WebApi https://staging-inolex.mydwsite.com/dwapi/docs/index.html?url=/dwapi/api.json#/Commerce%20%3E%20Products/Products_GetAll , the controller does not require bearer token but the controller overrides the UserId property with UserId from the bearer token either way.

 
The issue with the second calls seems to be related to product not existing in ERP, which makes the LiveIntegration StockProvider request the product again. In StockProvider the LiveContext is built and not received from DW as in PriceProvider - https://github.com/dynamicweb/DataIntegration.LiveIntegration/blob/2d8a4280e189b0bc54379edaf92188cf8f211626/src/Dynamicweb.Ecommerce.DynamicwebLiveIntegration/Products/StockProvider.cs#L15
https://github.com/dynamicweb/DataIntegration.LiveIntegration/blob/2d8a4280e189b0bc54379edaf92188cf8f211626/src/Dynamicweb.Ecommerce.DynamicwebLiveIntegration/Helpers.cs#L275
The LiveIntegration helper to get user from request uses the Decrypt, which does not account for web encoding. Assuming it will be in querystring and not in view model (UserId in viewmodel is integer and not a string).
UserId=1466
Encrypted value "IqTmSqPFZ7A="
Encrypted value in request  "IqTmSqPFZ7A%3D"
This makes LiveIntegration not to be able to load the user when it decrypts the encrypted value in request.
BR Mario