Use case

Facebook Ad Research for Agencies: Audits, Reports and Creative Boards

For a performance agency, the Meta Ad Library is free market research on every client's competitors. The problem is time: nobody wants to scroll through 400 ads before a pitch, or rebuild the same competitor slide every Monday. This guide shows the four research deliverables agencies sell most, how to produce each from Ad Library data with a few API calls, and a script that writes one CSV report per client.

Published 6 min read

Four deliverables built on Ad Library data

Agencies that do this well rarely sell "ad spying". They sell answers the client cares about, built on public data:

  1. The pitch audit. Before the first meeting: who the prospect competes with on Facebook and Instagram, how many ads each rival runs, which formats and offers dominate, and where the prospect is behind. Nothing wins a pitch faster than showing a prospect their market better than they know it.
  2. The onboarding competitor map. In the first weeks: a full inventory of competitors' active ads, grouped by landing page and creative, with the long-running winners highlighted.
  3. The weekly competitor report. Ongoing: what each competitor launched and stopped this week, with links to the ads. It keeps the client informed and gives the creative team a reason to test new angles.
  4. The creative inspiration board. For the creative team: the best-performing hooks, formats and visuals of the category, refreshed every month, saved before the media links expire.

All four rest on the same few calls: find advertisers, list their ads, look at the important ads in detail. What changes is how often you run them and how you present the result.

The calls behind every report

NeedEndpointNotes
Competitors of a clientGET /v1/pages/search?q=Advertisers running ads on a keyword, with page ids
Everything a competitor runsGET /v1/pages/{page_id}/adsUp to 30 ads per call, filters as in search
Ads on a theme across advertisersGET /v1/ads/search?q=Keyword, country, media type, platforms, dates
One ad in fullGET /v1/ads/{ad_id}Payer, EU reach by country, age and gender
Google and LinkedIn adsGET /v1/google/ads/search, GET /v1/linkedin/ads/searchSame key, same billing

The advertiser search is the starting point of every audit; the page ads API does most of the work. B2B clients usually care as much about LinkedIn as about Meta, and the LinkedIn Ad Library API reads it with the same key.

A per-client CSV report

The script below takes a list of clients, each with the page ids of its competitors, and writes one CSV per client with every active ad: advertiser, start date, days active, variants, format, platforms, landing page, the first line of the text and the link to the ad in the library. Open it in Google Sheets or Excel, sort by days_active or variants_count, and the winners are at the top.

import csv
import datetime
import os
import requests

API = "https://api.scrapeadlibrary.com"
HEADERS = {"X-API-Key": os.environ["SCRAPEADLIBRARY_API_KEY"]}
PAGES_PER_COMPETITOR = 2  # up to 60 ads, 2 credits
CLIENTS = {
    "acme-shoes": ["15087023444", "115939511520844"],
    "nordic-coffee": ["100064027342136"],
}


def competitor_ads(page_id, country):
    cursor = None
    for _ in range(PAGES_PER_COMPETITOR):
        params = {"status": "active", "country": country, "sort": "impressions"}
        if cursor:
            params.update(cursor=cursor)
        response = requests.get(f"{API}/v1/pages/{page_id}/ads", params=params, headers=HEADERS, timeout=60)
        response.raise_for_status()
        page = response.json()
        yield from page["data"]
        if not page["has_more"]:
            return
        cursor = page["next_cursor"]


today = datetime.date.today().isoformat()
for client, competitors in CLIENTS.items():
    with open(f"{client}-{today}.csv", "w", newline="", encoding="utf-8") as f:
        writer = csv.writer(f)
        writer.writerow(["advertiser", "started", "days_active", "variants", "format", "platforms",
                         "landing_page", "hook", "ad_library_url"])
        for page_id in competitors:
            for ad in competitor_ads(page_id, "US"):
                hook = (ad["body"] or "").split("\n")[0][:120]
                writer.writerow([ad["page"]["name"], (ad["started_at"] or "")[:10], ad["days_active"],
                                 ad["variants_count"], ad["format"], " ".join(ad["platforms"]),
                                 ad["link_url"], hook, ad["url"]])
    print("wrote", client)

For a weekly report, combine it with the daily diff of the competitor tracking guide: the CSV becomes "new this week" and "stopped this week" instead of the full inventory. To keep the creatives of the board, download images and videos the day you collect them; the creatives guide has the script, because media links expire after a few days.

Reading the report with a client

  • Sort by `days_active`. The top rows are the competitor ads that have survived longest, the closest public proxy for "this works".
  • Filter by `variants`. Creatives with many variants are being scaled; they show where a competitor is putting its budget.
  • Pivot by landing page. Count ads per landing page to see which products or offers each competitor pushes.
  • Read the hooks column. Forty opening lines in one column reveal the angles of a whole category in five minutes.

Clients often ask what competitors spend. Be straight with them: Meta publishes spend only for political ads. The ad spend guide explains which signals you can show instead and how to present them honestly.

Budgeting credits across clients

Every successful call costs one credit, whatever the number of ads it returns, and errors are free. That makes budgeting simple arithmetic: count calls, not ads.

DeliverableTypical callsFrequency
Pitch audit (5 competitors)1 advertiser search + 10 pages of ads + 10 ad details = 21Once per prospect
Weekly report (5 competitors)5 to 10 pages of adsWeekly, or daily for a diff
Creative board10 to 20 keyword searchesMonthly

A client with five competitors tracked daily needs about 150 calls a month; ten such clients, about 1,500. The first 65 calls every month are free and the rest cost $5 per 1,000 calls, with volume packs on the pricing page. Purchased credits stay valid for 12 months and are not a subscription, so a quiet month costs nothing. One account and one key can serve every client; create a separate API key per client in the dashboard, so you can revoke one when an engagement ends.

AI-assisted research with the MCP server

Strategists who prefer asking questions to writing scripts can use the same data inside Claude, ChatGPT, Cursor and other assistants through the MCP server. The assistant calls the API as tools (search ads, list a page's ads, get an ad, search advertisers, Google and LinkedIn libraries) and answers questions like "which of these three brands has the most video ads running for more than 30 days, and what do their hooks have in common?". Tool calls are billed exactly like API calls.

# Remote connector (OAuth login, no key in the config)
claude mcp add --transport http scrapeadlibrary https://api.scrapeadlibrary.com/mcp

# Or the local server, with your API key
SCRAPEADLIBRARY_API_KEY=sal_your_key uvx scrapeadlibrary-mcp

It is a fast way to explore a new category before building the repeatable report. Ask the assistant to show the ad ids and Ad Library links it relied on, so every claim in a client deck can be checked.

From scripts to a product

When the reports become a service, move from scripts to the official SDKs: pip install scrapeadlibrary or npm install scrapeadlibrary (SDK docs). They handle retries, typed responses and cursor pagination, and raise typed errors for the error codes. The API reference documents every parameter, and how to scrape the Facebook Ad Library is a good first read for a developer joining the team. To get started, create a free account and run the first audit on the free calls.

Frequently asked questions

Can one account serve several agency clients?
Yes. One account holds one credit balance; create one API key per client in the dashboard and revoke it when the engagement ends.
Can I share the ads with my clients?
Share findings and links to the public Ad Library freely. Republishing a competitor's creatives is another matter: they are copyrighted works, so keep them for internal analysis and inspiration.
How often should a competitor report run?
Weekly is enough for most clients. Run the underlying collection daily if you want to catch short tests that start and stop within the week.
Does it cover Instagram and other platforms?
Yes. Meta's library covers Facebook, Instagram, Messenger, Threads and the Audience Network, and the same API key reads the Google Ads Transparency Center and the LinkedIn Ad Library.

Related guides

← All guides

Try it on your own competitors

Create a free account and get 65 free calls every month, no credit card. One API key works on every endpoint.