{
  "openapi": "3.0.1",
  "info": {
    "title": "Brazil E-commerce CNPJ Scraper - Online Seller Contacts",
    "description": "Brazilian online-shop domains in, one seller per row out: razão social, check-digit-verified CNPJ, inscrição estadual, address, email, phone, WhatsApp and SAC, plus the Receita Federal register status. Billed only for rows with the seller's own CNPJ. $4.00 per 1,000 sellers.",
    "version": "0.1",
    "x-build-id": "bJdRQh0rGfNPjRpuD"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapersdelight~br-decreto7962-ecommerce-contact-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapersdelight-br-decreto7962-ecommerce-contact-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/scrapersdelight~br-decreto7962-ecommerce-contact-scraper/runs": {
      "post": {
        "operationId": "runs-sync-scrapersdelight-br-decreto7962-ecommerce-contact-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/scrapersdelight~br-decreto7962-ecommerce-contact-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-scrapersdelight-br-decreto7962-ecommerce-contact-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": {
          "domains": {
            "title": "Brazilian online-shop domains (or page URLs)",
            "type": "array",
            "description": "One entry per shop. Accepts a bare domain (\"attracione.com.br\"), a homepage URL (\"https://www.anjuss.com.br\") or a direct page URL (\"https://loja.com.br/politica-de-privacidade\"). Any platform (VTEX, Nuvemshop, Tray, Loja Integrada, Shopify, WooCommerce, Wake, Magento...) and any TLD. The Actor reads the seller block each shop prints (razão social, CNPJ, inscrição estadual, address, contacts) into one row per seller. Leave empty to run the built-in demo batch.",
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "Start URLs (list source)",
            "type": "array",
            "description": "The same shop list handed over as URLs, so Make, Zapier, Clay or a Google Sheet can pass it natively (a link to a text/CSV file of URLs also works). Merged with the domain list.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "sourceDatasetId": {
            "title": "Enrich an existing dataset",
            "type": "string",
            "description": "Dataset ID of a previous Actor run (a Google Maps, marketplace-seller or directory scraper). Each item's domain / website / site / url column is read and enriched."
          },
          "domainFieldName": {
            "title": "Domain field / CSV column",
            "type": "string",
            "description": "Which field of the source dataset (or which CSV column of the list file) holds the domain. Leave empty to auto-detect domain / website / site / url / dominio / loja. Dotted paths like \"company.website\" work."
          },
          "domainsFileUrl": {
            "title": "Domain list file URL",
            "type": "string",
            "description": "URL of a CSV, TXT, JSON or JSONL file holding the domains — for lists too big to paste into the editor. The column is picked with \"Domain field / CSV column\"."
          },
          "skipDomains": {
            "title": "Suppression list",
            "type": "array",
            "description": "Domains to skip outright — customers you already have, competitors, do-not-contact entries. Matched on the registrable domain, so \"www.x.com.br/pagina\" and \"x.com.br\" are the same entry. Never charged.",
            "items": {
              "type": "string"
            }
          },
          "previousDatasetId": {
            "title": "Skip what a previous run delivered",
            "type": "string",
            "description": "Dataset ID of an earlier run of this Actor. Every domain and CNPJ it delivered is skipped, so a monthly refresh never re-buys a seller you already paid for."
          },
          "maxItems": {
            "title": "Max results (billed rows)",
            "minimum": 0,
            "type": "integer",
            "description": "Hard cap on rows DELIVERED AND BILLED this run. Distinct from \"Max domains\": not every shop prints a CNPJ, so a list yields a fraction of its domains as billed rows. 0 = no cap.",
            "default": 1000
          },
          "maxDomains": {
            "title": "Max domains",
            "minimum": 0,
            "type": "integer",
            "description": "Cap on the number of domains attempted (after dedupe and suppression). 0 = all.",
            "default": 0
          },
          "verifyWithRegister": {
            "title": "Cross-check each CNPJ with the Receita Federal register",
            "type": "boolean",
            "description": "For every billed row, look the CNPJ the site printed up in the Receita Federal's open CNPJ data (BrasilAPI, with minhareceita.org as fallback) and add the register's own answer: registerStatus (ATIVA / BAIXADA / INAPTA / SUSPENSA / NULA), registerName, registerTradeName, main CNAE, size, Simples / MEI, city/UF, and registerNameMatchesSite. It never changes what the site printed and never changes what is billed (unless you turn on \"Only active CNPJs\").",
            "default": true
          },
          "requireActiveCnpj": {
            "title": "Only active CNPJs",
            "type": "boolean",
            "description": "Deliver and bill only rows whose CNPJ the register reports as ATIVA. A BAIXADA / INAPTA / SUSPENSA seller, or a row the register could not answer for, is filtered out and never charged. Needs the register cross-check on.",
            "default": false
          },
          "requireContact": {
            "title": "Require an email, phone or WhatsApp",
            "type": "boolean",
            "description": "Deliver and bill only rows that carry at least one email, phone or WhatsApp number.",
            "default": false
          },
          "requireAddress": {
            "title": "Require a physical address",
            "type": "boolean",
            "description": "Deliver and bill only rows where the shop printed a physical address.",
            "default": false
          },
          "requireStateRegistration": {
            "title": "Require an inscrição estadual",
            "type": "boolean",
            "description": "Deliver and bill only rows where the shop printed its inscrição estadual (or ISENTO).",
            "default": false
          },
          "platformFilter": {
            "title": "Only these e-commerce platforms",
            "type": "array",
            "description": "Keep only shops detected on these platforms (detected from each homepage's own bytes). Empty = every platform.",
            "items": {
              "type": "string",
              "enum": [
                "vtex",
                "nuvemshop",
                "tray",
                "loja-integrada",
                "shopify",
                "woocommerce",
                "magento",
                "wake",
                "yampi",
                "bagy",
                "linx",
                "irroba",
                "dooca",
                "wix",
                "prestashop",
                "opencart",
                "unknown"
              ],
              "enumTitles": [
                "VTEX",
                "Nuvemshop",
                "Tray",
                "Loja Integrada",
                "Shopify",
                "WooCommerce",
                "Magento",
                "Wake (Fbits)",
                "Yampi",
                "Bagy",
                "Linx",
                "Irroba",
                "Dooca",
                "Wix",
                "PrestaShop",
                "OpenCart",
                "Not detected"
              ]
            }
          },
          "minFieldsRequired": {
            "title": "Minimum filled fields",
            "minimum": 0,
            "maximum": 14,
            "type": "integer",
            "description": "Deliver and bill only rows with at least this many of: CNPJ, razão social, name near the CNPJ, inscrição estadual, address, CEP, city, UF, email, phone, WhatsApp, SAC phone, SAC email, service hours. 0 = off.",
            "default": 0
          },
          "emailPolicy": {
            "title": "Email policy",
            "enum": [
              "all",
              "role-only",
              "exclude-role"
            ],
            "type": "string",
            "description": "\"Role only\" keeps just generic mailboxes (contato@, sac@, atendimento@...); \"Exclude role\" keeps only named mailboxes.",
            "default": "all"
          },
          "dedupeBy": {
            "title": "Deduplicate by",
            "enum": [
              "cnpj-then-domain",
              "cnpj-root",
              "domain",
              "none"
            ],
            "type": "string",
            "description": "Which key collapses duplicates BEFORE anything is pushed or charged. Two domains of the same seller (same CNPJ) collapse into one billed row.",
            "default": "cnpj-then-domain"
          },
          "maxPagesParsed": {
            "title": "Subpages read per shop",
            "minimum": 0,
            "maximum": 10,
            "type": "integer",
            "description": "How many of the shop's own pages (Termos de Uso, Política de Privacidade, Quem Somos, Fale Conosco...) may be read after the homepage when the homepage alone does not carry the full block. Stops early once CNPJ, name, address and a contact are all found.",
            "default": 2
          },
          "maxDiscoveryRequestsPerDomain": {
            "title": "Max requests per shop (after the homepage)",
            "minimum": 0,
            "maximum": 40,
            "type": "integer",
            "description": "Budget of requests per shop after the homepage, including sitemap and page-index lookups.",
            "default": 6
          },
          "discoveryChannels": {
            "title": "Discovery channels",
            "type": "array",
            "description": "How subpages are found. anchor = the shop's own links ranked by Brazilian labels; sitemap and wpJson run only when the footer offered no candidate link; pathGuess (off by default) tries /quem-somos, /institucional, /termos, /politica-de-privacidade and the platforms' own URL shapes. The homepage is always read.",
            "items": {
              "type": "string",
              "enum": [
                "anchor",
                "sitemap",
                "wpJson",
                "pathGuess"
              ],
              "enumTitles": [
                "Ranked footer links",
                "XML sitemap",
                "WordPress page index",
                "Guessed paths"
              ]
            },
            "default": [
              "anchor",
              "sitemap",
              "wpJson"
            ]
          },
          "perDomainTimeoutSecs": {
            "title": "Per-shop timeout (seconds)",
            "minimum": 5,
            "maximum": 600,
            "type": "integer",
            "description": "Hard deadline per shop. A shop that does not finish is reported as unreachable and never charged.",
            "default": 60
          },
          "requestTimeoutSecs": {
            "title": "Request timeout (seconds)",
            "minimum": 5,
            "maximum": 120,
            "type": "integer",
            "description": "Timeout for one HTTP request (a hard deadline is also enforced around it).",
            "default": 25
          },
          "maxRequestRetries": {
            "title": "Retries per request",
            "minimum": 0,
            "maximum": 6,
            "type": "integer",
            "description": "Retries on a transient failure or a refusal (each retry on a fresh residential session when escalation is on). Dead hosts and 404s are never retried.",
            "default": 2
          },
          "requestConcurrency": {
            "title": "Parallel shops",
            "minimum": 1,
            "maximum": 30,
            "type": "integer",
            "description": "Shops processed in parallel. Lowered automatically to what the run's memory can hold.",
            "default": 10
          },
          "followWwwAndRootVariants": {
            "title": "Try the www / non-www variant",
            "type": "boolean",
            "description": "When a homepage fails, try the other host variant once.",
            "default": true
          },
          "respectRobotsTxt": {
            "title": "Respect robots.txt",
            "type": "boolean",
            "description": "Skip pages robots.txt disallows for this user agent.",
            "default": false
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Leave as is for the measured default: DIRECT requests first, then Apify RESIDENTIAL (Brazil) only for a shop that refuses us. Supply your own proxy URLs or an Apify proxy group to route the FIRST attempt through them instead.",
            "default": {
              "useApifyProxy": false
            }
          },
          "proxyCountry": {
            "title": "Residential exit country",
            "type": "string",
            "description": "ISO country code for the RESIDENTIAL retry. BR by default. Only used when a shop refuses the direct request.",
            "default": "BR"
          },
          "escalateToResidentialOnBlock": {
            "title": "Retry refused shops on Apify residential",
            "type": "boolean",
            "description": "Retry a shop that answers 403 / 429 / a challenge page through Apify RESIDENTIAL proxy (fresh session per attempt).",
            "default": true
          },
          "escalateToUnblockerOnBlock": {
            "title": "Escalate to Apify Unblocker on a block",
            "type": "boolean",
            "description": "Last-resort rung for shops that refuse even the residential retry. Slower and uses more proxy traffic.",
            "default": false
          },
          "customUserAgent": {
            "title": "User agent",
            "type": "string",
            "description": "Override the default desktop Chrome user agent."
          },
          "extraHttpHeaders": {
            "title": "Extra HTTP headers",
            "type": "object",
            "description": "Extra request headers as a JSON object."
          },
          "tldFilterMode": {
            "title": "TLD filter mode",
            "enum": [
              "none",
              "include",
              "exclude"
            ],
            "type": "string",
            "description": "No TLD filter by default — Brazilian shops trade on .com as well as .com.br. Use include / exclude with the list below.",
            "default": "none"
          },
          "tldFilter": {
            "title": "TLDs",
            "type": "array",
            "description": "TLDs for the filter above, e.g. \"com.br\", \"br\", \"com\".",
            "items": {
              "type": "string"
            }
          },
          "extractSocials": {
            "title": "Social profile links",
            "type": "boolean",
            "description": "Return the shop's Instagram / Facebook / TikTok / YouTube / LinkedIn profile links.",
            "default": true
          },
          "extractPolicyUrls": {
            "title": "Policy page links",
            "type": "boolean",
            "description": "Return the shop's own terms, privacy and exchange/return policy URLs.",
            "default": true
          },
          "includeMissRows": {
            "title": "Include unbilled miss rows",
            "type": "boolean",
            "description": "Emit a row for every domain that produced no seller row — dead, blocked, no CNPJ printed, contact details only, only a platform/payment company's CNPJ, an individual seller with a CPF, filtered out, a duplicate, or suppressed — with its status and missReason. These rows are never billed.",
            "default": false
          },
          "includeFieldSources": {
            "title": "Field sources",
            "type": "boolean",
            "description": "Add fieldSources: the exact URL every field was read from.",
            "default": false
          },
          "saveRawPages": {
            "title": "Save the pages read",
            "type": "boolean",
            "description": "Store every page the parser read, gzipped, in the run's key-value store (<domain>__<n>), so any row can be re-checked against the exact bytes it came from.",
            "default": 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
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "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
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}