🎁 Get the FREE AI Skills Starter Guide β€” Subscribe β†’
BytesAgainBytesAgain
πŸ¦€ ClawHub

Clickbank Scraper

by @marlowne12

Scrape top ClickBank products by category with gravity scores, commission rates, and estimated monthly sales. Integrates with affiliate marketing automation...

Versionv1.0.0
Downloads284
TERMINAL
clawhub install clickbank-scraper

πŸ“– About This Skill


name: clickbank-scraper description: > Scrape top ClickBank products by category with gravity scores, commission rates, and estimated monthly sales. Integrates with affiliate marketing automation pipelines for Pinterest board generation and pin content creation. Part of Max's ClickBank affiliate marketing automation suite.

ClickBank Product Scraper

Autonomous scraper for high-performing ClickBank products. Pulls product metadata (gravity, commission, sales estimates) from CBTrends.com and exports structured JSON for pipeline integration.

Installation

npm install

Dependencies:

  • cheerio β€” HTML parsing
  • node-fetch β€” HTTP requests
  • node β‰₯ v16
  • Usage

    Basic Run

    node scraper.js
    
    Outputs to output/latest.json, output/products-YYYY-MM-DD.json

    With ClickBank Affiliate ID

    CB_AFFILIATE_ID=your_nickname node scraper.js
    
    Generates hoplinks with your affiliate ID embedded.

    Scheduled Runs

    Use OpenClaw cron or n8n workflows to run daily:
    {
      "job": "clickbank-scraper",
      "schedule": "0 9 * * *",
      "command": "CB_AFFILIATE_ID=your_id node scraper.js"
    }
    

    Output Format

    latest.json

    Always-current snapshot for real-time pipeline feeds.

    {
      "category": "Health & Fitness",
      "updatedAt": "2026-03-27T14:00:00Z",
      "products": [
        {
          "name": "Product Name",
          "vendorId": "vendor123",
          "gravity": 87.5,
          "avgSaleAmount": "$47.00",
          "commissionPct": 75,
          "rebillPct": 30,
          "hoplink": "https://yourname.clickbank.net/...",
          "estimatedMonthlySales": "$12000"
        }
      ]
    }
    

    products-YYYY-MM-DD.json

    Full daily archive for historical analysis.

    top10-YYYY-MM-DD.json

    Filtered to gravity > 50 for quick high-performers reference.

    Integration Use Cases

    1. Pinterest Board Automation

    Feed latest.json β†’ n8n workflow β†’ Auto-generate Pinterest pins for top 10 products

    2. Product Comparison Content

    Extract gravity + commission β†’ Generate comparison tables for blog posts

    3. Affiliate Performance Tracking

    Monitor gravity trends over time β†’ Pivot to rising winners

    4. Landing Page Personalization

    Cross-reference user interests β†’ Recommend high-gravity products

    Data Fields Reference

    | Field | Type | Description | |-------|------|-------------| | name | string | Product name | | vendorId | string | ClickBank vendor identifier | | gravity | number | Affiliate gravity (higher = more demand, 0-100+) | | avgSaleAmount | string | Average transaction value | | commissionPct | number | Commission rate (0-100%) | | rebillPct | number | Rebill/recurring commission % | | hoplink | string | Ready-to-use affiliate link | | estimatedMonthlySales | string | Rough sales estimate |

    Limitations

  • Single page per category (10 products) from CBTrends
  • Gravity data may lag 1-2 hours behind ClickBank live marketplace
  • No API key required (scrapes public data)
  • Categories limited to: Health & Fitness, Supplements, E-Business, Self-Help
  • Roadmap

  • [x] Health & Fitness category scraper
  • [ ] Multi-category support (Supplements, Self-Help, E-Business, Investing)
  • [ ] Pagination (pages 2-5 for 50+ products)
  • [ ] ClickBank Marketplace API integration (when account active)
  • [ ] Scheduled runs via cron
  • [ ] Gravity trend tracking over time
  • [ ] Email digest of top gainers/losers
  • Integration with n8n

    Example n8n workflow node:

    // n8n "Execute Command" node
    const exec = require('child_process').execSync;
    const result = exec('CB_AFFILIATE_ID=your_id node scraper.js', {
      cwd: '/path/to/clickbank-scraper'
    });
    return JSON.parse(result.toString());
    

    Integration with OpenClaw

    Use as a cron job or sub-agent:

    openclaw cron add clickbank-scraper \
      --schedule "0 9 * * *" \
      --command "cd path/to/scraper && node scraper.js"
    

    Author

    Max @ max-co.digital β€” Autonomous ClickBank affiliate marketing automation.

    License

    Proprietary β€” Part of Digital Helper Agency / max-co product suite.

    πŸ’‘ Examples

    Basic Run

    node scraper.js
    
    Outputs to output/latest.json, output/products-YYYY-MM-DD.json

    With ClickBank Affiliate ID

    CB_AFFILIATE_ID=your_nickname node scraper.js
    
    Generates hoplinks with your affiliate ID embedded.

    Scheduled Runs

    Use OpenClaw cron or n8n workflows to run daily:
    {
      "job": "clickbank-scraper",
      "schedule": "0 9 * * *",
      "command": "CB_AFFILIATE_ID=your_id node scraper.js"
    }