I am getting this error on my woo-commerce website. I tried many solutions by searching on the internet like permalink settings, legacy setting in woo-commerce but nothing worked.
My code worked on the staging URL but on the live domain, it stops working. Is this something related to Cloudflare or related to any plugin like WP Rocket, Rank math or something? I tried this by disabling most of the plugins.
Fatal error: Uncaught Automattic\WooCommerce\HttpClient\HttpClientException: JSON ERROR: Syntax error in /home/509781.cloudwaysapps.com/nfkyzbddyz/public_html/api/vendor/automattic/woocommerce/src/WooCommerce/HttpClient/HttpClient.php:378 Stack trace: #0 /home/509781.cloudwaysapps.com/nfkyzbddyz/public_html/api/vendor/automattic/woocommerce/src/WooCommerce/HttpClient/HttpClient.php(422): Automattic\WooCommerce\HttpClient\HttpClient->processResponse() #1 /home/509781.cloudwaysapps.com/nfkyzbddyz/public_html/api/vendor/automattic/woocommerce/src/WooCommerce/Client.php(82): Automattic\WooCommerce\HttpClient\HttpClient->request('products/88963/...', 'GET', Array, Array) #2 /home/509781.cloudwaysapps.com/nfkyzbddyz/public_html/api/api_single_product.php(40): Automattic\WooCommerce\Client->get('products/88963/...') #3 {main} thrown in /home/509781.cloudwaysapps.com/nfkyzbddyz/public_html/api/vendor/automattic/woocommerce/src/WooCommerce/HttpClient/HttpClient.php on line 378
Thanks in advance