shopify-mcp
MCP server for Shopify. Full Admin GraphQL API tooling plus an AI-driven product creation bridge via ComfyUI image generation.
The pitch
Every other Shopify MCP is a plain Admin API wrapper. This one pairs with @miller-joe/comfyui-mcp so you can say things like:
"Create a product called 'Nebula Dreamer'. Generate a cosmic abstract image for it, description matching the vibe, tagged astrology, status draft."
Claude then runs ComfyUI, gets an image back, creates the Shopify product, and attaches the image, all in one call.
Install
# npx, no install
npx @miller-joe/shopify-mcp \
--shopify-store your-store.myshopify.com \
--shopify-access-token shpat_xxx
# Docker
docker run -p 9110:9110 \
-e SHOPIFY_STORE=your-store.myshopify.com \
-e SHOPIFY_ACCESS_TOKEN=shpat_xxx \
-e COMFYUI_URL=http://comfyui:8188 \
ghcr.io/miller-joe/shopify-mcp:latest
Connect an MCP client
claude mcp add --transport http shopify http://localhost:9110/mcp
Or point your MCP gateway at the Streamable HTTP endpoint.
Configuration
Transports
The server speaks streamable HTTP by default (great for Claude Code, MetaMCP, raw fetch). Pass --stdio (or set MCP_TRANSPORT=stdio) to switch into stdio mode, which is what stdio-first clients like Claude Desktop and the MCP Inspector expect:
// claude_desktop_config.json
{
"mcpServers": {
"shopify": {
"command": "npx",
"args": ["-y", "@miller-joe/shopify-mcp", "--stdio"],
"env": {
"SHOPIFY_STORE": "my-store.myshopify.com",
"SHOPIFY_ACCESS_TOKEN": "shpat_…"
}
}
}
}
Getting a Shopify access token
Easy path, existing dev store: Shopify Admin → Apps → Develop apps → Create custom app → enable relevant Admin API scopes (write_products, read_orders, write_inventory, read_customers) → install → copy the admin API access token (starts with shpat_).
For new apps (post-Jan 2026): legacy custom-app tokens are deprecated for freshly-created apps. Use the Dev Dashboard token-exchange flow once to obtain a working token, then supply it here. Multi-tenant OAuth is on the roadmap.
Tools
Core Admin
Metafields
Draft orders
Webhooks
Metaobjects
Fulfillment
Partial fulfillment is supported. Pass specific fulfillmentOrderLineItems with quantity per line, or omit the array to fulfill everything on the fulfillment order.
Variants and product options
For an entirely new product, creating the first real variant requires strategy="REMOVE_STANDALONE_VARIANT" to replace the auto-generated "Default Title" variant.
Collections and tagging
Analytics (ShopifyQL)
Examples:
FROM sales SHOW total_sales BY day SINCE -30d TIMESERIESFROM products SHOW product_title, quantity_sold BY product_id SINCE -7d ORDER BY quantity_sold DESC LIMIT 10
ComfyUI bridge (when COMFYUI_URL is configured)
Template placeholders for bulk_regenerate_images: {title}, {handle}.
Example: the whole pitch in one call
Claude, use generate_and_create_product:
prompt: "minimalist sunset mountain silhouette, warm gradient, vector style"
title: "Mountain Sunset Poster"
status: DRAFT
tags: ["posters", "nature", "minimalist"]
ComfyUI generates the image, Shopify creates the product with the image attached, and you get the product ID and image URL back. One prompt, one call, real listing.
Architecture
┌────────────────┐ ┌──────────────────┐ ┌─────────────────┐
│ MCP client │────▶│ shopify-mcp │────▶│ Shopify Admin │
│ (Claude etc.) │◀────│ (this server) │◀────│ GraphQL API │
└────────────────┘ └────────┬─────────┘ └─────────────────┘
│
│ (bridge tools only)
▼
┌──────────────────┐
│ ComfyUI │
│ (txt2img) │
└──────────────────┘
Bridge tools call ComfyUI directly over HTTP, get an image URL, and pass it to Shopify's productCreateMedia mutation. Shopify fetches and hosts the image on its CDN.
Development
git clone https://github.com/miller-joe/shopify-mcp
cd shopify-mcp
npm install
npm run dev # hot reload via tsx watch
npm run build
npm run typecheck
npm test
Requires Node 20+.
Roadmap
Shipped:
- Core products CRUD plus image attach
- Orders read, Inventory set + locations, Customers read
- ComfyUI bridge:
generate_and_create_product,generate_product_image,bulk_regenerate_images - Metafields:
set_metafield,list_metafields,delete_metafield - Draft orders: create / update / complete / delete / list / get
- Collections and tagging: CRUD, product add/remove,
add_tags/remove_tags - Variants and product options: bulk create / update / delete / reorder plus
add_product_options - Fulfillment: list/get fulfillment orders, create fulfillment (partial supported), update tracking, cancel
- Webhooks: list / get / create / update / delete
- Metaobjects: definitions list plus metaobject CRUD
- ShopifyQL analytics:
run_shopifyql_querywith ASCII-table rendering - Image refinement bridge:
refine_product_image(ComfyUI img2img on product images)
Planned:
- OAuth token-exchange flow for new-app auth.
License
MIT © Joe Miller
Support
If this saves you time, consider supporting development: