dist/codex/shopify-commerce/skills/shopify-catalog/SKILL.md
Manage Shopify catalog — Product, Variant, and Option models, collections, metafields and metaobjects, inventory management, product taxonomy, bulk operations, and media. Use when working with Shopify product data.
npx skillsauth add orcaqubits/agentic-commerce-claude-plugins shopify-catalogInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Fetch live docs:
site:shopify.dev graphql admin api product for product queries and mutationssite:shopify.dev metafields metaobjects for custom data APIssite:shopify.dev inventory management api for inventory operationshttps://shopify.dev/docs/api/admin-graphql and search for productCreate, metafieldsSet, bulkOperationRunQuery for current input schemassite:shopify.dev product variant options 2025 for latest variant limits and option changesProduct
├── Title, description, vendor, type, tags
├── Status: ACTIVE, DRAFT, ARCHIVED
├── Options (up to 3): Size, Color, Material
├── Variants (combinations of options)
│ ├── Price, compare-at price
│ ├── SKU, barcode
│ ├── Inventory (per location)
│ └── Weight, dimensions
├── Media (images, video, 3D models)
├── Metafields (custom data)
└── Collections (many-to-many)
| Operation | Mutation | Notes |
|-----------|----------|-------|
| Create product | productCreate | Returns product ID + userErrors |
| Update product | productUpdate | Partial updates supported |
| Delete product | productDelete | Removes all variants and media |
| Create variant | productVariantCreate | Specify options + price + inventory |
| Bulk update variants | productVariantsBulkUpdate | Up to 100 variants per call |
| Manage media | productCreateMedia | Images, video, 3D models |
| Set metafield | metafieldsSet | Works on any resource |
Fetch live docs for exact mutation input types and required fields — these evolve with each quarterly API version.
# Pattern: paginated product query with cursor
# Fetch live docs for current available fields
query Products($first: Int!, $after: String) {
products(first: $first, after: $after) {
edges {
node {
id
title
handle
status
variants(first: 10) {
edges { node { id sku price } }
}
}
}
pageInfo { hasNextPage endCursor }
}
}
Two types:
Smart collection rules support: tag, title, type, vendor, variant_price, variant_compare_at_price, variant_weight, variant_inventory, variant_title.
Typed key-value pairs on any resource:
custom.care_instructions){{ product.metafields.custom.care_instructions.value }}| Type | Example Value | Use Case |
|------|--------------|----------|
| single_line_text | "Organic cotton" | Short text |
| multi_line_text | "Line 1\nLine 2" | Descriptions |
| number_integer | 42 | Counts, quantities |
| number_decimal | 3.14 | Measurements |
| boolean | true | Flags |
| date | "2025-01-15" | Dates |
| json | {"key": "value"} | Structured data |
| url | "https://..." | Links |
| color | "#FF0000" | Colors |
| file_reference | GID | Images, files |
| product_reference | GID | Related products |
| list.single_line_text | ["a", "b"] | Multi-value |
Fetch live docs for the full list of metafield types — new types are added periodically (e.g.,
money,rating,dimension).
# Pattern: set metafields on any resource
mutation MetafieldsSet($metafields: [MetafieldsSetInput!]!) {
metafieldsSet(metafields: $metafields) {
metafields { id namespace key value }
userErrors { field message }
}
}
# Fetch live docs for MetafieldsSetInput fields — ownerId, namespace, key, type, value
Standalone custom content types:
metaobjectCreateFetch live docs: Web-search
site:shopify.dev metaobject definition createfor schema creation and entry management.
Multi-location inventory tracking:
inventoryAdjustQuantities — adjust stock by delta (+/-)inventorySetQuantities — set absolute quantityreceived, correction, shrinkage, promotion, etc.Fetch live docs for
InventoryAdjustQuantitiesInputfields — the input shape and available reason codes evolve.
Shopify's standard product taxonomy:
productCategory field on productsFor large catalog operations (> 250 items):
bulkOperationRunQuery — submit a GraphQL query for bulk exportcurrentBulkOperation query until status is COMPLETEDurl field__parentId)stagedUploadsCreate — get a presigned URLbulkOperationRunMutation — process the staged uploadFetch live docs: Web-search
site:shopify.dev bulk operationsfor current input format, JSONL structure, and polling patterns.
userErrors in mutation responses — 200 status does not mean successFetch the Shopify product and metafield API documentation for exact mutation inputs, metafield types, and bulk operation patterns before implementing.
development
Build with Spree's headless Next.js storefront — the official `spree/storefront` repo (Next.js 16 App Router with Server Actions and Turbopack, React 19 Server Components, Tailwind CSS 4, TypeScript 5, `@spree/sdk`, Sentry), server-only auth (httpOnly JWT cookies + publishable key), MeiliSearch faceted catalog, one-page checkout with Apple/Google Pay/Klarna/Affirm/SEPA, multi-region market routing, GA4 + JSON-LD SEO, and Vercel/Docker deployment. Use when forking or customizing the storefront, or evaluating headless adoption.
tools
Build Spree extensions as Rails engines — gem scaffolding, `bin/rails g spree:extension`, mounting routes/migrations/assets, the modern `prepend` decorator pattern (`*_decorator.rb` with `self.prepended(base)`), generators (`spree:model_decorator`, `spree:controller_decorator`), the four customization surfaces in preference order (Events > Webhooks > Dependencies > Decorators), Spree::Dependencies for swapping service objects, gem release/versioning, and the deprecated Deface engine. Use when building a reusable Spree extension or adding non-trivial customization to an app.
development
Build with Spree's event bus and Webhooks 2.0 — `Spree::Events` publication, `Spree::Subscriber` DSL with `subscribes_to` and `on`, wildcard matching, lifecycle events (`{model}.created/.updated/.deleted` via `publishes_lifecycle_events`), the canonical event catalog (order.*, payment.*, shipment.*, product.*), Webhooks 2.0 endpoints, HMAC-SHA256 signing (`X-Spree-Webhook-Signature`), exponential-backoff retries, and Sidekiq job orchestration. Use when wiring event-driven business logic, building webhook consumers, or replacing ActiveSupport callback chains.
tools
Cross-cutting Spree development patterns — the customization preference hierarchy (Events > Webhooks > Dependencies > Decorators), `Spree::Dependencies` service-object swapping, the `_decorator.rb` + `prepend` + `self.prepended` idiom, idempotent subscribers and webhook receivers, multi-store scoping discipline, prefixed IDs, calculator polymorphism (shipping/promotion/tax share the base), service-object composition with `dry-monads` or simple results, why to avoid `class_eval` reopening and Deface, and Spree-on-Rails idioms (Hotwire/Turbo Stimulus, ActiveStorage, Action Cable, Sidekiq). Use when designing the architecture of a Spree extension or solving cross-cutting concerns.