From c71d4a68baa9b29753b71937324833c848ff8906 Mon Sep 17 00:00:00 2001 From: Alex Hellier Date: Mon, 12 Aug 2019 17:21:42 +0100 Subject: [PATCH] DIRTY HACK TO MAKE ORDERS WORK ON v3 --- bigcommerce/connection.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/bigcommerce/connection.py b/bigcommerce/connection.py index a4f745a..8c6df1d 100644 --- a/bigcommerce/connection.py +++ b/bigcommerce/connection.py @@ -55,7 +55,10 @@ def _run_method(self, method, url, data=None, query=None, headers=None): # Support v3 if self.api_path and 'v3' in self.api_path: - url = 'catalog/{}'.format(url) + if url is 'orders': + self.api_path = self.api_path.replace('v3', 'v2') + else: + url = 'catalog/{}'.format(url) # make full path if not given if url and url[:4] != "http":