Related Documents
Document Properties
Last Modified23-Jun-2020
Added to KB29-Jun-2016
Public AccessEveryone
Doc TypeReferences
ProductICM 7.8

REST API - Set basket line item related data (7.8)



Http Method


Short Description

Sets line item related data

Query Parameters


Example Requests


HTTP Status Codes

200 OK

400 Bad Request
       Possible values for header 'error-key':

    • basket.basket_id_required.error
    • basket.lineitem.id_required.error
    • basket.product.sku_required.error
    • basket.product.variation.update_not_successful.error
    • basket.product.update_quantity.error
    • basket.invalid_address.error

404 Not Found
       Possible values for header 'error-key':

  • basket.basket_not_found.error
  • basket.lineitem.not_found.error
  • basket.product.not_found.error
  • basket.warranty.not_found.error


Sets following line item related data:

  • Quantity
  • Product variation option
  • Ship-to address
  • Shipping method
  • Gift certificate data

If basket or basket line item is not found then a status code 404 is returned as a result.

Depending on the flag MultipleShipmentsSupported the shipping methods and addresses can be set at the line item level:

  • MultipleShipmentsSupported = true: the shipping methods and addresses can be set on line item level (not at basket level)
  • MultipleShipmentsSupported = false: the shipping methods and addresses cannot be set on line item level (only at basket level)




B2C Web Shop, SMB Web Shop

Product Version


Product To Version




Request Data Format


Request related java object

Request Example

Set item quantity

    "quantity": {
        "value": 3


Set product variation option



Set shipping method (only if MultipleShipmentsSupported = true => multiple shipment where shipping methods on line item level)

    "shippingMethod": {
        "id": "STD_2DAY"

Set ship-to address

    "shipToAddress": {
        "country": "Germany",
        "city": "Potsdam",
        "postalCode": "14482",
        "addressLine1": "Berliner Str. 20",
        "phoneHome": "049364112677",
        "firstName": "Patricia",
        "lastName": "Miller",
        "title": "Mrs.",
        "countryCode": "DE"

Existing addresses of registered customers may also be used by passing the URN:

	"shipToAddress" : { 
		"urn" : "urn:address:customer:As8BcSwoiuFEEEAd3pp1Oye:Xf7AqMgoyuMAAAEs2sx0Uei" 

Deprecated: For compatibility reasons the UUID of the address can also be specified:

	"shipToAddress" : { 
		"id" : "Xf7AqMgoyuMAAAEs2sx0Uei" 

The request body above can also be used to set a store as ship-to address in case pickup in store is enabled. For this to work, the UUID of the store has to be passed which can be retrieved via the REST API - Store locator request.


Response Data Format


Response related java object

Response Example

    "type": "Link",
    "title": "7XwKDACqvlwAAAFCkrZCMC2X",
    "uri": "inSPIRED-inTRONICS-Site/-/baskets/XkoKDACqjEkAAAFCHClCMC0h/items/7XwKDACqvlwAAAFCkrZCMC2X"


XML Request Data Format


XML Request Java Objects

XML Request Example

Set item quantity

<?xml version="1.0" encoding="UTF-8"?>
    <quantity type="Quantity">

Set product variation option

<?xml version="1.0" encoding="UTF-8"?>

Set shipping method (only if MultipleShipmentsSupported = true => multiple shipment where shipping methods on line item level)

<?xml version="1.0" encoding="UTF-8"?>

Set ship-to address

<?xml version="1.0" encoding="UTF-8"?>
    <shipToAddress type="Address">
        <addressName>Patricia Miller, Berliner Str. 20, Potsdam</addressName>
        <addressLine1>Berliner Str.</addressLine1>

XML Response Data Format


XML Response Java Objects

XML Response Example

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<Link type="Link">

Reference - WebShop REST APIs


The information provided in the Knowledge Base may not be applicable to all systems and situations. Intershop Communications will not be liable to any party for any direct or indirect damages resulting from the use of the Customer Support section of the Intershop Corporate Web site, including, without limitation, any lost profits, business interruption, loss of programs or other data on your information handling system.

Customer Support
Knowledge Base
Product Resources