Okay so I'm VERRY VERRY VERRY new to the subject so please go easy on me. What I have done is to create a wordpress woocommerce website. What I want to do now is to get product-data from the wordpress site in node.js. If I have understood everything correctly i first have to Authenticate myself.
First i installed the WooCommerce package with:
Then i tried to Authenticante like this:
I realise It's an verry open question and i might be far of from on the right track. But I would appriciate some tips or guiding.
Thanks!
First i installed the WooCommerce package with:
Code:
npm install --save woocommerce-api
Then i tried to Authenticante like this:
Code:
var WooCommerce = require('woocommerce');
var wooCommerce = new WooCommerce({
consumerKey: 'ck_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx',
consumerSecret: 'cs_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx',
url: 'http://localhost/wordpress',
});
I realise It's an verry open question and i might be far of from on the right track. But I would appriciate some tips or guiding.
Thanks!