Hello Shopify Friends,
There are multiple ways to create Shopify Apps. In this article, we are going to learn How to Integrate Shopify App with Laravel. Before that have a look at my previous article that states, How to Get Shopify Product Data using Laravel.
Laravel is a web application framework with elegant syntax that simplifies common tasks. Shopify apps are used to add additional features to control and manage the Shopify store. Let’s see how you can Integrate Shopify App with Laravel.
For integrating Laravel with Shopify we are using osiset/laravel-shopify addon in Laravel.
Step 1: Run the following composer command in project root or you can clone or download a zip of osiset plugin from,
https://github.com/osiset/laravel-shopify
and put it in the ‘vendor’ folder of the project.
Following command create ‘osiset’ folder in ‘vendor’ folder
composer require osiset/laravel-shopify
Step 2: Generate Config file:
The following command will create a Shopify configuration file in the ‘config’ folder
php artisan vendor:publish --tag=shopify-config
Step 3: Copy the API key, API secret key, and app name of your Shopify app and paste it into the Shopify configuration file created in the ‘config’ folder.
'app_name' => env('SHOPIFY_APP_NAME', 'shopify app name') 'api_key' => env('SHOPIFY_API_KEY', 'shopify api key') 'api_secret' => env('SHOPIFY_API_SECRET', 'shopify api secret')
Step 4: Use the following Middleware with your routes to access shop data:
middleware(['verify.shopify'])
Consequently, you can successfully Integrate Shopify App with Laravel. For any doubts and queries, you can ping me in the comment box. Stay with us for upcoming tutorials.
Happy Coding!
Hello Magento Friends, In today’s blog, I will explain How to Add Tooltip in Checkout…
MongoDB is a popular NoSQL database that offers flexibility and scalability when handling modern web…
In NodeJS, callbacks empower developers to execute asynchronous operations like reading files, handling requests, and…
Hello Magento Friends, In today’s blog, we will learn How to Show SKU in Order…
The "Buy Now" and "Add to Cart" buttons serve as the primary call-to-action (CTA) elements…
Hello Magento Friends, In Magento 2, the checkout process allows customers to choose multiple shipping…
View Comments
hi sir, how can i load my shop in admin.shopify.com ?
For this, you have to use this updated composer
Here is the link - https://github.com/Kyon147/laravel-shopify/wiki/Installation
Error:
Class '\App\Jobs\AfterAuthenticateJob::class' not found
Is there any solution?
You have to define namespace in AfterAuthenticateJob class like this
namespace App\Jobs;
and take it to use in another file where you call
use App\Jobs\AfterAuthenticateJob;
Hello,
Thanks for this short article.
I did the steps, but I got this error from the beginning:
Osiset\ShopifyApp\Exceptions\MissingShopDomainException
No authenticated user or shop domain
I don't know what might be the cause?
Thanks
You can add the below line in your file AppServiceProvider.php file
URL::forceScheme('https');
File path : app\Providers\AppServiceProvider.php
Here is the link where you have to add the code : https://i.imgur.com/BuXzs0K.png