{
  "openapi": "3.0.1",
  "info": {
    "title": "Temu Product Scraper & Price Monitor",
    "description": "Search public Temu products with region-bound coverage, extract exact products and SKUs, create commerce-ready rows, or monitor factual changes.",
    "version": "0.4",
    "x-build-id": "Gx7KcnWtZKYepJfvd"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/luminar~temu-product-scraper-price-monitor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-luminar-temu-product-scraper-price-monitor",
        "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/luminar~temu-product-scraper-price-monitor/runs": {
      "post": {
        "operationId": "runs-sync-luminar-temu-product-scraper-price-monitor",
        "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/luminar~temu-product-scraper-price-monitor/run-sync": {
      "post": {
        "operationId": "run-sync-luminar-temu-product-scraper-price-monitor",
        "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": {
          "workflow": {
            "title": "What do you want to do?",
            "enum": [
              "search_products",
              "scrape_exact_products",
              "track_product_changes"
            ],
            "type": "string",
            "description": "Monitoring creates a quiet baseline, then emits factual NEW, UPDATED, or confirmed ENDED rows after two comparable absences.",
            "default": "search_products"
          },
          "searchKeywords": {
            "title": "Search keywords",
            "maxItems": 10,
            "uniqueItems": true,
            "type": "array",
            "description": "Up to 10 phrases processed sequentially for the selected market. Keyword-fidelity checks reject unrelated products.",
            "items": {
              "type": "string",
              "minLength": 1,
              "maxLength": 120
            },
            "default": [
              "wireless earbuds"
            ]
          },
          "region": {
            "title": "Temu region preset",
            "enum": [
              "us",
              "uk",
              "de",
              "fr",
              "es",
              "it",
              "nl",
              "au",
              "ca",
              "br",
              "mx",
              "jp",
              "kr",
              "pl",
              "se",
              "at",
              "be",
              "pt",
              "cz",
              "ie"
            ],
            "type": "string",
            "description": "Selects the Temu market and expected currency. Currency is reported only when the public source confirms it.",
            "default": "us"
          },
          "sortBy": {
            "title": "Result order",
            "enum": [
              "relevance",
              "top_sales",
              "newest",
              "price_asc",
              "price_desc"
            ],
            "type": "string",
            "description": "Relevance preserves source order. Price and sales orders are mechanical. Newest fails closed if the source does not publish listing time.",
            "default": "relevance"
          },
          "maxProductsPerKeyword": {
            "title": "Maximum products per keyword",
            "minimum": 1,
            "maximum": 300,
            "type": "integer",
            "description": "Hard ceiling per keyword. Coverage becomes CAPPED if more source rows remain.",
            "default": 20
          },
          "minPrice": {
            "title": "Minimum price",
            "minimum": 0,
            "maximum": 1000000,
            "type": "number",
            "description": "Keep rows at or above this source-published price."
          },
          "maxPrice": {
            "title": "Maximum price",
            "minimum": 0,
            "maximum": 1000000,
            "type": "number",
            "description": "Keep rows at or below this source-published price."
          },
          "productUrls": {
            "title": "Exact Temu product or share URLs",
            "maxItems": 100,
            "type": "array",
            "description": "Public first-party product URLs and Temu share links. Redirect-only links are resolved without login; non-Temu hosts are rejected.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "title": "Product URL",
                  "type": "string",
                  "pattern": "^https://(?:[A-Za-z0-9-]+\\.)*temu\\.com/",
                  "maxLength": 1200,
                  "description": "A public first-party Temu product URL or Temu share link."
                }
              }
            }
          },
          "productIds": {
            "title": "Bare Temu goods IDs",
            "maxItems": 100,
            "uniqueItems": true,
            "type": "array",
            "description": "Stable numeric product IDs for exact extraction or monitoring.",
            "items": {
              "type": "string",
              "pattern": "^[0-9]{5,}$",
              "maxLength": 32
            }
          },
          "includeVariants": {
            "title": "Include variants and SKUs",
            "type": "boolean",
            "description": "Adds source-published SKU IDs, labels, prices, availability, stock, and media when present.",
            "default": true
          },
          "outputFormat": {
            "title": "Output row shape",
            "enum": [
              "default",
              "shopify",
              "google_merchant"
            ],
            "type": "string",
            "description": "Selects one mechanical row shape per product. Apify Dataset exports remain available as JSON, CSV, Excel, XML, and RSS.",
            "default": "default"
          },
          "retailMarkup": {
            "title": "User-supplied price multiplier",
            "minimum": 1,
            "maximum": 10,
            "type": "number",
            "description": "Applied only to commerce prices and labeled in every derived row. The Actor does not recommend a margin or claim profitability.",
            "default": 1
          },
          "includeSummary": {
            "title": "Add mechanical summary",
            "type": "boolean",
            "description": "Adds a free summary row with counts, price statistics, field coverage, and source-sold-count ordering when available.",
            "default": true
          },
          "stateNamespace": {
            "title": "Monitoring scope name",
            "pattern": "^[A-Za-z0-9._~-]{1,64}$",
            "maxLength": 64,
            "type": "string",
            "description": "Separates monitoring baselines. Run the same namespace and exact scope sequentially.",
            "default": "default"
          },
          "includeUnchanged": {
            "title": "Also output unchanged snapshots",
            "type": "boolean",
            "description": "Monitoring only. Adds unchanged current snapshots as free rows.",
            "default": false
          },
          "maxBuyerChargeUsd": {
            "title": "Maximum projected Actor charge",
            "minimum": 0.01,
            "maximum": 1000,
            "type": "number",
            "description": "Work stops before the maximum event vector can exceed this amount.",
            "default": 10
          },
          "maxRequests": {
            "title": "Request guard",
            "minimum": 1,
            "maximum": 12000,
            "type": "integer",
            "description": "Safety ceiling for public source requests in one run.",
            "default": 12000
          },
          "maxSourceBytes": {
            "title": "Transfer guard",
            "minimum": 10000,
            "maximum": 1500000000,
            "type": "integer",
            "description": "Safety ceiling for total public source bytes in one run.",
            "default": 1500000000
          },
          "maxRuntimeSecs": {
            "title": "Runtime guard",
            "minimum": 30,
            "maximum": 7200,
            "type": "integer",
            "description": "Safety ceiling for source work in one run.",
            "default": 7200
          },
          "maxEstimatedPlatformUsd": {
            "title": "Platform-cost guard",
            "minimum": 0.01,
            "maximum": 3,
            "type": "number",
            "description": "Safety ceiling checked before starting source work.",
            "default": 1
          }
        }
      },
      "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}