https://github.com/rem42/scraper-prestashop
https://github.com/rem42/scraper-prestashop
Last synced: 3 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/rem42/scraper-prestashop
- Owner: rem42
- License: mit
- Created: 2018-09-05T13:57:39.000Z (almost 7 years ago)
- Default Branch: main
- Last Pushed: 2023-08-07T03:51:28.000Z (almost 2 years ago)
- Last Synced: 2023-09-20T02:04:57.377Z (almost 2 years ago)
- Language: PHP
- Size: 165 KB
- Stars: 3
- Watchers: 2
- Forks: 1
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
Scraper Prestashop
==================






Scraper can handle multiple request type and transform them into object in order to create some API.
Installation
------------````bash
composer require rem42/scraper-prestashop
````Requirement
------------ PHP >= 8.1
Usage
-----Initiate the client with the http client of your choice that implement the `Symfony\Contracts\HttpClient\HttpClientInterface` interface.
`````php
addFilter('limit', 1)
->addFilter('offset', 1)
;/** @var PrestashopProducts $products */
$products = $client->execute($request);$products->getProducts(); // Return an array of PrestashopProduct
`````Product detail
--------------`````php
setId(42);/** @var PrestashopProduct $product */
$product = $client->execute($request);$product->name; // Return the product name
$product->dateAdd; // Return the product creation date
`````