{
  "openapi": "3.0.1",
  "info": {
    "title": "TikTok, Douyin & Bilibili Scraper — Videos, Profiles, Comments",
    "description": "Scrape TikTok, Douyin, Bilibili, Kuaishou & Xigua: videos, profiles, comments + replies, followers, keyword search, hashtags, sounds, trending, TikTok Shop, danmaku & subtitles. No login or cookies. Pay only per result.",
    "version": "1.0",
    "x-build-id": "iTrmM7AcRiaDaMHNk"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/openclawai~tiktok-douyin-bilibili-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-openclawai-tiktok-douyin-bilibili-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/openclawai~tiktok-douyin-bilibili-scraper/runs": {
      "post": {
        "operationId": "runs-sync-openclawai-tiktok-douyin-bilibili-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/openclawai~tiktok-douyin-bilibili-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-openclawai-tiktok-douyin-bilibili-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",
        "required": [
          "mode"
        ],
        "properties": {
          "mode": {
            "title": "🎬 What to scrape",
            "enum": [
              "user_posts",
              "video_detail",
              "user_profile",
              "video_comments",
              "search_videos",
              "search_users",
              "search_hashtags",
              "search_music",
              "search_live",
              "hashtag_videos",
              "music_videos",
              "followers",
              "following",
              "user_likes",
              "user_reposts",
              "user_playlists",
              "trending",
              "hot_search",
              "live_info",
              "shop_search",
              "shop_product",
              "shop_reviews",
              "danmaku",
              "subtitles",
              "hd_video_link",
              "fake_view_check"
            ],
            "type": "string",
            "description": "Pick a mode. Not every platform has every mode — see the table in the README. Modes marked (keywords) read the Keywords field; trending / hot search need no input.",
            "default": "user_posts"
          },
          "urls": {
            "title": "🔗 Links, @usernames or IDs",
            "type": "array",
            "description": "One per line: video links, profile links, @usernames (TikTok), BV ids (Bilibili), hashtag names, product links. Short share links (vm.tiktok.com, v.douyin.com, b23.tv, v.kuaishou.com) work too. The platform is detected from each link.",
            "items": {
              "type": "string"
            }
          },
          "queries": {
            "title": "🔎 Keywords (search modes)",
            "type": "array",
            "description": "One keyword per line for the search_* and shop_search modes. Use Chinese keywords for Douyin, Bilibili and Kuaishou.",
            "items": {
              "type": "string"
            }
          },
          "platform": {
            "title": "🌐 Platform",
            "enum": [
              "auto",
              "tiktok",
              "douyin",
              "bilibili",
              "kuaishou",
              "xigua"
            ],
            "type": "string",
            "description": "Leave on Auto to detect the platform from each link. Set it for keyword searches and trending / hot search (Auto = TikTok).",
            "default": "auto"
          },
          "maxItems": {
            "title": "📊 Max results per input",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Stop after this many rows per link or keyword (comments include their replies).",
            "default": 100
          },
          "includeReplies": {
            "title": "↩️ Include comment replies",
            "type": "boolean",
            "description": "In video_comments mode, also fetch the replies under each comment that has 3 or more replies (TikTok, Douyin, Bilibili). Replies are billed as comments. Paid Apify plans only.",
            "default": false
          },
          "downloadVideos": {
            "title": "⬇️ Include video file URLs",
            "type": "boolean",
            "description": "Add the direct video file URL to each video row when the platform provides one. For full-quality Douyin files use the 'Douyin HD video download link' mode.",
            "default": true
          },
          "region": {
            "title": "🗺️ Region",
            "type": "string",
            "description": "Two-letter country code for TikTok search, sounds and TikTok Shop (e.g. US, GB, DE, ID).",
            "default": "US"
          },
          "exploreCategory": {
            "title": "🔥 Trending category (TikTok)",
            "enum": [
              "all",
              "food",
              "comedy",
              "beauty",
              "fashion",
              "gaming",
              "sports",
              "animals",
              "music_dance",
              "fitness",
              "tech",
              "education",
              "cars",
              "daily_life",
              "family",
              "relationships",
              "drama",
              "animation",
              "performance",
              "lip_sync",
              "society"
            ],
            "type": "string",
            "description": "Category for TikTok trending videos.",
            "default": "all"
          },
          "url": {
            "title": "🔗 Single link (older field)",
            "type": "string",
            "description": "Kept for older saved tasks. Use 'Links, @usernames or IDs' above instead."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}