Palbase Commerce & Promotions · API
/commerce/carts/{cart_id}/items/{line_id}Update cart item quantity or selection
Update cart item quantity or selection; a quantity of 0 takes the line out. The quantity of a line whose unit price the project's server set (its secret key) is the server's to change: a buyer's change of it is refused (403 custom_price_forbidden), taking the line out or changing its selection is not. The listing's most per order and its stock count every line of it in the cart.
Called by your app, with the publishable key; or a signed-in user of your app, with their token and the publishable key; or your server, with the project's secret key.
Path
cart_idstring · requiredPath parameter cart_id.line_idstring · requiredPath parameter line_id.curl -X PATCH "https://<your-ref>.palbase.studio/commerce/carts/<cart_id>/items/<line_id>" \
-H "apikey: $PALBASE_SECRET_KEY" \
-H "content-type: application/json" \
-d '{}'Responses
200Update cart item quantity or selection
defaultStandard Palbase JSON error envelope (`error` and `error_description`).
Operation UpdateCartItem of commerce's contract.