# Shopify

The tap-shopify extractor pulls data from the Shopify API.

To learn more about tap-shopify, refer to the repository at https://github.com/singer-io/tap-shopify.

# Getting Started

# Prerequisites

If you haven't already, follow the initial steps of the Getting Started guide:

  1. Install Meltano
  2. Create your Meltano project

# Installation and configuration

# Using the Command Line Interface

  1. Add the tap-shopify extractor to your project using meltano add:

    meltano add extractor tap-shopify
    
  2. Configure the settings below using meltano config.

# Using Meltano UI

  1. Start Meltano UI using meltano ui:

    meltano ui
    
  2. Open the Extractors interface at http://localhost:5000/extractors.

  3. Click the "Add to project" button for "Shopify".

  4. Configure the settings below in the "Configuration" interface that opens automatically.

# Next steps

Follow the remaining steps of the Getting Started guide:

  1. Select entities and attributes to extract
  2. Add a loader to send data to a destination
  3. Run a data integration (EL) pipeline

# Settings

tap-shopify requires the configuration of the following settings:

These and other supported settings are documented below. To quickly find the setting you're looking for, use the Table of Contents in the sidebar.

# Minimal configuration

A minimal configuration of tap-shopify in your meltano.yml project file will look like this:






 
 
 

plugins:
  extractors:
  - name: tap-shopify
    variant: singer-io
    pip_url: tap-shopify
    config:
      shop: my_store_subdomain
      start_date: '2020-10-01T00:00:00Z'

Sensitive values are most appropriately stored in the environment or your project's .env file:

export TAP_SHOPIFY_API_KEY=my_key

# Shop

The store subdomain, which can be derived from your Shopify admin URL.

If your admin URL starts with https://my-first-store.myshopify.com/, your store subdomain is my-first-store.

# How to use

Manage this setting using Meltano UI, meltano config, or an environment variable:

meltano config tap-shopify set shop <subdomain>

export TAP_SHOPIFY_SHOP=<subdomain>

# API Key

A Private App API Password or API Key generated using OAuth

# How to get

# Create private app

First, you will need to create a Private App:

  1. Log in to your Shopify store admin at https://<store subdomain>.myshopify.com/admin
  2. Click "Apps" in the sidebar on the left
  3. On the bottom of the page, click "Manage private apps" next to "Working with a developer on your shop?"
  4. Click the "Create a new private app" button
  5. Enter a "Private app name" of your choosing, e.g. "Meltano"
  6. Enter your email address under "Emergency developer email"
  7. In the "Admin API" section, click "▼ Review disabled Admin API permissions"
  8. Choose "Read access" rather than "No access" in the access level dropdowns for the following permissions:
    1. Products, variants and collections - read_products, write_products
    2. Orders, transactions and fulfillments - read_orders, write_orders
    3. Customer details and customer groups - read_customers, write_customers
  9. Click "Save"
  10. In the modal that appears, click "I understand, create the app"
# Find your API password

Now that your app has been created, we can acquire the password Meltano will use to authenticate with the Shopify API.

  1. In the "Admin API" section on the private app details page, find the "Password" field and click "Show"
  2. The value that appears (starting with shppa_) is your API password. You can copy and paste it into the Meltano data source configuration.

Screenshot of Shopify interface showing private app API password

# How to use

Manage this setting using Meltano UI, meltano config, or an environment variable:

meltano config tap-shopify set api_key <key>

export TAP_SHOPIFY_API_KEY=<key>

# Start Date

This property determines how much historical data will be extracted.

Please be aware that the larger the time period and amount of data, the longer the initial extraction can be expected to take.

# How to use

Manage this setting using Meltano UI, meltano config, or an environment variable:

meltano config tap-shopify set start_date YYYY-MM-DDTHH:MM:SSZ

export TAP_SHOPIFY_START_DATE=YYYY-MM-DDTHH:MM:SSZ

# For example:
meltano config tap-shopify set start_date 2020-10-01T00:00:00Z

export TAP_SHOPIFY_START_DATE=2020-10-01T00:00:00Z