# ReclameAqui Scraper - Complaints, Reputation & Company Intel BR (`blackfalcondata/reclameaqui-scraper`) Actor

Scrape ReclameAqui (Brazil): the full company reply thread, reputation scores, and company intel — by company slug, URL, name, or free-text search. Each complaint includes the consumer-company conversation and a structured reputation scorecard for due diligence.

- **URL**: https://apify.com/blackfalcondata/reclameaqui-scraper.md
- **Developed by:** [Black Falcon Data](https://apify.com/blackfalcondata) (community)
- **Categories:** E-commerce, Lead generation, Automation
- **Stats:** 3 total users, 2 monthly users, 100.0% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

from $25.00 / 1,000 complaint records

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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

## 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

### What does ReclameAqui Scraper do?

ReclameAqui Scraper extracts consumer complaints, the full company reply thread, and company reputation data from [reclameaqui.com.br](https://www.reclameaqui.com.br) — Brazil's largest consumer-complaints platform. Get each complaint's back-and-forth with the company (company answers, consumer replies, and the final evaluation), reputation scores with response and resolution rates, segment ranking, top problems, CNPJ and contacts — by company slug, URL, name, or platform-wide free-text search.

**New to Apify?** [Sign up free](https://console.apify.com/sign-up?fpr=1h3gvi) and use the included $5 monthly platform credit to test this actor.

### Key features

<!-- KEY_FEATURES:START -->
- **💬 Full company reply thread** — every complaint carries `interactions[]` — the complete ordered thread of company answers (`type: ANSWER`, `author: company`) and consumer replies and the final evaluation (`author: consumer`), each with its HTML and plain-text message and timestamp. A convenience `companyAnswer` holds the first company reply. No other ReclameAqui actor reconstructs the thread — most stop at a single answer or just a reply count. Turn off `includeInteractions` for a faster, lighter pull.
- **🏅 Full reputation scorecard** — each company record is a reputation scorecard: `finalScore`, `consumerScore`, `reputationLabel` (Ótimo/Bom/Regular/Ruim), `raStatus` (e.g. RA1000), `responseRate`, `resolutionRate`, `recommendationRate`, `avgResponseTimeHuman`, and complaint counts for the last 30 days, 6 months and 12 months — straight from ReclameAqui's own indices.
- **📊 Segment ranking, top problems & CNPJ** — company records include `segmentRankingPosition` (rank within its category), `mainProblems[]` (top complaint categories with counts), `secondarySegments`, the CNPJ in `documents`, listed `phones`/`emails`, the official `website`, and `subBrands` — turning a reputation lookup into a full company-intel record.
- **🗂️ Structured category / problem / product** — each complaint resolves `category`, `problemType` and `productType` to structured `{id, name}` objects, plus the consumer's city/state, solved and evaluated flags, and the post-resolution score — ready for grouping and trend analysis without string-matching.
- **🚦 Derived risk & responsiveness signals** — every complaint includes an `analysis` block — `riskLevel` (low/medium/high), `hasCompanyReply`, `firstReplyDelayDays`, `resolutionDelayDays`, `isOverdue` — derived from the reply-thread timestamps and status for triage and SLA monitoring. Every company adds `scoreTrend` + `complaintVolumeTrend` (6-month vs 12-month, with delta and direction) and a `statusDistribution` breakdown, so you see whether reputation is rising or falling at a glance.
- **♻️ Incremental mode** — recurring runs emit only complaints that are new or whose status, reply thread or evaluation changed since last run — track reputation movement and company responsiveness over time without re-pulling the whole history. Saves 80–95% on monitoring runs.
- **📌 Change classification** — each complaint carries a `changeType` of NEW / UPDATED / UNCHANGED / REAPPEARED / EXPIRED, computed from its status, solved/evaluated flags and interaction count. Default emits NEW + UPDATED + REAPPEARED; opt into the rest with `emitUnchanged` / `emitExpired`.
- **🔔 Notifications** — Telegram, Slack, Discord, WhatsApp Cloud API, and generic webhook out of the box. Pair with incremental for daily new-listing alerts without pipeline glue.
- **📧 Email + phone extraction** — best-effort extraction of emails, phone numbers, URLs and social profiles from complaint bodies and company info — emitted as `extractedEmails[]`, `extractedPhones[]`, `extractedUrls[]` and `socialProfiles` on every record.
- **📦 Compact mode** — compact mode returns a slim subset of fields (ids, headline reputation, complaint status) — ideal when feeding an LLM or building a reputation comparison sheet across many companies.
<!-- KEY_FEATURES:END -->

### What data can you extract from ReclameAqui?

Each result includes Core listing fields (`recordType`, `scrapedAt`, `legacyId`, `shortname`, `name`, `fantasyName`, `website`, and `finalScore`, and more), detail fields when enrichment is enabled (`description`), contact information (`phones`, `emails`, `extractedEmails`, and `extractedPhones`), and company metadata (`companyId` and `companyUrl`). In standard mode, all fields are always present — unavailable data points are returned as `null`, never omitted. In compact mode, only core fields are returned.

### Input

Configure the actor through the input schema in Apify Console.

Key parameters:

- **`companies`** — Companies to scrape — each entry can be a ReclameAqui **slug** (`nubank`), a full company **URL** (`https://www.reclameaqui.com.br/empresa/nubank/`), or a company **name** (`Nubank`). Names and URLs are resolved automatically.
- **`searchQueries`** — Free-text complaint searches across the whole platform (e.g. `atraso entrega`, `cobrança indevida`). Returns matching complaints from any company. Use instead of, or alongside, `companies`. (default: `[]`)
- **`includeCompanyProfile`** — Emit one company record per company with reputation score, RA status, response/resolution/recommendation rates, complaint counts by period, segment ranking, top problems, CNPJ and contacts. (default: `true`)
- **`scrapeComplaints`** — Emit complaint records for each company / search query. (default: `true`)
- **`includeInteractions`** — Enrich each complaint with the complete back-and-forth thread (company answers + consumer replies + final evaluation) and structured category/problem/product taxonomy. Adds one request per complaint. Turn off for a faster, lighter pull. (default: `true`)
- **`extractContacts`** — Mine emails, phones, URLs and social profiles from complaint bodies and company info. (default: `true`)
- **`statusFilter`** — Which complaint buckets to pull. `LATEST` = all recent complaints. (default: `["LATEST"]`)
- **`dateFrom`** — Only complaints created on or after this date (YYYY-MM-DD).
- **`dateTo`** — Only complaints created on or before this date (YYYY-MM-DD).
- **`maxComplaintsPerCompany`** — Cap complaints pulled per company (or per search query). 0 = unlimited for companies; free-text searches cap at 200 per query. (default: `100`)
- **`maxItems`** — Hard cap across all records (companies + complaints). 0 = unlimited. (default: `0`)
- **`compact`** — Emit a slim subset of fields (ids, headline reputation, complaint status) for lighter datasets. (default: `false`)
- ...and 19 more parameters

### Input examples

**Company reputation + recent complaints with reply thread** — Pull one company's reputation scorecard plus its latest complaints, each enriched with the full company↔consumer thread.

→ One company record + up to 20 complaint records, each with `interactions[]`.

```json
{
  "companies": [
    "nubank"
  ],
  "includeCompanyProfile": true,
  "scrapeComplaints": true,
  "includeInteractions": true,
  "statusFilter": [
    "LATEST"
  ],
  "maxComplaintsPerCompany": 20
}
````

**Multi-company reputation scorecards only** — Compare reputation across companies without pulling individual complaints.

→ One company record per company — scores, rates, ranking, top problems, CNPJ, contacts.

```json
{
  "companies": [
    "nubank",
    "itau",
    "magazine-luiza-loja-online"
  ],
  "includeCompanyProfile": true,
  "scrapeComplaints": false
}
```

**Platform-wide free-text complaint search** — Find complaints across every company by keyword — no company list needed.

→ Complaint records matching the search terms, with reply threads.

```json
{
  "searchQueries": [
    "atraso entrega",
    "cobrança indevida"
  ],
  "includeInteractions": true,
  "maxComplaintsPerCompany": 50
}
```

**Incremental tracking of solved complaints in a date window** — First run builds the baseline; later runs emit only changed complaints for this stateKey.

→ Complaint records classified NEW / UPDATED / REAPPEARED (changed-only by default).

```json
{
  "companies": [
    "magazine-luiza-loja-online"
  ],
  "statusFilter": [
    "SOLVED"
  ],
  "dateFrom": "2026-01-01",
  "dateTo": "2026-06-01",
  "incrementalMode": true,
  "stateKey": "magalu-solved-tracker"
}
```

### Output

Each run produces a dataset of structured listing records. Results can be downloaded as JSON, CSV, or Excel from the Dataset tab in Apify Console.

### Example listing record

```json
{
  "recordType": "company",
  "source": "ReclameAqui",
  "scrapedAt": "2026-06-09T15:20:44.025Z",
  "companyId": "88850",
  "legacyId": 88850,
  "shortname": "nubank",
  "name": "Nubank",
  "fantasyName": "Nubank",
  "companyUrl": "https://www.reclameaqui.com.br/empresa/nubank/",
  "website": "http://www.nubank.com.br",
  "finalScore": 8.7,
  "consumerScore": 7.63,
  "reputationLabel": "Ótimo",
  "raStatus": "RA1000",
  "hasStamp": true,
  "isRA1000": true,
  "ravLabel": "SHOW_VERIFIED",
  "hasVerificada": true,
  "mainSegment": "Bancos e Financeiras",
  "mainSegmentShortname": "bancos-e-financeiras",
  "secondarySegments": [
    "bancos-tradicionais-e-digitais",
    "cartoes-de-credito",
    "bancos-digitais",
    "emissoras-e-bandeiras-cartao-de-credito"
  ],
  "segmentRankingPosition": 1,
  "segmentRankingLabel": "BEST",
  "segmentRankingName": "Melhores Emissoras e Bandeiras de Cartão de Crédito",
  "complaintsTotal": 60129,
  "complaints6Months": 57544,
  "complaints12Months": 119270,
  "complaints30Days": 11317,
  "responseRate": 99.5,
  "resolutionRate": 92.3,
  "recommendationRate": 80.3,
  "avgResponseTimeSeconds": 400113.38366284757,
  "avgResponseTimeHuman": "4 dias, 15 horas",
  "totalAnswered": 57256,
  "totalNotAnswered": 260,
  "totalEvaluated": 22085,
  "scoreTrend": {
    "sixMonths": 8.7,
    "twelveMonths": 8.6,
    "delta": 0.1,
    "direction": "up"
  },
  "complaintVolumeTrend": {
    "sixMonths": 57544,
    "twelveMonths": 119270,
    "delta": -4182,
    "direction": "down"
  },
  "statusDistribution": {
    "answered": 57256,
    "notAnswered": 260,
    "evaluated": 22085
  },
  "memberSince": "2014-12-12T10:47:00",
  "description": "Somos uma fintech que nasceu para mudar como você lida com o seu dinheiro. Lutamos contra a burocracia para deixar você sempre no controle.",
  "documents": [
    "18236120000158"
  ],
  "phones": [
    "0800 591 2117"
  ],
  "emails": [],
  "city": "SAO PAULO",
  "state": "SP",
  "mainProblems": [
    {
      "id": "0000000000000003",
      "name": "Cartões de Crédito",
      "count": 134492
    },
    {
      "id": "0000000000000000",
      "name": "Não encontrei meu problema",
      "count": 53232
    },
    {
      "id": "0000000000000001",
      "name": "Bancos",
      "count": 41646
    },
    {
      "id": "0000000000000311",
      "name": "Aplicativos",
      "count": 39207
    },
    {
      "id": "0000000000000004",
      "name": "Financeiras",
      "count": 14050
    },
    {
      "id": "0000000000000255",
      "name": "Problemas com o Atendimento",
      "count": 5664
    },
    {
      "id": "-000000000000001",
      "name": "Não categorizado",
      "count": 5547
    },
    {
      "id": "0000000000000135",
      "name": "Meios de pagamentos eletrônicos",
      "count": 3190
    },
    {
      "id": "0000000000000259",
      "name": "Problemas com o Site",
      "count": 1511
    },
    {
      "id": "0000000000000084",
      "name": "Recuperadora de crédito e cobrança",
      "count": 1256
    }
  ],
  "subBrands": [],
  "competitors": [],
  "extractedEmails": [],
  "extractedPhones": [
    "0800 591 2117"
  ],
  "extractedUrls": [],
  "socialProfiles": {
    "linkedin": null,
    "twitter": null,
    "instagram": null,
    "facebook": null,
    "youtube": null,
    "tiktok": null,
    "github": null,
    "xing": null,
    "bluesky": null,
    "threads": null,
    "mastodon": null
  }
}
```

### Incremental fields

When incremental mode is on, each record also carries:

- `changeType` — one of `NEW`, `UPDATED`, `UNCHANGED`, `REAPPEARED`, `EXPIRED`. Default output covers `NEW` / `UPDATED` / `REAPPEARED`; set `emitUnchanged: true` or `emitExpired: true` to opt into the others.

### How to scrape ReclameAqui

1. Go to [ReclameAqui Scraper](https://apify.com/blackfalcondata/reclameaqui-scraper?fpr=1h3gvi) in Apify Console.
2. Configure the input.
3. Set `maxItems` to control how many results you need.
4. Click **Start** and wait for the run to finish.
5. Export the dataset as JSON, CSV, or Excel.

### Use cases

- Extract listing data from ReclameAqui for market research and competitive analysis.
- Monitor new and changed listings on scheduled runs without processing the full dataset every time.
- Feed structured data into AI agents, MCP tools, and automated pipelines using compact mode.
- Export clean, structured data to dashboards, spreadsheets, or data warehouses.

### How much does it cost to scrape ReclameAqui?

ReclameAqui Scraper uses [pay-per-event](https://docs.apify.com/platform/actors/paid-actors/pay-per-event) pricing. You pay a small fee when the run starts and then for each result that is actually produced.

- **Run start:** $0.005 per run
- **Per listing (primary event):** $0.025

You are billed only for the events your run actually triggers. Prices below are the Free plan tier.

| Event | Price (Free tier) | Charged when |
|---|---|---|
| Actor Start | $0.005 (one-time) | Charged when the Actor starts running. Number of events charged depends on Actor memory (one event per GB, minimum one event). |
| Complaint record (primary) | $0.025 | One complaint record, including the full company reply thread when enabled. |
| Company reputation record | $0.05 | One company reputation/intel record (score, rates, ranking, top problems, contacts). |

Example costs (primary event only — other events above add cost when they fire):

- 10 results: **$0.26**
- 25 results: **$0.63**
- 100 results: **$2.5**
- 200 results: **$5**
- 500 results: **$12.51**

#### Example: recurring monitoring savings

These examples compare full re-scrapes with incremental runs at different churn rates. Churn is the share of listings that are new or whose tracked content changed since the previous run. Actual churn depends on your query breadth, source activity, and polling frequency — the scenarios below are examples, not predictions.

Example setup: 250 results per run, daily polling (30 runs/month). Event-pricing examples scale linearly with result count.

Numbers below are for the primary **Complaint record** event. Other events (**Company reputation record**) are billed separately when they fire.

| Churn rate | Full re-scrape run cost | Incremental run cost | Savings vs full re-scrape | Monthly cost after baseline |
|---|---:|---:|---:|---:|
| 5% — stable niche query | $6.25 | $0.32 | $5.94 (95%) | $9.53 |
| 15% — moderate broad query | $6.25 | $0.94 | $5.31 (85%) | $28.27 |
| 30% — high-volume aggregator | $6.25 | $1.88 | $4.38 (70%) | $56.40 |

Full re-scrape monthly cost at daily polling: $187.65. First month with incremental costs $15.46 / $33.59 / $60.77 for the 5% / 15% / 30% scenarios because the first run builds baseline state at full cost before incremental savings apply.

Platform usage is included in the per-result fee shown above.

### FAQ

#### How many results can I get from ReclameAqui?

The number of results depends on the search query and available listings on ReclameAqui. Use the `maxItems` parameter to control how many results are returned per run.

#### Does ReclameAqui Scraper support recurring monitoring?

Yes. Enable incremental mode to only receive new or changed listings on subsequent runs. This is ideal for scheduled monitoring where you want to track changes over time without re-processing the full dataset.

#### Can I integrate ReclameAqui Scraper with other apps?

Yes. ReclameAqui Scraper works with Apify's [integrations](https://apify.com/integrations?fpr=1h3gvi) to connect with tools like Zapier, Make, Google Sheets, Slack, and more. You can also use webhooks to trigger actions when a run completes.

#### Can I use ReclameAqui Scraper with the Apify API?

Yes. You can start runs, manage inputs, and retrieve results programmatically through the [Apify API](https://docs.apify.com/api/v2). Client libraries are available for JavaScript, Python, and other languages.

#### Can I use ReclameAqui Scraper through an MCP Server?

Yes. Apify provides an [MCP Server](https://apify.com/apify/actors-mcp-server?fpr=1h3gvi) that lets AI assistants and agents call this actor directly. Use compact mode, `descriptionMaxLength`, a single `descriptionFormat`, and `excludeEmptyFields` to keep payloads manageable for LLM context windows.

#### Is it legal to scrape ReclameAqui?

This actor extracts publicly available data from ReclameAqui. Web scraping of public information is generally considered legal, but you should always review the target site's terms of service and ensure your use case complies with applicable laws and regulations, including GDPR where relevant.

#### Your feedback

If you have questions, need a feature, or found a bug, please [open an issue](https://apify.com/blackfalcondata/reclameaqui-scraper/issues?fpr=1h3gvi) on the actor's page in Apify Console. Your feedback helps us improve.

### You might also like

- [Kununu Scraper - Company Ratings & Employer Reviews (DACH)](https://apify.com/blackfalcondata/kununu-scraper?fpr=1h3gvi) — Scrape kununu.com across DACH — company ratings with 4-bucket distribution, 24-month score trends,.
- [Trustpilot Scraper — 200+ Reviews & Complaint Monitoring](https://apify.com/blackfalcondata/trustpilot-reviews-scraper?fpr=1h3gvi) — Scrape full trustpilot.com review history per company — all languages, business data, reviewer.

### Getting started with Apify

New to Apify? [Create a free account with $5 credit](https://console.apify.com/sign-up?fpr=1h3gvi) — no credit card required.

1. Sign up — $5 platform credit included
2. Open this actor and configure your input
3. Click **Start** — export results as JSON, CSV, or Excel

Need more later? [See Apify pricing](https://apify.com/pricing?fpr=1h3gvi).

# Actor input Schema

## `companies` (type: `array`):

Companies to scrape — each entry can be a ReclameAqui **slug** (`nubank`), a full company **URL** (`https://www.reclameaqui.com.br/empresa/nubank/`), or a company **name** (`Nubank`). Names and URLs are resolved automatically.

## `searchQueries` (type: `array`):

Free-text complaint searches across the whole platform (e.g. `atraso entrega`, `cobrança indevida`). Returns matching complaints from any company. Use instead of, or alongside, `companies`.

## `includeCompanyProfile` (type: `boolean`):

Emit one company record per company with reputation score, RA status, response/resolution/recommendation rates, complaint counts by period, segment ranking, top problems, CNPJ and contacts.

## `scrapeComplaints` (type: `boolean`):

Emit complaint records for each company / search query.

## `includeInteractions` (type: `boolean`):

Enrich each complaint with the complete back-and-forth thread (company answers + consumer replies + final evaluation) and structured category/problem/product taxonomy. Adds one request per complaint. Turn off for a faster, lighter pull.

## `extractContacts` (type: `boolean`):

Mine emails, phones, URLs and social profiles from complaint bodies and company info.

## `statusFilter` (type: `array`):

Which complaint buckets to pull. `LATEST` = all recent complaints.

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

Only complaints created on or after this date (YYYY-MM-DD).

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

Only complaints created on or before this date (YYYY-MM-DD).

## `maxComplaintsPerCompany` (type: `integer`):

Cap complaints pulled per company (or per search query). 0 = unlimited for companies; free-text searches cap at 200 per query.

## `maxItems` (type: `integer`):

Hard cap across all records (companies + complaints). 0 = unlimited.

## `compact` (type: `boolean`):

Emit a slim subset of fields (ids, headline reputation, complaint status) for lighter datasets.

## `descriptionFormat` (type: `string`):

Which complaint description variants to keep: all (text + HTML + Markdown), plain text only, HTML only, or Markdown only.

## `excludeEmptyFields` (type: `boolean`):

Drop null / empty fields from every record for a leaner dataset.

## `descriptionMaxLength` (type: `integer`):

Truncate complaint description / text to this many characters (0 = no limit).

## `incrementalMode` (type: `boolean`):

Track complaints across runs and classify each as NEW / UPDATED / UNCHANGED / REAPPEARED / EXPIRED. Only changed complaints are emitted by default.

## `stateKey` (type: `string`):

Override the automatic incremental state key (advanced — share state across runs).

## `emitUnchanged` (type: `boolean`):

In incremental mode, also emit complaints with no changes.

## `emitExpired` (type: `boolean`):

In incremental mode, emit complaints that disappeared from the source (only when full coverage is proven).

## `telegramToken` (type: `string`):

Send a summary of new records to Telegram.

## `telegramChatId` (type: `string`):

Target Telegram chat ID.

## `discordWebhookUrl` (type: `string`):

Post a summary to Discord.

## `slackWebhookUrl` (type: `string`):

Post a summary to Slack.

## `whatsappAccessToken` (type: `string`):

WhatsApp Cloud API token.

## `whatsappPhoneNumberId` (type: `string`):

WhatsApp Cloud API sender phone number ID.

## `whatsappTo` (type: `string`):

Recipient phone number in international format.

## `webhookUrl` (type: `string`):

POST new records to any webhook (n8n, Make, Zapier).

## `webhookHeaders` (type: `object`):

Optional headers for the generic webhook. Note: stored with your run input — avoid embedding long-lived secrets where a per-request token works.

## `notificationLimit` (type: `integer`):

Max records included per notification.

## `notifyOnlyChanges` (type: `boolean`):

Only notify on changed records (incremental mode).

## `minDelayMs` (type: `integer`):

Politeness delay between request batches.

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

Optional. The actor runs fine without a proxy; configure one only if you want requests routed through it.

## Actor input object example

```json
{
  "companies": [
    "nubank"
  ],
  "searchQueries": [],
  "includeCompanyProfile": true,
  "scrapeComplaints": true,
  "includeInteractions": true,
  "extractContacts": true,
  "statusFilter": [
    "LATEST"
  ],
  "maxComplaintsPerCompany": 20,
  "maxItems": 0,
  "compact": false,
  "descriptionFormat": "all",
  "excludeEmptyFields": false,
  "descriptionMaxLength": 0,
  "incrementalMode": false,
  "emitUnchanged": false,
  "emitExpired": false,
  "notificationLimit": 5,
  "notifyOnlyChanges": false,
  "minDelayMs": 0,
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `results` (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 = {
    "companies": [
        "nubank"
    ],
    "statusFilter": [
        "LATEST"
    ],
    "maxComplaintsPerCompany": 20
};

// Run the Actor and wait for it to finish
const run = await client.actor("blackfalcondata/reclameaqui-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 = {
    "companies": ["nubank"],
    "statusFilter": ["LATEST"],
    "maxComplaintsPerCompany": 20,
}

# Run the Actor and wait for it to finish
run = client.actor("blackfalcondata/reclameaqui-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 '{
  "companies": [
    "nubank"
  ],
  "statusFilter": [
    "LATEST"
  ],
  "maxComplaintsPerCompany": 20
}' |
apify call blackfalcondata/reclameaqui-scraper --silent --output-dataset

```

## MCP server setup

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

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "ReclameAqui Scraper - Complaints, Reputation & Company Intel BR",
        "description": "Scrape ReclameAqui (Brazil): the full company reply thread, reputation scores, and company intel — by company slug, URL, name, or free-text search. Each complaint includes the consumer-company conversation and a structured reputation scorecard for due diligence.",
        "version": "0.1",
        "x-build-id": "RJIxYp8Gyb71gBs10"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/blackfalcondata~reclameaqui-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-blackfalcondata-reclameaqui-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/blackfalcondata~reclameaqui-scraper/runs": {
            "post": {
                "operationId": "runs-sync-blackfalcondata-reclameaqui-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/blackfalcondata~reclameaqui-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-blackfalcondata-reclameaqui-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",
                "properties": {
                    "companies": {
                        "title": "🏢 Companies",
                        "type": "array",
                        "description": "Companies to scrape — each entry can be a ReclameAqui **slug** (`nubank`), a full company **URL** (`https://www.reclameaqui.com.br/empresa/nubank/`), or a company **name** (`Nubank`). Names and URLs are resolved automatically.",
                        "items": {
                            "type": "string"
                        }
                    },
                    "searchQueries": {
                        "title": "🔎 Search queries",
                        "type": "array",
                        "description": "Free-text complaint searches across the whole platform (e.g. `atraso entrega`, `cobrança indevida`). Returns matching complaints from any company. Use instead of, or alongside, `companies`.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "includeCompanyProfile": {
                        "title": "🏅 Include company reputation record",
                        "type": "boolean",
                        "description": "Emit one company record per company with reputation score, RA status, response/resolution/recommendation rates, complaint counts by period, segment ranking, top problems, CNPJ and contacts.",
                        "default": true
                    },
                    "scrapeComplaints": {
                        "title": "🗣️ Scrape complaints",
                        "type": "boolean",
                        "description": "Emit complaint records for each company / search query.",
                        "default": true
                    },
                    "includeInteractions": {
                        "title": "💬 Include full reply thread",
                        "type": "boolean",
                        "description": "Enrich each complaint with the complete back-and-forth thread (company answers + consumer replies + final evaluation) and structured category/problem/product taxonomy. Adds one request per complaint. Turn off for a faster, lighter pull.",
                        "default": true
                    },
                    "extractContacts": {
                        "title": "📇 Extract contacts",
                        "type": "boolean",
                        "description": "Mine emails, phones, URLs and social profiles from complaint bodies and company info.",
                        "default": true
                    },
                    "statusFilter": {
                        "title": "🔖 Complaint status",
                        "type": "array",
                        "description": "Which complaint buckets to pull. `LATEST` = all recent complaints.",
                        "items": {
                            "type": "string",
                            "enum": [
                                "LATEST",
                                "EVALUATED",
                                "ANSWERED",
                                "SOLVED"
                            ],
                            "enumTitles": [
                                "Latest (all)",
                                "Evaluated by consumer",
                                "Answered by company",
                                "Solved"
                            ]
                        },
                        "default": [
                            "LATEST"
                        ]
                    },
                    "dateFrom": {
                        "title": "📅 Date from",
                        "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
                        "type": "string",
                        "description": "Only complaints created on or after this date (YYYY-MM-DD)."
                    },
                    "dateTo": {
                        "title": "📅 Date to",
                        "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
                        "type": "string",
                        "description": "Only complaints created on or before this date (YYYY-MM-DD)."
                    },
                    "maxComplaintsPerCompany": {
                        "title": "🔢 Max complaints per company / query",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Cap complaints pulled per company (or per search query). 0 = unlimited for companies; free-text searches cap at 200 per query.",
                        "default": 100
                    },
                    "maxItems": {
                        "title": "💯 Max total records",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Hard cap across all records (companies + complaints). 0 = unlimited.",
                        "default": 0
                    },
                    "compact": {
                        "title": "📦 Compact output",
                        "type": "boolean",
                        "description": "Emit a slim subset of fields (ids, headline reputation, complaint status) for lighter datasets.",
                        "default": false
                    },
                    "descriptionFormat": {
                        "title": "📝 Description format",
                        "enum": [
                            "all",
                            "text",
                            "html",
                            "markdown"
                        ],
                        "type": "string",
                        "description": "Which complaint description variants to keep: all (text + HTML + Markdown), plain text only, HTML only, or Markdown only.",
                        "default": "all"
                    },
                    "excludeEmptyFields": {
                        "title": "🧹 Exclude empty fields",
                        "type": "boolean",
                        "description": "Drop null / empty fields from every record for a leaner dataset.",
                        "default": false
                    },
                    "descriptionMaxLength": {
                        "title": "✂️ Description max length",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Truncate complaint description / text to this many characters (0 = no limit).",
                        "default": 0
                    },
                    "incrementalMode": {
                        "title": "🔁 Incremental mode",
                        "type": "boolean",
                        "description": "Track complaints across runs and classify each as NEW / UPDATED / UNCHANGED / REAPPEARED / EXPIRED. Only changed complaints are emitted by default.",
                        "default": false
                    },
                    "stateKey": {
                        "title": "🗝️ State key",
                        "type": "string",
                        "description": "Override the automatic incremental state key (advanced — share state across runs)."
                    },
                    "emitUnchanged": {
                        "title": "♻️ Emit unchanged",
                        "type": "boolean",
                        "description": "In incremental mode, also emit complaints with no changes.",
                        "default": false
                    },
                    "emitExpired": {
                        "title": "⚰️ Emit expired",
                        "type": "boolean",
                        "description": "In incremental mode, emit complaints that disappeared from the source (only when full coverage is proven).",
                        "default": false
                    },
                    "telegramToken": {
                        "title": "Telegram bot token",
                        "type": "string",
                        "description": "Send a summary of new records to Telegram."
                    },
                    "telegramChatId": {
                        "title": "💬 Telegram chat ID",
                        "type": "string",
                        "description": "Target Telegram chat ID."
                    },
                    "discordWebhookUrl": {
                        "title": "Discord webhook URL",
                        "type": "string",
                        "description": "Post a summary to Discord."
                    },
                    "slackWebhookUrl": {
                        "title": "Slack webhook URL",
                        "type": "string",
                        "description": "Post a summary to Slack."
                    },
                    "whatsappAccessToken": {
                        "title": "WhatsApp access token",
                        "type": "string",
                        "description": "WhatsApp Cloud API token."
                    },
                    "whatsappPhoneNumberId": {
                        "title": "WhatsApp phone number ID",
                        "type": "string",
                        "description": "WhatsApp Cloud API sender phone number ID."
                    },
                    "whatsappTo": {
                        "title": "WhatsApp recipient",
                        "type": "string",
                        "description": "Recipient phone number in international format."
                    },
                    "webhookUrl": {
                        "title": "Generic webhook URL",
                        "type": "string",
                        "description": "POST new records to any webhook (n8n, Make, Zapier)."
                    },
                    "webhookHeaders": {
                        "title": "Webhook headers",
                        "type": "object",
                        "description": "Optional headers for the generic webhook. Note: stored with your run input — avoid embedding long-lived secrets where a per-request token works."
                    },
                    "notificationLimit": {
                        "title": "Notification limit",
                        "minimum": 1,
                        "type": "integer",
                        "description": "Max records included per notification.",
                        "default": 5
                    },
                    "notifyOnlyChanges": {
                        "title": "Notify only changes",
                        "type": "boolean",
                        "description": "Only notify on changed records (incremental mode).",
                        "default": false
                    },
                    "minDelayMs": {
                        "title": "⏱️ Min delay (ms)",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Politeness delay between request batches.",
                        "default": 0
                    },
                    "proxyConfiguration": {
                        "title": "🌐 Proxy",
                        "type": "object",
                        "description": "Optional. The actor runs fine without a proxy; configure one only if you want requests routed through it.",
                        "default": {
                            "useApifyProxy": false
                        }
                    }
                }
            },
            "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
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
