{
  "openapi": "3.0.1",
  "info": {
    "title": "TikTok Shop Videos — Search, Products & Comments",
    "description": "Research TikTok videos by market, keyword, views, likes and commerce metrics. Get video details, featured products, comments and similar videos. Export structured results as JSON, CSV or Excel.",
    "version": "0.0",
    "x-build-id": "7hObCKZAX1WFyw6N8"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/datanebula~tiktok-shop-videos/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-datanebula-tiktok-shop-videos",
        "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/datanebula~tiktok-shop-videos/runs": {
      "post": {
        "operationId": "runs-sync-datanebula-tiktok-shop-videos",
        "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/datanebula~tiktok-shop-videos/run-sync": {
      "post": {
        "operationId": "run-sync-datanebula-tiktok-shop-videos",
        "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",
        "required": [
          "operation",
          "country"
        ],
        "properties": {
          "operation": {
            "title": "Operation",
            "enum": [
              "videos-search",
              "videos-detail",
              "videos-products",
              "videos-reviews",
              "videos-similar"
            ],
            "type": "string",
            "description": "Choose one operation per run. See the README for the required inputs for each operation.",
            "default": "videos-search"
          },
          "country": {
            "title": "Market",
            "enum": [
              "br",
              "de",
              "es",
              "fr",
              "gb",
              "id",
              "it",
              "jp",
              "mx",
              "my",
              "ph",
              "sg",
              "th",
              "us",
              "vn"
            ],
            "type": "string",
            "description": "Use the market in which the entity ID was found. Data coverage varies by market.",
            "default": "us"
          },
          "maxResults": {
            "title": "Maximum results",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Total result rows across this run. Stops pagination at this limit. Apify Free plan users receive up to 20 rows per run. Analytical results may contain nested report data.",
            "default": 10
          },
          "ids": {
            "title": "Entity IDs",
            "maxItems": 100,
            "type": "array",
            "description": "Required for details and related data. Paste IDs returned by a search in the selected market. Handles and URLs are not supported.",
            "items": {
              "type": "string"
            }
          },
          "include": {
            "title": "Additional detail sections",
            "type": "array",
            "description": "Optional sections for detail operations only. These do not fetch related lists such as comments or videos.",
            "items": {
              "type": "string",
              "enum": [
                "core"
              ]
            }
          },
          "keyword": {
            "title": "Keyword",
            "type": "string",
            "description": "Search keyword\nApplies to: Search Videos."
          },
          "category": {
            "title": "Category",
            "type": "string",
            "description": "Product category ID as a numeric string, such as 601450. Filters videos by the associated product category; see the category reference in Search Products. Do not use creator content category IDs.\nApplies to: Search Videos.\nEnter a category ID or a category name from the reference table, such as Beauty & Personal Care."
          },
          "is_commercial": {
            "title": "Is commercial",
            "enum": [
              "any",
              "yes",
              "no"
            ],
            "type": "string",
            "description": "Whether this is a selling video\nApplies to: Search Videos."
          },
          "min_views": {
            "title": "Min views",
            "type": "number",
            "description": "Minimum views\nApplies to: Search Videos."
          },
          "max_views": {
            "title": "Max views",
            "type": "number",
            "description": "Maximum views\nApplies to: Search Videos."
          },
          "min_likes": {
            "title": "Min likes",
            "type": "number",
            "description": "Minimum likes\nApplies to: Search Videos."
          },
          "max_likes": {
            "title": "Max likes",
            "type": "number",
            "description": "Maximum likes\nApplies to: Search Videos."
          },
          "min_gmv_30d": {
            "title": "Min gmv 30d",
            "type": "number",
            "description": "Minimum 30-day GMV in USD\nApplies to: Search Videos."
          },
          "max_gmv_30d": {
            "title": "Max gmv 30d",
            "type": "number",
            "description": "Maximum 30-day GMV in USD\nApplies to: Search Videos."
          },
          "min_engagement": {
            "title": "Min engagement",
            "type": "number",
            "description": "Minimum engagement ratio, from 0 to 1 For example, 0.05 means 5%.\nApplies to: Search Videos."
          },
          "max_engagement": {
            "title": "Max engagement",
            "type": "number",
            "description": "Maximum engagement ratio, from 0 to 1 For example, 0.05 means 5%.\nApplies to: Search Videos."
          },
          "sort": {
            "title": "Sort",
            "type": "string",
            "description": "Sort as field, field:asc or field:desc. A bare field uses descending order.\nApplies to: Search Videos.\nAllowed fields — Search Videos: engagement, gmv_30d, launch_time, likes, sold_30d, views. Append :asc for ascending order."
          },
          "account_type": {
            "title": "Account type",
            "enum": [
              "0",
              "3",
              "4"
            ],
            "type": "string",
            "description": "Creator account type: 0 = personal; 3 = shop operating account; 4 = shop-linked account.\nApplies to: Search Videos."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}