{
  "openapi": "3.0.1",
  "info": {
    "title": "AliExpress Price Tracker & Scraper - Price History",
    "description": "AliExpress price tracker and scraper: search results for any keyword, or the products you watch, priced for your country and currency, with variants, shipping, reviews, units sold and store. Scheduled runs report price drops, price history and new best-sellers.",
    "version": "0.1",
    "x-build-id": "elFwUQ5odn7g59kpD"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/akhil_rajesh~aliexpress-price-tracker/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-akhil_rajesh-aliexpress-price-tracker",
        "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/akhil_rajesh~aliexpress-price-tracker/runs": {
      "post": {
        "operationId": "runs-sync-akhil_rajesh-aliexpress-price-tracker",
        "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/akhil_rajesh~aliexpress-price-tracker/run-sync": {
      "post": {
        "operationId": "run-sync-akhil_rajesh-aliexpress-price-tracker",
        "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": {
          "searchQueries": {
            "title": "Search keywords",
            "maxItems": 50,
            "type": "array",
            "description": "Keywords to search AliExpress for, one per line, such as smart watch (up to 50). You can also paste AliExpress search links (https://www.aliexpress.com/w/wholesale-phone-case.html?sortType=price_asc): each keeps its own sort, price range and AliExpress filters; the form's apply to typed keywords only (Minimum units sold, Minimum rating and the Include options apply to both). Max results is shared between the keywords. Leave it empty to watch products only (Watch products).",
            "items": {
              "type": "string"
            }
          },
          "country": {
            "title": "Ship to",
            "enum": [
              "AU",
              "CA",
              "FR",
              "DE",
              "GB",
              "US",
              "AT",
              "BE",
              "BR",
              "CL",
              "CZ",
              "DK",
              "FI",
              "HU",
              "IE",
              "IL",
              "IT",
              "JP",
              "MX",
              "NL",
              "NZ",
              "NO",
              "PL",
              "PT",
              "RO",
              "SA",
              "KR",
              "ES",
              "SE",
              "CH",
              "TR",
              "AE"
            ],
            "type": "string",
            "description": "The country AliExpress prices and ships the search for. AliExpress shows each country its own prices, offers and delivery estimates; a US visitor gets AliExpress's US site, with its own product ids.",
            "default": "US"
          },
          "currency": {
            "title": "Currency",
            "enum": [
              "auto",
              "USD",
              "EUR",
              "GBP",
              "CAD",
              "AUD",
              "NZD",
              "CHF",
              "PLN",
              "CZK",
              "SEK",
              "NOK",
              "DKK",
              "HUF",
              "RON",
              "BRL",
              "MXN",
              "CLP",
              "JPY",
              "KRW",
              "ILS",
              "SAR",
              "AED",
              "TRY"
            ],
            "type": "string",
            "description": "Currency of the prices. By default, the ship-to country's own (US dollars for the United States, euros for Germany). The run says so if AliExpress shows prices in another one.",
            "default": "auto"
          },
          "sortBy": {
            "title": "Sort by",
            "enum": [
              "best-match",
              "orders",
              "price-low-to-high",
              "price-high-to-low"
            ],
            "type": "string",
            "description": "AliExpress's order of the results. Orders (best-selling first) puts the products people buy most first; best match differs most between visitors (two fresh visitors shared as few as 3 of the first 40 products), so new products are only reported in sorted searches. Pasted search links keep their own.",
            "default": "orders"
          },
          "minPrice": {
            "title": "Minimum price (optional)",
            "minimum": 0,
            "type": "number",
            "description": "Only products from this price, in the currency of the search (AliExpress's own price filter)."
          },
          "maxPrice": {
            "title": "Maximum price (optional)",
            "minimum": 0,
            "type": "number",
            "description": "Only products up to this price, in the currency of the search."
          },
          "freeShipping": {
            "title": "Free shipping only",
            "type": "boolean",
            "description": "AliExpress's Free shipping filter.",
            "default": false
          },
          "choiceOnly": {
            "title": "Choice only",
            "type": "boolean",
            "description": "AliExpress's Choice filter: products with AliExpress's own fulfilment and delivery promise.",
            "default": false
          },
          "fourStarsAndUp": {
            "title": "4 stars and up only",
            "type": "boolean",
            "description": "AliExpress's 4-stars-and-up filter.",
            "default": false
          },
          "shipFrom": {
            "title": "Ships from (optional)",
            "enum": [
              "",
              "CN",
              "US",
              "DE",
              "FR",
              "ES",
              "IT",
              "PL",
              "GB",
              "AU",
              "BR",
              "KR",
              "SA",
              "AE",
              "TR",
              "AT",
              "BE",
              "CA",
              "CH",
              "CL",
              "CZ",
              "DK",
              "FI",
              "HU",
              "IE",
              "IL",
              "JP",
              "MX",
              "NL",
              "NO",
              "NZ",
              "PT",
              "RO",
              "SE"
            ],
            "type": "string",
            "description": "AliExpress's own Ships from filter: only products sent from this country's warehouses (faster delivery, often no import duties). Empty: from anywhere.",
            "default": ""
          },
          "minOrders": {
            "title": "Minimum units sold (optional)",
            "minimum": 0,
            "maximum": 1000000000,
            "type": "integer",
            "description": "Only products sold at least this many times (\"1,000+ sold\" counts as 1,000); products whose card shows no units sold are left out. The run reads on until it has Max results such products or the search ends, and stops a search after 5 pages in a row where none passed."
          },
          "minRating": {
            "title": "Minimum rating (optional)",
            "minimum": 0,
            "maximum": 5,
            "type": "number",
            "description": "Only products rated at least this many stars (0 to 5). Products without a rating are left out. Like Minimum units sold, it reads on to fill Max results."
          },
          "listedWithinDays": {
            "title": "Listed within, in days (optional)",
            "minimum": 0,
            "maximum": 3650,
            "type": "integer",
            "description": "Only products AliExpress listed within this many days: new products for product research. Applied after reading, like Minimum units sold."
          },
          "includeSponsored": {
            "title": "Include sponsored results",
            "type": "boolean",
            "description": "Sponsored results (AliExpress's \"Ad\" cards) are marked in each row. Turn off to leave them out. Their positions still count, as on AliExpress.",
            "default": true
          },
          "includeRelated": {
            "title": "Include related products",
            "type": "boolean",
            "description": "When a narrow keyword's matches run out, AliExpress fills its pages with related products (\"brass fountain pen converter 0.38 mm left handed\" got 4 matches and 56 other pen products on its first US page). They are left out by default, and the run says how many. Turn on to get them too, each marked Related product.",
            "default": false
          },
          "reviewSummary": {
            "title": "Add review summary",
            "type": "boolean",
            "description": "Add each product's reviews: how many, the average rating, the share of each star rating and of positive reviews, how many have photos, the newest review's date, reviews in the last 30 days, AliExpress's review tags, and how many reviews it got since the last run. One more request per product (about half a second each), at no extra charge.",
            "default": false
          },
          "latestReviews": {
            "title": "Newest reviews per product",
            "minimum": 0,
            "maximum": 20,
            "type": "integer",
            "description": "Also add each product's newest reviews (up to 20): date, stars, the buyer's country, the text in English (with the original when AliExpress translated it), the variant bought and photos. Turns on the review summary.",
            "default": 0
          },
          "productIds": {
            "title": "Products to watch",
            "maxItems": 1000,
            "type": "array",
            "description": "AliExpress products to watch, one per line (up to 1,000): product links (https://www.aliexpress.com/item/1005007954929165.html, a country's own site, aliexpress.us, or a short a.aliexpress.com link) or product ids. Each run returns each product's price, variants with their prices, shipping fee and delivery days to the ship-to country, units sold, reviews and store, and what changed since the last run. Read through AliExpress's official affiliate API with your own App Key (below).",
            "items": {
              "type": "string"
            }
          },
          "aliexpressAppKey": {
            "title": "AliExpress App Key",
            "type": "string",
            "description": "The App Key of your app on AliExpress's Open Platform (App Console → your app → Overview). AliExpress gives affiliates an app for free: the README's Watch products section shows how. Stored encrypted; used only to sign this run's calls."
          },
          "aliexpressAppSecret": {
            "title": "AliExpress App Secret",
            "type": "string",
            "description": "The App Secret shown next to the App Key (View). Stored encrypted, never logged."
          },
          "aliexpressTrackingId": {
            "title": "Tracking ID (optional)",
            "type": "string",
            "description": "One of your AliExpress Portals tracking IDs, for the promotion links in the rows. Needed when your account has several; with one, leave it empty."
          },
          "includeVariants": {
            "title": "Include variants",
            "type": "boolean",
            "description": "Read each product's variants (colours, sizes...) with their prices including tax, and track the cheapest. One more call per product.",
            "default": true
          },
          "includeDelivery": {
            "title": "Include shipping and delivery",
            "type": "boolean",
            "description": "Add each variant's shipping fee, delivery days and ship-from country for the ship-to country (AliExpress answers more slowly with it).",
            "default": false
          },
          "maxResults": {
            "title": "Max results",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "The most rows a run outputs, shared between the keywords. With Only changes, it is how many products are watched (the first N of each search's share), and the run outputs the changes among them. A results page holds 60 products; page 1 is AliExpress's steadiest selection, while later pages are another selection on every visit, so their products' prices are tracked but not their positions. Each keyword needs at least 1 to be read. A run asks at most four times the pages Max results needs, plus two per keyword (at least 10, at most 400, refused pages included).",
            "default": 60
          },
          "trackChanges": {
            "title": "Compare with the previous run",
            "type": "boolean",
            "description": "Compare each search with the previous runs of the same search (keyword, ship-to country and filters): store price changes, units sold since, the price history, and new products on the first page of a sorted search. The history is kept in a key-value store of your account (History name).",
            "default": true
          },
          "priceHistoryRuns": {
            "title": "Price history: runs to keep",
            "minimum": 0,
            "maximum": 365,
            "type": "integer",
            "description": "How many runs' prices each product keeps for its lowest, highest and average price. 0 leaves the price history out of this run's rows; the prices stored for the search's other schedules stay.",
            "default": 30
          },
          "onlyChanges": {
            "title": "Only changes",
            "type": "boolean",
            "description": "Output only what changed since the previous run: store price changes past the limit below, and new products on the first page of a sorted search. A first run outputs everything, as the baseline, and so do products below the places earlier runs read. Max results is then how many products are watched. Sponsored results are left out.",
            "default": false
          },
          "onlyPriceDrops": {
            "title": "Only price drops",
            "type": "boolean",
            "description": "With Only changes: output store price drops and new products, not rises (a rise moves the baseline quietly, so the next drop counts from it). For price drop alerts.",
            "default": false
          },
          "minPriceChangePercent": {
            "title": "Smallest price change, in %",
            "minimum": 0,
            "type": "number",
            "description": "A smaller store price change isn't counted as a change (with Only changes, isn't output, and adds up until it is).",
            "default": 1
          },
          "historyName": {
            "title": "History name (optional)",
            "type": "string",
            "description": "The key-value store that keeps the runs' history (default aliexpress-tracker-history): one record per search, of up to about 1.5 MB, keeping each product 30 days after a run last met it. Use another name to keep a schedule's history apart."
          },
          "proxy": {
            "title": "Proxy",
            "type": "object",
            "description": "Not needed: the Actor reads AliExpress without a proxy. Apify's datacenter proxy or your own proxies can be set here; residential and other per-GB proxies aren't available in this Actor."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}