Skip to content
This repository was archived by the owner on Feb 23, 2024. It is now read-only.

Commit 3448b3c

Browse files
Update cart.md (#7700)
* Update cart.md Add information on how to add extra data to the /add-item request * Update src/StoreApi/docs/cart.md Co-authored-by: Niels Lange <[email protected]> * Update src/StoreApi/docs/cart.md Co-authored-by: Niels Lange <[email protected]>
1 parent 1e647e2 commit 3448b3c

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/StoreApi/docs/cart.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -332,6 +332,8 @@ curl --header "Nonce: 12345" --request POST https://example-store.com/wp-json/wc
332332

333333
Returns the full [Cart Response](#cart-response) on success, or an [Error Response](#error-response) on failure.
334334

335+
If you want to add supplemental cart item data before it is passed into `CartController::add_to_cart` use the [`woocommerce_store_api_add_to_cart_data`](https://github.com/woocommerce/woocommerce-blocks/blob/4d1c295a2bace9a4f6397cfd5469db31083d477a/docs/third-party-developers/extensibility/hooks/filters.md#woocommerce_store_api_add_to_cart_data) filter.
336+
335337
## Remove Item
336338

337339
Remove an item from the cart and return the full cart response, or an error.

0 commit comments

Comments
 (0)