{
  "openapi": "3.0.1",
  "info": {
    "title": "Trustpilot Scraper",
    "description": "Request-first Trustpilot scraper for reviews, company profiles, ratings, logos, contacts, sentiment, topics, replies, delta monitoring, and clean analytics-ready datasets",
    "version": "0.1",
    "x-build-id": "GQmc0KyKrR3h1VgDt"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/trakk~trustpilot-review-intelligence-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-trakk-trustpilot-review-intelligence-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/trakk~trustpilot-review-intelligence-scraper/runs": {
      "post": {
        "operationId": "runs-sync-trakk-trustpilot-review-intelligence-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/trakk~trustpilot-review-intelligence-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-trakk-trustpilot-review-intelligence-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": {
          "companyDomains": {
            "title": "🏢 Company domain(s)",
            "type": "array",
            "description": "Business domains to scrape on Trustpilot, e.g. trustpilot.com, amazon.com, apple.com, shopify.com.",
            "items": {
              "type": "string"
            },
            "default": [
              "trustpilot.com"
            ]
          },
          "maxReviewsPerCompany": {
            "title": "🧾 Reviews per company",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Maximum number of reviews to collect for each company.",
            "default": 10
          },
          "maxResults": {
            "title": "💯 Maximum output items",
            "minimum": 1,
            "maximum": 50000,
            "type": "integer",
            "description": "Safety cap for the total number of dataset items produced by the run.",
            "default": 10
          },
          "mode": {
            "title": "🧭 Run mode",
            "enum": [
              "AUTO",
              "REVIEWS",
              "SEARCH"
            ],
            "type": "string",
            "description": "AUTO chooses the right mode from your input. REVIEWS scrapes company review pages. SEARCH discovers companies from Trustpilot search.",
            "default": "AUTO"
          },
          "startUrls": {
            "title": "🔗 Trustpilot URL(s)",
            "type": "array",
            "description": "Trustpilot review URLs or search URLs. Use this when you already have exact Trustpilot links.",
            "default": [],
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "businessUnitIds": {
            "title": "Business Unit IDs",
            "type": "array",
            "description": "Optional Trustpilot business unit IDs. Use plain IDs or id:domain pairs.",
            "items": {
              "type": "string"
            },
            "default": []
          },
          "searchQueries": {
            "title": "🔎 Search query(s)",
            "type": "array",
            "description": "Company names or keywords to search on Trustpilot.",
            "items": {
              "type": "string"
            },
            "default": []
          },
          "sort": {
            "title": "Sort reviews",
            "enum": [
              "recency",
              "relevance"
            ],
            "type": "string",
            "description": "Trustpilot review sort order.",
            "default": "recency"
          },
          "stars": {
            "title": "Rating filter",
            "type": "array",
            "description": "Trustpilot star ratings to keep. Leave empty for all ratings. Example: 1 and 2 for negative reviews.",
            "items": {
              "type": "string"
            },
            "default": []
          },
          "verified": {
            "title": "Verified reviews",
            "enum": [
              "",
              "true",
              "false"
            ],
            "type": "string",
            "description": "Filter reviews by Trustpilot verification state when supported.",
            "default": ""
          },
          "includeCompanyProfile": {
            "title": "🏢 Add company profile",
            "type": "boolean",
            "description": "Attach company reputation/profile fields to every review.",
            "default": true
          },
          "includeSearchResults": {
            "title": "Output search result rows",
            "type": "boolean",
            "description": "When using SEARCH mode, also output matched company items before review scraping.",
            "default": false
          },
          "enableDeltaMonitoring": {
            "title": "🕒 Delta monitoring",
            "type": "boolean",
            "description": "Compare current reviews with the previous run stored in the default key-value store.",
            "default": false
          },
          "rawOutput": {
            "title": "Include raw/debug fields",
            "type": "boolean",
            "description": "Include selected raw parser fields. Useful for debugging; usually keep it off.",
            "default": false
          },
          "browserFallback": {
            "title": "🛡️ Browser fallback",
            "type": "boolean",
            "description": "Use a browser only when normal HTTP requests hit Trustpilot protection. Keep enabled for reliable arbitrary-company runs.",
            "default": true
          },
          "fastBrowserMode": {
            "title": "Fast browser mode",
            "type": "boolean",
            "description": "Skip the HTTP preflight for Trustpilot HTML pages and use the optimized browser fetcher directly.",
            "default": false
          },
          "maxPagesPerCompany": {
            "title": "Max pages per company",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Safety limit for Trustpilot review pagination.",
            "default": 1
          },
          "maxConcurrency": {
            "title": "Max concurrency",
            "minimum": 1,
            "maximum": 30,
            "type": "integer",
            "description": "Maximum parallel fetches. For fast browser mode, 3-5 is usually the best speed/stability range.",
            "default": 4
          },
          "maxRetries": {
            "title": "Max retries",
            "minimum": 0,
            "maximum": 20,
            "type": "integer",
            "description": "Retry budget for HTTP 429/5xx/parse errors. Proxy and block retries have separate budgets.",
            "default": 5
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Residential proxies are recommended. US or target-market residential IPs work best.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}