GET /v1/meta_ads/stored/advertiser/ads

Meta Ad Library stored ads API: an advertiser's ad history by page id

Returns one tracked advertiser's stored ads as Posts, running ads first and then the newest start, with the advertiser as an Account. Send the page_id; active_only=true lists only running ads, and next_cursor goes back as cursor while has_more is true. This is a stored read: an advertiser we never stored is a 404, is not billed and never starts a crawl.

Price
$0.0005 per call
Batch
Yes, through /v1/batch
Failed calls
Not charged

Example request

curl
curl 'https://api.virev.ai/v1/meta_ads/stored/advertiser/ads?page_id=15087023444&limit=2' \
  -H "Authorization: Bearer $VIREV_API_KEY"
python
import os
import requests

response = requests.request(
    "GET",
    "https://api.virev.ai/v1/meta_ads/stored/advertiser/ads",
    params={
        "page_id": "15087023444",
        "limit": "2",
    },
    headers={"Authorization": f"Bearer {os.environ['VIREV_API_KEY']}"},
    timeout=60,
)
response.raise_for_status()
print(response.json())

Parameters

NameInTypeDescription
page_id requiredquerystringThe numeric Facebook Page id of a tracked advertiser. Example 15087023444.
limit queryintegerAds per page. Default 30.
active_only querybooleantrue lists only running ads. Default false.
cursor querystringnext_cursor from the previous page.

Example response

The example response of the API reference, with lists cut to their first 3 items and long text shortened.

json
{
  "data": {
    "advertiser": {
      "id": "15087023444",
      "username": "nike",
      "full_name": "Nike",
      "is_verified": null,
      "is_private": false,
      "avatar_url": "https://api.virev.ai/v1/media/meta_advertiser/15087023444/profile_pic?e=1793750400&s=98b4bdad4fd7074de644339239015e70",
      "latest_story_at": null,
      "extra": {
        "category": "Sportswear Store",
        "likes": 39494438,
        "is_deleted": false,
        "url": "https://www.facebook.com/nike"
      }
    },
    "items": [
      {
        "id": "1476143881043704",
        "shortcode": null,
        "taken_at": "2026-10-23T07:00:00+00:00",
        "kind": "carousel",
        "product_type": "DPA",
        "caption": "Get the gear that goes hard on and off the field.",
        "hashtags": [],
        "mentions": [],
        "accessibility_caption": null,
        "likes": null,
        "comments": null,
        "views": null,
        "counts_hidden": null,
        "comments_disabled": null,
        "is_pinned": null,
        "is_paid_partnership": false,
        "owner": {
          "id": "15087023444",
          "username": "nike",
          "full_name": "Nike",
          "is_verified": null,
          "is_private": false,
          "avatar_url": "https://api.virev.ai/v1/media/meta_advertiser/15087023444/profile_pic?e=1793750400&s=98b4bdad4fd7074de644339239015e70",
          "latest_story_at": null,
          "extra": {
            "category": "Sportswear Store",
            "likes": 39494438,
            "is_deleted": false,
            "url": "https://www.facebook.com/nike"
          }
        },
        "coauthors": [],
        "sponsors": [],
        "tagged": [],
        "location": null,
        "audio": null,
        "thumbnail_url": "https://api.virev.ai/v1/media/meta_ad_creative/4407/creative?e=1793750400&s=b5fe69728cf5cce311c8723c83a61107",
        "video_duration": null,
        "media": [
          {
            "kind": "image",
            "url": "https://api.virev.ai/v1/media/meta_ad_creative/4407/creative?e=1793750400&s=b5fe69728cf5cce311c8723c83a61107",
            "width": null,
            "height": null,
            "duration": null
          },
          {
            "kind": "image",
            "url": "https://api.virev.ai/v1/media/meta_ad_creative/4408/creative?e=1793750400&s=53cbbe4d84e633f6ee5d3af20cfdfcd1",
            "width": null,
            "height": null,
            "duration": null
          },
          {
            "kind": "image",
            "url": "https://api.virev.ai/v1/media/meta_ad_creative/4409/creative?e=1793750400&s=413d351393d9d36507b651045f84a6b7",
            "width": null,
            "height": null,
            "duration": null
          }
        ],
        "media_urls": [
          "https://api.virev.ai/v1/media/meta_ad_creative/4407/creative?e=1793750400&s=b5fe69728cf5cce311c8723c83a61107",
          "https://api.virev.ai/v1/media/meta_ad_creative/4408/creative?e=1793750400&s=53cbbe4d84e633f6ee5d3af20cfdfcd1",
          "https://api.virev.ai/v1/media/meta_ad_creative/4409/creative?e=1793750400&s=413d351393d9d36507b651045f84a6b7"
        ],
        "extra": {
          "url": "https://www.facebook.com/ads/library/?id=1476143881043704",
          "is_active": true,
          "end_date": "2026-10-27T07:00:00+00:00",
          "title": "{{product.name}}",
          "link_caption": "NIKE.COM",
          "link_url": "https://www.nike.com/",
          "link_domain": "nike.com",
          "cta_type": "SHOP_NOW",
          "cta_text": "Shop now",
          "collation_id": null,
          "collation_count": null,
          "publisher_platforms": [
            "facebook",
            "instagram"
          ],
          "countries": [],
          "categories": [
            "UNKNOWN"
          ],
          "currency": null
        }
      },
      {
        "id": "1120113070497516",
        "shortcode": null,
        "taken_at": "2026-10-23T07:00:00+00:00",
        "kind": "carousel",
        "product_type": "DPA",
        "caption": "Get the gear not afraid to put in the work.",
        "hashtags": [],
        "mentions": [],
        "accessibility_caption": null,
        "likes": null,
        "comments": null,
        "views": null,
        "counts_hidden": null,
        "comments_disabled": null,
        "is_pinned": null,
        "is_paid_partnership": false,
        "owner": {
          "id": "15087023444",
          "username": "nike",
          "full_name": "Nike",
          "is_verified": null,
          "is_private": false,
          "avatar_url": "https://api.virev.ai/v1/media/meta_advertiser/15087023444/profile_pic?e=1793750400&s=98b4bdad4fd7074de644339239015e70",
          "latest_story_at": null,
          "extra": {
            "category": "Sportswear Store",
            "likes": 39494438,
            "is_deleted": false,
            "url": "https://www.facebook.com/nike"
          }
        },
        "coauthors": [],
        "sponsors": [],
        "tagged": [],
        "location": null,
        "audio": null,
        "thumbnail_url": "https://api.virev.ai/v1/media/meta_ad_creative/4395/creative?e=1793750400&s=c7ccfb5a4aaefaeddfb3b504498e7a70",
        "video_duration": null,
        "media": [
          {
            "kind": "image",
            "url": "https://api.virev.ai/v1/media/meta_ad_creative/4395/creative?e=1793750400&s=c7ccfb5a4aaefaeddfb3b504498e7a70",
            "width": null,
            "height": null,
            "duration": null
          },
          {
            "kind": "image",
            "url": "https://api.virev.ai/v1/media/meta_ad_creative/4396/creative?e=1793750400&s=ddb11cc45f38f4745e4ffec542e6b3fa",
            "width": null,
            "height": null,
            "duration": null
          },
          {
            "kind": "image",
            "url": "https://api.virev.ai/v1/media/meta_ad_creative/4397/creative?e=1793750400&s=4f9840c411c5fbfc47f4a11f41784cc8",
            "width": null,
            "height": null,
            "duration": null
          }
        ],
        "media_urls": [
          "https://api.virev.ai/v1/media/meta_ad_creative/4395/creative?e=1793750400&s=c7ccfb5a4aaefaeddfb3b504498e7a70",
          "https://api.virev.ai/v1/media/meta_ad_creative/4396/creative?e=1793750400&s=ddb11cc45f38f4745e4ffec542e6b3fa",
          "https://api.virev.ai/v1/media/meta_ad_creative/4397/creative?e=1793750400&s=4f9840c411c5fbfc47f4a11f41784cc8"
        ],
        "extra": {
          "url": "https://www.facebook.com/ads/library/?id=1120113070497516",
          "is_active": true,
          "end_date": "2026-10-27T07:00:00+00:00",
          "title": "{{product.name}}",
          "link_caption": "NIKE.COM",
          "link_url": "https://www.nike.com/",
          "link_domain": "nike.com",
          "cta_type": "SHOP_NOW",
          "cta_text": "Shop now",
          "collation_id": null,
          "collation_count": null,
          "publisher_platforms": [
            "facebook",
            "instagram"
          ],
          "countries": [],
          "categories": [
            "UNKNOWN"
          ],
          "currency": null
        }
      }
    ],
    "next_cursor": "W3RydWUsIjIwMjYtMTAtMjNUMDc6MDA6MDArMDA6MDAiLCIxMTIwMTEzMDcwNDk3NTE2Il0",
    "has_more": true
  },
  "meta": {
    "cost": "$0.0005",
    "balance": "$49.9895",
    "request_id": "req_e3ecdc90108dc8d1c45f61acf4d1d3e3"
  }
}

How it works

One tracked advertiser's stored ads as Posts, running ads first and then the newest start. Pass next_cursor back as cursor while has_more is true; active_only=true lists only running ads. The answer also carries the advertiser as an Account.

Strictly DB: this reads what the crawler already stored and never crawls. An advertiser we never stored is a 404 and is not billed. Read fresh ads with /v1/meta_ads/company_ads.

Errors

StatusWhen
400The request parameters are invalid.
401Missing, malformed, or revoked API key.
402Balance is too low for this request.
404Advertiser not tracked. You are not charged.
429Over the per-minute limit. The limit belongs to your organization and all its API keys share it: 100 requests per minute unless an increase was granted. Wait for the Retry-After seconds, then retry. On a live read, code rate_limited means the platform itself rate-limited this read; retry after the Retry-After seconds. You are not charged.
502The upstream fetch failed. You are not charged.
503Billing could not be confirmed, so no upstream data was returned.
504The upstream request timed out. You are not charged.

Guides that use this endpoint