I’m using Woocommerce in my project, I’m trying to call an API every time order status changes from “pending payment” to “processing”.
I’m looking for an action to do that.
Question posted in Woocommerce
The official Woocommerce documentation can be found here.
The official Woocommerce documentation can be found here.
2
Answers
You can use “woocommerce_order_status_changed” hook as below,
$this_get_id : Order ID
$this_status_transition_from : Order status changing from
$this_status_transition_to : Order status changing to
$instance : Order object instance
try using this code: