1. Go to this page and download the library: Download swappycom/php-client 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/ */
swappycom / php-client example snippets
onfigure OAuth2 access token for authorization: oauth
Swappy\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
$api_instance = new Swappy\Api\BulkApi();
$body = array(new Product()); // \Swappy\Api\Model\Product[] | Product list to be uploaded
$language = "language_example"; // string | Language for the response
try {
$result = $api_instance->createBulkJob($body, $language);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling BulkApi->createBulkJob: ', $e->getMessage(), PHP_EOL;
}