---
title: "Search the public Ad Library"
method: GET
path: "/v1/ads/library"
tags: ["Ad Library"]
---

# Search the public Ad Library

`GET /v1/ads/library`

Competitor and market research over the public ad archives. Meta's Ad Library
(`GET /ads_archive`) is searched with Zernio's own developer access, so `platform=meta` needs
no connected account at all. LinkedIn's Ad Library (`GET /rest/adLibrary`) runs on a connected
`linkedin` / `linkedinads` account, passed as `accountId`. Passing a Meta account as `accountId`
also selects Meta. Rows are returned in the platform's raw shape under `data`; `paging.after`
is an opaque cursor on both (`null` when exhausted).

**Meta coverage.** Political and social-issue ads are searchable worldwide. Every other ad is
in the archive only if it was delivered to the EU or UK within the last year, so a US-only
commercial advertiser is invisible. Spend, impressions and demographics are political-only
fields and are left out of the default projection; request them via `fields`. All customers
share Zernio's Meta quota, so a `429` means back off for a minute.

**LinkedIn coverage.** Ads served after June 1 2023, worldwide, kept for a year after their
last impression. EU-delivered ads carry impression ranges and the disclosed targeting facets.
Pages are capped at 25 ads (`limit` > 25 is a 400); `after` is the next offset.

Which params apply: `q`, `countries`, `limit`, `after` on both; `pageIds`, `adType`, `status`,
`platforms`, `mediaType`, `languages`, `searchType`, `fields`, `since`, `until` are Meta-only;
`advertiser` is LinkedIn-only. Passing a param the account's platform does not support is a 400
naming the param.

## Query parameters

- `platform` 'meta' | 'linkedin'
- `accountId` string
- `q` string
- `pageIds` string
- `advertiser` string
- `countries` string
- `adType` 'ALL' | 'POLITICAL_AND_ISSUE_ADS' | 'HOUSING_ADS' | 'EMPLOYMENT_ADS' | 'FINANCIAL_PRODUCTS_AND_SERVICES_ADS'
- `status` 'ACTIVE' | 'INACTIVE' | 'ALL'
- `platforms` string
- `mediaType` 'ALL' | 'IMAGE' | 'MEME' | 'VIDEO' | 'NONE'
- `languages` string
- `since` string, date
- `until` string, date
- `searchType` 'KEYWORD_UNORDERED' | 'KEYWORD_EXACT_PHRASE'
- `fields` string
- `limit` integer
- `after` string

## Response `200`

Archived ads (raw platform shape)

- object
  - `platform` 'meta' | 'linkedin', required
  - `data` object[], required
  - `paging` object, required
    - `after` string, nullable — Cursor for the next page; null when exhausted.
    - `total` integer — LinkedIn only. Total matching ads.

## Other responses

- `400` — Invalid request
- `401` — Unauthorized
- `403` — Ads access required (legacy plans need the Ads add-on; included on usage-based plans), or `payment_required`: the billing owner has no payment method on file and no legacy paid plan. Searches are free; the card keeps the shared archive quota for real accounts.
- `404` — The account or requested resource was not found or is not accessible. An account ID may have been disconnected and removed. Read GET /v1/accounts for current account IDs.
- `409` — The account exists but is inactive or needs reconnection. Reconnect it, then read GET /v1/accounts for its current account ID before retrying. Code: ads_connection_required.
- `501` — Only supported on Meta and LinkedIn accounts
- `503` — Meta's Ad Library is unavailable on Zernio's side (`PLATFORM_DISABLED`); LinkedIn searches are unaffected.

## Changes

- **2026-09-25** `2c04683ce694` — 12 info
  - added the optional property `details/adAccountId` to the response with the `400` status
  - added the optional property `details/adAccountId` to the response with the `404` status
  - added the optional property `details/adAccountId` to the response with the `409` status
  - added the optional property `details/createdObjects` to the response with the `400` status
  - …8 more
- **2026-09-16** `3e6ddf2a99ea` — 3 info
  - added the optional property `details/budgetScope` to the response with the `400` status
  - added the optional property `details/budgetScope` to the response with the `404` status
  - added the optional property `details/budgetScope` to the response with the `409` status
- **2026-09-15** `0dba7d004d75` — 6 info
  - added the optional property `details/quotaExhausted` to the response with the `400` status
  - added the optional property `details/quotaExhausted` to the response with the `404` status
  - added the optional property `details/quotaExhausted` to the response with the `409` status
  - added the optional property `details/quotaScope` to the response with the `400` status
  - …2 more
- **2026-09-10** `e70ed06e7150` — 2 info
  - added the media type `application/json` for the response with the status `404`
  - added the non-success response with the status `409`
- **2026-09-08** `d7a8fa118ef0` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/zernio/apis/zernio-api/changes/v1/ads/library/get.md)

---

[API](https://skmtc.dev/zernio/apis/zernio-api.md) · [All operations](https://skmtc.dev/zernio/apis/zernio-api/llms.txt) · [OpenAPI document](https://skmtc.dev/zernio/apis/zernio-api/revisions/b2325332041a?raw)
