Facebook Ad Library

Company Ads

Fetches all ads currently running for a specific company from the Meta Ad Library. Each ad includes ad_archive_id, page_name, is_active, publisher_platform, and a snapshot with body, images, videos, and display_format. Supports filtering by country, media_type, date range, and language with cursor-based pagination. Both GET and POST are supported. If the cursor becomes too large after extensive pagination, use POST and send the same parameters in the JSON body.

get/v1/facebook/adLibrary/company/ads

Query parameters

pageIdstring

The companies ad library page id. You can get this with my Search For Companies Endpoint. Can either use this or companyName

companyNamestring

The name of the company. Can either use this or pageId

countrystring

This can only be one country. It has to be the 2 letter code for the country. It defaults to ALL.

status'ALL' | 'ACTIVE' | 'INACTIVE'

Status of the ad. Defaults to ACTIVE.

media_type'ALL' | 'IMAGE' | 'VIDEO' | 'MEME' | 'IMAGE_AND_MEME' | 'NONE'

Media type of the ad. Defaults to ALL. Meme refers to ads with image and text. Not sure why they call it meme.

languagestring

Language to filter ads on. Needs to be 2 letter language code, ie EN, ES, FR, etc

sort_by'total_impressions' | 'relevancy_monthly_grouped'

Sort by impressions (high to low), or Most Recent (relevancy_monthly_grouped). Defaults to impressions.

start_datestring

Start date to search for. Format: YYYY-MM-DD

end_datestring

End date to search for. Format: YYYY-MM-DD

cursorstring

Cursor to paginate through results

trimboolean

Set to true for a trimmed down version of the response

Response

Successful response

Changes