Update Items in Cart

Update one or more items in the specified cart with the revised set of items specified in the request body.

This API can update the following information:

  • Item quantity

  • Attribute values for the items

  • Any other updatable field on the line item, such as Service Account ID or Billing Account ID

Update Line Items in Cart replaces the OmniCPQServiceWrapper updateItem method.

This API supports the guest user enhancements that Salesforce introduced with the Winter ‘21 release. To encrypt and decrypt data for guest users, use the UserSecurity class with this API. See Guest User Technical Details.

For additional information, ​see UserSecurity Class and CPQ and Digital Commerce Changes for Guest Users.

PUT

ParameterDescription
namespacevlocity_cmt
cart_IDThe unique ID of the cart, which is the ID of the opportunity, quote, or order

For information about query parameters, request formats, response formats, see Industries Configure, Price, Quote Web APIs v2 Documentation.

To call putCartsItems, you must pass the JSONRecord for the attribute to update. The format of the request is:

In the request, itemJSON is the actual JSONRecord that is being updated. This JSONRecord is provided by the response to an Add Items to Cart or Get Cart Items API call. Based on that response, update the record or record attribute.

Example Request Body Format

In the request, itemJSON is the actual JSONRecord that is being updated. This JSONRecord is provided by the response to an Add Items to Cart or Get Cart Items API call. Based on that response, update the record or record attribute.

See Also