{
  "openapi": "3.0.1",
  "info": {
    "title": "Google Maps Review Change Feed",
    "description": "Production Google Maps reputation monitor for agencies and multi-location brands. Detect new/changed reviews and owner replies, flag possible removals safely, prioritize unanswered negatives, and export Dataset + webhook/email alerts.",
    "version": "1.4",
    "x-build-id": "ddgezC22q2SEQYJEo"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/basta_compilar~google-maps-review-change-feed/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-basta_compilar-google-maps-review-change-feed",
        "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/basta_compilar~google-maps-review-change-feed/runs": {
      "post": {
        "operationId": "runs-sync-basta_compilar-google-maps-review-change-feed",
        "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/basta_compilar~google-maps-review-change-feed/run-sync": {
      "post": {
        "operationId": "run-sync-basta_compilar-google-maps-review-change-feed",
        "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": {
          "places": {
            "title": "Places (URLs or Place IDs)",
            "uniqueItems": true,
            "type": "array",
            "description": "Google Maps place URLs or Place IDs (ChIJ…). Use placeItems instead when you need client labels/tags.",
            "items": {
              "type": "string",
              "minLength": 5,
              "maxLength": 2000
            }
          },
          "placeItems": {
            "title": "Places with metadata (agencies)",
            "type": "array",
            "description": "Structured places with optional label, clientName and tags for multi-client agencies.",
            "items": {
              "type": "object",
              "properties": {
                "place": {
                  "title": "URL or Place ID",
                  "type": "string",
                  "description": "Google Maps URL or Place ID (ChIJ…).",
                  "editor": "textfield"
                },
                "label": {
                  "title": "Label",
                  "type": "string",
                  "description": "Optional internal label for this location.",
                  "editor": "textfield"
                },
                "clientName": {
                  "title": "Client name",
                  "type": "string",
                  "description": "Optional client/account name for agency workflows.",
                  "editor": "textfield"
                },
                "tags": {
                  "title": "Tags",
                  "type": "array",
                  "description": "Optional tags for filtering and reporting.",
                  "editor": "stringList",
                  "items": {
                    "type": "string"
                  }
                }
              },
              "required": [
                "place"
              ]
            }
          },
          "runMode": {
            "title": "Run mode",
            "enum": [
              "monitor",
              "import_history",
              "reset_baseline",
              "export_snapshot"
            ],
            "type": "string",
            "description": "monitor = scheduled change feed (limited depth). import_history = one-shot deeper history import (not for high-frequency schedules). reset_baseline = wipe + re-baseline. export_snapshot = alias of import_history.",
            "default": "monitor"
          },
          "maxReviewsPerPlace": {
            "title": "Max reviews per place",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "Most-recent public reviews to analyse per place. Monitor/reset capped at 40 (default 20). import_history capped at 100. Keep shallow to control platform usage."
          },
          "maxBudgetUsd": {
            "title": "Max budget this run (USD)",
            "minimum": 0,
            "maximum": 10000,
            "type": "number",
            "description": "Optional soft cap for place-monitored charges this run, planned at USD 0.10 per successful place. Also set Apify max total charge on the run. Failures are never billed."
          },
          "maxPlacesPerRun": {
            "title": "Max successful places this run",
            "minimum": 1,
            "maximum": 200,
            "type": "integer",
            "description": "Hard cap of successful place-monitored charges in this run. Default safety cap is 50 when both this and maxBudgetUsd are unset."
          },
          "sortBy": {
            "title": "Sort reviews by",
            "enum": [
              "newest",
              "relevant",
              "highest",
              "lowest"
            ],
            "type": "string",
            "description": "Google Maps review sort order before collection.",
            "default": "newest"
          },
          "reviewSource": {
            "title": "Review source",
            "enum": [
              "auto",
              "maps_panel"
            ],
            "type": "string",
            "description": "Anonymous Google Maps now shows a limited view (about 5 'most relevant' reviews; sorting asks for sign-in). 'auto' reads the public Google Search reviews dialog for the same place (sortable by newest, paginated, same review ids) and falls back to the Maps panel. 'maps_panel' uses only the Maps panel (limited samples are flagged and never trigger removal alerts).",
            "default": "auto"
          },
          "locale": {
            "title": "Browser locale",
            "type": "string",
            "description": "Browser locale and Google interface language (sent as hl=), e.g. en-US, pt-BR, es-ES, fr-FR. Without hl Google picks the language from the IP.",
            "default": "en-US"
          },
          "mapsHost": {
            "title": "Google Maps host",
            "type": "string",
            "description": "Host used when building Place ID URLs, e.g. www.google.com or www.google.com.br.",
            "default": "www.google.com"
          },
          "minRating": {
            "title": "Min rating filter",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "Optional. Keep only reviews with rating ≥ this value."
          },
          "maxRating": {
            "title": "Max rating filter",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "Optional. Keep only reviews with rating ≤ this value."
          },
          "languages": {
            "title": "Language codes",
            "type": "array",
            "description": "Optional BCP-47 prefixes, e.g. en, pt, es. Reviews with unknown language are kept.",
            "items": {
              "type": "string",
              "minLength": 2,
              "maxLength": 16
            }
          },
          "onlyWithText": {
            "title": "Only reviews with text",
            "type": "boolean",
            "description": "When true, discard rating-only reviews with empty text.",
            "default": false
          },
          "onlyWithoutOwnerResponse": {
            "title": "Only unanswered reviews",
            "type": "boolean",
            "description": "When true, keep only reviews without an owner response.",
            "default": false
          },
          "publishedWithinDays": {
            "title": "Published within days",
            "minimum": 1,
            "maximum": 3650,
            "type": "integer",
            "description": "Best-effort filter using absolute/relative dates. Unknown dates are kept."
          },
          "negativeRatingThreshold": {
            "title": "Negative rating threshold",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "Ratings at or below this value are treated as negative for priority actions. Default: 2."
          },
          "maxPriorityActionsPerPlace": {
            "title": "Max priority actions per place",
            "minimum": 0,
            "maximum": 200,
            "type": "integer",
            "description": "Cap priority_action records emitted per place. Default: 50.",
            "default": 50
          },
          "emitBaselineAsNew": {
            "title": "Emit first-run reviews as new",
            "type": "boolean",
            "description": "When false (default), the first snapshot only establishes baseline history (still emits unanswered negatives).",
            "default": false
          },
          "trackPossibleRemovals": {
            "title": "Track possible removals",
            "type": "boolean",
            "description": "After consecutiveMissThreshold successful scrapes without seeing a known review, emit possible_removal (never hard-delete).",
            "default": true
          },
          "consecutiveMissThreshold": {
            "title": "Consecutive miss threshold",
            "minimum": 2,
            "maximum": 20,
            "type": "integer",
            "description": "How many successful scrapes a review must be missing before possible_removal. Default: 3.",
            "default": 3
          },
          "dedupeEmittedChanges": {
            "title": "Deduplicate emitted changes",
            "type": "boolean",
            "description": "Skip change events already emitted with the same fingerprint.",
            "default": true
          },
          "includeUnchangedReviews": {
            "title": "Include unchanged review snapshots",
            "type": "boolean",
            "description": "When true, also push review_snapshot records for reviews that did not change.",
            "default": false
          },
          "includeFlatExport": {
            "title": "Include flat CSV-friendly rows",
            "type": "boolean",
            "description": "Push flat_export records (one row per review) for Sheets/CSV.",
            "default": true
          },
          "includeRunDigest": {
            "title": "Include run digest",
            "type": "boolean",
            "description": "Push a run_digest record summarizing the whole execution.",
            "default": true
          },
          "historyStoreName": {
            "title": "History store name",
            "type": "string",
            "description": "Named Apify Key-Value Store for durable review history across schedules.",
            "default": "google-maps-review-history"
          },
          "maxConcurrency": {
            "title": "Place concurrency",
            "minimum": 1,
            "maximum": 3,
            "type": "integer",
            "description": "Parallel places. Keep at 1 unless using residential proxy. Max 3."
          },
          "delayBetweenPlacesMs": {
            "title": "Delay between places (ms)",
            "minimum": 0,
            "maximum": 60000,
            "type": "integer",
            "description": "Applied when concurrency is 1. Default: 1500.",
            "default": 1500
          },
          "navigationTimeoutSecs": {
            "title": "Navigation timeout (seconds)",
            "minimum": 15,
            "maximum": 60,
            "type": "integer",
            "description": "Timeout for loading a place page. Default: 35. Max: 60."
          },
          "maxRetriesPerPlace": {
            "title": "Max retries per place",
            "minimum": 0,
            "maximum": 1,
            "type": "integer",
            "description": "Extra attempts after a scrape failure. Retries are never PPE-billed but still use platform time. Default: 0. Max: 1.",
            "default": 0
          },
          "customerGoogleApiKey": {
            "title": "Customer Google API key (optional)",
            "type": "string",
            "description": "If a Google API is required in the future, provide YOUR key. The Actor developer does not pay for external APIs."
          },
          "failRunOnAnyPlaceError": {
            "title": "Fail entire run on any place error",
            "type": "boolean",
            "description": "When true, exit with failure if any place errors. Default: false (isolate failures).",
            "default": false
          },
          "webhookUrls": {
            "title": "Webhook URLs",
            "type": "array",
            "description": "Optional HTTP endpoints that receive JSON payloads for notifications.",
            "items": {
              "type": "string"
            }
          },
          "alertEmails": {
            "title": "Alert emails",
            "type": "array",
            "description": "Recipients for HTML/text alert emails (actions + reviews per place). Sent directly via Gmail SMTP (default), custom SMTP, or Resend. Configure provider credentials as secret Actor environment variables. Gmail requires GMAIL_USER and GMAIL_APP_PASSWORD; no custom domain is needed. See EMAILS guides.",
            "items": {
              "type": "string"
            }
          },
          "emailMode": {
            "title": "Email mode",
            "enum": [
              "digest",
              "per_place"
            ],
            "type": "string",
            "description": "digest = one email at end of run with a section per establishment (recommended). per_place = one email per place with alerts.",
            "default": "digest"
          },
          "notifyOn": {
            "title": "Notify on",
            "enum": [
              "none",
              "priority_actions",
              "changes",
              "priority_and_changes",
              "all"
            ],
            "type": "string",
            "description": "Which events are sent to webhookUrls and alertEmails.",
            "default": "priority_actions"
          },
          "minPriorityToNotify": {
            "title": "Minimum priority to notify",
            "enum": [
              "critical",
              "high",
              "medium",
              "low"
            ],
            "type": "string",
            "description": "Ignore priority actions below this level when notifying (webhooks and email).",
            "default": "high"
          },
          "webhookSlackCompatible": {
            "title": "Slack-compatible webhook payload",
            "type": "boolean",
            "description": "Include Slack text/blocks fields in webhook payloads.",
            "default": false
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Recommended for larger place lists or frequent schedules."
          },
          "debug": {
            "title": "Debug logging",
            "type": "boolean",
            "description": "Verbose scrape and diff logs for local troubleshooting.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}