WordPress at Your Fingertips
action is not described

wooocommerce_store_api_validate_add_to_cart action-hook . WC 1.0

Fire action to validate add to cart. Functions hooking into this should throw an \Exception to prevent add to cart from occuring.


add_action( 'wooocommerce_store_api_validate_add_to_cart', 'action_function_name_2710', 10, 2 );
function action_function_name_2710( $product, $request ){
	// action...
Product object being added to the cart.
Add to cart request params including id, quantity, and variation attributes.

Where the hook is called

woocommerce/packages/woocommerce-blocks/src/StoreApi/Utilities/CartController.php 225
do_action( 'wooocommerce_store_api_validate_add_to_cart', $product, $request );

Where in WP core the hook is used WooCommerce

Usage not found.