{
  "openapi": "3.0.1",
  "info": {
    "title": "Coles Stock Checker & API: Prices & Specials by Store",
    "description": "Coles stock checker and API: exact stock count, price, specials, half price and multibuy deals and unit price at every Coles store near your postcode or suburb. Search, categories, the whole specials catalogue or product links. Scheduled runs = restock and price drop alerts.",
    "version": "0.1",
    "x-build-id": "ZGmt45CkWefCHmH1m"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/s_actors~coles-stock-checker/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-s_actors-coles-stock-checker",
        "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/s_actors~coles-stock-checker/runs": {
      "post": {
        "operationId": "runs-sync-s_actors-coles-stock-checker",
        "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/s_actors~coles-stock-checker/run-sync": {
      "post": {
        "operationId": "run-sync-s_actors-coles-stock-checker",
        "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": {
          "searchTerms": {
            "title": "🔎 Search terms",
            "type": "array",
            "description": "What to search on coles.com.au, one per line (e.g. \"milk\", \"tim tam\", \"pokemon cards\"). Each term is searched at every chosen store.",
            "items": {
              "type": "string"
            }
          },
          "locations": {
            "title": "📍 Postcodes or suburbs (store stock)",
            "type": "array",
            "description": "Australian postcodes or suburbs, one per line (2000, 3000, \"Bondi Junction\"). For each, the stock count, price and specials of every product at the nearest Coles supermarkets. Empty = Coles online prices and stock without a store.",
            "items": {
              "type": "string"
            }
          },
          "storesPerLocation": {
            "title": "🏬 Stores per postcode",
            "minimum": 1,
            "maximum": 50,
            "type": "integer",
            "description": "How many of the nearest Coles supermarkets to check around each postcode or suburb (up to 50).",
            "default": 3
          },
          "radiusKm": {
            "title": "📏 Radius (km)",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Only stores this close to the postcode or suburb.",
            "default": 25
          },
          "storeIds": {
            "title": "🔢 Coles store numbers",
            "type": "array",
            "description": "Exact Coles stores by number, one per line (853 = Coles Bondi Westfield). The number is the storeId column of an earlier run. Store address columns stay empty for these.",
            "items": {
              "type": "string"
            }
          },
          "categories": {
            "title": "🗂️ Categories and specials",
            "type": "array",
            "description": "Whole Coles categories, one per line: a category link (https://www.coles.com.au/browse/dairy-eggs-fridge/milk), its path (\"dairy-eggs-fridge/milk\") or a top category name (\"Pantry\"). \"specials\" = the whole specials catalogue of the week, also \"half price\", \"multibuy\" and \"online only\".",
            "items": {
              "type": "string"
            }
          },
          "products": {
            "title": "🏷️ Products (links or ids)",
            "type": "array",
            "description": "Exact products, one per line: a coles.com.au product link (https://www.coles.com.au/product/arnott-s-tim-tam-original-chocolate-biscuit-large-pack-365g-6634760) or its id (6634760). Best for a restock watchlist.",
            "items": {
              "type": "string"
            }
          },
          "maxItemsPerQuery": {
            "title": "🔢 Max products per query and store",
            "minimum": 0,
            "maximum": 20000,
            "type": "integer",
            "description": "How many products to take from each search term or category at each store (48 per Coles page). 0 = all of them.",
            "default": 100
          },
          "sortBy": {
            "title": "↕️ Sort by",
            "enum": [
              "relevance",
              "priceLowToHigh",
              "priceHighToLow",
              "unitPriceLowToHigh",
              "popular"
            ],
            "type": "string",
            "description": "The order of coles.com.au, which decides the products taken when there is a limit.",
            "default": "relevance"
          },
          "specialsOnly": {
            "title": "🏷️ Only specials",
            "type": "boolean",
            "description": "Return only products on special this week (price cuts, half price, multibuy).",
            "default": false
          },
          "minDiscountPercent": {
            "title": "💸 Minimum discount %",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "Return only specials at least this much below the regular price (e.g. 50 = half price). Empty = any."
          },
          "inStockOnly": {
            "title": "✅ Only in stock",
            "type": "boolean",
            "description": "Skip products with no stock at the store.",
            "default": false
          },
          "includeDetails": {
            "title": "🧾 Barcode, ingredients and nutrition",
            "type": "boolean",
            "description": "Add the barcode (EAN), description, ingredients, allergens, nutrition per 100 g and country of origin. One extra request per product: slower on big runs.",
            "default": false
          },
          "onlyChanges": {
            "title": "🔔 Only report changes",
            "type": "boolean",
            "description": "For scheduled runs. The first run saves stock and prices; later runs return only what changed at each store: back in stock, restocked, out of stock, specials started or ended, price drops and rises, new products. You pay only for the changes returned.",
            "default": false
          },
          "monitorName": {
            "title": "🏷️ Monitor name",
            "type": "string",
            "description": "Separate monitors keep separate memory. Use a different name for each scheduled task.",
            "default": "default"
          },
          "maxConcurrency": {
            "title": "⚡ Parallel requests",
            "minimum": 1,
            "maximum": 8,
            "type": "integer",
            "description": "How many requests run at the same time.",
            "default": 4
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}