Add product to cart for user – WC()->cart->add_to_cart [closed]

It sounds like you want to add an item to the cart of a specific user, not just the session of the browser making the request. WooCommerce’s add_to_cart function will only add an item to the cart of the user making the request.

I don’t believe WooCommerce has an easy one-line solution, but you could make your own function. There’s a pretty good example in this answer for updating a user’s cart using user meta: Add Products to user’s ID Woocommerce