{
  "openapi": "3.0.1",
  "info": {
    "title": "Kwai Scraper - Videos, Profiles, Hashtags, Creators, MP4",
    "description": "Kwai without login: video search, hashtags, profiles with every video, related videos, no-watermark MP4 saved to your storage, ranked creators by niche, monitors with alerts and the feed of other countries. $1.50 per 1,000.",
    "version": "1.0",
    "x-build-id": "NQlUareJNM8Dab6id"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/pomlabs~kwai-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-pomlabs-kwai-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/pomlabs~kwai-scraper/runs": {
      "post": {
        "operationId": "runs-sync-pomlabs-kwai-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/pomlabs~kwai-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-pomlabs-kwai-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": {
          "queries": {
            "title": "Queries",
            "type": "array",
            "description": "One per line: a keyword (video search), a #hashtag, an @creator or profile link (https://www.kwai.com/@name), a video link or id (https://www.kwai.com/@name/video/5203777995084625720), or the word feed (the \"for you\" feed, in the Country you pick). Up to 20. The input names of other Kwai scrapers work too (searchQueries, searchTerms, videoUrls, startUrls, profileUrls, usernames, hashtags).",
            "items": {
              "type": "string"
            }
          },
          "mode": {
            "title": "Mode",
            "enum": [
              "search",
              "profile",
              "user_videos",
              "creators",
              "music",
              "feed",
              "monitor"
            ],
            "type": "string",
            "description": "Optional shortcut. Search reads Queries as usual; Creators ranks the creators of the niche word or #hashtag in the query by median views and engagement; Search with the whole sound returns videos with the music id, name, artist and audio link; Follower monitor returns the follower count of each profile and its change since the last run with the same State key.",
            "default": "search"
          },
          "maxResults": {
            "title": "Max results per query",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "1 to 5,000 videos per query (search, hashtag, profile). A profile gives all its videos when this is high enough. In Creators mode it is the number of creators (up to 100).",
            "default": 40
          },
          "country": {
            "title": "Country of the feed",
            "enum": [
              "",
              "ID",
              "IN",
              "PK",
              "PH",
              "ES",
              "MX",
              "NG",
              "BR",
              "EG",
              "TR",
              "SA"
            ],
            "type": "string",
            "description": "Which country's Kwai the run reads. The for-you feed really changes for ID (Indonesia), IN (India) and PK (Pakistan), where the app runs as SnackVideo; for the other countries the server reports the country but the feed stays close to the default.",
            "default": ""
          },
          "minViews": {
            "title": "Minimum views",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only videos with at least this many views.",
            "default": 0
          },
          "minLikes": {
            "title": "Minimum likes",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only videos with at least this many likes.",
            "default": 0
          },
          "minComments": {
            "title": "Minimum comments",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only videos with at least this many comments (the count; the comment list itself is not returned).",
            "default": 0
          },
          "publishedAfter": {
            "title": "Published after",
            "type": "string",
            "description": "Keep only videos published on or after this date (YYYY-MM-DD)."
          },
          "publishedBefore": {
            "title": "Published before",
            "type": "string",
            "description": "Keep only videos published on or before this date (YYYY-MM-DD)."
          },
          "postedWithinDays": {
            "title": "Posted within the last N days",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only videos published in the last N days."
          },
          "captionContains": {
            "title": "Caption must contain",
            "type": "array",
            "description": "Keep only videos whose caption has at least one of these words (case-insensitive).",
            "items": {
              "type": "string"
            }
          },
          "verifiedOnly": {
            "title": "Verified creators only",
            "type": "boolean",
            "description": "Keep only videos of verified creators.",
            "default": false
          },
          "excludeAiVideos": {
            "title": "Skip AI-generated videos",
            "type": "boolean",
            "description": "Drop videos Kwai labels as AI-generated.",
            "default": false
          },
          "expandWithHashtag": {
            "title": "Also read the hashtag of the word",
            "type": "boolean",
            "description": "For keyword queries, also read the hashtag of the same word and merge, which goes deeper than the search alone.",
            "default": false
          },
          "includeAuthorStats": {
            "title": "Add the creator's numbers to each video",
            "type": "boolean",
            "description": "Adds authorStats (followers, following, likes received, videos, bio, niche) to every video, read once per creator.",
            "default": false
          },
          "includeRelated": {
            "title": "Related videos of a video link",
            "type": "boolean",
            "description": "For video links: also the videos Kwai shows next to it.",
            "default": false
          },
          "includeAlbums": {
            "title": "Albums of a profile",
            "type": "boolean",
            "description": "For profiles: the creator's albums (playlists) with video count, views and first caption.",
            "default": false
          },
          "includeQualities": {
            "title": "Every resolution of the video",
            "type": "boolean",
            "description": "Adds the list of resolutions Kwai has for each video (width, height, codec, bitrate, link). Every video already carries videoUrl, the no-watermark MP4 link.",
            "default": false
          },
          "saveVideos": {
            "title": "Save MP4 videos",
            "type": "boolean",
            "description": "Save each video's MP4 (no watermark) to the run's key-value store before the link expires; the file goes in videoFile. Charged per stored file.",
            "default": false
          },
          "saveCovers": {
            "title": "Save covers",
            "type": "boolean",
            "description": "Save each video's cover image to the key-value store; the file goes in coverFile. Charged per stored file.",
            "default": false
          },
          "kvStoreName": {
            "title": "Key-value store name",
            "type": "string",
            "description": "Optional named key-value store for the saved files (kept after the run). Empty = the run's own store."
          },
          "includeTranscript": {
            "title": "Transcribe the videos",
            "type": "boolean",
            "description": "For each video returned, add a transcript row with the speech as text (language detected), timed segments and an optional summary. Charged per transcript; videos without speech are free.",
            "default": false
          },
          "transcriptLanguage": {
            "title": "Transcript language",
            "type": "string",
            "description": "Language code of the speech (en, pt, es, id, hi...) or auto to detect it.",
            "default": "auto"
          },
          "transcriptTimestamps": {
            "title": "Timed segments",
            "type": "boolean",
            "description": "Add the timed segments (start, end, text) to each transcript.",
            "default": true
          },
          "summarize": {
            "title": "Summarize",
            "type": "boolean",
            "description": "Add a 2 to 3 sentence summary to each transcript (needs Transcribe the videos).",
            "default": false
          },
          "summaryLanguage": {
            "title": "Summary language",
            "type": "string",
            "description": "Language of the summary, as a name (English, Portuguese...). Empty: the language of the speech."
          },
          "maxTranscripts": {
            "title": "Max transcripts",
            "minimum": 1,
            "maximum": 200,
            "type": "integer",
            "description": "The most transcripts of one run, counted from the first video (default 20).",
            "default": 20
          },
          "maxCreators": {
            "title": "Creators to rank",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "Creators mode: how many ranked creators to return (up to 100).",
            "default": 30
          },
          "sampleVideos": {
            "title": "Niche videos to sample",
            "minimum": 50,
            "maximum": 1000,
            "type": "integer",
            "description": "Creators mode: how many videos of the niche are read to find its creators (more videos, more creators found, slower).",
            "default": 300
          },
          "deltaMode": {
            "title": "Only new videos (monitor)",
            "type": "boolean",
            "description": "Return only videos this account has not received in earlier runs with the same State key (kept 30 days). For schedules and alerts.",
            "default": false
          },
          "deltaStateKey": {
            "title": "State key",
            "type": "string",
            "description": "Name of the monitor memory, so different schedules do not mix (default: default)."
          },
          "monitorFollowers": {
            "title": "Follower change on profiles",
            "type": "boolean",
            "description": "Adds followersChange (previous count, time of the previous run, change) to each profile row, compared with the last run with the same State key.",
            "default": false
          },
          "minFollowerChange": {
            "title": "Only profiles that changed by at least",
            "minimum": 0,
            "type": "integer",
            "description": "With follower monitoring: skip profiles whose follower count moved by less than this since the last run.",
            "default": 0
          },
          "webhookUrl": {
            "title": "Webhook address",
            "type": "string",
            "description": "Receives a POST with the run, dataset, count and a sample of rows when the run delivers (use with Only new videos for alerts)."
          },
          "webhookHeaders": {
            "title": "Webhook headers",
            "type": "object",
            "description": "Headers sent with the webhook, for example an authorization token."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}