{
  "openapi": "3.0.1",
  "info": {
    "title": "TikTok Hashtag Scraper - Video Analytics",
    "description": "Scrape public TikTok hashtag videos: views, likes, comments, shares, saves, engagement rate, creator bio emails, hashtag totals, dates and ad flags. Date, language and engagement filters, one video per creator, fast parallel runs. No cookies.",
    "version": "0.1",
    "x-build-id": "qXzbS0IdZO2kMpb01"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/khadinakbar~tiktok-hashtag-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-khadinakbar-tiktok-hashtag-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/khadinakbar~tiktok-hashtag-scraper/runs": {
      "post": {
        "operationId": "runs-sync-khadinakbar-tiktok-hashtag-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/khadinakbar~tiktok-hashtag-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-khadinakbar-tiktok-hashtag-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": {
          "hashtags": {
            "title": "Hashtags",
            "type": "array",
            "description": "Use this when you want videos from one or more public TikTok hashtag feeds. Enter names with or without '#', for example 'fitness' or '#booktok'. Several hashtags run side by side. Not for TikTok profiles, comments, or keyword search.",
            "items": {
              "type": "string"
            }
          },
          "hashtagUrls": {
            "title": "Hashtag URLs",
            "type": "array",
            "description": "Use this when you already have TikTok /tag/ URLs instead of plain hashtag names. Accepts URLs like 'https://www.tiktok.com/tag/skincare'. Empty by default. Not for video URLs or profile URLs.",
            "items": {
              "type": "string"
            }
          },
          "maxVideosPerHashtag": {
            "title": "Max videos per hashtag",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Maximum videos to save and pay for per hashtag, after all filters. Accepts 1 to 10000, for example 100. Defaults to 50. This is a per-hashtag cap, not a total across hashtags. Prefill is 10 so a first test costs a fraction of a cent.",
            "default": 50
          },
          "region": {
            "title": "Region",
            "type": "string",
            "description": "Two-letter country code used to localize hashtag results. Use values like 'US', 'GB', or 'DE'. Defaults to 'US'. Not a language filter; use the Language filter for that.",
            "default": "US"
          },
          "minViews": {
            "title": "Minimum views",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only videos with at least this many plays/views. Use 100000 to focus on viral posts. Defaults to 0, which keeps all view counts. Filtered-out videos are not saved or charged.",
            "default": 0
          },
          "minLikes": {
            "title": "Minimum likes",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only videos with at least this many likes. Use 5000 to focus on posts with proven engagement. Defaults to 0. Not a sort option; it removes rows below the threshold.",
            "default": 0
          },
          "minComments": {
            "title": "Minimum comments",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only videos with at least this many comments. Use 100 to find discussion-heavy hashtag posts. Defaults to 0. Not for downloading comments; use a TikTok comments actor for comment text.",
            "default": 0
          },
          "minShares": {
            "title": "Minimum shares",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only videos with at least this many shares. Use 100 to find posts spreading beyond the original audience. Defaults to 0. Not a share-export option.",
            "default": 0
          },
          "minDurationSeconds": {
            "title": "Minimum duration",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only videos at least this many seconds long. Use 15 to skip very short clips. Defaults to 0. Videos missing duration are dropped only when this filter is set.",
            "default": 0
          },
          "maxDurationSeconds": {
            "title": "Maximum duration",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only videos no longer than this many seconds. Use 60 to focus on short-form clips. Defaults to 0, meaning no upper limit. Videos missing duration are dropped only when this filter is set.",
            "default": 0
          },
          "includePhotoPosts": {
            "title": "Include photo posts",
            "type": "boolean",
            "description": "TikTok hashtag feeds can include image carousel posts. Keep true to include them, or set false to keep video posts only. Defaults to true. Not a media download option.",
            "default": true
          },
          "postedWithinDays": {
            "title": "Posted within days",
            "minimum": 0,
            "maximum": 3650,
            "type": "integer",
            "description": "Keep only videos posted in the last N days. Use 7 for the last week. Defaults to 0, which means any date. Combine with Posted after for a window.",
            "default": 0
          },
          "postedAfter": {
            "title": "Posted after",
            "type": "string",
            "description": "Keep only videos posted on or after this date, for example '2026-10-01'. Leave empty for no start date. Not a relative date; use Posted within days for that."
          },
          "postedBefore": {
            "title": "Posted before",
            "type": "string",
            "description": "Keep only videos posted on or before this date, for example '2026-11-01'. Leave empty for no end date."
          },
          "language": {
            "title": "Language",
            "type": "string",
            "description": "Keep only videos written in these languages. Use two-letter codes separated by commas, for example 'en' or 'en,es'. Empty keeps all languages. TikTok detects the language of the caption, so videos without a caption are dropped when this is set."
          },
          "onlyVerifiedCreators": {
            "title": "Only verified creators",
            "type": "boolean",
            "description": "Keep only videos from creators with TikTok's verified badge. Defaults to false.",
            "default": false
          },
          "excludeAds": {
            "title": "Exclude ads",
            "type": "boolean",
            "description": "Drop videos TikTok marks as ads or sponsored. Defaults to false.",
            "default": false
          },
          "excludePinned": {
            "title": "Exclude pinned videos",
            "type": "boolean",
            "description": "Drop videos a creator pinned to the top of their profile. Defaults to false. Handy when you want only fresh content.",
            "default": false
          },
          "minEngagementRate": {
            "title": "Minimum engagement rate (%)",
            "minimum": 0,
            "maximum": 100,
            "type": "number",
            "description": "Keep only videos where (likes + comments + shares) divided by views is at least this percent. Use 5 for 5%. Defaults to 0, which keeps everything.",
            "default": 0
          },
          "captionIncludes": {
            "title": "Caption must contain",
            "type": "array",
            "description": "Keep only videos whose caption contains at least one of these words or phrases (not case sensitive). Empty keeps all. Example: ['review','haul'].",
            "items": {
              "type": "string"
            }
          },
          "captionExcludes": {
            "title": "Caption must not contain",
            "type": "array",
            "description": "Drop videos whose caption contains any of these words or phrases (not case sensitive). Empty drops none. Example: ['giveaway'].",
            "items": {
              "type": "string"
            }
          },
          "maxVideosPerCreator": {
            "title": "Max videos per creator",
            "minimum": 0,
            "maximum": 10000,
            "type": "integer",
            "description": "Keep at most this many videos per creator across the whole run. Use 1 for one video per creator. Defaults to 0, which means no limit.",
            "default": 0
          },
          "sortBy": {
            "title": "Sort results by",
            "enum": [
              "none",
              "views",
              "likes",
              "engagement",
              "newest"
            ],
            "type": "string",
            "description": "Order the saved videos. Sorting only reorders the videos collected in this run; it does not search all of TikTok. Defaults to feed order.",
            "default": "none"
          },
          "maxPagesPerHashtag": {
            "title": "Max pages per hashtag",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Safety cap on pages read per hashtag (20 videos per page). Accepts 1 to 500, for example 100. Defaults to 100. Raise it only when maxVideosPerHashtag is high or filters are strict.",
            "default": 100
          },
          "includeRawData": {
            "title": "Include raw response data",
            "type": "boolean",
            "description": "Attach the raw provider payload to each dataset row under rawResult. Use this for debugging or custom downstream parsing. Defaults to false to keep rows compact. Not recommended for AI-agent previews.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}