WooCommerce REST API Error – WordPress Development Stack Exchange

I am trying to use the REST API of WooCommerce. I just started following the instructions in the documents. I have tried with the sample code.
I have created a consumer key and a secret, this simply is not in the code below.
Does anyone know why I'm getting errors? On my local machine, I receive another error, but this is from the staging server.

requires __DIR__. & # 39; /vendor/autoload.php&#39 ;;
use Automattic  WooCommerce  Client;
$ woocommerce = new customer (
& # 39; https: //example.com & # 39 ;,
& # 39; consumer_key & # 39 ;,
& # 39; consumer_secret & # 39 ;,
    [
        'wp_api' => true,
        'version' => 'wc/v3'
    ]
);

print_r ($ woocommerce-> get (& # 39; products / 794 & # 39;));

Serious error: Not caught Automattic WooCommerce HttpClient HttpClientException: Syntax error in /var/www/bdnordic.com/fantrips/wp-content/plugins/fantrupcion of nature people / ribs of nature / ribs / ribs / ribs / ribs / ribs. Tracking 375 stacks: # 0 /var/www/bdnordic.com/fantrips/wp-content/plugins/fantrips/vendor/automattic/woocommerce/src/WooCommerce/HttpClient/HttpClient.php(414): Automattic WooCommerce Hpp / Hp HttpClient-> processResponse () # 1 /var/www/bdnordic.com/fantrips/wp-content/plugins/fantrips/vendor/automattic/woocommerce/src/WooCommerce/Client.php(82): Automattic WooCommerce / HpPc / pcpp / pcpp / pcpp / pcpp / pcpp / pcpp / pcpp / pcpp / pcpp / pcpp / pcppp / pcpp / pcpp / pcc / pcpp / pdf HttpClient-> request (& # 39; products / 89 & # 39 ;, # 39; GET & # 39 ;, Array, Array) # 2 /var/www/bdnordic.com/fantrips/wp-content/plugins/fantrips/fantrips.php(69): Automattic WooCommerce Client-> get (& # 39; products / 89 & # 39;) # 3 /var/www/bdnordic.com/fantrips/wp-settings.php(305): include_once (& # 39; / var / www / bdnord … & # 39 😉 # 4 /var/www/bdnordic.com/fantrips/wp-config.php(91): require_once (& # 39; / var / www / bdnord … & # 39;) # 5 / var / www /bdnordic.com/fantrip s / wp-load.php (37): require_once (& # 39; / var in / var / www / b dnordic.com/fantrips/wp-content/plugins/fantrips/vendor/automattic/woocommerce/src/WooCommerce/HttpClient/HttpClient. php online 375