Add Item to Cart

Once a cart has been created you can begin adding items to it. Items are added by their SKUSKU - A SKU is the combination of variants that represent an actual item that can be purchased. An example of this might be a hoodie that has a size of Large and a color of Purple. ID. SKUs can be found by searching the product catalog, and then selecting the desired SKU of the desired offer.

Required Body Parameters:

sku_id - the ID of the SKU you wish to add to the cart.

Optional Query Parameters:

quantity - the quantity of this item you wish to purchase. Note: the current upper limit for quantity is 10, and the lower limit is 1. Any values above 10 will default to 10 and any values below 1 will default to 1. If no quantity is passed the value will default to 1.

curl -X POST https://sandbox-api.violet.io/v1/checkout/cart/{cart_id}/skus \
-H "X-Violet-App-Id: your-app-id-here" \
-H "X-Violet-App-Secret: your-app-secret-here" \
-H "X-Violet-Token: your-token-here" \
-H "Content-type: application/json" \
-d '{"sku_id": 999, "quantity": 1}'