# How do I research Meta ads through an API?

How do I research Meta ads through an API? Follow concrete contracts, examples and reviewable steps using Meta Ad Library.

Canonical page: https://datanavoapi.com/en/answers/meta-ad-library-api/

This is a local simulation. Program-generated samples are not live platform data and do not establish provider availability.

## Answer

Start by inspecting the contracts and local samples for Meta Ad Library search, Meta ad detail, Meta advertiser's ads. Establish the input for meta.ads.search, then check whether its ad object contains the fields your task needs.

Document the input scope, sampling rule and intended use, and preserve request IDs and missing-field markers. An API supplies the contracted sample; interpretation still requires checks of context and representativeness.

## Relevant contracts

| Capability | Object | Shape | Pagination |

| --- | --- | --- | --- |

| meta.ads.search | Ad | items | Explicit cursor |

| meta.ads.get | Ad | item | No cursor |

| meta.advertisers.ads.list | Ad | items | Explicit cursor |

- [Meta Ad Library search](https://datanavoapi.com/en/apis/meta/ads/search/)
- [Meta ad detail](https://datanavoapi.com/en/apis/meta/ads/get/)
- [Meta advertiser's ads](https://datanavoapi.com/en/apis/meta/advertisers/ads/list/)

## Input contract

Inspect meanings, examples and conditional rules for the selected method. view and fields control the response without changing the TEST unit price.

- Only send fields defined for this method; unknown fields are rejected before execution.

| Method | Field | Type | Requirement | Meaning | Enum or bound | Example |

| --- | --- | --- | --- | --- | --- | --- |

| GET | query | string | Required | Search terms | — | "running shoes" |

| GET | region | string | Optional / conditional | Only ads delivered in this country or region, by its two-letter code; all of them when left out | — | — |

| GET | sort | string | Optional / conditional | By impressions, highest first, or newest first | ["popular","latest"] | — |

| GET | type | string | Optional / conditional | Only image ads or only video ads; all of them when left out | ["image","video"] | — |

| GET | cursor | string | Optional / conditional | The `next_cursor` of the previous page. A new page is a new call. | — | — |

| GET | view | string | Optional / conditional | How much of each item: compact (the most used fields, long text cut short), standard, or full (adds `ext`). | ["compact","standard","full"] | — |

| GET | fields | array | Optional / conditional | Return only these fields of each item, by path (`author.name`). | maxItems: 64 | — |

## Complete one verification

Run one local fixture for a listed capability and inspect the object structure. Then filter, classify or export according to the question. A local sample cannot replace evidence for a real-platform conclusion.

```json
{
  "capability": "meta.ads.search",
  "method": "GET",
  "params": {
    "query": "running shoes"
  }
}
```

## Related pages

- [Meta Ad Library search](https://datanavoapi.com/en/apis/meta/ads/search/)
- [Meta ad detail](https://datanavoapi.com/en/apis/meta/ads/get/)
- [Meta advertiser's ads](https://datanavoapi.com/en/apis/meta/advertisers/ads/list/)
- [Meta Ad Library APIs](https://datanavoapi.com/en/apis/meta/)
- [Meta Ad Library MCP](https://datanavoapi.com/en/mcp/meta/)
- [Ad fields](https://datanavoapi.com/en/docs/objects/ad/)
- [Ad creative research workflow](https://datanavoapi.com/en/skills/ads/)
- [Competitor content research workflow](https://datanavoapi.com/en/skills/competitors/)
- [Which data tools fit a marketing research task?](https://datanavoapi.com/en/answers/chinese-social-media-marketing-data-tools/)

[中文](https://datanavoapi.com/answers/meta-ad-library-api/)
