{
  "openapi": "3.0.1",
  "info": {
    "title": "Amazon Best Sellers Scraper & Rank Tracker",
    "description": "Amazon Best Sellers, New Releases and Movers & Shakers with all 100 ranks in 22 marketplaces, plus what changed since your last run: rank moves, new entries, drop-outs and computed movers, with a summary per chart. Bestseller rank tracking from $1.50 per 1,000 products.",
    "version": "0.1",
    "x-build-id": "bZyihPd6lqbehgkgC"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/cleanpull~amazon-bestsellers-tracker/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-cleanpull-amazon-bestsellers-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/cleanpull~amazon-bestsellers-tracker/runs": {
      "post": {
        "operationId": "runs-sync-cleanpull-amazon-bestsellers-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/cleanpull~amazon-bestsellers-tracker/run-sync": {
      "post": {
        "operationId": "run-sync-cleanpull-amazon-bestsellers-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": {
          "categories": {
            "title": "Categories",
            "type": "array",
            "description": "Departments or categories, one per line: a department slug from the chart URL (\"kitchen\", \"toys-and-games\"), a department name (\"Toys & Games\"), or department/node for a subcategory (\"kitchen/289728\"). Read in every marketplace below.",
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "Chart URLs",
            "type": "array",
            "description": "Optional. Any Amazon chart page: Best Sellers, New Releases, Movers & Shakers, Most Wished For or Gift Ideas, in any category and marketplace (amazon.com/gp/bestsellers/kitchen/289728, amazon.co.uk/Best-Sellers-…/zgbs/…).",
            "items": {
              "type": "string"
            }
          },
          "marketplaces": {
            "title": "Marketplaces",
            "type": "array",
            "description": "Country codes or domains: US, GB (or UK), DE, FR, IT, ES, CA, MX, BR, JP, IN, AU, NL, SE, PL, BE, TR, AE, SA, SG, EG, IE. Default US.",
            "items": {
              "type": "string"
            }
          },
          "charts": {
            "title": "Charts",
            "type": "array",
            "description": "Which charts to read for each category. Amazon currently shows Movers & Shakers, Most Wished For and Gift Ideas empty in most categories; empty charts are reported and never billed.",
            "items": {
              "type": "string",
              "enum": [
                "best-sellers",
                "new-releases",
                "movers-and-shakers",
                "most-wished-for",
                "gift-ideas"
              ],
              "enumTitles": [
                "Best Sellers",
                "New Releases",
                "Movers & Shakers",
                "Most Wished For",
                "Gift Ideas"
              ]
            },
            "default": [
              "best-sellers"
            ]
          },
          "allCategories": {
            "title": "All departments",
            "type": "boolean",
            "description": "Read every department of each marketplace (about 40 on amazon.com). Combine with Subcategory depth to go deeper.",
            "default": false
          },
          "subcategoryDepth": {
            "title": "Subcategory depth",
            "minimum": 0,
            "maximum": 5,
            "type": "integer",
            "description": "How many levels of subcategories to read below each category: 0 reads only the category, 1 adds its subcategories, and so on. Limited by Max categories.",
            "default": 0
          },
          "maxCategories": {
            "title": "Max categories",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Stop after this many categories (each category reads every chart selected). The run summary says how many were found.",
            "default": 50
          },
          "maxItemsPerChart": {
            "title": "Products per chart",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "Ranks to read per chart (Amazon shows 100 on two pages). Every rank is included, also the ones Amazon loads only as you scroll.",
            "default": 100
          },
          "maxItems": {
            "title": "Max rows",
            "minimum": 1,
            "type": "integer",
            "description": "Optional. Stop after this many product rows in the run."
          },
          "domain": {
            "title": "Domain (alias)",
            "type": "string",
            "description": "Optional. One marketplace domain, as other actors take it (amazon.de)."
          },
          "categoryUrls": {
            "title": "Category URLs (alias)",
            "type": "array",
            "description": "Optional. Same as Chart URLs; accepted so inputs from other actors work unchanged.",
            "items": {
              "type": "string"
            }
          },
          "monitorName": {
            "title": "Tracking name",
            "type": "string",
            "description": "Each run remembers every chart under this name, and the next run reports movement against it: previous rank, places climbed, new entries, re-entries, products that dropped out, days on chart and price change. Use different names for different schedules.",
            "default": "default"
          },
          "changesOnly": {
            "title": "Changes only",
            "type": "boolean",
            "description": "Return only products that moved (and products that dropped out), plus a summary per chart. Unchanged products cost $0.10 per 1,000. The first run returns every product as a baseline. Schedule it daily or hourly.",
            "default": false
          },
          "changeTypes": {
            "title": "Changes to report",
            "type": "array",
            "description": "Which movements count as a change.",
            "items": {
              "type": "string",
              "enum": [
                "new",
                "re-entry",
                "up",
                "down",
                "dropped"
              ],
              "enumTitles": [
                "New entry",
                "Re-entry",
                "Climbed",
                "Fell",
                "Dropped out"
              ]
            },
            "default": [
              "new",
              "re-entry",
              "up",
              "down",
              "dropped"
            ]
          },
          "minRankChange": {
            "title": "Minimum rank move",
            "minimum": 1,
            "maximum": 99,
            "type": "integer",
            "description": "Moves of fewer places count as unchanged.",
            "default": 3
          },
          "moverCount": {
            "title": "Movers per chart",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "How many of the biggest climbers in each chart are flagged as movers (computedMover), our Movers & Shakers from your own runs.",
            "default": 10
          },
          "includeSummary": {
            "title": "Summary per chart",
            "type": "boolean",
            "description": "One summary row per chart: new entries, drop-outs, climbers, volatility, median price and its change, brands entering and leaving (with product details), and coverage.",
            "default": true
          },
          "historyDatasetName": {
            "title": "History dataset",
            "type": "string",
            "description": "Optional. A named dataset that every run appends its ranks to (date, chart, category, rank, ASIN, price), for rank history charts without a database of your own. Free."
          },
          "includeProductDetails": {
            "title": "Product details",
            "type": "boolean",
            "description": "Open the product page of the top products in each chart: Best Sellers Rank at every category level, brand, seller and who ships it, stock, parent product, date first available, and \"bought in past month\" when Amazon shows it. Billed per product.",
            "default": false
          },
          "productDetailsTopN": {
            "title": "Details for the top",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "Read product details for this many products from the top of each chart.",
            "default": 20
          },
          "fields": {
            "title": "Only these fields",
            "type": "array",
            "description": "Optional. Keep only these fields, for example [\"rank\", \"asin\", \"title\", \"price\", \"rankChange\"]. Dotted paths reach into lists.",
            "items": {
              "type": "string"
            }
          },
          "maxConcurrency": {
            "title": "Categories at a time",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "Categories read in parallel. Amazon answers bursts with CAPTCHAs, so keep this low.",
            "default": 2
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Optional. The actor picks proxies itself (direct, then datacenter, then residential only when Amazon blocks the others)."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}