---
title: "Ads"
description: "Meta 광고 라이브러리를 검색하거나, 한 광고주가 Facebook, Instagram, Messenger, Audience Network에 집행하는 모든 광고를 가져옵니다."
---

> Every apinoa docs page as markdown: https://apinoa.com/llms.txt (all in one file: https://apinoa.com/llms-full.txt; this API family in one file: https://apinoa.com/docs/ads/llms.txt)

```http
GET | POST /v1/meta-ads/ads
```

파라미터는 `GET`의 쿼리 문자열로도, `POST`의 JSON 본문으로도 보낼 수 있습니다. 둘은 같습니다.

## 요청

```bash tab="cURL"
curl "https://gateway.apinoa.com/v1/meta-ads/ads?advertiser=15087023444&status=all" \
  -H "x-api-key: $APINOA_API_KEY"
```

```js tab="JavaScript"
const params = new URLSearchParams({ advertiser: "15087023444", status: "all" });
const res = await fetch(`https://gateway.apinoa.com/v1/meta-ads/ads?${params}`, {
  headers: { "x-api-key": process.env.APINOA_API_KEY },
});
const { success, data, error } = await res.json();
```

```python tab="Python"
import os

import requests

res = requests.get(
    "https://gateway.apinoa.com/v1/meta-ads/ads",
    params={"advertiser": "15087023444", "status": "all"},
    headers={"x-api-key": os.environ["APINOA_API_KEY"]},
)
body = res.json()
```

## 넘길 값

| 넘기는 값 | 읽는 것 | 비고 |
|---|---|---|
| `query` | 키워드에 맞는 광고 | `exact`는 구절 전체가 맞는 것만 |
| `advertiser` | 한 광고주가 집행하는 모든 광고 | 광고주의 `id`. [`advertisers`](/docs/api-reference/meta-ads/advertisers)나 광고의 `advertiser.id`에서 얻습니다 |
| `query` + `advertiser` | 키워드에 맞는 광고 중 이 광고주들의 것만 | id 최대 10개, 쉼표로 구분 |

`query`나 `advertiser`, 또는 둘 다 넘기세요. 필터(`country`, `status`, `adType`, `mediaType`, `platforms`, `languages`, `startDate`, `endDate`, `sort`)는 어느 쪽과도 함께 쓸 수 있습니다.

## 파라미터

| Parameter | Type | Required | Notes |
|---|---|---|---|
| `adType` | enum |  | all (default), or one special category: political (social issues, elections or politics), housing, employment, credit. `all` `political` `housing` `employment` `credit` |
| `advertiser` | string list |  | The advertiser's id, as `advertisers` returns it (or an ad's `advertiser.id`): every ad it runs. With `query`, up to 10 ids, comma-separated, narrow the keyword search to those advertisers. |
| `country` | string |  | Where the ads ran: an ISO 3166-1 alpha-2 code, or ALL (default). |
| `cursor` | string |  | Opaque cursor from the previous page's `cursor`. Pass it alone for the next page. |
| `endDate` | string |  | Only ads that started running on or before this day (YYYY-MM-DD). |
| `exact` | boolean |  | query: match the exact phrase instead of any of its words. |
| `languages` | string list |  | Only ads in these languages (ISO 639-1). |
| `mediaType` | enum |  | all (default), image, video, meme, image_and_meme, none. `all` `image` `video` `meme` `image_and_meme` `none` |
| `platforms` | string list |  | Only ads that ran on these platforms. |
| `query` | string |  | Keywords to search the Ad Library for. |
| `sort` | enum |  | relevance (default), or impressions (highest first; Facebook states impressions for political ads). `relevance` `impressions` |
| `startDate` | string |  | Only ads that started running on or after this day (YYYY-MM-DD). |
| `status` | enum |  | active (default), inactive or all. `active` `inactive` `all` |

The same parameters, and every response type, are in the OpenAPI document: https://apinoa.com/openapi.json

## 응답

`data`에 [`AdPage`](/docs/api-reference/ads/response-schema#adpage)를 돌려줍니다. 실제 응답을 줄인 것입니다. 배열은 앞쪽 항목만 남기고 긴 텍스트는 잘랐습니다.

```json
{
  "success": true,
  "data": {
    "library": "meta-ads",
    "items": [
      {
        "library": "meta-ads",
        "id": "1702938977100376",
        "url": "https://www.facebook.com/ads/library/?id=1702938977100376",
        "advertiser": {
          "id": "15087023444",
          "name": "Nike",
          "url": "https://www.facebook.com/nike/",
          "avatarUrl": "https://scontent-bos5-1.xx.fbcdn.net/v/t39.35426-6/431756959_71287105437…",
          "ext": {
            "likes": 39488420,
            "categories": [
              "Sportswear",
              "Product/service"
            ]
          }
        },
        "format": "DPA",
        "title": "{{product.name}}",
        "text": "Bring sports more fully into your day with the Nike App.",
        "linkUrl": "http://itunes.apple.com/app/id1095459556",
        "ctaText": "Install now",
        "images": [],
        "videos": [],
        "cards": [
          {
            "title": "Nike Run Swift 3 Women's Road Running Shoes",
            "text": "Bring sports more fully into your day with the Nike App.",
            "linkUrl": "https://www.nike.com/ph/t/run-swift-3-road-running-shoes-2fHbzp/DR2698-0…",
            "ctaText": "Install Now",
            "image": {
              "url": "https://scontent-bos5-1.xx.fbcdn.net/v/t39.35426-6/431679131_94921416663…",
              "ext": {
                "resizedUrl": "https://scontent-bos5-1.xx.fbcdn.net/v/t39.35426-6/431679131_94921416663…"
              }
            },
            "ext": {
              "caption": "itunes.apple.com",
              "linkDescription": "₱3,995",
              "ctaType": "INSTALL_MOBILE_APP"
            }
          },
          {
            "title": "Nike Invincible 3 Women's Road Running Shoes",
            "text": "Bring sports more fully into your day with the Nike App.",
            "linkUrl": "https://www.nike.com/ph/t/invincible-3-road-running-shoes-LL61DX/DR2660-…",
            "ctaText": "Install Now",
            "image": {
              "url": "https://scontent-bos5-1.xx.fbcdn.net/v/t39.35426-6/431631323_92872743202…",
              "ext": {
                "resizedUrl": "https://scontent-bos5-1.xx.fbcdn.net/v/t39.35426-6/431631323_92872743202…"
              }
            },
            "ext": {
              "caption": "itunes.apple.com",
              "linkDescription": "₱9,895",
              "ctaType": "INSTALL_MOBILE_APP"
            }
          }
        ],
        "firstShownAt": "2025-04-07T07:00:00.000Z",
        "lastShownAt": "2026-11-07T08:00:00.000Z",
        "ext": {
          "active": true,
          "platforms": [
            "facebook",
            "instagram"
          ],
          "caption": "itunes.apple.com",
          "ctaType": "INSTALL_MOBILE_APP",
          "has_user_reported": false,
          "gated_type": "ELIGIBLE",
          "is_aaa_eligible": false,
          "regional_regulation_data": {
            "finserv": {
              "is_deemed_finserv": false,
              "is_limited_delivery": false
            },
            "tw_anti_scam": {
              "is_limited_delivery": false
            }
          },
          "hide_data_status": "NONE",
          "snapshot": {
            "is_reshared": false
          }
        }
      }
    ],
    "cursor": "FBe_2wsngLShai3Nb8Z3btwLqnQCPM5mfHmg_xoJDSWCYQpot_7Bie7WzcRR96xHrpnClTN0…",
    "total": 15646,
    "ext": {
      "searchType": "page",
      "countries": [
        "ALL"
      ],
      "status": "all",
      "adType": "all",
      "mediaType": "all",
      "advertiser": "15087023444"
    }
  }
}
```

## 에러

| 상태 | 코드 | 의미 |
|---|---|---|
| 400 | `INVALID_CURSOR` | 이 오퍼레이션이 돌려준 `cursor`가 아닙니다. `cursor` 없이 처음부터 다시 시작하세요. |
| 400 | `INVALID_PARAMS` | 파라미터가 없거나, 알 수 없거나, 범위를 벗어났습니다. 메시지에 이름이 나옵니다. |
| 401 | `UNAUTHORIZED` | `x-api-key` 헤더가 없거나, 폐기되었거나 알 수 없는 키입니다. |
| 402 | `INSUFFICIENT_CREDITS` | 크레딧이 이 호출 비용에 모자랍니다. 대시보드에서 플랜을 고르거나 충전하세요. |
| 429 | `MARKETPLACE_SATURATED` | 동시 호출이 너무 많습니다. `Retry-After` 초만큼 기다린 뒤 다시 시도하세요. |
| 502 | `UPSTREAM_ERROR` | 라이브러리가 쓸 수 없는 응답을 보냈습니다. 간격을 두고 다시 시도하세요. |

모든 코드는 [Errors](/docs/errors)에 있습니다. 실패한 호출은 과금되지 않습니다.

## 가격

**Price** 1 credit per call. [Plans and credits](https://apinoa.com/en/pricing).

## 참고

- `total`은 맞는 광고 수를 광고 라이브러리가 밝힌 그대로 담습니다. 50,000을 넘으면 그 이상이라고만 밝히므로, 대신 `totalRange`(`{"lower": 50000}`)가 옵니다.
- 사회 문제·선거·정치 광고(`adType=political`)에는 범위(`{text, lower, upper}`)로 된 `spend`, `impressions`, `reach`와 `currency`, 광고비를 낸 주체(`paidBy`)도 있습니다.
- `country`는 ISO 3166-1 alpha-2 코드 하나, 또는 `ALL`(기본값)입니다. `startDate`와 `endDate`는 광고가 집행을 시작한 날을 제한합니다.
- 각 광고의 `ext`에는 Meta만 밝히는 값이 있습니다: `active`, `platforms`(집행된 곳), `adId`, `activeSeconds`, 크리에이티브의 `caption`, `linkDescription`, `ctaType`, 광고비 주체 공시의 나머지(`disclaimer`: 라벨, Meta가 주체를 확인한 방법, 연락처), `collationId`와 `collationCount`(Meta가 한 크리에이티브로 묶은 광고), `sensitive`, 그리고 광고 라이브러리가 보내는 다른 모든 필드를 그 이름 그대로. 광고주의 `ext`에는 `likes`, `categories`, 광고에 쓰인 이름(`nameInAd`), `deleted`가 있고, 이미지와 동영상은 Meta의 다른 사본(`resizedUrl`, `watermarkedUrl`, `sdUrl` 등)을 각자의 `ext`에 둡니다.
- 응답의 `ext`는 광고 라이브러리가 실제로 적용한 검색 조건입니다.
- 다음 페이지는 `cursor`만 넘기면 됩니다.
