{
  "openapi": "3.0.1",
  "info": {
    "title": "Taobao Scraper & Tmall 淘宝 天猫 – Products, Prices ($1.20/1K)",
    "description": "Taobao 淘宝 and Tmall 天猫 products by keyword, category, shop or link: CNY prices, labels, shops, ratings, review samples. No login. JSON, CSV or Excel.",
    "version": "0.1",
    "x-build-id": "LeQ4MwTxIYXtwIryE"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/monkey.d.scraping~taobao-tmall-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-monkey.d.scraping-taobao-tmall-scraper",
        "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/monkey.d.scraping~taobao-tmall-scraper/runs": {
      "post": {
        "operationId": "runs-sync-monkey.d.scraping-taobao-tmall-scraper",
        "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/monkey.d.scraping~taobao-tmall-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-monkey.d.scraping-taobao-tmall-scraper",
        "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",
            "maxItems": 200,
            "type": "array",
            "description": "Short product keywords, one per line, e.g. 蓝牙耳机 or 手机壳. Chinese keywords usually return more matches. You can also paste complete Taobao app share text containing its link and product title here. Numeric IDs are treated as product IDs.",
            "items": {
              "type": "string",
              "maxLength": 512
            }
          },
          "maxItems": {
            "title": "Max products",
            "minimum": 0,
            "maximum": 20000,
            "type": "integer",
            "description": "Stop after this many products in total across all searches, links and IDs. 0 = no limit (up to 20,000).",
            "default": 100
          },
          "startUrls": {
            "title": "Taobao links",
            "type": "array",
            "description": "Use catalogUrl from a previous result, a Taobao search/category/shop link, or an app short link (e.tb.cn, m.tb.cn). For item.taobao.com/item.htm?id=… and detail.tmall.com links, add Product lookup keywords below. Only the exact requested product ID is saved.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "itemLookupTerms": {
            "title": "Product lookup keywords",
            "maxItems": 3,
            "type": "array",
            "description": "For numeric product links only: up to 3 short Chinese keywords or a distinctive product title. These help find the exact requested IDs; other products are not exported. For a general search, use Search terms instead. A title in complete app share text is used automatically.",
            "items": {
              "type": "string",
              "minLength": 1,
              "maxLength": 160
            }
          },
          "shopIds": {
            "title": "Shop IDs",
            "maxItems": 200,
            "type": "array",
            "description": "Taobao / Tmall shop IDs, e.g. 124688715: all products of the shop (up to 60 per shop).",
            "items": {
              "type": "string"
            }
          },
          "categoryIds": {
            "title": "Category IDs",
            "maxItems": 200,
            "type": "array",
            "description": "Taobao category IDs, e.g. 150704 (phone cases). You find them in category links: taobao.com/list/category/150704.htm.",
            "items": {
              "type": "string"
            }
          },
          "sortBy": {
            "title": "Sort by",
            "enum": [
              "best-sellers",
              "price-asc",
              "price-desc",
              "shop-rating"
            ],
            "type": "string",
            "description": "Preferred order for search results. Category and shop inputs use their displayed order.",
            "default": "best-sellers"
          },
          "minPrice": {
            "title": "Min price (CNY)",
            "minimum": 0,
            "type": "integer",
            "description": "Only products at or above this price in yuan."
          },
          "maxPrice": {
            "title": "Max price (CNY)",
            "minimum": 0,
            "type": "integer",
            "description": "Only products at or below this price in yuan."
          },
          "tmallOnly": {
            "title": "Tmall shops only",
            "type": "boolean",
            "description": "Keep only products from Tmall shops (flagship, specialty and official stores). Exact with item details, otherwise from the shop name.",
            "default": false
          },
          "deepScan": {
            "title": "Deep scan",
            "type": "boolean",
            "description": "Collect more distinct products per search using Deep scan. Off = a quick list of best sellers.",
            "default": true
          },
          "includeDetails": {
            "title": "Include item details",
            "type": "boolean",
            "description": "Open each product's page for ships-from location, category path, original price, rating split, review count, latest review, seller type, shop age and shop scores. Charged per product with details.",
            "default": false
          },
          "includeAgentLinks": {
            "title": "Add shopping-agent links",
            "type": "boolean",
            "description": "Add links that open each product in CNFans, Mulebuy, Hoobuy, OOPBuy, ACBuy, CSSBuy, Superbuy, AllChinaBuy, Kakobuy, Sugargoo and Joyagoo.",
            "default": false
          },
          "expandKeywords": {
            "title": "Expand keywords with Taobao suggestions",
            "type": "boolean",
            "description": "Also search the first five keywords Taobao's search box suggests for each of your search terms (their first page each), and list all suggestions in the run summary.",
            "default": false
          },
          "onlyNewOrChanged": {
            "title": "Only new or changed products",
            "type": "boolean",
            "description": "Remember the products this input returned and output only new ones or those whose price changed since the previous run with the same input. Save the input as a task and add a schedule for daily price monitoring.",
            "default": false
          },
          "monitoringKey": {
            "title": "Monitoring key",
            "type": "string",
            "description": "Optional label that keeps several schedules on the same search separate (e.g. daily and weekly)."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}