{
  "openapi": "3.0.1",
  "info": {
    "title": "Douyin Scraper",
    "description": "Scrape Douyin (抖音, Chinese TikTok) without an account: videos from keyword search and creator profiles with likes, comments, shares, saves, hashtags, music, cover and video file, plus video comments with likes, replies and region. Chinese or English keywords. JSON, CSV, Excel.",
    "version": "0.1",
    "x-build-id": "GvdSIOtHuikGcYOs4"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/blueskyscraper~douyin-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-blueskyscraper-douyin-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/blueskyscraper~douyin-scraper/runs": {
      "post": {
        "operationId": "runs-sync-blueskyscraper-douyin-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/blueskyscraper~douyin-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-blueskyscraper-douyin-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": "Chinese works best: <code>咖啡</code>, <code>护肤</code>, <code>巴厘岛</code>. Each keyword returns videos whose title matches, each with full stats.",
            "items": {
              "type": "string"
            }
          },
          "profileUrls": {
            "title": "👤 Creator profiles",
            "type": "array",
            "description": "Profile link: <code>https://www.douyin.com/user/MS4wLjABAAAA…</code> (or the MS4w… sec_uid). Returns the creator's videos, newest first.",
            "items": {
              "type": "string"
            }
          },
          "videoUrls": {
            "title": "💬 Video links (comments)",
            "type": "array",
            "description": "Video link or ID: <code>https://www.douyin.com/video/7695040675984805171</code>. Returns the video's comments.",
            "items": {
              "type": "string"
            }
          },
          "publishedAfter": {
            "title": "📅 Search: published after",
            "type": "string",
            "description": "Search: keep only videos published on or after this date (<code>YYYY-MM-DD</code>)."
          },
          "hotLists": {
            "title": "🔥 Hot lists and billboards (no keyword needed)",
            "type": "array",
            "description": "Douyin's own rankings, read as they stand at run time: <b>hot_search</b> — real-time hot search board (~50); <b>seeding</b> — 种草榜 product-seeding board (~50); <b>hot_topics</b> — topic (话题) billboard; <b>rising_topics</b> — topics with the fastest-rising heat; <b>hot_videos</b> — video billboard with real play counts; <b>rising_events</b> — rising hot events (上升热点). Each row is a ranking row with <code>rank</code>, <code>heat</code> (Douyin's own heat index — not views, not people), the heat curve where Douyin gives one (daily for topics, hourly for events) and <code>snapshotAt</code>. Up to <b>Results per input</b> rows per list (billboards go to 1,000). Billed per row like a video.",
            "items": {
              "type": "string",
              "enum": [
                "hot_search",
                "seeding",
                "hot_topics",
                "rising_topics",
                "hot_videos",
                "rising_events"
              ],
              "enumTitles": [
                "Hot search board (实时热搜)",
                "Product-seeding board (种草榜)",
                "Topic billboard (话题榜)",
                "Rising topics (飙升话题)",
                "Video billboard (视频榜)",
                "Rising hot events (上升热点)"
              ]
            }
          },
          "hotListWindowHours": {
            "title": "🗓️ Billboard window",
            "enum": [
              "1",
              "24",
              "72",
              "168"
            ],
            "type": "string",
            "description": "Ranking window of the topic, rising-topic and video billboards (the hot search, seeding and rising-event boards are real-time).",
            "default": "24"
          },
          "refreshVideos": {
            "title": "🔁 Re-measure videos (by link or ID)",
            "type": "array",
            "description": "Links or IDs of videos you already track: <code>https://www.douyin.com/video/7695040675984805171</code>. Returns each video again with today's likes, comments, shares and saves — and <b>views</b> (Douyin hides them everywhere else; read in batches of up to 50 for a panel of any size).",
            "items": {
              "type": "string"
            }
          },
          "maxResultsPerInput": {
            "title": "💯 Results per input",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "Cap for each keyword, creator or video: videos per search or creator; comments per video.",
            "default": 50
          },
          "maxItems": {
            "title": "Maximum rows per run",
            "minimum": 1,
            "maximum": 1000000,
            "type": "integer",
            "description": "Stop after this many rows in the whole run — a hard ceiling on cost.",
            "default": 10000
          },
          "monitoringStoreName": {
            "title": "🔔 Monitoring mode — store name",
            "type": "string",
            "description": "Give the run a name (e.g. <code>brand-mentions</code>) and every later run with the same name returns <b>only rows it has not delivered before</b>. Empty = normal run."
          },
          "dataContract": {
            "title": "🧾 Data contract (provenance + null reasons)",
            "type": "boolean",
            "description": "Adds to every row a <code>provenance</code> block (platform, upstream API, endpoint, mode, source ID, canonical URL, observedAt / collectedAt, schema version, checksum of ID + counters, <code>rawChecksum</code> of the source record) and a <code>metrics</code> block where every counter is a value or <code>null</code> with the reason — never a fake zero. On by default; switch off for plain rows.",
            "default": true
          },
          "authorPrivacy": {
            "title": "🕶️ Author data",
            "enum": [
              "full",
              "pseudonymous"
            ],
            "type": "string",
            "description": "Default: Pseudonymous. Choose Full to get author names, IDs and profile links. Pseudonymous replaces author names, IDs, links and avatars with <code>authorKey</code> — a salted, stable hash (one key per author on the platform's stable id, the same in every mode; deleted authors get none) that still lets you measure how concentrated a topic is, without storing profiles. Profile inputs are replaced by the same key in <code>sourceInput</code>; sound titles named after a creator and Reddit <code>u_…</code> profile links are masked too. @mentions inside post, comment and title text become <code>@user_&lt;hash&gt;</code> (Reddit <code>u/name</code> → <code>u/user_&lt;hash&gt;</code>) — the same hash for the same handle in every run; e-mail addresses and #hashtags stay as written.",
            "default": "pseudonymous"
          },
          "stripSignedTokens": {
            "title": "✂️ Remove signed tokens from links",
            "type": "boolean",
            "description": "Removes signed parameters (xsec_token, expiring media signatures) from links and drops signed video file links. On by default (and always on with pseudonymous authors).",
            "default": true
          },
          "snapshotId": {
            "title": "🏷️ Snapshot id",
            "type": "string",
            "description": "Optional label of this snapshot (e.g. the date), written into provenance of every row."
          },
          "panelId": {
            "title": "🏷️ Panel id / version",
            "type": "string",
            "description": "Optional id of your fixed panel of posts, written into provenance. With Re-measure IDs it also keeps a <b>panel journal</b> between runs: free <code>panel_change</code> rows say which IDs were added, removed from your input or are still in the panel but gone on the source (with the date they joined and the previous run time), <code>panelVersion</code> goes up whenever the membership changes, and the run's key-value store gets a <code>PANEL</code> record with the full membership."
          },
          "queryId": {
            "title": "🏷️ Query id / version",
            "type": "string",
            "description": "Optional id of your search profile version, written into provenance."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}