Hi,
I checked the WooCommerce Rest API doc, unfortunately, didn't found any end point to get the "Cart Count Total".
So I create my custom end point and use WC()->cart->get_cart_contents_count()
it always return 0. Even there are products in the cart.
Is there any way to get the cart total by using the Rest API ?
My WordPress is in a sub directory and I want to show the cart count total on the homepage.
This is not possible - the REST API handles WooCommerce data, but not user sessions/carts. You'll need to create a custom endpoint to return this. It does not need to be via the REST API - it could be done in a plugin.