Converting a Laravel App to a Shopify App
source link: https://fuzzyblog.io/blog/laravel/2021/08/27/converting-a-laravel-app-to-a-shopify-app.html
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
Converting a Laravel App to a Shopify App
Aug 27, 2021
This blog post tackles the odd topic of taking a Laravel application and converting it to a Shopify app.
Overview
Shopify is an ecommerce platform for building hosted shopping sites. With Shopify your whole ecommerce experience exists on a shopify url (whether the domain is .shopify.com or not; Shopify is serving everything and the underlying source of data is Shopify itself). Laravel is an MVC based framework for building web applications using the php language.
In this blog post, I will attempt to document all the steps to build a "shopify app" using Laravel. A Shopify app is a web application which, can be hosted anywhere, that authenticates itself to Shopify and is embedded in a page on the Shopify website.
Step 1: Create a Shopify App Using the Shopify Dashboard
There are a few different types of Shopify apps:
- Private / Custom – A private app can only be used by one shopify site and cannot be listed in the Shopify app catalog. Private apps have no review / approval cycle.
- Public – A public app is listed in the Shopify catalog, is reviewed and approved by Shopify
In this tutorial we will be focused on private / custom apps.
The first step is to create our app. This can be done with this url:
There are two url settings:
- The Callback url; this might also be called the App url (Shopify has changed their UI a number of times)
- The Redirect uri; this might be called the "Allowed redirection URL(s)"
The callback url needs to be set to your home route, the default route for your application.
The redirect uri needs to be set to the /authenticate route (this is automatically provided by )
Note: Everything you do with the Shopify website needs to be done in Chrome. No other browser such as Brave seems to work.
Step 2: Adding Shopify Support to Your Laravel App
The first step is to install the osiset shopify component:
composer require osiset/laravel-shopify
After that you need to generate a configuration file:
php artisan vendor:publish --tag=shopify-config
The next step is to add your credentials from Step 1 into the config file. Or move them into a .env file if that's the approach you are using. The values you need to fill in are: app_name, api_key, api_secret, and api_scopes
Step 3: Adding Your Shopify App to
Sources
Here are some of the references I used for this.
Recommend
-
5
Laravel Shopify App A full-featured Laravel package for aiding in Shopify App development, similar to shopify_app for Rails. Works for Laravel 7 and up. Table of Contents * Wiki...
-
2
August 24, 2021
-
12
VajroBuild a mobile app for your Shopify store in 60 minutes
-
1
Not FoundYou just hit a route that doesn't exist... the sadness.LoginRadius empowers businesses to deliver a delightful customer experience and win customer trust. Using the LoginRadius Identity...
-
4
Shopify App Tips80+ tips to help you build your Shopify AppThe Best Tips to Run a Shopify App Business is a website curating a list of 80+ tips to help you run a Shopify App. - H...
-
5
In this post, we will be building a simple Node.js application and then migrating it into a TypeScript app.JavaScriptJavaScript is a scripting language native to the web used to make web apps interactive. It is usua...
-
3
LiveAlerts Shopify AppiOS Inspired Popups to Collect Email + SMS contactsFree OptionsCreate iOS inspired popups for your Shopify store that visito...
-
1
如何从0搭建 Shopify APP Qing 2022-12-28 0 评论...
-
6
很多文章会分析 Shopify 市场、Shopify 商家怎么建站,却很少有描述怎么在Shopify 做APP。本文作者之前从 0 – 1 打造了一款 Shopify app page builder,并实现了从免费转付费的过程,这篇文章是对如何做好Shopify APP的分析,一起来看一下吧。
-
2
March 4, 2024Converting a Vue 2 App to Alpine.jsjavascript
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK