{
  "openapi": "3.0.1",
  "info": {
    "title": "WooCommerce Catalog & Price Monitor - Diffs & Low-Stock Alerts",
    "description": "Export any public WooCommerce store's full catalog (products, variations, prices, stock) from the Store API and get typed change alerts on every scheduled run — price drops, new products, stock-outs, and low-stock-remaining warnings.",
    "version": "0.1",
    "x-build-id": "nF3eoclnsoUNmCju2"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/yasaslive~woo-monitor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-yasaslive-woo-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/yasaslive~woo-monitor/runs": {
      "post": {
        "operationId": "runs-sync-yasaslive-woo-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/yasaslive~woo-monitor/run-sync": {
      "post": {
        "operationId": "run-sync-yasaslive-woo-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": [
          "storeUrls"
        ],
        "properties": {
          "storeUrls": {
            "title": "WooCommerce store URLs",
            "minItems": 1,
            "maxItems": 100,
            "type": "array",
            "description": "Store URLs to monitor. Any URL on the store works — it is normalised to the https origin (for example https://porterandyork.com/product-category/beef/ becomes https://porterandyork.com). Each store is read from its public WooCommerce Store API (/wp-json/wc/store/v1/products). Not sure which of your prospects qualify? Run `npm run discover -- domain1.com domain2.com` first. Note that some WordPress hosts ship a robots.txt that excludes /wp-json/; those stores are reported as \"skipped\" and cost nothing.",
            "default": [
              "https://porterandyork.com",
              "https://lifterlms.com"
            ],
            "items": {
              "type": "string"
            }
          },
          "exportCatalog": {
            "title": "Export the full catalog",
            "type": "boolean",
            "description": "Push every product/variation to the dataset (kind: \"record\"). Turn this off to run in alert-only mode: snapshots and change events are still produced, but the catalog rows are not stored — much cheaper for high-frequency schedules.",
            "default": true
          },
          "lowStockThreshold": {
            "title": "Low-stock threshold (units)",
            "minimum": 0,
            "maximum": 10000,
            "type": "integer",
            "description": "Fire a low_stock event when a product's remaining units fall to this number or below. The event fires when stock CROSSES into the threshold or falls further while low — not on every run while it sits there — so a scheduled monitor does not repeat the same three items every fifteen minutes. Set to 0 to disable low-stock alerting entirely.",
            "default": 5
          },
          "storeName": {
            "title": "Snapshot key-value store name",
            "type": "string",
            "description": "Named key-value store that holds the previous run's snapshot per store (one record per hostname). Keep this stable across scheduled runs — it is what makes diffing possible. Use a different name to keep separate monitoring streams apart.",
            "default": "woo-monitor-snapshots"
          },
          "watchFilters": {
            "title": "Change event filters",
            "type": "object",
            "description": "Optional filters applied to change events only — the catalog export is never filtered. All supplied conditions must match (AND); within a list, any entry matches (OR). nameIncludes/categories/tags are case-insensitive; nameIncludes is a substring match, categories and tags are exact matches. minPctChange (default 0 = report every price move) keeps only price moves whose absolute percentage change is greater than or equal to the threshold; it never filters stock, low-stock or product events."
          },
          "slackWebhookUrl": {
            "title": "Slack incoming webhook URL",
            "type": "string",
            "description": "Optional. Slack incoming webhook (https://hooks.slack.com/services/...). Receives a grouped summary per store: event counts, EVERY low-stock hit, and the ten most significant price moves. Nothing is sent when a run produces no change events."
          },
          "alertWebhookUrl": {
            "title": "Generic alert webhook URL",
            "type": "string",
            "description": "Optional. Any HTTPS endpoint that accepts a POST with a JSON body. Receives the same grouped summary as a machine-readable payload. Must resolve to a public address."
          },
          "maxProductsPerStore": {
            "title": "Maximum products per store",
            "minimum": 1,
            "maximum": 20000,
            "type": "integer",
            "description": "Stop paginating a store after this many products. A store cut short by this limit is reported as \"partial\" and its change detection is skipped for that run, because a truncated catalog would look like mass product removal on the next diff. Raise it for large catalogs; lower it to bound run time.",
            "default": 5000
          },
          "fetchVariations": {
            "title": "Fetch exact variation prices",
            "type": "boolean",
            "description": "The Store API's product list returns variation ids and attributes but NO per-variation price or stock, so exact variation figures cost one extra request each. With this on, variation rows carry their own price and stock (priceSource: \"variation\"). With it off — or past the budget below — they inherit the parent product's price and are labelled priceSource: \"parent\" so you always know which you are looking at.",
            "default": true
          },
          "maxVariationFetchesPerStore": {
            "title": "Variation lookup budget per store",
            "minimum": 0,
            "maximum": 20000,
            "type": "integer",
            "description": "Ceiling on the extra per-variation requests described above. Variation rows beyond the budget keep the parent price and are labelled priceSource: \"parent\". Set to 0 to never fetch variations individually.",
            "default": 500
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Apify Proxy settings. Datacenter proxies are enough for the Store API; switch to residential if a store blocks datacenter ranges.",
            "default": {
              "useApifyProxy": true
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}