🎽
Ciseco - Hydrogen Shopify's Headless storefront
Preview demoBuy Ciseco
  • 💝A few words of thanks
  • 🌟Hydrogen and Oxygen fundamentals
  • 👋Getting started
  • Getting started
    • Step 1. Getting started with Ciseco - Hydrogen and Oxygen
    • Step 2. Import Definitions and demo entries.
    • Step 3. Deploy to Oxygen
    • Step 4. Setup for using Customer Account API (/account route)
    • Step 5. Congratulations!
  • Ciseco with Development store
    • 🐣Ciseco test with development store
    • Step 1. Install the required apps
    • Step 2. Setup environment variables.
    • Step 3. Setup for using Customer Account API (/account route)
    • Step 4. Install node_module and run on localhost
    • Step 5. Import Definitions and demo entries.
    • Step 6. Deployments
    • Step 6.1. Deployments with GitHub
    • Redirect traffic to the Hydrogen channel
  • Ciseco's features
    • Display the color variant options as image swatch
    • Wishlist
    • Header mega menu
    • Footer menus
    • Product reviews with Okendo
    • Smart filter feature
    • Use the Shopify checkout
    • Customize pages and sections?
    • Add new page
    • Ciseco metaobject definitions and metafield definitions
      • 1 - Product Metafield definitions and Collection Metafield definitions
      • 2 - Link, Social
      • 3 - Hero Item, Section | Hero, Section | HeroSlider
      • 4 - Client Say, Section | ClientsSay
      • 5 - Section | LatestBlog
      • 6 - Section | GridProductsAndFilter
      • 7 - Collection Group, Section | TabsCollectionsByGroup
      • 8 - Section | ImageWithText
      • 9 - Section | Steps
      • 10 - Section | ProductsSlider
      • 11 - Section | CollectionsSlider
      • 12 - Route
    • Custom color, fonts
    • Favicon & Seo
    • Internationalization with Shopify Markets
    • ⁉️Getting the problem while importing demo metaobjects entries.
  • Folder Structure
  • Component Structure
  • Sources And Credits
  • Support
  • Change log
    • Update project
    • Change log
Powered by GitBook
On this page
  • Requirements
  • Set up a public domain for local development

Was this helpful?

  1. Ciseco with Development store

Step 3. Setup for using Customer Account API (/account route)

Setup for using Customer Account API (/account section)

PreviousStep 2. Setup environment variables.NextStep 4. Install node_module and run on localhost

Last updated 12 months ago

Was this helpful?

Requirements

  • You have Apps and channels permissions on the Shopify store that you're working with.

  • You have installed the or sales channel from the Shopify App Store.

  • NOTE: Setup for using Customer Account API - Step 4. Setup for using Customer Account API (/account route)

Set up a public domain for local development

Note

Shopify doesn't support the use of localhost or any http based URL due to security . For development purposes, we recommend using a tunnelling service, such as .

Customer Account API authentication doesn't support the use of localhost due to . For development purposes, use a tunnelling service, such as .

In this step, you'll learn how to use to set up a public HTTPS domain that connects to your local Hydrogen application.

1 - Set up ngrok

Install and run ngrok in your development environment.

  1. Set up an account.

  2. In your ngrok settings, .

  3. Install the .

  4. In a terminal, start ngrok using the following command:

ngrok http --domain= 3000

2 - Add your ngrok domain to the content security policy

import {createContentSecurityPolicy} from '@shopify/hydrogen';
createContentSecurityPolicy({
  connectSrc: [
    // (ie. 'wss://<your-ngrok-domain>.app:*')
    'wss://<your-tunneled-host>:*',
  ],
});

3 - Include public domain in Customer Account API settings

  1. Go to your Shopify admin => Hydrogen or Headless app/channel => Customer Account API => Application setup

  2. Edit Callback URI(s) to include https://<your-ngrok-domain>.app/account/authorize

  3. Edit Javascript origin(s) to include your public domain https://<your-ngrok-domain>.app or keep it blank

  4. Edit Logout URI to include your public domain https://<your-ngrok-domain>.app or keep it blank

Modify your Hydrogen app’s to allow the development domain as a connect-src. Your content security policy is typically located in /app/entry.server.tsx.

Headless
Hydrogen
concerns
ngrok
security concerns
ngrok
ngrok
ngrok
add a static domain
ngrok CLI
content security policy