Tags active products that have any variant missing a SKU ('missing-sku') and/or barcode ('missing-barcode'), removing each tag once all variants have the field.
async def run(ctx): for product in await ctx.shopify.query(ACTIVE_PRODUCTS): missing_sku = any(not v.sku for v in product.variants)
How do you find products missing SKUs or barcodes on Shopify?
To find products missing SKUs or barcodes on Shopify, this template checks every variant and applies separate tags for missing SKUs and missing barcodes, removing each one once all of a product's variants carry the field. The two tags stay independent because the gaps have different owners: SKUs usually come from your own ops, barcodes from the supplier or GS1. Barcodes gate Google Shopping and marketplace listings; SKUs gate warehouses and inventory syncs.
Each gap is a channel rejection waiting to be discovered, and these blanks surface at the worst time, deep in a feed error log during a launch. As a standing check, the audit runs on schedule and the tags become the checklist your ops team clears at its own pace. The run report shows exactly which products would be flagged for which field, so the first pass sizes the problem honestly.
Last updated August 24, 2026
If you run a sharper version of this template, or something it inspired, send it in. We review every application and publish the good ones, credited to you or your agency.
AI writes real Python or TypeScript, a dry run rehearses it, you approve, it deploys.
Free plan · no card · 🇪🇺 EU data residency