I’m trying to set up an automation where product images stored in Google Drive are uploaded to WooCommerce. However, when I pass the Google Drive share link to the WooCommerce module, I get the following error:
The operation failed with an error. [400] Invalid image: Sorry, you are not allowed to upload this file type. (woocommerce_product_image_upload_error)
It looks like WooCommerce doesn’t accept the Google Drive share URL directly. Instead, it requires the actual image file with .webp .png format at the end of file
How can I configure the scenario so that the WooCommerce module receives the real image file from Google Drive (not just the share link) and uploads it properly?
I don’t have access to the WooCommerce module. However, typically this requires using the Google Drive File Download module. In its output, it provides the data of the file. Submit that as the image file content, and normally, the WooCommerce module should accept it.
The Google Drive upload module only transmits links that Woocommerce does not accept. I hope I am not entering the data in the wrong place in the Woocommerce module.
Thnak you! Yes, but what data should be used if there are links everywhere that the module does not accept, or another type of data that it does not accept, and it needs the image itself?
OK, I thought the WOoComerce module accepted image data but it doesn’t. What type of error are you getting from WooComerce? Also—and this is crucial*—the file must be accessible without logging into your account. So they need to be public.
I also saw this article which mentions using “&export=download” at the end of the link. You might need to use that and you might need to tinker with it before getting it to work.
L
[*] Despite the use of em dashes and the word crucial, this post was 100% human made.