# Facebook Posts Scraper (`scrapeengine/facebook-posts-scraper`) Actor

Scrape Facebook posts from public pages and profiles with ease 📘📢 Extract post text, dates, reactions, comments, shares, media, and more. Perfect for competitor research, content analysis, audience insights, and trend tracking. Turn Facebook data into actionable insights fast 🚀

- **URL**: https://apify.com/scrapeengine/facebook-posts-scraper.md
- **Developed by:** [ScrapeEngine](https://apify.com/scrapeengine) (community)
- **Categories:** Social media, Developer tools, Automation
- **Stats:** 6 total users, 2 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$19.99/month + usage

To use this Actor, you pay a monthly rental fee to the developer. The rent is subtracted from your prepaid usage every month after the free trial period.You also pay for the Apify platform usage, which gets cheaper the higher Apify subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#rental-actors

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

### Facebook Posts Scraper

Facebook Posts Scraper is a fast, reliable Facebook post scraper tool that collects public posts from Facebook pages and public profiles at scale. It discovers the page/profile ID and the correct GraphQL operation from live Facebook, then fetches the timeline with cursor-based pagination — no browser required. Built for marketers, developers, analysts, and researchers, this Facebook page posts scraper turns feeds into structured datasets for competitor tracking, content analysis, audience insights, and trend monitoring. Use it as a Facebook posts API alternative to scrape Facebook posts and export Facebook posts to CSV, JSON, or Excel for your workflows 🚀

### What data / output can you get?

Below are real output fields as they appear in the dataset. Results are export-ready (JSON, CSV, Excel) and accessible via the Apify dataset.

| Data type | Description | Example value |
| --- | --- | --- |
| facebookUrl | Input-normalized Facebook target URL | https://www.facebook.com/nytimes/ |
| postId | Unique post identifier | 1234567890123456 |
| pageName | Page or profile slug taken from the URL | nytimes |
| url | Direct URL to the post (falls back to canonical permalink) | https://www.facebook.com/100044185428261/posts/1397878851694949 |
| time | ISO timestamp string (UTC) | 2024-11-15T10:41:16.000Z |
| timestamp | Unix timestamp (seconds) | 1731667276 |
| user | Author/page metadata (id, name, profileUrl, profilePic) | {"id":"100044185428261","name":"The New York Times","profileUrl":"https://www.facebook.com/100044185428261","profilePic":"https://..."} |
| collaborators | Co-author/collaborator metadata when present | [] |
| text | Post text (caption). Can be emptied by input option | "New launch today..." |
| likes | Aggregate reactions count | 40224 |
| comments | Total comment count | 2279 |
| shares | Total share count | 1484 |
| topReactionsCount | Sum of top reactions | 7 |
| reactionLikeCount | Like reaction count | 35000 |
| reactionLoveCount | Love reaction count | 4200 |
| reactionHahaCount | Haha reaction count | 510 |
| reactionCareCount | Care reaction count | 90 |
| reactionSadCount | Sad reaction count | 50 |
| reactionWowCount | Wow reaction count | 1200 |
| reactionAngryCount | Angry reaction count | 174 |
| media | Image/media attachments with metadata (thumbnails, dimensions, optional OCR text) | [{"thumbnail":"https://...","photo_image":{"uri":"https://...","height":720,"width":720},"url":"https://...","id":"987654321"}] |
| feedbackId | Facebook feedback node ID | ZmVlZGJhY2s6MTM5Nzg3ODg1MTY5NDk0OQ== |
| topLevelUrl | Canonical permalink constructed from IDs | https://www.facebook.com/100044185428261/posts/1397878851694949 |
| facebookId | ID of the owning profile/page | 100044185428261 |
| pageAdLibrary | Ad Library reference with page ID | {"id":"100044185428261"} |
| inputUrl | Original input target for traceability | https://www.facebook.com/nytimes/ |

Note: The media array can include optional ocrText extracted from accessibility captions when available. Exports are available directly from the Apify dataset as JSON, CSV, or Excel.

### Key features

- 🔍 Robust feed extraction (no browser)
  Uses production-style GraphQL requests with dynamic doc_id discovery and the correct x-fb-friendly-name for pages vs. profiles. Efficiently fetches timeline posts with cursor-based pagination.

- 🔐 Anti-blocking with proxy preference
  Automatically prefers Apify Residential proxy, falls back to Apify Datacenter, and supports your custom proxy URLs. Built-in retries and exponential backoff handle empty or rate-limited responses.

- 🧠 Smart date filtering
  Filter posts by absolute dates (YYYY-MM-DD) or relative ranges like “7 days”, “2 months”, or “1 year” via the input. Filters are applied to the request and validated client-side.

- 📈 Full engagement metrics + reaction breakdown
  Collect aggregate reactions (“likes”), comments, shares, and top reactions by type (Like, Love, Haha, Care, Sad, Wow, Angry) for richer performance analysis.

- 🖼️ Media metadata with optional OCR captions
  Capture thumbnails, image dimensions, and attachment URLs. Includes accessibility captions (ocrText) when available in the media metadata.

- 🔗 Clean, canonical URLs
  Get a direct post URL and a canonical permalink (topLevelUrl) to ensure reliable tracing across exports and pipelines.

- 📦 Stream-to-dataset design
  Posts are queued and pushed to the dataset as they’re discovered, enabling faster iteration and monitoring on long runs.

- 👨‍💻 Developer-friendly and export-ready
  Use as a Facebook posts API alternative: integrate Apify datasets via API, export to CSV/JSON/Excel, and plug into your analytics or ETL workflows. Great for Facebook posts scraper Python workflows and automation.

- 🚀 Built for scale and stability
  Sequential target processing reduces rate limits. Deduplication and cursor-based pagination enable deep timelines for large-scale Facebook posts data extraction.

### How to use Facebook Posts Scraper - step by step

1. Sign in to Apify  
   Create or log in to your Apify account to access the Facebook Posts Scraper actor.

2. Add targets in startUrls  
   Provide Facebook page URLs or usernames. Examples:  
   - Full URL: https://www.facebook.com/nytimes/  
   - Username only: nytimes, Cristiano  
   You can mix formats; each page/profile is processed sequentially.

3. Set maxPosts per target  
   Control depth with maxPosts (1–10,000). The scraper stops once it reaches this count for each target.

4. (Optional) Configure date range  
   - oldestPostDateUnified: Include posts after this date. Accepts absolute (e.g., 2024-01-01) or relative values (e.g., 7 days, 2 months).  
   - newestPostDate: Include posts before this date. Supports absolute or relative values.

5. (Optional) Toggle Include Video Transcripts  
   Set includeVideoTranscript to true or false based on your needs. Default is false. When off, video posts still appear with metadata, but their transcript text is not included; the post text field can be emptied for faster runs.

6. (Optional) Proxy settings  
   Leave proxyConfiguration empty to prefer Apify Residential/Datacenter automatically, or supply custom proxy URLs.

7. Run the actor  
   Click Start. The run sequentially processes each target, paginates their timeline, applies filters, and pushes posts to the dataset in real time.

8. Download/export results  
   Open the run’s dataset to preview and download as JSON, CSV, or Excel — perfect for dashboards, BI tools, or further ETL. Ideal for “export Facebook posts to CSV” workflows.

Pro tip: Use the Apify API to automate this Facebook posts data export tool, or schedule runs in Make/n8n for recurring reporting.

### Use cases

| Use case name | Description |
| --- | --- |
| Marketing analytics – competitor post tracking | Monitor competitor pages, scrape Facebook posts, and compare reaction breakdowns to identify winning content themes and timing. |
| Content research – editorial planning | Analyze public posts to discover trending topics and formats; use the Facebook feed scraper output to inform your content calendar. |
| Social listening – brand health | Track brand pages or partner profiles and quantify audience response using likes, comments, shares, and reaction types. |
| Data enrichment – dashboards & BI | Feed structured post metrics into dashboards; this Facebook posts data extractor provides clean fields for direct ingestion. |
| Academic & media studies | Export long-run timelines as CSV/JSON to study engagement, topics, and public communication patterns. |
| Automation pipelines (API) | Run the Facebook posts crawler on a schedule and pull results via API for automated reporting and archiving. |

### Why choose Facebook Posts Scraper?

Facebook Posts Scraper is built for precision, automation, and reliability — a production-grade Facebook posts API alternative without headless browsers.

- 🎯 Accuracy-first extraction: Discovers the correct GraphQL doc_id and timeline operation from live bundles.
- 🧱 Stable at scale: Sequential processing, cursor-based pagination, and retries/backoff for resilience.
- 🌍 Public data focus: Targets public pages and profiles for ethical monitoring and analysis.
- 🔌 Integration-ready: Export JSON/CSV/Excel or access via API for BI tools, warehouses, and internal apps.
- 👨‍💻 Developer access: Structured fields with consistent types simplify downstream parsing and analysis.
- 🛡️ Anti-blocking strategy: Prefers Residential proxy with Datacenter fallback; supports custom proxies.
- 💰 Cost-effective vs browser extensions: Avoids brittle browser automation and unstable plugins while maintaining reliability.

In short: a production-ready Facebook posts scraping tool that outperforms unstable, browser-bound alternatives.

### Is it legal / ethical to use Facebook Posts Scraper?

Yes — when used responsibly. This Facebook public posts scraper is designed for publicly available page and profile data.

Guidelines for compliant use:
- Only target and process public content.
- Do not attempt to access private or restricted data.
- Understand and respect Facebook’s terms of use.
- Ensure your processing aligns with applicable data protection laws (e.g., GDPR, CCPA).
- Consult your legal team for edge cases or regulated use.

### Input parameters & output format

Example input
```json
{
  "startUrls": [
    "nytimes",
    "https://www.facebook.com/Cristiano/"
  ],
  "maxPosts": 50,
  "includeVideoTranscript": false,
  "oldestPostDateUnified": "7 days",
  "newestPostDate": "",
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
````

Parameters (from the schema):

- startUrls (array, required)\
  Description: Enter one or more Facebook page targets. Accepts full URLs (e.g., https://www.facebook.com/nytimes/) or usernames (e.g., nytimes). Targets are scraped in sequence.\
  Default: none (required)

- maxPosts (integer, optional)\
  Description: Limit how many posts to collect per target page. Minimum 1, maximum 10,000.\
  Default: 10

- includeVideoTranscript (boolean, optional)\
  Description: Capture video captions & transcripts toggle as defined in the input description. ON extracts caption/transcript text; OFF collects video posts with metadata without transcript text.\
  Default: false

- oldestPostDateUnified (string, optional)\
  Description: Only include posts after this date. Accepts absolute dates (YYYY-MM-DD) or relative values (e.g., 7 days, 2 months, 1 year).

- newestPostDate (string, optional)\
  Description: Only include posts before this date. Accepts absolute dates or relative values (e.g., 0 for today).

- proxyConfiguration (object, optional)\
  Description: Proxy settings. The actor prefers Apify Residential proxy when available, falls back to Apify Datacenter, and supports custom proxy URLs.\
  Default: {"useApifyProxy": false}

Example output

```json
{
  "facebookUrl": "https://www.facebook.com/nytimes/",
  "postId": "1397878851694949",
  "pageName": "nytimes",
  "url": "https://www.facebook.com/100044185428261/posts/1397878851694949",
  "time": "2024-11-15T10:41:16.000Z",
  "timestamp": 1731667276,
  "user": {
    "id": "100044185428261",
    "name": "The New York Times",
    "profileUrl": "https://www.facebook.com/100044185428261",
    "profilePic": "https://scontent.xx.fbcdn.net/v/t39.30808-1/....jpg"
  },
  "collaborators": [],
  "text": "Big stories of the week...",
  "likes": 40224,
  "comments": 2279,
  "shares": 1484,
  "topReactionsCount": 7,
  "reactionLikeCount": 35000,
  "reactionLoveCount": 4200,
  "reactionHahaCount": 510,
  "reactionCareCount": 90,
  "reactionSadCount": 50,
  "reactionWowCount": 1200,
  "reactionAngryCount": 174,
  "media": [
    {
      "thumbnail": "https://scontent.xx.fbcdn.net/v/t39.30808-6/....jpg",
      "__typename": "Photo",
      "__isMedia": "Photo",
      "accent_color": "FFFFFFFF",
      "photo_product_tags": [],
      "photo_image": {
        "uri": "https://scontent.xx.fbcdn.net/v/t39.30808-6/....jpg",
        "height": 720,
        "width": 720
      },
      "url": "https://www.facebook.com/photo/?fbid=...",
      "id": "987654321",
      "feedback": {
        "can_viewer_comment": true,
        "id": "ZmVlZGJhY2s6OTg3NjU0MzIx"
      },
      "ocrText": "Aerial view of..."
    }
  ],
  "feedbackId": "ZmVlZGJhY2s6MTM5Nzg3ODg1MTY5NDk0OQ==",
  "topLevelUrl": "https://www.facebook.com/100044185428261/posts/1397878851694949",
  "facebookId": "100044185428261",
  "pageAdLibrary": {
    "id": "100044185428261"
  },
  "inputUrl": "https://www.facebook.com/nytimes/"
}
```

Fields that may be empty/unknown:

- text can be set to an empty string depending on your includeVideoTranscript setting.
- media may be empty if the post has no media attachments.
- ocrText inside media appears only when accessibility captions are available.

### FAQ

#### Does this scrape Facebook pages or profiles?

Yes. The actor bootstraps both Facebook Pages and public Profiles, then uses the correct timeline GraphQL operation for each. Provide either a page URL or a username in startUrls.

#### Can it scrape Facebook groups?

The actor focuses on public pages and profiles. If you need a Facebook public group posts scraper, contact support to discuss feasibility and customization.

#### Do I need to log in or provide cookies?

No. This Facebook posts scraping tool works without login. It uses browser-like HTTP/TLS fingerprints and prefers Apify proxies to improve reliability.

#### How many posts can I download per target?

Use maxPosts to set the limit per target. It supports 1 to 10,000 posts per page/profile in a single run.

#### How do date filters work?

Use oldestPostDateUnified to include posts newer than a given date and newestPostDate to include posts older than a date. Both accept absolute dates (YYYY-MM-DD) or relative phrases (e.g., 7 days, 2 months).

#### What engagement data is included?

For each post, you get an aggregate “likes” count (total reactions), comments count, shares count, and a breakdown by reaction type: Like, Love, Haha, Care, Sad, Wow, Angry.

#### Do you collect comments text or only counts?

Only counts. This Facebook comments scraper focuses on counts and reaction metrics; it does not capture full comment threads or bodies.

#### How do I export results?

Open the run’s dataset to download as JSON, CSV, or Excel. You can also access the dataset via the Apify API for programmatic pipelines and “export Facebook posts to CSV” automations.

#### Which proxies are used?

The scraper prefers Apify Residential proxy, falls back to Apify Datacenter, and supports custom proxy URLs. Configure proxyConfiguration or leave it empty to use defaults.

#### Is this an alternative to the Facebook posts API?

Yes. It’s a practical Facebook posts API alternative for public page/profile data, delivering structured outputs suitable for analytics and automation.

### Closing CTA / Final thoughts

Facebook Posts Scraper is built for fast, reliable Facebook posts extraction at scale. It helps marketers, developers, data analysts, and researchers export structured post data — with reaction breakdowns, media metadata, and canonical URLs — without brittle browser automation. Set your targets, choose maxPosts and dates, run the scraper, and export clean JSON/CSV/Excel or pull via API. Developers can integrate it into Python pipelines or automation platforms for scheduled refreshes. Start extracting smarter Facebook insights today.

# Actor input Schema

## `startUrls` (type: `array`):

📌 **Required.** Enter one or more Facebook *page* targets.

• **Full URL:** `https://www.facebook.com/nytimes/` or `https://www.facebook.com/Cristiano/`
• **Username only:** `nytimes`, `Cristiano`, `iamsrk` — the actor will turn these into full URLs.

You can mix URLs and usernames. Each target is scraped in sequence (one page after another) to reduce rate limits. 🔄

## `maxPosts` (type: `integer`):

🎯 **Limit how many posts to collect *per target page*.**

• Minimum: **1** — Maximum: **10,000**.
• Default: **10** — Good for quick tests.
• Increase for deeper timelines (e.g. 50–500). The actor stops once this count is reached for each page. 🛑

## `includeVideoTranscript` (type: `boolean`):

📝 **Capture video captions & transcripts!**

• **ON** ✨ — Extracts closed captions/transcripts from video & reel posts into the output.
• **OFF** — Video posts still appear with metadata, but no transcript text.

Default: **OFF** for faster scraping. Turn **ON** when you need subtitle/caption data. 🎬

## `timeoutMode` (type: `string`):

Choose how per-target timeout is determined. **Auto** scales timeout from requested post count. **Manual** uses your custom timeout value.

## `targetTimeoutSecs` (type: `integer`):

Used only when Timeout Mode is set to **Manual**. The actor will stop a target when this time limit is reached.

## `oldestPostDateUnified` (type: `string`):

⏳ **Only include posts *after* this date.**

• **Absolute:** Pick a calendar date (e.g. `2024-01-01`).
• **Relative:** e.g. `7` days, `2` months, `1` year — counted backward from today.

Leave empty to allow posts from any past date. Combines with "Posts Older Than" for a window. 🗓️

## `newestPostDate` (type: `string`):

🛑 **Only include posts *before* this date.**

• **Absolute:** e.g. `2024-12-31`.
• **Relative:** e.g. `0` for “today” or a number of days/months/years ago.

Use together with "Posts Newer Than" to scrape a precise date range. Leave empty for no end limit. 📆

## `proxyConfiguration` (type: `object`):

🛡️ **Anti-block & reliability.**

• The actor **prefers Apify Residential proxy** when available for higher success rates.
• If residential isn’t set, it falls back to **Apify Datacenter** proxy.
• You can optionally provide **custom proxy URLs** here as a fallback.

No proxy configuration is required for basic runs; the actor will use Apify proxy when possible. 🔒

## Actor input object example

```json
{
  "startUrls": [
    "iamsrk",
    "https://www.facebook.com/nytimes/"
  ],
  "maxPosts": 10,
  "includeVideoTranscript": false,
  "timeoutMode": "auto",
  "targetTimeoutSecs": 1200,
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# 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 = {
    "startUrls": [
        "https://www.facebook.com/nytimes"
    ],
    "proxyConfiguration": {
        "useApifyProxy": false
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("scrapeengine/facebook-posts-scraper").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 = {
    "startUrls": ["https://www.facebook.com/nytimes"],
    "proxyConfiguration": { "useApifyProxy": False },
}

# Run the Actor and wait for it to finish
run = client.actor("scrapeengine/facebook-posts-scraper").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "startUrls": [
    "https://www.facebook.com/nytimes"
  ],
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}' |
apify call scrapeengine/facebook-posts-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=scrapeengine/facebook-posts-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Facebook Posts Scraper",
        "description": "Scrape Facebook posts from public pages and profiles with ease 📘📢 Extract post text, dates, reactions, comments, shares, media, and more. Perfect for competitor research, content analysis, audience insights, and trend tracking. Turn Facebook data into actionable insights fast 🚀",
        "version": "0.1",
        "x-build-id": "Pl6XIj4giJGJ4TfZv"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/scrapeengine~facebook-posts-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-scrapeengine-facebook-posts-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/scrapeengine~facebook-posts-scraper/runs": {
            "post": {
                "operationId": "runs-sync-scrapeengine-facebook-posts-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/scrapeengine~facebook-posts-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-scrapeengine-facebook-posts-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "startUrls"
                ],
                "properties": {
                    "startUrls": {
                        "title": "🔗 Facebook Page URLs or Usernames",
                        "type": "array",
                        "description": "📌 **Required.** Enter one or more Facebook *page* targets.\n\n• **Full URL:** `https://www.facebook.com/nytimes/` or `https://www.facebook.com/Cristiano/`\n• **Username only:** `nytimes`, `Cristiano`, `iamsrk` — the actor will turn these into full URLs.\n\nYou can mix URLs and usernames. Each target is scraped in sequence (one page after another) to reduce rate limits. 🔄",
                        "items": {
                            "type": "string"
                        }
                    },
                    "maxPosts": {
                        "title": "📊 Maximum Posts per Page",
                        "minimum": 1,
                        "maximum": 1000000,
                        "type": "integer",
                        "description": "🎯 **Limit how many posts to collect *per target page*.**\n\n• Minimum: **1** — Maximum: **10,000**.\n• Default: **10** — Good for quick tests.\n• Increase for deeper timelines (e.g. 50–500). The actor stops once this count is reached for each page. 🛑",
                        "default": 10
                    },
                    "includeVideoTranscript": {
                        "title": "🎥 Include Video Transcripts",
                        "type": "boolean",
                        "description": "📝 **Capture video captions & transcripts!**\n\n• **ON** ✨ — Extracts closed captions/transcripts from video & reel posts into the output.\n• **OFF** — Video posts still appear with metadata, but no transcript text.\n\nDefault: **OFF** for faster scraping. Turn **ON** when you need subtitle/caption data. 🎬",
                        "default": false
                    },
                    "timeoutMode": {
                        "title": "⏱️ Timeout Mode",
                        "enum": [
                            "auto",
                            "manual"
                        ],
                        "type": "string",
                        "description": "Choose how per-target timeout is determined. **Auto** scales timeout from requested post count. **Manual** uses your custom timeout value.",
                        "default": "auto"
                    },
                    "targetTimeoutSecs": {
                        "title": "⏳ Per-Target Timeout (seconds)",
                        "minimum": 60,
                        "maximum": 72000,
                        "type": "integer",
                        "description": "Used only when Timeout Mode is set to **Manual**. The actor will stop a target when this time limit is reached.",
                        "default": 1200
                    },
                    "oldestPostDateUnified": {
                        "title": "📅 Posts Newer Than (Start Date)",
                        "type": "string",
                        "description": "⏳ **Only include posts *after* this date.**\n\n• **Absolute:** Pick a calendar date (e.g. `2024-01-01`).\n• **Relative:** e.g. `7` days, `2` months, `1` year — counted backward from today.\n\nLeave empty to allow posts from any past date. Combines with \"Posts Older Than\" for a window. 🗓️"
                    },
                    "newestPostDate": {
                        "title": "⌛ Posts Older Than (End Date)",
                        "type": "string",
                        "description": "🛑 **Only include posts *before* this date.**\n\n• **Absolute:** e.g. `2024-12-31`.\n• **Relative:** e.g. `0` for “today” or a number of days/months/years ago.\n\nUse together with \"Posts Newer Than\" to scrape a precise date range. Leave empty for no end limit. 📆"
                    },
                    "proxyConfiguration": {
                        "title": "🌐 Proxy Settings",
                        "type": "object",
                        "description": "🛡️ **Anti-block & reliability.**\n\n• The actor **prefers Apify Residential proxy** when available for higher success rates.\n• If residential isn’t set, it falls back to **Apify Datacenter** proxy.\n• You can optionally provide **custom proxy URLs** here as a fallback.\n\nNo proxy configuration is required for basic runs; the actor will use Apify proxy when possible. 🔒"
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
