{
  "openapi": "3.0.1",
  "info": {
    "title": "Amazon Search, Category & Best Sellers Scraper",
    "description": "Scrape Amazon keyword search, category browse, and Best Sellers across 21 storefronts. Export ASINs, titles, prices, ratings, images, and product URLs.",
    "version": "0.3",
    "x-build-id": "7Bodn37EbCYA6cZmP"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/lentic_clockss~amazon-search-results-collector/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-lentic_clockss-amazon-search-results-collector",
        "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/lentic_clockss~amazon-search-results-collector/runs": {
      "post": {
        "operationId": "runs-sync-lentic_clockss-amazon-search-results-collector",
        "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/lentic_clockss~amazon-search-results-collector/run-sync": {
      "post": {
        "operationId": "run-sync-lentic_clockss-amazon-search-results-collector",
        "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": {
          "keywords": {
            "title": "Keywords",
            "minItems": 0,
            "maxItems": 10,
            "type": "array",
            "description": "Amazon search keywords. Required for keyword mode. Optional for category mode (search within a category). Ignored for pure bestsellers browsing when empty.",
            "items": {
              "type": "string"
            },
            "default": [
              "usb hub"
            ]
          },
          "mode": {
            "title": "Collection mode",
            "enum": [
              "keyword",
              "category",
              "bestsellers",
              "newreleases",
              "detail"
            ],
            "type": "string",
            "description": "keyword = Amazon search results; category = category browse or in-category search; bestsellers = Best Sellers ranking pages; newreleases = New Releases ranking pages; detail = fetch each detailUrls entry (product pages and/or seller profiles) with full seller lead extraction.",
            "default": "keyword"
          },
          "detailUrls": {
            "title": "Detail URLs (for detail mode)",
            "minItems": 0,
            "maxItems": 20,
            "type": "array",
            "description": "Product (/dp/{ASIN}) or seller profile (/sp?seller={sellerId}) URLs to fetch when mode=detail. Product pages are enriched with the seller profile (business name + business address).",
            "items": {
              "type": "string"
            },
            "default": []
          },
          "scrapeDetails": {
            "title": "Scrape detail pages for seller leads",
            "type": "boolean",
            "description": "Fetch detail pages (PDP) and follow the seller-profile chain to collect seller organization and address leads. On by default.",
            "default": true
          },
          "enrichDetails": {
            "title": "Enrich items with seller profile leads",
            "type": "boolean",
            "description": "Follow the PDP merchant link to the seller profile (Detailed Seller Information: business name + business address) and merge leads into items. On by default.",
            "default": true
          },
          "enrichMaxItems": {
            "title": "Max items to enrich with seller leads",
            "minimum": 0,
            "maximum": 20,
            "type": "integer",
            "description": "How many list rows (from the top of results) to enrich with seller-profile leads per run (0-20).",
            "default": 1
          },
          "market": {
            "title": "Market",
            "enum": [
              "AE",
              "AU",
              "BE",
              "BR",
              "CA",
              "DE",
              "EG",
              "ES",
              "FR",
              "GB",
              "IE",
              "IN",
              "IT",
              "JP",
              "MX",
              "NL",
              "PL",
              "SA",
              "SE",
              "SG",
              "TR",
              "US",
              "ZA"
            ],
            "type": "string",
            "description": "Amazon storefront to query.",
            "default": "US"
          },
          "category": {
            "title": "Category key",
            "enum": [
              "all",
              "amazon-devices",
              "audible",
              "automotive",
              "baby",
              "beauty",
              "books",
              "computers",
              "electronics",
              "fashion",
              "garden",
              "grocery",
              "handmade",
              "health",
              "home",
              "industrial",
              "kindle-store",
              "kitchen",
              "luggage",
              "movies-tv",
              "music",
              "office-products",
              "pet-supplies",
              "software",
              "sports",
              "tools",
              "toys-and-games",
              "video-games"
            ],
            "type": "string",
            "description": "Stable ecommerce department key (e.g. electronics, books, kitchen). Required for category/bestsellers unless categoryNodeId or categorySlug is set."
          },
          "categoryNodeId": {
            "title": "Category browse node ID",
            "type": "string",
            "description": "Optional Amazon browse node ID. Overrides the mapped node for any subcategory."
          },
          "categorySlug": {
            "title": "Best Sellers category slug",
            "type": "string",
            "description": "Optional Best Sellers path slug (e.g. electronics). Overrides the mapped slug."
          },
          "sort": {
            "title": "Search sort order",
            "enum": [
              "featured",
              "relevance",
              "price-asc",
              "price-desc",
              "newest",
              "avg-review",
              "review-count"
            ],
            "type": "string",
            "description": "Sort order for keyword/category search (s= parameter). Not supported for bestsellers/newreleases/detail.",
            "default": "featured"
          },
          "condition": {
            "title": "Condition filter",
            "enum": [
              "new",
              "used",
              "collectible",
              "refurbished",
              "renewed"
            ],
            "type": "string",
            "description": "Item condition facet for keyword/category search. Not supported for bestsellers/newreleases/detail."
          },
          "minPrice": {
            "title": "Minimum price",
            "minimum": 0,
            "type": "number",
            "description": "Lower price bound for keyword/category search (low-price parameter). Not supported for bestsellers/newreleases/detail."
          },
          "maxPrice": {
            "title": "Maximum price",
            "minimum": 0,
            "type": "number",
            "description": "Upper price bound for keyword/category search (high-price parameter). Not supported for bestsellers/newreleases/detail."
          },
          "pages": {
            "title": "Pages per keyword",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "Maximum number of result pages to request for each task.",
            "default": 1
          },
          "maxItems": {
            "title": "Max results per keyword or detail URL",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "Most product rows for each keyword or detail URL; a category or ranking target is one input. Default 70; larger numbers are collected in parts of 70. All row types count together. The whole run stops at your maximum total charge. Free Apify plan: up to 200 rows per run and 10 runs of this Actor (limits set by the Actor developer).",
            "default": 70
          },
          "maxItemsPerKeyword": {
            "title": "Maximum output items per keyword",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "Optional secondary cap for one keyword task. It defaults to the schema maximum so maxItems controls the per-input row limit.",
            "default": 100
          },
          "workerBaseUrl": {
            "title": "Worker base URL (optional)",
            "type": "string",
            "description": "Override the Cloud Run worker origin for this run. Defaults to Actor env WORKER_BASE_URL. Production migrations should update WORKER_BASE_URL in Actor settings (no code change).",
            "default": ""
          },
          "provider": {
            "title": "Engine provider",
            "enum": [
              "direct",
              "render",
              "httpx",
              "zyte"
            ],
            "type": "string",
            "description": "Worker acquisition engine. `direct` (default) uses the UA-whitelist direct-HTTP channel (curl_cffi + UA pool) — Amazon's primary gate is a UA whitelist, so a correct UA gets live SSR rows with no browser. `render` uses the real-browser render ladder as fallback (UA burn / login-gated surfaces). `httpx` is a probe/diagnostic arm only. `zyte` uses the control-plane HTTP extract.",
            "default": "direct"
          },
          "requestTimeoutSecs": {
            "title": "Request timeout (seconds)",
            "minimum": 5,
            "maximum": 180,
            "type": "integer",
            "description": "HTTP timeout for each Amazon request.",
            "default": 30
          },
          "userAgent": {
            "title": "User-Agent override",
            "type": "string",
            "description": "Optional HTTP User-Agent override for local debugging."
          },
          "debug": {
            "title": "Debug mode",
            "type": "boolean",
            "description": "Enable verbose diagnostic logging and extra debugging artifacts.",
            "default": false
          },
          "includeRawHtml": {
            "title": "Save raw HTML",
            "type": "boolean",
            "description": "Persist raw HTML snapshots to the default key-value store for debugging.",
            "default": false
          },
          "fixtureHtmlPath": {
            "title": "Local fixture HTML path",
            "type": "string",
            "description": "Optional local HTML fixture path for deterministic offline validation and gate runs."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}