{
  "openapi": "3.0.1",
  "info": {
    "title": "Alibaba Scraper",
    "description": "Scrape Alibaba.com B2B products by keyword or link: price range, quantity price breaks, minimum order, sales, photos, specs, variants and lead times, plus supplier name, country, years, ratings, response time and verification.",
    "version": "0.1",
    "x-build-id": "gftEm0YDs4NBDrCdt"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/automly~alibaba-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-automly-alibaba-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/automly~alibaba-scraper/runs": {
      "post": {
        "operationId": "runs-sync-automly-alibaba-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/automly~alibaba-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-automly-alibaba-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": {
          "keywords": {
            "title": "Search keywords",
            "type": "array",
            "description": "What to search Alibaba.com for, one keyword per line, e.g. phone case, led strip, cnc machine. Each keyword is searched separately and Max results applies to each one.",
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "Product or search links",
            "type": "array",
            "description": "Alibaba.com product links or product IDs, e.g. https://www.alibaba.com/product-detail/Clear-TPU-Phone-Case_1601993972548.html or 1601993972548. Search links (https://www.alibaba.com/trade/search?SearchText=...) work too, with the filters set on the site.",
            "items": {
              "type": "string"
            }
          },
          "maxResults": {
            "title": "Max results per keyword",
            "minimum": 0,
            "maximum": 1000000,
            "type": "integer",
            "description": "Most products to save for each keyword or search link, e.g. 100. Set 0 for every product Alibaba.com lists for it (usually about 3,000). Product links are always saved. A product found by several keywords is saved once.",
            "default": 100
          },
          "includeDetails": {
            "title": "Include full product details",
            "type": "boolean",
            "description": "Open each product's page and add quantity price breaks (with US dollar prices), variants, specifications, all photos, category, lead times by quantity, customization options, certificates, and the supplier's business type, staff, verification, response time, on-time delivery, store rating, orders in the last 6 months and capabilities. Product links always come with details.",
            "default": false
          },
          "currency": {
            "title": "Currency",
            "enum": [
              "USD",
              "EUR",
              "GBP",
              "CAD",
              "AUD",
              "JPY",
              "INR",
              "BRL",
              "MXN",
              "AED",
              "SAR",
              "TRY",
              "KRW",
              "RUB"
            ],
            "type": "string",
            "description": "Currency of the prices, e.g. USD. Price breaks also carry the US dollar price.",
            "default": "USD"
          },
          "minPrice": {
            "title": "Min price",
            "minimum": 0,
            "type": "number",
            "description": "Only products from this unit price, in the chosen currency, e.g. 1.5. Leave empty for no minimum."
          },
          "maxPrice": {
            "title": "Max price",
            "minimum": 0,
            "type": "number",
            "description": "Only products up to this unit price, in the chosen currency, e.g. 20. Leave empty for no maximum."
          },
          "maxMOQ": {
            "title": "Max minimum order",
            "minimum": 0,
            "type": "integer",
            "description": "Only products whose minimum order quantity is at most this, e.g. 10. Leave empty for any."
          },
          "supplierCountries": {
            "title": "Supplier countries",
            "type": "array",
            "description": "Only suppliers from these countries, as two-letter codes, e.g. CN, IN, VN, US. Leave empty for all.",
            "items": {
              "type": "string"
            }
          },
          "minReviewScore": {
            "title": "Min store rating",
            "enum": [
              "any",
              "4",
              "4.5",
              "5"
            ],
            "type": "string",
            "description": "Only suppliers with at least this store rating, e.g. 4.5 and up.",
            "default": "any"
          },
          "tradeAssurance": {
            "title": "Trade Assurance only",
            "type": "boolean",
            "description": "Only products covered by Alibaba.com Trade Assurance order protection.",
            "default": false
          },
          "verifiedSupplier": {
            "title": "Verified Supplier only",
            "type": "boolean",
            "description": "Only products from Verified Suppliers: suppliers whose credentials and capabilities were inspected and verified by third-party companies. This is Alibaba.com's own Verified Supplier filter.",
            "default": false
          },
          "verifiedProSupplier": {
            "title": "Verified Pro Supplier only",
            "type": "boolean",
            "description": "Only products from Verified Pro Suppliers: industry-leading Verified Suppliers with 5+ years of experience. This is Alibaba.com's own Verified Pro Supplier filter.",
            "default": false
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Leave the default.",
            "default": {
              "useApifyProxy": true
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}