A fast flexible price search engine for various german online shops!
Curiosity 🤷♂️
- eBay
- Amazon
- MediaMarkt
- MediMax
- Mindfactory
- Saturn
- Cyberport
- Proshop.de
- Otto.de
- Alternate
- Kaufland
- Clevertronic
- Bücher.de
npm i more4less
import * as more4less from "more4less";
import { AmazonPriceSearchEngine, EbayPriceSearchEngine } from 'more4less'; // Individual classes
const more4less = require("more4less");
const { EbayPriceSearchEngine } = require('more4less'); // Individual classes
import * as more4less from "more4less";
const ebay = new more4less.EbayPriceSearchEngine();
(async () => {
const getProduct = await ebay.search("alexa firestick");
console.log(getProduct);
})();
// or
import { SearchEngineFactory } from "more4less";
const engine = new SearchEngineFactory().GetSearchEngine("Amazon");
(async () => {
const getProduct = await engine.search("alexa firestick");
console.log(getProduct);
})();
import * as more4less from "more4less";
const engine = new SearchEngineFactory().GetSearchEngine("All");
(async () => {
const getProduct = await engine.search("alexa firestick");
console.log(getProduct);
})();
import * as more4less from "more4less";
const searchEngines = new more4less.SearchEngineList([new more4less.EbayPriceSearchEngine(), new more4less.AmazonPriceSearchEngine2()]);
(async () => {
const getProduct = await searchEngines.search("alexa firestick");
console.log(getProduct);
})();
There are two ways of saving the output, either as JSON or CSV
import * as more4less from "more4less";
const searchEngines = new more4less.SearchEngineList([new more4less.EbayPriceSearchEngine(), new more4less.AmazonPriceSearchEngine2()]);
const output = new more4less.JSONOutput("test.json") // path and filename
(async () => {
const getProduct = await searchEngines.search("alexa firestick");
output.outputData(getProduct);
})();
// Each price engine provides the follwoing results:
interface ISearchResult {
engine: string;
link: string;
name: string;
rating: number;
price: number;
thumbnail: string;
}
Software contributions are welcome. If you are not a dev, testing and reproting bugs can also be very helpful!
Please open an issue if you have questions, wish to request a feature, etc.