{
  "openapi": "3.0.1",
  "info": {
    "title": "TikTok Scraper - Hashtags, Profiles & Videos (No Login)",
    "description": "Scrape public TikTok posts, hashtags and profiles without login or API key: views, likes, comment, share and save counts, caption, sound and author followers. One flat price per result: date and view filters and MP4, cover and subtitle downloads cost nothing extra. Failed inputs never billed.",
    "version": "1.1",
    "x-build-id": "Q6Ucs2V10Y8dJE3SA"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/badr_xba~tiktok-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-badr_xba-tiktok-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/badr_xba~tiktok-scraper/runs": {
      "post": {
        "operationId": "runs-sync-badr_xba-tiktok-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/badr_xba~tiktok-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-badr_xba-tiktok-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": {
          "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"
            }
          },
          "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, 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. When TikTok returns none, the post is listed in FAILED_INPUTS and nothing is charged.",
            "default": false
          },
          "oldestPostDate": {
            "title": "Published after",
            "type": "string",
            "description": "Keep only posts published after this date: 2026-01-31, a full timestamp (2026-01-31T10:00:00Z), or a phrase such as 7 days, 3 weeks, 2 months, 1 year. 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": "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": "Drop posts watched fewer times than this. 0 keeps everything.",
            "default": 0
          },
          "minDiggCount": {
            "title": "Minimum likes",
            "minimum": 0,
            "type": "integer",
            "description": "Drop posts with fewer likes than this. 0 keeps everything.",
            "default": 0
          },
          "excludePinnedPosts": {
            "title": "Skip pinned posts",
            "type": "boolean",
            "description": "Drop the posts a creator pinned to the top of their profile (often old hits), so a profile's list holds only its latest videos. Off by default: pinned posts are kept, as before.",
            "default": false
          },
          "shouldDownloadVideos": {
            "title": "Download the video files",
            "type": "boolean",
            "description": "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
          },
          "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. A page TikTok refuses (403, 429, robot check, empty page) is not retried and not charged; only a technical error (network, timeout, 5xx) gets at most 2 new tries, on a new address of the same proxy. Residential proxies are not used (the price covers the datacenter proxy).",
            "default": {
              "useApifyProxy": false
            }
          },
          "failRunOnError": {
            "title": "Fail the run when TikTok blocks everything",
            "type": "boolean",
            "description": "When TikTok refuses every request (HTTP 403/429, a robot-check or empty page), the run normally ends as SUCCEEDED with a clear message, RUN_SUMMARY status BLOCKED and nothing charged. Turn this on to end such runs as FAILED instead (useful for alerts in schedules or integrations). A real technical error always ends the run as FAILED.",
            "default": 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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}