{
  "openapi": "3.0.1",
  "info": {
    "title": "Website Change Monitor: Page & Selector Alerts",
    "description": "Checks web pages or CSS selectors on a schedule and reports each page as changed, unchanged, baseline, selector missing or fetch error, with a line diff. Sends one alert per run to Slack, Discord or a webhook.",
    "version": "0.1",
    "x-build-id": "XeDlqofpxGxqBLZaV"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/hollowayco~website-change-monitor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-hollowayco-website-change-monitor",
        "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/hollowayco~website-change-monitor/runs": {
      "post": {
        "operationId": "runs-sync-hollowayco-website-change-monitor",
        "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/hollowayco~website-change-monitor/run-sync": {
      "post": {
        "operationId": "run-sync-hollowayco-website-change-monitor",
        "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",
        "required": [
          "pages"
        ],
        "properties": {
          "pages": {
            "title": "Pages to watch",
            "minItems": 1,
            "maxItems": 1000,
            "type": "array",
            "description": "One entry per page. Give the full URL. Add a CSS selector to watch only part of the page, for example a price, a table or an article. If the selector stops matching (for example after a redesign), that page is reported as \"selector_missing\" and the run still finishes. The label is shown in results and alerts.",
            "items": {
              "type": "object",
              "properties": {
                "url": {
                  "title": "URL",
                  "type": "string",
                  "description": "Full address of the page, starting with http:// or https://.",
                  "editor": "textfield",
                  "pattern": "^https?://\\S+$"
                },
                "selector": {
                  "title": "CSS selector (optional)",
                  "type": "string",
                  "description": "Watch only the elements that match this selector, for example #price or main article. Leave empty to watch the whole page.",
                  "editor": "textfield"
                },
                "label": {
                  "title": "Label (optional)",
                  "type": "string",
                  "description": "Short name shown in results and alerts.",
                  "editor": "textfield"
                }
              },
              "required": [
                "url"
              ],
              "additionalProperties": false
            }
          },
          "mode": {
            "title": "What to compare",
            "enum": [
              "text",
              "html",
              "selector"
            ],
            "type": "string",
            "description": "text: the visible text of the page, or of the elements that match the selector. Markup, scripts and styles are ignored. html: the HTML of the page or of the matched elements, without scripts and styles; use it to catch changed links, images or attributes. selector: the visible text of the matched elements, and every page must have a selector.",
            "default": "text"
          },
          "ignorePatterns": {
            "title": "Ignore patterns",
            "type": "array",
            "description": "Regular expressions for content that should not count as a change. Matching text is removed before the comparison. The defaults remove timestamps, dates, clock times, \"5 minutes ago\" texts, Unix timestamps, CSRF and nonce tokens, cache-busting query parameters and hashed asset file names. Write /pattern/i to ignore letter case. Remove the date patterns if you want to know when a date on the page changes.",
            "default": [
              "\\b\\d{4}-\\d{2}-\\d{2}[T ]\\d{2}:\\d{2}(?::\\d{2}(?:[.,]\\d+)?)?(?:Z|[+-]\\d{2}:?\\d{2})?\\b",
              "\\b\\d{4}-\\d{2}-\\d{2}\\b",
              "\\b\\d{1,2}[/.-]\\d{1,2}[/.-](?:\\d{4}|\\d{2})\\b",
              "/\\b(?:jan(?:uary)?|feb(?:ruary)?|mar(?:ch)?|apr(?:il)?|may|june?|july?|aug(?:ust)?|sep(?:t(?:ember)?)?|oct(?:ober)?|nov(?:ember)?|dec(?:ember)?)\\.?\\s+\\d{1,2}(?:st|nd|rd|th)?,?\\s+\\d{4}\\b/i",
              "/\\b\\d{1,2}(?:st|nd|rd|th)?\\s+(?:jan(?:uary)?|feb(?:ruary)?|mar(?:ch)?|apr(?:il)?|may|june?|july?|aug(?:ust)?|sep(?:t(?:ember)?)?|oct(?:ober)?|nov(?:ember)?|dec(?:ember)?)\\.?,?\\s+\\d{4}\\b/i",
              "/\\b\\d{1,2}:\\d{2}(?::\\d{2})?(?:\\s*[ap]\\.?m\\.?)?/i",
              "/\\b\\d+\\s+(?:seconds?|secs?|minutes?|mins?|hours?|hrs?|days?|weeks?|months?|years?)\\s+ago\\b/i",
              "/\\b(?:just now|an? (?:second|minute|hour|day|week|month|year) ago)\\b/i",
              "\\b1[5-9]\\d{8}(?:\\d{3})?\\b",
              "/\\b(?:nonce|integrity)=[\"'][^\"']*[\"']/i",
              "/(?:csrf|xsrf)[\\w-]*[\"']\\s+content=[\"'][^\"']*[\"']/i",
              "/\\bname=[\"'](?:_token|authenticity_token|csrfmiddlewaretoken|__requestverificationtoken|[\\w-]*(?:csrf|xsrf)[\\w-]*)[\"'][^>]*?\\bvalue=[\"'][^\"']*[\"']/i",
              "/\\bdata-[\\w-]*(?:csrf|xsrf|nonce|token)[\\w-]*=[\"'][^\"']*[\"']/i",
              "/[?&](?:v|ver|version|_|t|ts|cb|cache|cachebust|cachebuster|rev|hash|timestamp|nocache)=[^&\"'\\s<>]*/i",
              "/[.-][0-9a-f]{8,32}(?=\\.(?:js|mjs|css|map|woff2?|ttf|png|jpe?g|gif|svg|webp|ico)\\b)/i"
            ],
            "items": {
              "type": "string"
            }
          },
          "minChangePercent": {
            "title": "Minimum change",
            "minimum": 0,
            "maximum": 100,
            "type": "number",
            "description": "Report a page as changed only when at least this share of its content changed (0 to 100). With 0, every change is reported. A smaller change is reported as \"unchanged\" with its percent, and the stored copy is kept, so small changes add up until they pass the threshold.",
            "default": 0
          },
          "maxDiffLines": {
            "title": "Maximum diff lines",
            "minimum": 0,
            "maximum": 1000,
            "type": "integer",
            "description": "The most added lines and the most removed lines to include in each result and in the JSON webhook. The total counts are always included.",
            "default": 50
          },
          "watchSitemap": {
            "title": "Sitemap URL (optional)",
            "pattern": "^https?://\\S+$",
            "type": "string",
            "description": "Also watch a sitemap.xml, a sitemap index, or an RSS or Atom feed, and report URLs added since the last run. Each run adds one result for it: \"baseline\" on the first run, then \"new_urls\" with the list of new URLs."
          },
          "notifyOn": {
            "title": "When to send a notification",
            "enum": [
              "changes",
              "always",
              "errors"
            ],
            "type": "string",
            "description": "changes: when a page changed, new sitemap URLs appeared, a selector was not found, a page could not be fetched, or the run stopped at its charge limit. always: after every run, with a summary. errors: only when a selector was not found, a page or the sitemap could not be fetched, or the run stopped at its charge limit.",
            "default": "changes"
          },
          "webhookUrl": {
            "title": "Webhook URL (JSON POST)",
            "type": "string",
            "description": "Any URL that accepts a POST request with a JSON body, for example Zapier, Make, n8n or your own server. The body contains the run summary and every result with its diff. Stored encrypted."
          },
          "slackWebhookUrl": {
            "title": "Slack webhook URL",
            "type": "string",
            "description": "A Slack incoming webhook URL (https://hooks.slack.com/services/...). Stored encrypted."
          },
          "discordWebhookUrl": {
            "title": "Discord webhook URL",
            "type": "string",
            "description": "A Discord channel webhook URL (https://discord.com/api/webhooks/...). Stored encrypted."
          },
          "monitorId": {
            "title": "Monitor ID",
            "type": "string",
            "description": "Name of the stored history. Runs with the same monitor ID compare against each other. If empty, the ID is derived from the page list, so editing the list starts a new history. Set your own ID, for example shop-prices, to keep the history when you add or remove pages. Use different IDs for tasks that must not share history."
          },
          "renderJs": {
            "title": "Render JavaScript",
            "type": "boolean",
            "description": "Load each page in headless Chrome so that content created by JavaScript is included. Slower, and the default memory goes from 256 MB to 2 GB. Leave it off for normal pages.",
            "default": false
          },
          "requestTimeoutSecs": {
            "title": "Page timeout",
            "minimum": 1,
            "maximum": 300,
            "type": "integer",
            "description": "How long to wait for each page. A page that takes longer is tried once more and then reported as \"fetch_error\".",
            "default": 30
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Optional. Use a proxy when a site blocks requests from data centers.",
            "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
                  },
                  "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}