# Facebook Comment Thread Audit (`apifmcpfactory/facebook-comment-thread-audit`) Actor

Audit saved Facebook comment threads and see where a source parent is missing. For a paid audit set Maximum cost per run to $0.001 or pass maxTotalChargeUsd=0.001 in the API. Apify run usage is separate.

- **URL**: https://apify.com/apifmcpfactory/facebook-comment-thread-audit.md
- **Developed by:** [Howth Technology Factory](https://apify.com/apifmcpfactory) (community)
- **Categories:** Social media, Automation
- **Features:** Limited permissions
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.00 / 1,000 saved comment thread audits

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

Learn more: https://docs.apify.com/actors/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

## Facebook Comment Thread Audit

Find where your saved comment export leaves a gap. The audit shows which replies have their parent in the same sample, which parents sit outside it and which relationships need a source check.

![Thread coverage report in a monitor](https://howthtechnologyfactory.pro/assets/facebook-comment-thread-audit/01-find-thread-gaps.png)

### Get started

1. Run **Preview the report** to see the relationship categories with demo data.
2. Choose **Review saved data**. Enter the original Facebook post links and the time the source collected the sample in UTC.
3. Choose one input. Select an Apify dataset with Read access, paste structured comment rows, or paste metadata from saved Graph responses you have permission to use.
4. Open the report and review the relationship categories. Download the result dataset in JSON, CSV or XLSX when you need the rows in another tool.

### Prepare your input

For rows, use `facebookUrl` and a string `commentId`. Add `parentCommentId`, `isReply`, `date` and `commentUrl` if your source supplied them. Keep IDs as strings to preserve digits.

For a saved Graph response, wrap each post as `{ "postUrl": "…", "topLevel": true, "hasMorePages": false, "response": { "data": [] } }`. Set `topLevel` to `true` only when the source response is known to contain direct comments on that post at its first level. Use `hasMorePages` when the source indicated additional pages. Keep `id`, `parent.id`, `created_time` and `comments.data`. Before pasting, remove access tokens, paging URLs, names, profile links and raw comment text. [Meta’s comments edge](https://developers.facebook.com/docs/graph-api/reference/object/comments)

### Price

USD 0.001 per saved audit with at least one matching comment record, with separate Apify platform usage. Preview and empty reviews have no HTF event. Each audit works from the metadata you supply.

![Relationship breakdown from a saved sample](https://howthtechnologyfactory.pro/assets/facebook-comment-thread-audit/05-check-parent-relationships.png)

![Workflow for auditing a saved social comment export](https://howthtechnologyfactory.pro/assets/facebook-comment-thread-audit/08-thread-audit-workflow.png)

See the [first report](https://howthtechnologyfactory.pro/assets/facebook-comment-thread-audit/02-read-your-first-audit.png), [saved input](https://howthtechnologyfactory.pro/assets/facebook-comment-thread-audit/03-prepare-a-saved-export.png), [input recovery](https://howthtechnologyfactory.pro/assets/facebook-comment-thread-audit/04-resolve-input-conflicts.png), [output fields](https://howthtechnologyfactory.pro/assets/facebook-comment-thread-audit/06-export-dated-relationships.png) and [sample boundaries](https://howthtechnologyfactory.pro/assets/facebook-comment-thread-audit/07-understand-sample-limits.png).

### Frequently asked questions

**Who uses this?** Social teams, moderators and analysts checking whether a saved export preserves the relationships they need to review.

**What data do I need?** Supply the original post links, the collection time and records containing comment IDs. Parent IDs are needed to check particular links.

**Can I start without my dataset?** Yes. Preview shows four demo records with no data-source requests or HTF charge.

**How many posts can I review?** Use up to five original Facebook post, reel or video links per audit.

**How many comments can I review?** Choose up to 100 saved rows per post, including replies. The audit refuses a sample over the chosen limits.

**Can I paste records instead of creating a dataset?** Yes. Paste structured JSON rows in the input form. Use one input route per review.

**Does it accept Facebook Graph exports?** It can read saved responses containing comment IDs and nested `comments.data`. Use an export you are permitted to process and remove credentials and personal fields before pasting.

**Can I mix a dataset and pasted Graph data?** Choose one input route per review. A Graph input may contain one saved response per selected post.

**What does Parent in sample mean?** The reply’s reported parent ID appears among the comment rows for the same post.

**What does Parent outside the sample mean?** The source reported a parent ID and that ID is absent from those supplied rows.

**Does an absent parent prove deletion?** The result describes the sample you supplied. Check the original source before deciding what happened to the comment.

**What if my source omits the relationship?** The report keeps that row in a separate unreported category for follow-up.

**What does Conflicting relationship mean?** Source fields disagree, a row points to itself, or the parent chain loops. Check the implicated IDs in the original export.

**What if the Graph export has more pages?** Set `hasMorePages` in the supplied metadata. The report flags the additional pages outside the saved sample.

**What does `topLevel` change?** It tells the importer that the first-level records came from known direct comments. Use `false` for flattened or uncertain exports.

**What if the same comment ID occurs twice?** The audit stops on a duplicate within one post. Deduplicate the source while preserving its original relationship fields and try again.

**Why keep IDs as strings?** Long IDs can lose digits when a spreadsheet automatically converts them to numbers.

**What does the dataset export include?** It includes source links where available, original comment and parent IDs, the sample time, and the assigned relationship category.

**Where are names and comment text shown?** The report and result dataset contain only the relationship metadata. Keep names, raw text and personal details out of the supplied input as well.

**Does this require a Facebook login in Apify?** Run the audit from authorised records you already hold. The input form asks for links and saved metadata.

**How are costs controlled?** Use the preview first and set an Apify event cap for a review. The paid HTF event requires saved matching results. Apify usage is recorded separately.

**Where can I get help?** Use the Actor’s Issues tab. Share the action and run status, plus a redacted example with credentials and personal data removed.

# Actor input Schema

## `action` (type: `string`):

Open a no-request demo or review comments you already have permission to use.

## `posts` (type: `array`):

For a review, enter the one to five original links that match your saved records.

## `observedAt` (type: `string`):

Use the time the source obtained the sample, ending in Z.

## `resultLimit` (type: `integer`):

The audit stops if the saved sample exceeds this limit. Each reply counts as one row.

## `authorizedUse` (type: `boolean`):

Confirm that you may process the supplied comment relationship metadata.

## `datasetId` (type: `string`):

Choose one dataset or paste data below. Use Read access.

## `inlineRows` (type: `array`):

Use JSON rows with facebookUrl and string commentId. Keep parentCommentId and an explicit isReply when the source provides them.

## `graphExports` (type: `array`):

For each post use postUrl, topLevel, hasMorePages and response.data. Paste IDs, dates and nested comments.data only. Remove names, text, access tokens and paging URLs before saving input.

## Actor input object example

```json
{
  "action": "preview",
  "resultLimit": 30,
  "authorizedUse": false
}
```

# Actor output Schema

## `report` (type: `string`):

No description

## `structured` (type: `string`):

No description

## `rows` (type: `string`):

No description

# 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 = {};

// Run the Actor and wait for it to finish
const run = await client.actor("apifmcpfactory/facebook-comment-thread-audit").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 = {}

# Run the Actor and wait for it to finish
run = client.actor("apifmcpfactory/facebook-comment-thread-audit").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 '{}' |
apify call apifmcpfactory/facebook-comment-thread-audit --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,apifmcpfactory/facebook-comment-thread-audit"
        }
    }
}
```

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/F3gWVZdeSKT30fNBc/builds/wz0b1lQIdL8hZTNKs/openapi.json
