API response of Update Cart Item doesn't yield expected result


According to the docs a successful call to Update Cart Item of the javascript SDK will return the cart items. I’d expect the cart items to include any flows attached to cart_items. That’s not the case. The method call does not return the flow fields.

Moltin.Cart().UpdateItemQuantity( item, ‘3’ ) will return the cart items without the flows.

Contrast that with an item added by Add Product which returns the cart items with flows.

Moltin.Cart().AddProduct( item, ‘1’ ) will return the cart with flows.

I was expecting the flows. The documentation makes it seem like flows would be there. Having them there would make my life easier and let me forgo another API call, but it’s your baby and you can do what you want. Maybe being a bit clearer on the documentation might be good.

As an aside, if the API call is used to update the flow on a particular cart item the returned object contains the updated field for that item. But, again, the other fields don’t have flow fields.




Hi @mzinbergs

Thanks for reporting this. I think you’re correct and the flow fields should be attached in both responses. We’ll get an engineer to look into what’s going on and get that fixed.