Skip to content

takuma-competition/sample-django-app

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

55 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sample Django App

A demo app created using Django and ShopifyAPI v8.4+.

Quick start

To run this app locally, you can clone the repository and do the following.

  1. Create a .env file to specify this app's API key and API secret key app credentials that can be found in the Shopify Partners dashboard.
SHOPIFY_API_KEY=<The API key app credential specified in the Shopify Partners dashboard>
SHOPIFY_API_SECRET=<The API secret key app credential specified in the Shopify Partners dashboard>
APP_URL=<The public app URL specified in the Shopify Partners dashboard>

Note: If you do not have an API key or an API secret key, see the following sections of the Build a Shopify App with Node and React guide.

  1. Expose your dev environment
  2. Get a Shopify API Key and Shopify API secret key
  3. Add the Shopify API Key and Shopify API secret key
  1. Run the following to install the required dependencies:
$ pip install -r requirements.txt
  1. Change directories to the main sample_django_app app and run all pending migrations:
$ cd sample_django_app
$ python manage.py migrate
  1. Ensure ngrok is running on port 8000:
$ ngrok http 8000
  1. Run the server:
$ python manage.py runserver
  1. In your browser, open the https ngrok url to install and open this app on a shop. Requests to authenticated resources like the products view in the api app should now be secured with an Authorization: Bearer <session token> header.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 43.1%
  • HTML 38.4%
  • CSS 18.5%