{
  "openapi": "3.0.1",
  "info": {
    "title": "TikTok Profile Scraper (Engagement Rate & Brand Deals)",
    "description": "Scrape TikTok creator profiles plus their recent public videos into one row each: followers, likes, engagement rate, median views, posting cadence, top hashtags and brand-deal share. Same formula for every creator. Not-found accounts are free. No login. $30 per 1,000 creator reports.",
    "version": "0.1",
    "x-build-id": "gYGlbbfdUohavkh6D"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/locaihost~tiktok-creators/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-locaihost-tiktok-creators",
        "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/locaihost~tiktok-creators/runs": {
      "post": {
        "operationId": "runs-sync-locaihost-tiktok-creators",
        "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/locaihost~tiktok-creators/run-sync": {
      "post": {
        "operationId": "run-sync-locaihost-tiktok-creators",
        "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": {
          "handles": {
            "title": "TikTok creators",
            "type": "array",
            "description": "Handles or profile URLs, in any form TikTok shows them: \"khaby.lame\", \"@duolingo\", \"https://www.tiktok.com/@nba\", or a video URL. Each creator becomes one row. Repeats are fetched and charged once. Short links (vm.tiktok.com/…) are not supported: open them and paste the profile URL.",
            "items": {
              "type": "string"
            }
          },
          "includeVideos": {
            "title": "Include recent videos and analytics",
            "type": "boolean",
            "description": "Read each creator's recent public videos and add engagement rate, median views, posting cadence, top hashtags and brand-deal share. A row with videos is charged as a creator report; turn this off for cheaper, faster profile-only rows.",
            "default": true
          },
          "maxVideosPerCreator": {
            "title": "Videos to analyse per creator",
            "minimum": 1,
            "maximum": 60,
            "type": "integer",
            "description": "The newest this many public videos (pinned videos are left out). 30 covers about a month for a creator who posts daily.",
            "default": 30
          },
          "videosNewerThan": {
            "title": "Videos newer than",
            "type": "string",
            "description": "Only analyse and list videos posted after this: a date like 2026-10-01 (midnight UTC) or a period like \"30 days\", \"2 weeks\" or \"3 months\". The analytics then cover that window, and posting cadence is videos per week over it. A creator with no video in the window comes back as a profile (charged as a profile, not a report). Applies to the newest videos read (up to \"Videos to analyse per creator\"). Empty = every date."
          },
          "onlyNew": {
            "title": "Only creators not returned before",
            "type": "boolean",
            "description": "Skip creators this saved task already returned (and charged) in an earlier run, so a growing list only vets the additions. Off by default, so every run returns every creator.",
            "default": false
          },
          "videosSort": {
            "title": "Video order",
            "enum": [
              "latest",
              "popular"
            ],
            "type": "string",
            "description": "Which videos the row lists. Latest: the newest videos, newest first. Most viewed: the most viewed of the videos read (the newest pages of the profile, inside any date window), most viewed first; it is not the creator's all-time top list. The analytics always use the newest videos, so creators stay comparable.",
            "default": "latest"
          },
          "outputShape": {
            "title": "Output shape",
            "enum": [
              "creators",
              "videos"
            ],
            "type": "string",
            "description": "One row per creator (profile + analytics + recentVideos), or one row per analysed video with the creator's name, follower count and account type copied in, ready for a spreadsheet. In the video shape a creator without public videos still gets one profile row, and not-found or private creators one free row.",
            "default": "creators"
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Apify Proxy by default. Profile-only rows start on datacenter proxies and switch to residential only if TikTok blocks them. Videos always load through residential proxies (included in the price), because TikTok refuses the video list to datacenter IPs.",
            "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
                  },
                  "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}