{
  "openapi": "3.0.1",
  "info": {
    "title": "TikTok Scraper Pro",
    "description": "Scrape TikTok videos from keyword searches, hashtags, profiles and video URLs: views, likes, shares, saves, comments, captions, music, author stats, with optional comments, video downloads and subtitles. No login. Pay per result.",
    "version": "1.0",
    "x-build-id": "ivLrVCr8PIS4h5EG9"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/badr_xba~tiktok-scraper-pro/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-badr_xba-tiktok-scraper-pro",
        "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/badr_xba~tiktok-scraper-pro/runs": {
      "post": {
        "operationId": "runs-sync-badr_xba-tiktok-scraper-pro",
        "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/badr_xba~tiktok-scraper-pro/run-sync": {
      "post": {
        "operationId": "run-sync-badr_xba-tiktok-scraper-pro",
        "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": {
          "postURLs": {
            "title": "🎬 Post URLs",
            "type": "array",
            "description": "TikTok post addresses, one per line: https://www.tiktok.com/@nasa/video/1234567890. A bare video ID, a vm.tiktok.com or tiktok.com/t/ short link, a mobile or embed link works too, with or without ?is_from_webapp=… tracking. This is the fastest and most reliable input — every field comes from the post's own page. Profile or hashtag links pasted here are moved to the right list for you.",
            "items": {
              "type": "string"
            }
          },
          "hashtags": {
            "title": "#️⃣ Hashtags",
            "type": "array",
            "description": "Hashtags to follow, with or without the #: cooking, travel, smallbusiness, or a tiktok.com/tag/… link. A list pasted on one line (#food #travel or food, travel) is split for you. You get the hashtag's own figures (views) plus the posts published under it (switch off \"Collect the videos under each hashtag\" for the figures only).",
            "items": {
              "type": "string"
            }
          },
          "profiles": {
            "title": "👤 Profiles",
            "type": "array",
            "description": "TikTok accounts, as nasa, @nasa or a full profile URL (a comma-separated list on one line is split for you; duplicates are read once). You get the account figures — followers, likes, number of videos, bio — and, with \"Collect the videos of each profile\" on, its latest posts, newest first.",
            "items": {
              "type": "string"
            }
          },
          "profileScrapeSections": {
            "title": "Profile sections",
            "type": "array",
            "description": "Which lists to read for each profile: its own videos, the videos it reposted, and its story if one is live right now.",
            "items": {
              "type": "string",
              "enum": [
                "videos",
                "reposts",
                "stories"
              ],
              "enumTitles": [
                "Videos",
                "Reposts",
                "Stories (active now)"
              ]
            },
            "default": [
              "videos"
            ]
          },
          "excludePinnedPosts": {
            "title": "Exclude pinned posts",
            "type": "boolean",
            "description": "Skip the videos a profile pinned at the top of its page (usually old, popular ones).",
            "default": false
          },
          "maxFollowersPerProfile": {
            "title": "👥 Followers per profile ($)",
            "minimum": 0,
            "type": "integer",
            "description": "Paid add-on. Adds up to this many follower accounts of each profile, one row each, with the profile they follow in \"connectedTo\". 0 = off. Uses residential addresses.",
            "default": 0
          },
          "maxFollowingPerProfile": {
            "title": "👥 Following per profile ($)",
            "minimum": 0,
            "type": "integer",
            "description": "Paid add-on. Adds up to this many accounts each profile follows. 0 = off.",
            "default": 0
          },
          "searchQueries": {
            "title": "🔍 Search queries",
            "type": "array",
            "description": "Keywords, exactly as you would type them in TikTok search (\"pasta recipe\", \"nike shoes\"). Use the section below to get videos (default) or profiles.",
            "items": {
              "type": "string"
            }
          },
          "searchSection": {
            "title": "Search for",
            "enum": [
              "",
              "/video",
              "/user"
            ],
            "type": "string",
            "description": "Videos returns the videos TikTok ranks for the keyword; Profiles returns matching accounts (followers, likes, bio) — set how many with \"Profiles per search\".",
            "default": ""
          },
          "maxProfilesPerQuery": {
            "title": "Profiles per search",
            "minimum": 1,
            "type": "integer",
            "description": "Only for profile searches: how many accounts to return per keyword.",
            "default": 10
          },
          "resultsPerPage": {
            "title": "Videos per hashtag or profile",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "How many posts to collect under each hashtag, for each profile, for each video search query, and next to each post URL when related videos are on. Post URLs you list yourself are never limited by this.",
            "default": 20
          },
          "maxItems": {
            "title": "Maximum posts in total",
            "minimum": 0,
            "type": "integer",
            "description": "A ceiling on the number of posts for the whole run, across every input. The run stops exactly there. Leave at 0 for no ceiling. Independently, the run also stops cleanly when your \"Maximum cost per run\" is reached.",
            "default": 0
          },
          "scrapeProfileVideos": {
            "title": "Collect the videos of each profile",
            "type": "boolean",
            "description": "On, each profile also returns its latest posts (up to \"Videos per hashtag or profile\"), read from TikTok's creator feed without a browser. Off, you only get the account figures — one result per profile.",
            "default": false
          },
          "scrapeHashtagVideos": {
            "title": "Collect the videos under each hashtag",
            "type": "boolean",
            "description": "On, each hashtag also returns its posts; this opens a browser and takes about half a minute per hashtag. Off, you only get the hashtag's counters, which is much faster.",
            "default": true
          },
          "scrapeRelatedVideos": {
            "title": "Collect videos related to each post URL",
            "type": "boolean",
            "description": "Adds the posts TikTok recommends next to each post URL you listed — about fifteen per post. A cheap way to widen a sample around a topic. TikTok serves these mostly to residential addresses.",
            "default": false
          },
          "oldestPostDate": {
            "title": "Published after ($)",
            "type": "string",
            "description": "Paid filter. Keep only posts published after this date: 2026-01-31, or a phrase such as 7 days, 3 weeks, 2 months. Leave empty for no limit. On profiles, reading stops as soon as posts get older than this date."
          },
          "newestPostDate": {
            "title": "Published before ($)",
            "type": "string",
            "description": "Paid filter. Keep only posts published before this date, same formats as above. Leave empty for no limit."
          },
          "minPlayCount": {
            "title": "Minimum views ($)",
            "minimum": 0,
            "type": "integer",
            "description": "Paid filter. Drop posts watched fewer times than this. 0 keeps everything.",
            "default": 0
          },
          "minDiggCount": {
            "title": "Minimum likes ($)",
            "minimum": 0,
            "type": "integer",
            "description": "Paid filter. Drop posts with fewer likes than this. 0 keeps everything.",
            "default": 0
          },
          "mostDiggs": {
            "title": "Maximum likes ($)",
            "minimum": 1,
            "type": "integer",
            "description": "Paid filter. Keeps only videos with fewer likes than this (find rising, non-viral posts)."
          },
          "shouldDownloadVideos": {
            "title": "Download the video files ($)",
            "type": "boolean",
            "description": "Paid add-on, billed per video file saved. Saves each MP4 in the run's storage and adds its address to the row (videoUrl). Expect a much longer, heavier run.",
            "default": false
          },
          "shouldDownloadCovers": {
            "title": "Download the cover images",
            "type": "boolean",
            "description": "Saves the thumbnail of each post (coverUrl).",
            "default": false
          },
          "shouldDownloadAvatars": {
            "title": "Download the author avatars",
            "type": "boolean",
            "description": "Saves the profile picture of each author, once per account (avatarUrl).",
            "default": false
          },
          "shouldDownloadMusicCovers": {
            "title": "Download the music covers",
            "type": "boolean",
            "description": "Saves the artwork of the sound used by each post (musicCoverUrl).",
            "default": false
          },
          "shouldDownloadSubtitles": {
            "title": "Download the subtitles",
            "type": "boolean",
            "description": "Saves the subtitle tracks TikTok publishes for a post, when it has any (subtitleUrls).",
            "default": false
          },
          "shouldDownloadSlideshowImages": {
            "title": "Download slideshow images",
            "type": "boolean",
            "description": "Photo posts carry images instead of a video: this saves them, up to twenty per post (slideshowImageUrls).",
            "default": false
          },
          "proxyCountryCode": {
            "title": "Scrape as in country ($)",
            "enum": [
              "None",
              "US",
              "GB",
              "DE",
              "FR",
              "ES",
              "IT",
              "CA",
              "MX",
              "BR",
              "JP",
              "KR",
              "IN",
              "ID",
              "AU",
              "NL",
              "SE",
              "PL",
              "TR",
              "AE",
              "SA",
              "EG",
              "MA"
            ],
            "type": "string",
            "description": "Paid add-on. Reads TikTok from addresses in this country, for content available only there. Requires the Apify proxy (residential works best).",
            "default": "None"
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Apify Proxy is optional: post URLs, hashtags and profile figures work without it. Switch it on (datacenter group) if the FAILED_INPUTS record shows BLOCKED, RATE_LIMITED or FEED_UNAVAILABLE: every retry then leaves from a new address. The RESIDENTIAL group only helps related videos.",
            "default": {
              "useApifyProxy": false
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}