{
  "openapi": "3.0.1",
  "info": {
    "title": "ReclameAqui Scraper · Brazil Complaints & Company Reputation",
    "description": "Monitor any Brazilian brand on ReclameAqui. Get every complaint with the company's full reply thread, plus the reputation scorecard buyers judge on — score, RA status, response and resolution rates, average answer time, CNPJ. Incremental runs emit only what changed. No browser.",
    "version": "0.0",
    "x-build-id": "FErKURge1aGpdsfin"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/memo23~reclameaqui-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-memo23-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/memo23~reclameaqui-scraper/runs": {
      "post": {
        "operationId": "runs-sync-memo23-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/memo23~reclameaqui-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-memo23-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 company name, or a full company URL (`https://www.reclameaqui.com.br/empresa/nubank/`). The slug is the part of the company page URL after /empresa/.",
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "🔗 Direct URLs",
            "type": "array",
            "description": "Paste company URLs or individual complaint URLs. Complaint URLs are scraped directly with their full reply thread. Works alongside the Companies field.",
            "items": {
              "type": "string"
            }
          },
          "includeCompanyProfile": {
            "title": "🏅 Include company reputation record",
            "type": "boolean",
            "description": "Emit one company record per company: reputation score and label (Ótimo/Bom/Regular/Ruim), RA status such as RA1000, response/resolution/recommendation rates, average answer time, complaint counts by period, segment, CNPJ, website, phones and address.",
            "default": true
          },
          "scrapeComplaints": {
            "title": "🗣️ Scrape complaints",
            "type": "boolean",
            "description": "Emit complaint records for each company. Turn off if you only want the reputation scorecard.",
            "default": true
          },
          "includeInteractions": {
            "title": "💬 Include full reply thread",
            "type": "boolean",
            "description": "Enrich every complaint with the complete back-and-forth thread — company answers, consumer replies and the final evaluation, each with HTML, plain text and Markdown. This costs one extra request per complaint, so runs are slower; leave off for a fast, cheap pull.",
            "default": false
          },
          "extractContacts": {
            "title": "📇 Extract contacts",
            "type": "boolean",
            "description": "Mine emails and phone numbers out of complaint bodies and reply threads into contactEmails / contactPhones.",
            "default": false
          },
          "enrichEmails": {
            "title": "✉️ Enrich company emails",
            "type": "boolean",
            "description": "Opt-in B2B enrichment. Scrapes the company's own website (taken from its ReclameAqui profile) for business contact emails and adds them as enrichedEmails on the company record. Billed only when an email is actually found.",
            "default": false
          },
          "statusFilter": {
            "title": "🔖 Complaint status",
            "type": "array",
            "description": "Which complaint buckets to pull. LATEST returns the newest complaints regardless of state (mostly not-yet-answered). Choose ANSWERED, EVALUATED or SOLVED to reach complaints that actually carry a company reply.",
            "items": {
              "type": "string",
              "enum": [
                "LATEST",
                "PENDING",
                "ANSWERED",
                "EVALUATED",
                "SOLVED",
                "UNSOLVED"
              ]
            },
            "default": [
              "LATEST"
            ]
          },
          "dateFrom": {
            "title": "📅 Date from",
            "type": "string",
            "description": "Only complaints created on or after this date (YYYY-MM-DD)."
          },
          "dateTo": {
            "title": "📅 Date to",
            "type": "string",
            "description": "Only complaints created on or before this date (YYYY-MM-DD)."
          },
          "includeKeywords": {
            "title": "✅ Include keywords",
            "type": "array",
            "description": "Keep only complaints whose title, description, problem type or category matches at least one of these terms.",
            "items": {
              "type": "string"
            }
          },
          "excludeKeywords": {
            "title": "🚫 Exclude keywords",
            "type": "array",
            "description": "Drop complaints matching any of these terms.",
            "items": {
              "type": "string"
            }
          },
          "solvedOnly": {
            "title": "✔️ Solved only",
            "type": "boolean",
            "description": "Keep only complaints the consumer marked as resolved.",
            "default": false
          },
          "withReplyOnly": {
            "title": "💬 With company reply only",
            "type": "boolean",
            "description": "Keep only complaints that received at least one company answer.",
            "default": false
          },
          "maxComplaintsPerCompany": {
            "title": "🔢 Max complaints per company",
            "minimum": 0,
            "type": "integer",
            "description": "Cap how many complaints are pulled per company. 0 means unlimited (large brands have hundreds of thousands).",
            "default": 100
          },
          "maxItems": {
            "title": "💯 Max total records",
            "minimum": 0,
            "type": "integer",
            "description": "Hard cap across all records (complaints + company records). 0 means unlimited.",
            "default": 1000
          },
          "maxConcurrency": {
            "title": "⚡ Concurrency",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "How many complaint detail pages to fetch in parallel when the reply thread is enabled.",
            "default": 5
          },
          "minDelayMs": {
            "title": "⏱️ Min delay (ms)",
            "minimum": 0,
            "maximum": 10000,
            "type": "integer",
            "description": "Politeness delay between requests. ReclameAqui rate-limits bursts, so lowering this raises the chance of retries.",
            "default": 250
          },
          "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.",
            "default": "all"
          },
          "descriptionMaxLength": {
            "title": "✂️ Description max length",
            "minimum": 0,
            "type": "integer",
            "description": "Truncate complaint descriptions to this many characters. 0 means no limit.",
            "default": 0
          },
          "excludeEmptyFields": {
            "title": "🧹 Exclude empty fields",
            "type": "boolean",
            "description": "Drop null and empty fields from every record for a leaner dataset.",
            "default": false
          },
          "flatten": {
            "title": "🗜️ Flatten for CSV",
            "type": "boolean",
            "description": "Flatten nested objects into underscore-separated top-level keys and JSON-stringify arrays of objects — friendlier for CSV and spreadsheet export.",
            "default": true
          },
          "incrementalMode": {
            "title": "🔁 Incremental mode",
            "type": "boolean",
            "description": "Track records across runs and classify each as NEW, UPDATED, UNCHANGED or EXPIRED. Only changed records are emitted by default, so recurring monitoring runs stay cheap.",
            "default": false
          },
          "stateKey": {
            "title": "🗝️ State key",
            "type": "string",
            "description": "Override the automatic incremental state key. Advanced — use it to share state across runs with different inputs."
          },
          "detectUpdates": {
            "title": "🔍 Detect updates",
            "type": "boolean",
            "description": "Re-fetch known complaints and compare content so edits and new company replies surface as UPDATED. Slower, because known records are fetched again.",
            "default": false
          },
          "emitUnchanged": {
            "title": "♻️ Emit unchanged",
            "type": "boolean",
            "description": "In incremental mode, also emit records with no changes.",
            "default": false
          },
          "emitExpired": {
            "title": "⚰️ Emit expired",
            "type": "boolean",
            "description": "Emit records that disappeared from the source. Only applied when the run completed a full sweep, since a capped run cannot tell 'gone' from 'not reached'.",
            "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."
          },
          "slackWebhookUrl": {
            "title": "Slack webhook URL",
            "type": "string",
            "description": "Post a summary to Slack."
          },
          "discordWebhookUrl": {
            "title": "Discord webhook URL",
            "type": "string",
            "description": "Post a summary to Discord."
          },
          "whatsappAccessToken": {
            "title": "WhatsApp access token",
            "type": "string",
            "description": "WhatsApp Cloud API access 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: these are stored with your run input — prefer a per-request token over a long-lived secret."
          },
          "notificationLimit": {
            "title": "Notification limit",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "Max records listed in each notification message.",
            "default": 10
          },
          "notifyOnlyNew": {
            "title": "Notify only on new records",
            "type": "boolean",
            "description": "In incremental mode, only notify about records classified NEW.",
            "default": true
          },
          "proxy": {
            "title": "🌐 Proxy",
            "type": "object",
            "description": "Optional, and off by default. ReclameAqui gates on the client fingerprint rather than the exit IP, so the actor runs fine with no proxy at all. Configure one only if you want requests routed through your own pool."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}