Skip to main content
skill CX Codex

shopify-setup — Claude Code skill: what it does, how to install

Configures Shopify CLI authentication and a stable Admin API access token for your store. Useful when connecting an agent to Shopify for product and content management.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add jezweb/claude-skills --skill shopify-setup -a claude-code
Open on GitHub

What shopify-setup does

The skill walks through the setup required to interact with a Shopify store. It checks for @shopify/cli, launches the browser login flow via shopify auth login, and helps generate a permanent Admin API access token (shpat_*). A custom app token prevents interruptions caused by expiring CLI session tokens.

Credentials are stored in a local .dev.vars file, which must be added to .gitignore. Once stored, the skill tests the connection with a GraphQL query against API version 2025-01 and saves project settings in shopify.config.json. If navigating the admin panel manually is tedious, the skill can guide the process using Chrome MCP or playwright-cli.

Setup requires store owner or staff permissions with rights to configure custom apps and assign API scopes like read_products and write_inventory.

What it helps with

  • install and authenticate the Shopify CLI with a store
  • generate a stable Admin API access token via a custom app
  • isolate Shopify API credentials inside .dev.vars
  • verify API access with a test GraphQL query
  • create a reusable shopify.config.json configuration file

Example prompts for the agent

  • Connect to mystore.myshopify.com and set up Shopify Admin API access
  • Help me create a Shopify custom app token and verify GraphQL access
  • Check Shopify CLI auth and generate shopify.config.json for this store

How to install shopify-setup

1Skills CLI (Vercel)

npx skills add jezweb/claude-skills --skill shopify-setup -a claude-code

2Manually: put the files in place

~/.claude/skills/shopify-setup/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/shopify-setup/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about shopify-setup

How to install shopify-setup in Claude Code?

Run npx skills add jezweb/claude-skills --skill shopify-setup -a claude-code in your terminal.

What does shopify-setup do?

It guides CLI authentication, custom app token creation, .dev.vars secret storage, and verifies the connection with a GraphQL query.

Why does the skill create a custom app token instead of using CLI login?

CLI session tokens expire quickly. Custom app Admin API tokens (shpat_*) remain stable and long-lived for managing store products and files.

Source text

SKILL.md · MIT
---
name: shopify-setup
description: "Set up Shopify CLI auth and Admin API access for a store. Install CLI, authenticate, create custom app, store access token, verify. Use whenever the user wants to connect to a Shopify store, set up Shopify API access, install Shopify CLI, or troubleshoot Shopify auth / Admin API token issues."
compatibility: claude-code-only
---

# Shopify Setup

Set up working Shopify CLI authentication and Admin API access for a store. Produces a verified API connection ready for product and content management.

## Workflow

### Step 1: Check Prerequisites

Verify the Shopify CLI is installed:

```bash
shopify version
```

If not installed:

```bash
npm install -g @shopify/cli
```

### Step 2: Authenticate with the Store

```bash
shopify auth login --store mystore.myshopify.com
```

This opens a browser for OAuth. The user must be a store owner or staff member with appropriate permissions.

After login, verify:

```bash
shopify store info
```

### Step 3: Create a Custom App for API Access

Custom apps provide stable Admin API access tokens (unlike CLI session tokens which expire).

**Check if an app already exists**: Ask the user if they have a custom app set up. If yes, skip to Step 4.

**If no custom app exists**, guide the user through creation via browser:

1. Navigate to `https://{store}.myshopify.com/admin/settings/apps/development`
2. Click **Create an app**
3. Name it (e.g. "Claude Code Integration")
4. Click **Configure Admin API scopes**
5. Enable these scopes (see `references/api-scopes.md` for details):
   - `read_products`, `write_products`
   - `read_content`, `write_content`
   - `read_product_listings`
   - `read_inventory`, `write_inventory`
   - `read_files`, `write_files`
6. Click **Save** then **Install app**
7. Copy the **Admin API access token** (shown only once)

Use browser automation (Chrome MCP or playwright-cli) if the user prefers assistance navigating the admin.

### Step 4: Store the Access Token

Store the token securely. Never commit it to git.

**For project use** — create `.dev.vars`:

```
SHOPIFY_STORE=mystore.myshopify.com
SHOPIFY_ACCESS_TOKEN=shpat_xxxxxxxxxxxxxxxxxxxxx
```

Ensure `.dev.vars` is in `.gitignore`.

**For cross-project use** — store in your preferred secrets manager (environment variable, 1Password CLI, etc.).

### Step 5: Verify API Access

Test the connection with a simple GraphQL query:

```bash
curl -s https://{store}.myshopify.com/admin/api/2025-01/graphql.json \
  -H "Content-Type: application/json" \
  -H "X-Shopify-Access-Token: {token}" \
  -d '{"query": "{ shop { name primaryDomain { url } } }"}' | jq .
```

Expected response includes the shop name and domain. If you get a 401, the token is invalid or expired — recreate the app.

### Step 6: Save Store Config

Create a `shopify.config.json` in the project root for other skills to reference:

```json
{
  "store": "mystore.myshopify.com",
  "apiVersion": "2025-01",
  "tokenSource": ".dev.vars"
}
```

---

## Critical Patterns

### API Version

Always specify an explicit API version (e.g. `2025-01`). Using `unstable` in production will break without warning. Shopify retires API versions quarterly.

### Token Types

| Token | Format | Use |
|-------|--------|-----|
| Admin API access token | `shpat_*` | Custom apps — stable, long-lived |
| CLI session token | Short-lived | Shopify CLI commands only |
| Storefront API token | `shpca_*` | Public storefront queries |

This skill sets up **Admin API access tokens** — the right choice for product and content management.

### Rate Limits

Shopify uses a leaky bucket rate limiter:
- **REST**: 40 requests/second burst, 2/second sustained
- **GraphQL**: 1,000 cost points per second, max 2,000 points per query

For bulk operations, use the `bulkOperationRunQuery` mutation instead of looping.

---

## Reference Files

- `references/api-scopes.md` — Admin API scopes needed for product and content management

© jezweb · MIT · jezweb/claude-skills

Similar skills

All skills for Backend and APIs →

From the same set60

vite-flare-starter Clones the vite-flare-starter template and configures it into your own Cloudflare Workers app, with React, Hono, D1 and Drizzle, auth and Workers AI already in place. CX Codex +1 1,200installs project-docs project-docs scans your codebase to generate or refresh ARCHITECTURE.md, API_ENDPOINTS.md, and DATABASE_SCHEMA.md. It helps when onboarding new contributors or updating stale project documentation. CX Codex +1 1,200installs git-workflow Guides Git work for pull requests, merged-branch cleanup, conflict resolution, and monorepo release tags in Claude Code. CX Codex +1 1,200installs resume-cover-letter Writes a resume, CV or cover letter aimed at one specific job, with regional formatting and ATS rules in mind. CX Codex +1 1,200installs aussie-business-english This skill guides business writing in Australian English, with a warm, direct tone. Use it to draft or review emails, proposals and other copy for an Australian audience. CX Codex +1 1,200installs google-chat-messages A skill that lets your agent post to Google Chat through an incoming webhook: plain text, cardsV2 cards and threaded replies. CX Codex +1 1,200installs product-showcase This skill turns a running web app into a multi-page site with real screenshots and visual workflow guides. Use it when a static image cannot explain how the app works. CX Codex +1 1,100installs gws-install Installs gws on a second machine using OAuth credentials you already have, so you skip the Google Cloud setup. CX Codex +1 1,100installs

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor