{
  "openapi": "3.0.1",
  "info": {
    "title": "Product Price Tracker with Price-Drop Alerts, Any Store",
    "description": "Give it product page URLs from independent online shops, get price, currency, stock, SKU and rating, plus change since the last run and price-drop and back-in-stock flags. Reads schema.org data, respects robots.txt. $0.002 per product.",
    "version": "0.1",
    "x-build-id": "o2X1kY9RSGdWrperU"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/opstoolkit~product-price-monitor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-opstoolkit-product-price-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/opstoolkit~product-price-monitor/runs": {
      "post": {
        "operationId": "runs-sync-opstoolkit-product-price-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/opstoolkit~product-price-monitor/run-sync": {
      "post": {
        "operationId": "run-sync-opstoolkit-product-price-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",
        "properties": {
          "urls": {
            "title": "Product page links",
            "type": "array",
            "description": "Links to single product pages on independent online shops, one per entry. Example: [\"https://web-scraping.dev/product/1\", \"https://yourshop.example/products/blue-mug\"]. Category pages, search pages and marketplace links (Amazon, eBay, Walmart and similar) are not read. Links that differ only by tracking parameters or a #fragment count once. Up to 20,000 per run. Required unless you give a dataset ID.",
            "items": {
              "type": "string"
            }
          },
          "datasetId": {
            "title": "Dataset with product links (optional)",
            "type": "string",
            "description": "ID of an Apify dataset that holds product links, for example the output of a sitemap extractor, so you do not have to paste them. Example: \"aBcDeFgHiJkLmNoPq\". The links are added to the ones in 'urls'. Default: empty."
          },
          "field": {
            "title": "Link column in that dataset",
            "type": "string",
            "description": "The dataset column that holds the product link. Example: \"url\". Default: empty, which tries url, productUrl, link and href in that order."
          },
          "historyStore": {
            "title": "History store name",
            "type": "string",
            "description": "Name of the key-value store that keeps each product's last price and stock between runs. Use the same name on every run of the same watch list, and a different name for a different list. 3 to 63 lower-case letters, digits and hyphens. Default: \"product-price-history\". The form is prefilled with a demo store so the example does not mix with your real history.",
            "default": "product-price-history"
          },
          "dropThresholdPercent": {
            "title": "Price change that counts as an alert (%)",
            "minimum": 0,
            "maximum": 100,
            "type": "number",
            "description": "A price drop or rise of at least this many percent against the last run sets priceDrop or priceRise and the alert field. Example: 5 means a drop from 100 to 95 or lower. Default 5. Range 0 to 100. Use 0 to flag any change.",
            "default": 5
          },
          "changedOnly": {
            "title": "Only output changed products",
            "type": "boolean",
            "description": "true writes only products that are new or whose price or stock changed since the last run, plus rows that failed. Default false (every product gets a row). Products are still checked and charged the same, this only keeps the dataset short for a daily schedule.",
            "default": false
          },
          "useAI": {
            "title": "AI fallback for pages without structured data",
            "type": "boolean",
            "description": "true asks an AI model to read the price from pages that show a price in their text but have no schema.org, microdata or Open Graph data. The price must appear in the page text or it is rejected. Costs an extra $0.002 per page it reads, plus model usage billed by Apify (about $0.0005). Default false.",
            "default": false
          },
          "maxUrls": {
            "title": "Max product pages",
            "minimum": 1,
            "maximum": 20000,
            "type": "integer",
            "description": "The most product pages to check in one run, from 1 to 20,000. Extra links are not checked. Default 500 (the form is prefilled with 10). Requests to one shop run at one per second, so 500 pages from one shop take about 9 minutes.",
            "default": 500
          },
          "currencyHint": {
            "title": "Currency to assume",
            "type": "string",
            "description": "A 3-letter currency code used only when a page shows a price but no currency. Example: \"EUR\". Default: empty, so the currency stays empty in that case."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}