Critical Fixes for ITBlogPros Article Generator

Issue 1: Meta-Commentary Still Visible on Live Site

Root Cause: The article file is clean, but the live site shows cached content.

Solutions:

  1. Force GitHub Cache Clear:

    # After committing changes, add an empty commit to force rebuild
    git commit --allow-empty -m "Force rebuild to clear cache"
    git push
    
  2. Clear Cloudflare Cache:

    curl -X POST "https://api.cloudflare.com/client/v4/zones/YOUR_ZONE_ID/purge_cache" \
         -H "Authorization: Bearer YOUR_API_TOKEN" \
         -H "Content-Type: application/json" \
         --data '{"purge_everything":true}'
    
  3. Clear Browser Cache:

  4. Verify Article File is Clean:

    # Check the actual file
    cat posts/2025-11-26-wifi-7-slower-than-expected-despite-high-specifications.md
    # Should NOT contain any "Word Count Check" or meta-commentary
    

Issue 2: Amazon Links Not Verified

Root Cause: The generator uses placeholder ASINs but doesn't verify:

  1. If the ASIN is a real product
  2. If the affiliate tag is correct
  3. If the link actually works

Current ASINs in the article (need verification):

Solution: Add Amazon ASIN verification to the generator.


Quick Verification Commands

# 1. Check if article file is clean
cat posts/2025-11-26-wifi-7-slower-than-expected-despite-high-specifications.md | grep -i "word count\|draft\|i'll now\|i'm good"

# 2. Check Amazon links in Eleventy config
grep "itblogpros100-20" .eleventy.js

# 3. Test Amazon link format
# Should produce: https://www.amazon.com/dp/B0CNJ5M2K9?linkCode=ll1&tag=itblogpros100-20&linkId=generated&language=en_US&ref_=as_li_ss_tl

# 4. Force rebuild
npm run build
# or
npx @11ty/eleventy

Immediate Actions Needed

1. Clear All Caches (Do this NOW)

# Commit and force rebuild
git add .
git commit -m "Clean article - force rebuild"
git commit --allow-empty -m "Force cache clear"
git push

# Wait 2-3 minutes for Cloudflare Pages to rebuild
# Then check the live site in incognito mode

2. Verify Amazon Links Work

Open each link manually to check:

https://www.amazon.com/dp/B0CNJ5M2K9?tag=itblogpros100-20
https://www.amazon.com/dp/B0C9D9183H?tag=itblogpros100-20
https://www.amazon.com/dp/B0CL2G998Z?tag=itblogpros100-20

Should redirect to real products with your affiliate tag.

3. Test the Generator

cd _automation
node gemini-article-generator.js test

Check the generated article for:


Long-term Fix: Add Amazon Verification

I'll create an enhanced generator with:

  1. Amazon ASIN validation
  2. Link testing
  3. Automatic affiliate tag verification
  4. Product existence checks

This will be in: gemini-article-generator-enhanced.js