{
  "openapi": "3.0.1",
  "info": {
    "title": "TikTok Scraper API Pro - All Features",
    "description": "All-in-one TikTok scraper with profiles, videos, comments, hashtags, search, and download add-ons. The most complete TikTok data extraction tool with 29 profile fields and 77 video fields. Granular pay-per-event pricing.",
    "version": "0.1",
    "x-build-id": "4jc6gSyyolQwb8fnX"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/makework36~tiktok-api-premium/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-makework36-tiktok-api-premium",
        "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/makework36~tiktok-api-premium/runs": {
      "post": {
        "operationId": "runs-sync-makework36-tiktok-api-premium",
        "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/makework36~tiktok-api-premium/run-sync": {
      "post": {
        "operationId": "run-sync-makework36-tiktok-api-premium",
        "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": [
          "usernames"
        ],
        "properties": {
          "usernames": {
            "title": "TikTok Usernames",
            "type": "array",
            "description": "List of TikTok usernames to scrape (with or without @). Example: [\"@mrbeast\", \"cristiano\"]",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "maxVideos": {
            "title": "Max Videos per User",
            "minimum": 1,
            "maximum": 200,
            "type": "integer",
            "description": "Maximum number of videos to scrape per user (1–200).",
            "default": 30
          },
          "includeComments": {
            "title": "Include Comments ($)",
            "type": "boolean",
            "description": "Scrape comments for each video. Charges $0.0003 per comment via PPE.",
            "default": false
          },
          "maxComments": {
            "title": "Max Comments per Video",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "Maximum comments per video (only used if includeComments is true).",
            "default": 20
          },
          "includePlaylists": {
            "title": "📁 Include Playlists",
            "type": "boolean",
            "description": "Scrape user's playlists (collections of videos grouped together).",
            "default": false
          },
          "downloadVideos": {
            "title": "📥 Download videos to permanent storage ($)",
            "type": "boolean",
            "description": "Download .mp4 video files to Apify Key-Value Store. Links won't expire (TikTok CDN URLs do). Charges $0.005 per video via PPE.",
            "default": false
          },
          "downloadCovers": {
            "title": "🖼️ Download video thumbnails ($)",
            "type": "boolean",
            "description": "Download cover/thumbnail images for each video. Charges $0.0005 per image.",
            "default": false
          },
          "downloadAvatars": {
            "title": "👤 Download profile avatars ($)",
            "type": "boolean",
            "description": "Download profile avatar images. Charges $0.0005 per avatar.",
            "default": false
          },
          "downloadSlideshow": {
            "title": "🎭 Download slideshow images ($)",
            "type": "boolean",
            "description": "For carousel/slideshow posts, download all images. Charges $0.0005 per image.",
            "default": false
          },
          "downloadSoundCovers": {
            "title": "🎵 Download music sound covers ($)",
            "type": "boolean",
            "description": "Download music cover artwork. Charges $0.0005 per image.",
            "default": false
          },
          "downloadSubtitles": {
            "title": "📝 Download subtitles ($)",
            "type": "boolean",
            "description": "Download subtitle files (multi-language) for AI training and translation. Charges $0.001 per file.",
            "default": false
          },
          "kvStoreName": {
            "title": "Storage name for downloaded files",
            "type": "string",
            "description": "Optional name for the Key-Value Store. Unnamed stores are deleted after 7 days on Free plan.",
            "default": ""
          },
          "proxyConfig": {
            "title": "Proxy Configuration",
            "type": "object",
            "description": "Proxy settings. TikTok requires proxies to avoid blocks.",
            "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}