woocommerce_store_api_cart_update_customer_from_request action-hookWC 7.2.0

Fires when the Checkout Block/Store API updates a customer from the API request data.

Usage

add_action( 'woocommerce_store_api_cart_update_customer_from_request', 'wp_kama_woocommerce_store_api_cart_update_customer_from_request_action', 10, 2 );

/**
 * Function for `woocommerce_store_api_cart_update_customer_from_request` action-hook.
 * 
 * @param \WC_Customer     $customer Customer object.
 * @param \WP_REST_Request $request  Full details about the request.
 *
 * @return void
 */
function wp_kama_woocommerce_store_api_cart_update_customer_from_request_action( $customer, $request ){

	// action...
}
$customer(\WC_Customer)
Customer object.
$request(\WP_REST_Request)
Full details about the request.

Changelog

Since 7.2.0 Introduced.

Where the hook is called

CartUpdateCustomer::get_route_post_response()
woocommerce_store_api_cart_update_customer_from_request
woocommerce/src/StoreApi/Routes/V1/CartUpdateCustomer.php 218
do_action( 'woocommerce_store_api_cart_update_customer_from_request', $customer, $request );

Where the hook is used in WooCommerce

Usage not found.