scrape-ads

Community

Extract competitor Meta ads at scale

Authorclenisa
Version1.0.0
Installs0

System Documentation

What problem does it solve?

Provides an automated way to collect competitor ad data from the Facebook/Meta Ad Library so teams can analyze ad copy, spend, impressions, and creative metadata without manual browsing and copying.

Core Features & Use Cases

  • Headless Chromium scraping with anti-detection arguments and realistic user agent to reduce bot detection.
  • Batched processing with per-batch browser contexts and inter-company delays to mitigate rate limiting.
  • Two-stage extraction: DOM-based Library ID parsing with a fallback full-page text split to maximize data recovery.
  • Landing page URL resolution by extracting l.facebook.com redirect links and associating them with ads.
  • Outputs structured CSV rows per ad for competitor intelligence, ad spend monitoring, and marketing research workflows.
  • Use Case: Run a company list to harvest ad copy, start dates, status, impressions, spend, and landing URLs for competitive analysis dashboards.

Quick Start

Scrape the Meta Ad Library for State Farm and Allstate and save the results to ./ads.csv.

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: scrape-ads
Download link: https://github.com/clenisa/optimal-cli/archive/main.zip#scrape-ads

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 223,000+ vetted skills library on demand.