← back to Consulting Designerwallcoverings Com
docs/aeo-drafts/collection-metafields/APPLY-metafields.sh
22 lines
#!/usr/bin/env bash
# TK-20 GATED — populate custom.faq + custom.category on the 3 AEO collections.
# The live theme (sections/dw-collection-hero.liquid) renders these as a VISIBLE
# FAQ + emits FAQPage + CollectionPage JSON-LD. DO NOT RUN until Steve GO.
# Requires SHOPIFY_ADMIN_TOKEN with write_products scope (collection metafields).
set -euo pipefail
TOKEN="${SHOPIFY_ADMIN_TOKEN:?export SHOPIFY_ADMIN_TOKEN first}"
STORE="designer-laboratory-sandbox.myshopify.com"
API="https://$STORE/admin/api/2024-10/graphql.json"
echo "== versace-wallpaper (6 FAQ) =="
curl -s "$API" -H "X-Shopify-Access-Token: $TOKEN" -H "Content-Type: application/json" \
--data-binary @"$(dirname "$0")/versace-wallpaper.metafieldsSet.json" | tee /tmp/aeo-mf-versace-wallpaper.json
echo "== osborne-little (6 FAQ) =="
curl -s "$API" -H "X-Shopify-Access-Token: $TOKEN" -H "Content-Type: application/json" \
--data-binary @"$(dirname "$0")/osborne-little.metafieldsSet.json" | tee /tmp/aeo-mf-osborne-little.json
echo "== zuber-wallcoverings (6 FAQ) =="
curl -s "$API" -H "X-Shopify-Access-Token: $TOKEN" -H "Content-Type: application/json" \
--data-binary @"$(dirname "$0")/zuber-wallcoverings.metafieldsSet.json" | tee /tmp/aeo-mf-zuber-wallcoverings.json