I want to share my findings today to hopefully save others time. The issue was that our client’s WordPress site - using WooCommerce and ShipStation - kept getting a 502 Bad Gateway Error when trying to import orders from Woo into ShipStation through the ShipStation plugin. The specific error was as follows:
An error occurred attempting to update orders: 502 Bad Gateway
502 Bad Gateway
The bad gateway error was not coming from the hosting provider’s server as WooCommerce had suspected, nor was it coming from the WooCommerce server as ShipStation had suspected.
The error was coming from Cloudflare. When we disabled the Cloudflare proxy, ShipStation connected without issue. We have a Cloudflare Edge Certificate issued and found that the minimum TLS version was set to 1.3 on the settings. Once we changed it to TLS 1.2, we were able to connect to ShipStation with the Cloudflare proxy enabled. I hope this helps someone.