> ## Documentation Index
> Fetch the complete documentation index at: https://docs.sitespy.app/llms.txt
> Use this file to discover all available pages before exploring further.

# Update watch

> Update an existing web page change monitor (watch) using JSON. Accepts the same structure as returned in [get single watch information](#operation/getWatch).



## OpenAPI

````yaml /api-reference/openapi.yaml put /watch/{uuid}
openapi: 3.1.0
info:
  title: Site Spy API
  description: >
    # Site Spy web page monitoring and notifications API


    REST API for managing page watches, group tags, and notifications.


    Site Spy can be driven by this simple REST API — the endpoint pages include
    `curl`, Python, and JavaScript examples to help you get started faster.


    ## Where to find my API key?


    Your API key is under [**Settings →
    API**](https://sitespy.app/dashboard/settings?tab=api) in the Site Spy
    dashboard.

    Simply click the API key to copy it to your clipboard.


    ## Connection URL


    All endpoints live under `https://detect.coolify.vkuprin.com/api/v1`, for
    example:

    `https://detect.coolify.vkuprin.com/api/v1/watch/cc0cfffa-f449-477b-83ea-0caafd1dc091/history`


    ## Authentication


    Almost all API requests require authentication, provided as an **API key**
    in the header of the HTTP request.


    For example: `x-api-key: YOUR_API_KEY`
  version: 0.1.6
  contact:
    name: Site Spy
    url: https://sitespy.app
  license:
    name: Apache 2.0
    url: https://www.apache.org/licenses/LICENSE-2.0.html
servers:
  - url: https://detect.coolify.vkuprin.com/api/v1
    description: Site Spy production
security:
  - ApiKeyAuth: []
tags:
  - name: Watch Management
    description: >
      Core functionality for managing web page monitors. Create, retrieve,
      update, and delete individual watches.

      Each watch represents a single URL being monitored for changes, with
      configurable settings for check intervals,

      notification preferences, and content filtering options.
  - name: Watch History
    description: |
      Get a list of timestamps of all changes detected for a watch.
  - name: Snapshots
    description: >
      Retrieve individual text snapshot of monitored content according to the
      `timestamp`. The text snapshot is the HTML

      to Text at page check time.


      Set the query argument `html` to any value to retrieve the last HTML
      fetched, the system only keeps the last two

      (2) HTML files fetched.


      Use the Watch History API endpoint to get a list of timestamps to pass to
      this query.
  - name: Favicon
    description: >
      Retrieve favicon images associated with monitored web pages. These are
      used in the dashboard interface

      to visually identify different watches in your monitoring list.
  - name: Tag Management
    description: >
      Organize your watches using tags and groups. Tags (also known as Groups)
      allow you to categorize monitors, set group-wide

      notification preferences, and perform bulk operations like mass rechecking
      or status changes across

      multiple related watches.
  - name: Notifications
    description: >
      Configure global notification endpoints that can be used across all your
      watches. Supports various

      notification services including email, Discord, Slack, webhooks, and many
      other popular platforms.

      These settings serve as defaults that can be overridden at the individual
      watch or tag level.


      The notification syntax uses
      [https://github.com/caronc/apprise](https://github.com/caronc/apprise).
  - name: User Settings
    description: >
      Manage user-specific settings such as default recheck intervals. These
      settings are stored per API key

      and apply to all watches created by that user unless overridden at the
      watch level.
  - name: Search
    description: >
      Search and filter your watches by URL patterns, titles, or tags. Useful
      for quickly finding specific

      monitors in large collections or identifying watches that match certain
      criteria.
  - name: Import
    description: >
      Bulk import multiple URLs for monitoring. Accepts plain text lists of URLs
      and can automatically

      apply tags, proxy settings, and other configurations to all imported
      watches simultaneously.
  - name: System Information
    description: >
      Retrieve system status and statistics about your Site Spy instance,
      including total watch

      counts, uptime information, and version details.
  - name: Email Verification
    description: >
      Manage email notification settings for your API key. Each API key can have
      one email address

      associated with it for receiving notifications. The email must be verified
      before notifications

      can be sent to it.
  - name: Telegram Notifications
    description: >
      Connect your Telegram account to receive instant change notifications.

      Generate a connect link, open it in Telegram, tap Start — done. Free for
      all plans.
  - name: Web Push Notifications
    description: >
      Subscribe to browser push notifications for instant alerts when watched
      pages change.

      Uses the Web Push protocol (RFC 8030) with VAPID authentication. Free for
      all plans.
  - name: RSS Feeds
    description: >
      Manage per-user RSS feed access tokens and retrieve feed URLs. Each user
      can generate a

      personal RSS token that provides access to their watches via standard RSS
      readers. Feeds

      are scoped to the user's watches only, ensuring multi-tenant privacy.
  - name: API Key Management
    description: >
      Generate and manage API keys. API keys are used to authenticate all
      requests to the API.

      Each API key is associated with a unique user and their watches.
  - name: Feature Flags
    description: >
      Retrieve feature flags for the current API key. Feature flags control
      which features are

      enabled or disabled for specific users.
  - name: Authentication
    description: >
      User account registration and authentication. Users can create accounts
      with email/password

      and receive an API key that links to their account. This enables syncing
      watches across

      the browser extension and web dashboard.
  - name: Plan
    description: >
      Retrieve the current subscription plan and usage for the authenticated API
      key. Plans control

      the maximum number of watches a user can create (Free: 2, Starter: 25,
      Pro: 100).
  - name: Billing
    description: >
      Manage subscriptions via Lemon Squeezy. Create checkout sessions to
      upgrade, access the

      customer billing portal, and receive webhook events from Lemon Squeezy.
  - name: Feedback
    description: >
      Collect product research responses from authenticated users. One-time PMF
      (Sean Ellis)

      survey submission per user.
  - name: Screenshots
    description: >
      Retrieve the history of visual snapshots captured for a watch. Use the
      returned timestamps

      with the Visual Diff endpoints to compare any two captures.
  - name: Visual Diff
    description: >
      Retrieve individual screenshots and pixel-level visual comparisons between
      any two captured

      snapshots of a watch, including difference metadata such as changed
      regions.
paths:
  /watch/{uuid}:
    put:
      tags:
        - Watch Management
      summary: Update watch
      description: >-
        Update an existing web page change monitor (watch) using JSON. Accepts
        the same structure as returned in [get single watch
        information](#operation/getWatch).
      operationId: updateWatch
      parameters:
        - name: uuid
          in: path
          required: true
          description: Web page change monitor (watch) unique ID
          schema:
            type: string
            format: uuid
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateWatch'
      responses:
        '200':
          description: Web page change monitor (watch) updated successfully
          content:
            text/plain:
              schema:
                type: string
                example: OK
        '500':
          description: Server error
      x-codeSamples:
        - lang: curl
          source: >
            curl -X PUT
            "https://detect.coolify.vkuprin.com/api/v1/watch/095be615-a8ad-4c33-8e9c-c7612fbf6c9f"
            \
              -H "x-api-key: YOUR_API_KEY" \
              -H "Content-Type: application/json" \
              -d '{
                "url": "https://updated-example.com",
                "title": "Updated Monitor",
                "paused": false
              }'
        - lang: Python
          source: >
            import requests


            headers = {
                'x-api-key': 'YOUR_API_KEY',
                'Content-Type': 'application/json'
            }

            uuid = '095be615-a8ad-4c33-8e9c-c7612fbf6c9f'

            data = {
                'url': 'https://updated-example.com',
                'title': 'Updated Monitor',
                'paused': False
            }

            response =
            requests.put(f'https://detect.coolify.vkuprin.com/api/v1/watch/{uuid}',
                                  headers=headers, json=data)
            print(response.text)
components:
  schemas:
    UpdateWatch:
      allOf:
        - $ref: '#/components/schemas/WatchBase'
        - type: object
          properties:
            last_viewed:
              type: integer
              description: >-
                Unix timestamp in seconds of the last time the watch was viewed.
                Setting it to a value higher than `last_changed` in the "Update
                watch" endpoint marks the watch as viewed.
              minimum: 0
    WatchBase:
      type: object
      properties:
        uuid:
          type: string
          format: uuid
          description: Unique identifier
          readOnly: true
        date_created:
          type:
            - integer
            - 'null'
          description: Unix timestamp of creation
          readOnly: true
        owner_api_key:
          type:
            - string
            - 'null'
          description: API key that owns this watch (multi-tenant isolation)
          readOnly: true
        url:
          type: string
          format: uri
          description: URL to monitor for changes
          maxLength: 5000
        title:
          type:
            - string
            - 'null'
          description: >-
            Custom title for the web page change monitor (watch), not to be
            confused with page_title
          maxLength: 5000
        tag:
          type: string
          description: Tag UUID to associate with this web page change monitor (watch)
          maxLength: 5000
        tags:
          type: array
          items:
            type: string
          description: Array of tag UUIDs
        paused:
          type: boolean
          description: Whether the web page change monitor (watch) is paused
        paused_by:
          type:
            - string
            - 'null'
          enum:
            - plan_limit
            - null
          description: >
            Non-null when `paused=true` was set automatically. Values:
              - `plan_limit` — owner exceeded their plan's watch cap; auto-deleted 30d after `paused_at` unless user upgrades or un-pauses.
            Null means the watch was paused manually by the user (no
            auto-delete).
          readOnly: true
        paused_at:
          type: integer
          description: >
            Unix timestamp when auto-pause was applied. Starts the auto-delete
            clock for

            `paused_by != null` watches. 0 when never auto-paused.
          readOnly: true
        notification_muted:
          type: boolean
          description: Whether notifications are muted
        method:
          type: string
          enum:
            - GET
            - POST
            - DELETE
            - PUT
          description: HTTP method to use
        fetch_backend:
          type: string
          description: |
            Backend to use for fetching content. Common values:
            - `system` (default) - Use the system-wide default fetcher
            - `html_requests` - Fast requests-based fetcher
            - `html_webdriver` - Browser-based fetcher (Playwright/Puppeteer)
            - `extra_browser_*` - Custom browser configurations (if configured)
            - Plugin-provided fetchers (if installed)
          pattern: ^(system|html_requests|html_webdriver|extra_browser_.+)$
          default: system
        headers:
          type: object
          additionalProperties:
            type: string
          description: HTTP headers to include in requests
        body:
          type:
            - string
            - 'null'
          description: HTTP request body
          maxLength: 5000
        proxy:
          type:
            - string
            - 'null'
          description: Proxy configuration
          maxLength: 5000
        ignore_status_codes:
          type:
            - boolean
            - 'null'
          description: Ignore HTTP status code errors (boolean or null)
        webdriver_delay:
          type:
            - integer
            - 'null'
          description: Delay in seconds for webdriver
        webdriver_js_execute_code:
          type:
            - string
            - 'null'
          description: JavaScript code to execute
          maxLength: 5000
        time_between_check:
          type: object
          properties:
            weeks:
              type:
                - integer
                - 'null'
              minimum: 0
              maximum: 52000
            days:
              type:
                - integer
                - 'null'
              minimum: 0
              maximum: 365000
            hours:
              type:
                - integer
                - 'null'
              minimum: 0
              maximum: 8760000
            minutes:
              type:
                - integer
                - 'null'
              minimum: 0
              maximum: 525600000
            seconds:
              type:
                - integer
                - 'null'
              minimum: 0
              maximum: 31536000000
          description: >-
            Time intervals between checks. All fields must be non-negative. At
            least one non-zero value required when not using default settings.
        time_between_check_use_default:
          type: boolean
          default: true
          description: >-
            Whether to use global settings for time between checks - defaults to
            true if not set
        notification_urls:
          type: array
          items:
            type: string
            maxLength: 1000
          maxItems: 100
          description: >-
            Notification URLs for this web page change monitor (watch). Maximum
            100 URLs.
        notification_title:
          type:
            - string
            - 'null'
          description: Custom notification title
          maxLength: 5000
        notification_body:
          type:
            - string
            - 'null'
          description: Custom notification body
          maxLength: 5000
        notification_format:
          type: string
          enum:
            - text
            - html
            - htmlcolor
            - markdown
            - System default
          description: Format for notifications
        track_ldjson_price_data:
          type:
            - boolean
            - 'null'
          description: Whether to track JSON-LD price data
        browser_steps:
          type: array
          items:
            type: object
            properties:
              operation:
                type:
                  - string
                  - 'null'
                maxLength: 5000
              selector:
                type:
                  - string
                  - 'null'
                maxLength: 5000
              optional_value:
                type:
                  - string
                  - 'null'
                maxLength: 5000
            required:
              - operation
              - selector
              - optional_value
            additionalProperties: false
          maxItems: 100
          description: Browser automation steps. Maximum 100 steps allowed.
        processor:
          type: string
          enum:
            - restock_diff
            - text_json_diff
            - image_ssim_diff
          default: text_json_diff
          description: >-
            Optional processor mode to use for change detection.
            `image_ssim_diff` (screenshot monitoring) requires Pro plan.
            Defaults to `text_json_diff` if not specified.
        screenshot_enabled:
          type: boolean
          default: false
          description: >-
            When true, capture and store screenshots alongside text snapshots on
            each check. Requires Pro plan and `fetch_backend` set to a
            browser-based fetcher (e.g. `html_webdriver`).
        include_filters:
          type: array
          items:
            type: string
            maxLength: 5000
          maxItems: 100
          description: CSS/XPath selectors to extract specific content from the page
        subtractive_selectors:
          type: array
          items:
            type: string
            maxLength: 5000
          maxItems: 100
          description: CSS/XPath selectors to remove content from the page
        ignore_text:
          type: array
          items:
            type: string
            maxLength: 5000
          maxItems: 100
          description: Text patterns to ignore in change detection
        trigger_text:
          type: array
          items:
            type: string
            maxLength: 5000
          maxItems: 100
          description: Text/regex patterns that must be present to trigger a change
        text_should_not_be_present:
          type: array
          items:
            type: string
            maxLength: 5000
          maxItems: 100
          description: Text that should NOT be present (triggers alert if found)
        extract_text:
          type: array
          items:
            type: string
            maxLength: 5000
          maxItems: 100
          description: Regex patterns to extract specific text after filtering
        trim_text_whitespace:
          type: boolean
          default: false
          description: Strip leading/trailing whitespace from text
        sort_text_alphabetically:
          type: boolean
          default: false
          description: Sort lines alphabetically before comparison
        remove_duplicate_lines:
          type: boolean
          default: false
          description: Remove duplicate lines from content
        check_unique_lines:
          type: boolean
          default: false
          description: Compare against all history for unique lines
        strip_ignored_lines:
          type:
            - boolean
            - 'null'
          description: Remove lines matching ignore patterns
        filter_text_added:
          type: boolean
          default: true
          description: Include added text in change detection
        filter_text_removed:
          type: boolean
          default: true
          description: Include removed text in change detection
        filter_text_replaced:
          type: boolean
          default: true
          description: Include replaced text in change detection
        in_stock_only:
          type: boolean
          default: true
          description: Only trigger on in-stock transitions (restock_diff processor)
        follow_price_changes:
          type: boolean
          default: true
          description: Monitor and track price changes (restock_diff processor)
        price_change_threshold_percent:
          type:
            - number
            - 'null'
          description: Minimum price change percentage to trigger notification
        has_ldjson_price_data:
          type:
            - boolean
            - 'null'
          description: Whether page has LD-JSON price data (auto-detected)
          readOnly: true
        notification_screenshot:
          type: boolean
          default: false
          description: >-
            Include screenshot in notifications (if supported by notification
            URL)
        filter_failure_notification_send:
          type: boolean
          default: true
          description: Send notification when filters fail to match content
        use_page_title_in_list:
          type:
            - boolean
            - 'null'
          description: Display page title in watch list (null = use system default)
        history_snapshot_max_length:
          type:
            - integer
            - 'null'
          minimum: 1
          maximum: 1000
          description: >-
            Maximum number of history snapshots to keep (null = use system
            default)
        time_schedule_limit:
          type: object
          description: Weekly schedule limiting when checks can run
          properties:
            enabled:
              type: boolean
              default: false
            monday:
              $ref: '#/components/schemas/DaySchedule'
            tuesday:
              $ref: '#/components/schemas/DaySchedule'
            wednesday:
              $ref: '#/components/schemas/DaySchedule'
            thursday:
              $ref: '#/components/schemas/DaySchedule'
            friday:
              $ref: '#/components/schemas/DaySchedule'
            saturday:
              $ref: '#/components/schemas/DaySchedule'
            sunday:
              $ref: '#/components/schemas/DaySchedule'
        conditions:
          type: array
          items:
            type: object
            properties:
              field:
                type: string
                description: Field to check (e.g., 'page_filtered_text', 'page_title')
              operator:
                type: string
                description: >-
                  Comparison operator (e.g., 'contains_regex', 'equals',
                  'not_equals')
              value:
                type: string
                description: Value to compare against
            required:
              - field
              - operator
              - value
          maxItems: 100
          description: >-
            Array of condition rules for change detection logic (empty array
            when not set)
        conditions_match_logic:
          type: string
          enum:
            - ALL
            - ANY
          default: ALL
          description: >-
            Logic operator - ALL (match all conditions) or ANY (match any
            condition)
        ai_alert_condition:
          type:
            - string
            - 'null'
          description: >-
            Plain-English condition for AI smart alerts (Pro+ only). When set,
            AI evaluates each change against this condition and suppresses
            notifications that don't match. Example - "Only notify me if the
            price drops below $50".
          maxLength: 500
        last_ai_summary:
          type:
            - string
            - 'null'
          description: >-
            AI-generated plain-English summary of the most recent change (Pro+
            only, read-only — generated automatically when a change is
            detected).
          readOnly: true
        track_what:
          type:
            - string
            - 'null'
          description: >-
            User's monitoring intent, e.g. "price changes", "new job listings".
            Set by smart-configure or AI chat when the user describes what they
            want to track.
          maxLength: 500
    DaySchedule:
      type: object
      properties:
        enabled:
          type: boolean
          default: true
        start_time:
          type: string
          pattern: ^([0-1]?[0-9]|2[0-3]):[0-5][0-9]$
          default: '00:00'
          description: Start time in HH:MM format
        duration:
          type: object
          properties:
            hours:
              type: string
              pattern: ^[0-9]+$
              default: '24'
            minutes:
              type: string
              pattern: ^[0-9]+$
              default: '00'
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        API key for authentication. You can find your API key in the Site Spy
        dashboard under Settings → API.

````