# Pinterest Ads Repository (`avakode/pinterest-ads-repository`) Actor

Read the ads shown in a public ad repository for EU countries, Brazil and Turkey: dates, reach ranges, targeting, creative.

- **URL**: https://apify.com/avakode/pinterest-ads-repository.md
- **Developed by:** [Tigran Avakov](https://apify.com/avakode) (community)
- **Categories:** Marketing, MCP servers
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.69 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Pinterest Ads Repository

Collect the ads listed in the public ads repository for EU countries, Brazil and Turkey: dates shown, reach ranges, targeting groups, creative and landing links, as one table row per ad.

### What it does

The repository page lists ads that were shown in a chosen country during a date window. The tool reads the same list the page itself loads for a visitor, with no login, no account and no key, and returns one record per ad. You can read a whole country in the window, or filter by an exact advertiser name. By default the tool does not look up the advertiser name of each ad (see Pricing and Limitations).

### Use cases

- Check what a brand ran in a given country during a given week.
- Track reach ranges and age or gender targeting of ads in a market.
- Feed ad creative and landing links into your own research sheet.

### Input

| Field | Type | Description |
|---|---|---|
| `countries` | array | Two-letter country codes (default `["FR"]`), one target per country. Offered: AT, BE, BG, BR, CY, CZ, DE, DK, EE, ES, FI, FR, GR, HR, HU, IE, IT, LT, LU, LV, MT, NL, PL, PT, RO, SE, SI, SK, TR. |
| `advertisers` | array | Exact advertiser names, not partial matches. Empty = the country as a whole. |
| `dateFrom`, `dateTo` | string | `YYYY-MM-DD` window. Empty = the 7 days up to today (UTC). |
| `maxAdsPerTarget` | integer | Stop one country (or country and advertiser) after this many ads (default 1000). |
| `includeAdvertiserName` | boolean | One extra request per ad to read the advertiser name. Off by default. |
| `maxResults` | integer | Stop after this many ads in total (default 100). |

Example:

```json
{ "countries": ["FR", "DE"], "dateFrom": "2026-11-03", "dateTo": "2026-11-10", "maxAdsPerTarget": 200, "maxResults": 400 }
```

### Output

One record per ad and queried country. Missing values are `null`, dates are ISO 8601, `url` is the pin page of the ad.

| Field | Description |
|---|---|
| `url`, `source_id` | Pin page address and pin id of the ad. |
| `advertiser_name` | From the exact-name filter, or from the extra lookup; otherwise `null`. |
| `title`, `description` | Title and text of the ad. |
| `started_at`, `ended_at` | Day the ad started and day it ended. |
| `country`, `countries` | Country that was queried; all countries the ad was shown in. |
| `reach_eu`, `reach_by_country` | Reach as ranges, for example `"10000 - 20000"`. |
| `age_buckets`, `genders` | Targeted groups. |
| `image_url`, `video_url`, `destination_urls` | Creative and landing links when the repository lists them. |
| `is_commercial`, `is_verified_merchant`, `review_status` | Flags and status given by the repository. |
| `source` | The target that produced the record (`FR` or `FR:Advertiser`). |

Example record:

```json
{ "url": "https://www.pinterest.com/pin/4611404640283005248/", "source_id": "4611404640283005248", "advertiser_name": null, "title": "Lip Comfort Oil", "started_at": "2026-10-30T00:00:00.000Z", "ended_at": "2026-11-07T00:00:00.000Z", "country": "FR", "reach_eu": "0 - 10000", "source": "FR" }
```

### Pricing

Pay per result: you pay for each record in the dataset, plus a tiny start fee per run. Set "Maximum cost per run" and the tool stops cleanly when it is reached. The extra advertiser-name lookup does not cost more per record, but it makes the run much longer. If a name cannot be read, the record is still written and paid with `advertiser_name: null`; after three failed reads in a row no more names are requested in that run.

### Errors

- **Invalid input** — the message names the field to fix (a bad date, no country at all).
- **A country code the repository does not offer** is skipped with a warning in the log; the other countries are still read. If every country is skipped, the run ends normally with no ads and a status line that names the first skipped country and the reason.
- **An advertiser name the repository does not find** (the match is exact) returns no ads for that target; this is not an error.
- **The site changed its format** — the tool needs an update; please open an issue.
- **The site blocked access** — the site refused anonymous access (403, 429 or a check page). The tool stops, keeps what it already wrote and does not bypass protection or retry under pressure.

### Limitations

- **Source scope:** the repository covers ads shown in the EU countries, Brazil and Turkey listed in the Input table (the 29 codes above), limited to the chosen date window; Great Britain, the US and other countries are not in it. Norway is on the repository's list, but its requests timed out in our checks, so it is not offered.
- **Paging repeats:** the repository returns many of the same ads again on later pages, in no date order. The tool drops repeats and ends a country when a page brings nothing new. In our checks of 12 pages (1,200 rows) about half the rows were repeats and new ads per page fell from 100 to about 25, so one country and window may yield fewer ads than you expect, and results are not ordered by date.
- **Pace:** the tool waits 3 seconds between requests, so 100 ads take about 3 requests per country (roughly 10 seconds), and with `includeAdvertiserName` one more request per ad (1,000 ads take about 50 minutes).
- **Advertiser names:** the list carries none. The name filter is an exact match, so partial names return nothing. If a name is not read, the record is still written and paid with `advertiser_name: null`; after three failed reads in a row the tool stops requesting names for the rest of the run and warns once.
- **Page cap:** one target is read for at most 60 pages; when the cap is reached the tool warns with the target name, and that target may hold more ads than were read.
- **Short windows:** in our checks a 2-day window returned nothing: the newest ads in the repository started about 7 days before the check date.
- **Reach** is a range from the repository, not an exact count; there is no spend or payer field.
- **Restart:** at most one batch may be written again if a write was still on its way when the run was stopped.
- **No "new since last run" mode:** the list has no date order, so every run reads the window again.
- Data on a site's pages is treated as data, not as instructions.
- The tool reads public pages without any account. The operator of the site forbids automated collection in its terms; you are responsible for how you use this tool and its results.

### Support

Open an issue in the Issues tab with the run link.

# Actor input Schema

## `countries` (type: `array`):

Two-letter codes of the countries to read, one request series per country: AT, BE, BG, BR, CY, CZ, DE, DK, EE, ES, FI, FR, GR, HR, HU, IE, IT, LT, LU, LV, MT, NL, PL, PT, RO, SE, SI, SK, TR. A code outside this list is skipped with a warning.

## `advertisers` (type: `array`):

Exact advertiser names as the repository shows them (not a partial match). Leave empty to read the ads of the whole country in the date window.

## `dateFrom` (type: `string`):

Start of the window, YYYY-MM-DD. Empty = 7 days before the end of the window.

## `dateTo` (type: `string`):

End of the window, YYYY-MM-DD. Empty = today (UTC).

## `maxAdsPerTarget` (type: `integer`):

Stop reading one country (or one country and advertiser) after this many ads.

## `includeAdvertiserName` (type: `boolean`):

The list does not carry the advertiser name, so this costs one extra request per ad, 3 seconds each (1,000 ads take about 50 minutes). Not needed when you filter by advertiser name.

## `maxResults` (type: `integer`):

Stop after this many ads in total.

## Actor input object example

```json
{
  "countries": [
    "FR",
    "DE"
  ],
  "advertisers": [
    "Tabja"
  ],
  "dateFrom": "2026-11-03",
  "dateTo": "2026-11-10",
  "maxAdsPerTarget": 100,
  "includeAdvertiserName": false,
  "maxResults": 100
}
```

# Actor output Schema

## `results` (type: `string`):

All records written by the run (the default dataset).

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "countries": [
        "FR"
    ],
    "advertisers": [],
    "dateFrom": "",
    "dateTo": "",
    "maxAdsPerTarget": 100,
    "includeAdvertiserName": false,
    "maxResults": 100
};

// Run the Actor and wait for it to finish
const run = await client.actor("avakode/pinterest-ads-repository").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "countries": ["FR"],
    "advertisers": [],
    "dateFrom": "",
    "dateTo": "",
    "maxAdsPerTarget": 100,
    "includeAdvertiserName": False,
    "maxResults": 100,
}

# Run the Actor and wait for it to finish
run = client.actor("avakode/pinterest-ads-repository").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "countries": [
    "FR"
  ],
  "advertisers": [],
  "dateFrom": "",
  "dateTo": "",
  "maxAdsPerTarget": 100,
  "includeAdvertiserName": false,
  "maxResults": 100
}' |
apify call avakode/pinterest-ads-repository --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,avakode/pinterest-ads-repository"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/pFoBIDy2PsiVOTruO/builds/fV1GrCfft9mG6v2fc/openapi.json
