A simple tool to access the open icecat product information API. The Package is build with modern web technologies like fetch to have a small footprint and native performance. It also has some nice features like retrying when the request fails and some interfaces to make typescript development easier.
Install
Install with npm:
$ npm i open-icecat
Declaration & Methods
; getProduct(options: GetProductOptions); getProductReviews(options: GetProductOptions); getProductRelatedProducts(options: GetProductOptions);}
Usage
1. Setup
; const oc = username: 'your-username' lang: 'en';
2. Get a Product by Brand & Product Code
async { const res = await oc; console;};
3. Get a Product by GTIN/EAN/UPC/JAN
async { const res = await oc; console;};
4. Get a Product by icecat_id
async { const res = await oc; console;};
5. Change the language for a single request
async { const res = await oc; console;};
License
Copyright © 2020, Tjark Kuehl Released under the MIT License.