PHP code example of bold-commerce / bold-shopify-toolkit
1. Go to this page and download the library: Download bold-commerce/bold-shopify-toolkit library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?phprequire_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
bold-commerce / bold-shopify-toolkit example snippets
$shopifyApiHandler = new ShopifyApiHandler();
$this->getContainer()->addShared(RequestHookInterface::class, $shopifyApiHandler);
$this->getContainer()->addShared(ApiSleeper::class, $shopifyApiHandler);
// $shop - Eloquent model containing at least the myshopify_domain ("example.myshopify.com")
app()->instance(BoldApps\ShopifyToolkit\Contracts\ShopBaseInfo::class, $shop);
// $accessToken - Contains the access token string created when the shop installed the app
app()->instance(BoldApps\ShopifyToolkit\Contracts\ShopAccessInfo::class, $accessToken);
$variantService = new BoldApps\ShopifyToolkit\Services\Variant();
//OR
$variantService = app()->make(BoldApps\ShopifyToolkit\Services\Variant::class);