Hi Florian
The action in the cart item is what is intended to happen to the Product referred to by the cart item. For example, a typical shopping cart is all about providing new products so we can expect to see
add actions in the cart items. But in case a shopping cart is used also to capture non-provide orders, we might see
modify,
remove, or even
suspend actions in the relevant items.
Hope this helps
------------------------------
Jonathan Goldberg
Amdocs Management Limited
Any opinions and statements made by me on this forum are purely personal, and do not necessarily reflect the position of the TM Forum or my employer.
------------------------------
Original Message:
Sent: Sep 15, 2022 14:22
From: Florian Wiesner
Subject: TMF-663 ShoppingCart - why is there an action in CartItem?
Hi,
I wonder how why there is an action
attribute with the CartItem
type in the shopping cart API. Given that we're talking about REST and therefore state-driven API, json-patch (as described in TMF-630) to me sounds significantly more appealing to modify the array of cart items, or even a POST
/PATCH
/PUT
/DELETE
to /shoppingCart/<cart-id>/cartItem/<cart-id-unless-POST>
. Also what is expected in this field in case of GET?
Thank you for helping in advance!
Florian
------------------------------
Florian Wiesner
Oracle Corporation
------------------------------