PHP code example of swellstores / swell-php

1. Go to this page and download the library: Download swellstores/swell-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/ */

    

swellstores / swell-php example snippets




$swell = new Swell\Client('my-store', 'secret-key');

$products = $swell->get('/products', [
  'category' => 't-shirts'
]);

print_r($products);



$swell = new Swell\Client('my-store', 'secret-key');

$products = $swell->get('/products', [
  'category' => 't-shirts'
]);

print_r($products);


$swell = new Swell\Client('my-store', 'secret-key', [
	'cache' => false
]);
json
"wellstores/swell-php": "dev-master"
},
"repositories": [
	{
		"type": "vcs",
		"url": "[email protected]:swellstores/swell-php.git"
	}
]