CartClear Operation

Description

The CartClear operation allows you to remove all the contents of a remote shopping cart.

Note:

Using CartClear on a shopping cart does not invalidate its CartId or HMAC. It simply removes all of its contents.

Note:

The cart lifespan is currently 90 days from the last date it was accessed.

Availability

CartClear is available in all of the locales.

Sample Request | Parameters

Sample Request

Using CartClear (REST)

This example demonstrates how to use CartClear to remove all the items from a shopping cart.

http://webservices.amazon.com/onca/xml?Service=AWSECommerceService&AWSAccessKeyId=[Your Access Key ID Here]&Operation=CartClear&CartId=[A Cart
ID]&HMAC=[An HMAC Shopping Cart
Token]
			

Request Parameters

Request parameters specify the terms of your request and control the output data that is returned to you.

You must include the required parameters in every request.

CartClear accepts the optional parameters that are common to all operations:

The following parameters are specific to the CartClear operation:

Parameter Description Required? Value
Operation The operation. Always Required CartClear
CartId

The CartId is a unique identifier for an Amazon remote shopping cart. CartIds are initially obtained by using the CartCreate operation.

Always Required

Required Value:

  • A Cart ID

HMAC

The HMAC is a unique security token that, when used with the CartId, allows you to access and modify (add to, remove from, empty) a specific remote shopping cart that you have created from your application or Web site. HMACs are initially obtained by using the CartCreate operation.

Any plus signs ("+") embedded in the HMAC must be encoded as %2B for REST.

Always Required

Required Value:

  • An HMAC Security Token

ResponseGroup

Controls the data returned by the operation. Use this parameter to specify which response group(s), or group(s) of data elements, you would like Amazon E-Commerce Service (ECS) to return to you.

You can specify as many response groups as you wish using a comma-separated list (REST) or multiple elements (SOAP).

Always Optional

Default Values:

Valid Values: