Product creation/update from Google Sheets to Woocommerce

Hi

I’ve set up the following scenario:

  1. Watch changes made in Google Sheets (this sheet is used for stock tracking)
  2. Sleeps for a few seconds to allow for multiple changes (I’m not sure if this is necessary but I’m still testing different possibilities - and learning along the way)
  3. Search WooCommerce to check if the product already exists
  4. If it exists, update the product
  5. If it doesn’t exist, create the product

I’m testing the scenario with a new product and keep getting the error: " Invalid module output. Expected Object, but found Array."

I thought the problem was from the product categories/tags but when I delete those fields, I still get the same error.

What could be causing the error and what’s the best way to correct it?

Thanks for the help :pray: