@mrclayton Following up on my earlier query, I’m now looking at the popup help message for setting “Capture Status” in WooCommerce > Stripe by Payment Plugins > Settings > Advanced Settings (see image). It explains:
For orders that are authorized, when the order is set to this status, it will trigger a capture.
This leads me to wonder if instead of capturing an authorized charge with the code you suggested above, it would be sufficient to just change the status of the order in WooCommerce, like the following, to be acted on by the “Capture Status” feature?
$order = wc_get_order( $order_id );
$new_status = 'completed';
$order->update_status( $new_status );