kloon / WooCommerce-REST-API-Client-Library

A PHP wrapper for the WooCommerce REST API
GNU General Public License v3.0
356 stars 175 forks source link

Trying to get list of orders but throws exception #253

Closed ovs1 closed 6 years ago

ovs1 commented 6 years ago

And i got it working to list all customers i have with:

$customers = $woocommerce->get('customers');

$orders = $woocommerce->get('orders');

i get an error:

Fatal error: Uncaught Automattic\WooCommerce\HttpClient\HttpClientException: The decoded property name is invalid in /home/xxx/xxx/vendor/automattic/woocommerce/src/WooCommerce/HttpClient/HttpClient.php:375 Stack trace:

0 /home/xxx/xxx/vendor/automattic/woocommerce/src/WooCommerce/HttpClient/HttpClient.php(414): Automattic\WooCommerce\HttpClient\HttpClient->processResponse()

1 /home/xxx/xxx/vendor/automattic/woocommerce/src/WooCommerce/Client.php(82): Automattic\WooCommerce\HttpClient\HttpClient->request('orders', 'GET', Array, Array)

2 /home/xxxx/xxxx/index.php(27): Automattic\WooCommerce\Client->get('orders')

3 {main} thrown in /home/xxxx/xxxx/vendor/automattic/woocommerce/src/WooCommerce/HttpClient/HttpClient.php on line 375

To note i run a Swedish webshop so we use å ä ö can this be an issue?