{
  "openapi": "3.0.1",
  "info": {
    "title": "TikTok & Reels Script Analyzer – Hook, CTA, Transcript",
    "description": "Turn TikToks and Instagram Reels into structured scripts: transcript, spoken hook, timed beats, CTA, angle, format and tone, plus optional sponsor signals and translations. Works from links, profiles or a scraper dataset. Failed, silent and unsupported videos are free.",
    "version": "0.1",
    "x-build-id": "ZgPl8oxrZBGfgqbdE"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/smoxy~short-video-script-analyzer/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-smoxy-short-video-script-analyzer",
        "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/smoxy~short-video-script-analyzer/runs": {
      "post": {
        "operationId": "runs-sync-smoxy-short-video-script-analyzer",
        "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/smoxy~short-video-script-analyzer/run-sync": {
      "post": {
        "operationId": "run-sync-smoxy-short-video-script-analyzer",
        "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": {
          "urls": {
            "title": "Video links",
            "maxItems": 500,
            "type": "array",
            "description": "Links to public Instagram Reels and posts (instagram.com/reel/...) or TikTok videos (tiktok.com/@user/video/..., vm.tiktok.com/...). Leave all the lists empty to try a free example: one static sample row, nothing is downloaded or analyzed.",
            "items": {
              "type": "string"
            }
          },
          "profiles": {
            "title": "TikTok profiles",
            "maxItems": 50,
            "type": "array",
            "description": "TikTok profile links (tiktok.com/@user): the latest videos of each profile are analyzed. Instagram profiles need a login and are not supported: paste the Reel links instead.",
            "items": {
              "type": "string"
            }
          },
          "datasetId": {
            "title": "Dataset of another scraper",
            "type": "string",
            "description": "Optional. The ID of the dataset of a previous run of a TikTok or Instagram Reel scraper. The video file link in it is used right away (those links expire), with the page link as a fallback."
          },
          "mode": {
            "title": "What to produce",
            "enum": [
              "script",
              "transcript"
            ],
            "type": "string",
            "description": "Script gives the whole breakdown and includes the transcript.",
            "default": "script"
          },
          "sponsorSignals": {
            "title": "Sponsor signals",
            "type": "boolean",
            "description": "Find brands, discount codes and whether the creator says it is an ad. One extra row per video.",
            "default": false
          },
          "translateTo": {
            "title": "Translate to",
            "maxItems": 5,
            "type": "array",
            "description": "Language codes such as en, de, it, fr, es (up to 5). One extra row per video and language, with the translated transcript and, in script mode, the translated hook, beats and CTA. Videos already in that language are skipped for free.",
            "items": {
              "type": "string"
            }
          },
          "nichePlaybook": {
            "title": "Niche playbook",
            "type": "boolean",
            "description": "After the run, write a playbook of the niche from all the analyzed videos (hook patterns, structures, CTAs, recommendations): one extra row and the files PLAYBOOK.json and PLAYBOOK.md. Needs script mode and at least 10 analyzed videos.",
            "default": false
          },
          "since": {
            "title": "Only profile videos posted after",
            "type": "string",
            "description": "For profile links: skip videos posted before this date. Useful to follow a niche with a scheduled run."
          },
          "maxPerProfile": {
            "title": "Videos per profile",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "For profile links: how many of the latest videos to take from each profile.",
            "default": 20
          },
          "maxItems": {
            "title": "Max videos",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "The most videos analyzed in one run, whatever the number of links, profiles and dataset items. Accounts without a paid plan get at most 20.",
            "default": 20
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}