Woocommerce - Create code to make all new products imported from Square as drafts by default

Job ID: 31735256

Budget: $10 – $30 USD

I use the Woocommerce Square plugin to import new products from Square to my Woocommerce (Wordpress) store. I need a custom code to automatically make all new imported products as "drafts" instead of "published".

The code needs to remain and work properly even when the plugin/Woocommerce is updated. I would like to know where the code is placed incase it ever gets removed as well.

Plugins used: Woocommerce and Woocommerce Square (https://wordpress.org/plugins/woocommerce-square/)