1. Go to this page and download the library: Download sellerlabs/modernmws-php library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
sellerlabs / modernmws-php example snippets
// ...
"labs/research-php": "*"
}
// ...
public function register()
{
$this->app->bind(
SellerLabs\Research\Interfaces\ResearchClientInterface::class,
function () {
return new ResearchClient(
'YourClientId',
'YourClientSecret',
'http://research.api.sellerlabs.com'
);
}
);
}
// ...
class ProductsController extends Controller
{
/**
* Implementation of a client for SellerLabs' research API
*
* @var ResearchClientInterface
*/
protected $researchClient;
/**
* Construct an instance of a ProductsController
*/
public function __construct(ResearchClientInterface $researchClient)
{
$this->researchClient = $researchClient;
}
/**
* Handle GET /products/
*/
public function getIndex()
{
return $this->researchClient->getSearch('keyword', 'testing');
}
}
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.