{
  "openapi": "3.0.1",
  "info": {
    "title": "Video Frame Extractor — YouTube & TikTok to Images, Scenes, OCR",
    "description": "Turn any video into images: YouTube, TikTok, Instagram, Facebook, X or MP4 links → frames every N seconds, scene changes, keyframes, exact times or best thumbnails. Free contact sheet, duplicate and blank-frame skip, OCR text. No login. JSON, CSV, Excel.",
    "version": "0.1",
    "x-build-id": "0a17NfGVNq07ZPh9S"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/apimy~video-frame-extractor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-apimy-video-frame-extractor",
        "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/apimy~video-frame-extractor/runs": {
      "post": {
        "operationId": "runs-sync-apimy-video-frame-extractor",
        "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/apimy~video-frame-extractor/run-sync": {
      "post": {
        "operationId": "run-sync-apimy-video-frame-extractor",
        "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": {
          "videoUrls": {
            "title": "🔗 Video URLs",
            "type": "array",
            "description": "Paste one or more public video links: YouTube videos and Shorts, TikTok, Instagram Reels and video posts, Facebook, X (Twitter), Vimeo, Reddit and 1,000+ other sites, or a direct file link (MP4, MOV, WebM, MKV, M3U8). A YouTube channel or playlist link, or a TikTok profile link, takes its newest videos. No login or cookies needed. Empty input runs a short sample video.",
            "items": {
              "type": "string"
            }
          },
          "maxVideosPerSource": {
            "title": "📺 Videos per channel, playlist or profile",
            "minimum": 1,
            "maximum": 200,
            "type": "integer",
            "description": "When a link points to a whole YouTube channel, playlist or TikTok profile, how many of its newest videos to take. Single video links are not affected.",
            "default": 5
          },
          "mode": {
            "title": "🎯 Which frames",
            "enum": [
              "auto",
              "interval",
              "count",
              "scenes",
              "keyframes",
              "timestamps",
              "bestThumbnails"
            ],
            "type": "string",
            "description": "Auto gives a storyboard that covers the whole video: the first frame, then the strongest shot change in each equal part (or the middle of the part when nothing changes there). Interval: one frame every N seconds. Count: N frames spread evenly. Scenes: one frame at the start of every shot. Keyframes: the encoder's own keyframes. Timestamps: exactly the times you list. Best thumbnails: scores ~70 candidate frames for sharpness, exposure, contrast, colour and faces, and returns the best few.",
            "default": "auto"
          },
          "frameCount": {
            "title": "🔢 Number of frames (auto and count)",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Auto and count modes: how many frames per video. Each frame comes from its own equal slice of the video, so black lead-ins and fade-outs are avoided.",
            "default": 12
          },
          "intervalSeconds": {
            "title": "⏱️ Every N seconds (interval)",
            "minimum": 0.1,
            "maximum": 3600,
            "type": "number",
            "description": "Interval mode: seconds between frames, counted from the start time. 1 = one frame per second, 0.5 = two per second.",
            "default": 5
          },
          "sceneThreshold": {
            "title": "🎚️ Scene sensitivity (scenes)",
            "minimum": 0.01,
            "maximum": 0.99,
            "type": "number",
            "description": "Scenes mode: how different two frames must be to count as a new shot. Lower finds more cuts (0.15 also catches soft transitions), higher only hard cuts (0.5). Auto mode uses at most 0.3.",
            "default": 0.3
          },
          "timestamps": {
            "title": "📍 Timestamps (timestamps mode)",
            "type": "array",
            "description": "Timestamps mode: the moments to capture. Seconds (90 or 90.5), clock format (1:30, 00:01:30.250) or 1m30s all work. Times past the end of a video are skipped and reported, never charged.",
            "items": {
              "type": "string"
            }
          },
          "startTime": {
            "title": "▶️ Start time",
            "type": "string",
            "description": "Optional. Ignore everything before this time, e.g. 30, 0:30 or 1m. Works in every mode except timestamps."
          },
          "endTime": {
            "title": "⏹️ End time",
            "type": "string",
            "description": "Optional. Ignore everything after this time, e.g. 300, 5:00 or 5m. Leave empty to run to the end. In scan modes (auto, scenes, keyframes, best thumbnails) a shorter window also means fewer scanned minutes."
          },
          "maxFramesPerVideo": {
            "title": "🧱 Max frames per video",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Upper limit on frames per video in every mode. In scenes mode the strongest shot changes are kept; in keyframes mode keyframes are sampled evenly.",
            "default": 50
          },
          "thumbnailCount": {
            "title": "🏆 Best thumbnails to return",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "Best thumbnails mode: how many winners per video, ranked (thumbnailRank 1 = best). Winners are at least a few seconds apart, so you get different shots, not three copies of one.",
            "default": 3
          },
          "skipBlankFrames": {
            "title": "⬛ Skip black and blank frames",
            "type": "boolean",
            "description": "When a chosen moment is black, a fade or one flat colour, step forward up to 2 seconds to a real picture. Frames that stay blank are dropped and never charged. Not applied in timestamps and keyframes modes, where you asked for that exact frame.",
            "default": true
          },
          "skipDuplicates": {
            "title": "♊ Skip near-duplicate frames",
            "type": "boolean",
            "description": "Drop a frame that looks almost the same as one already returned for that video (perceptual hash) — a talking head every 5 seconds becomes a few distinct frames instead of 60 identical ones. Dropped frames are never charged. Off in timestamps mode.",
            "default": true
          },
          "duplicateSensitivity": {
            "title": "🔬 Duplicate sensitivity",
            "minimum": 0,
            "maximum": 20,
            "type": "integer",
            "description": "How many of 64 hash bits may differ for two frames to count as duplicates. 0 drops only identical frames, 5 is a good default, 10+ also drops similar shots.",
            "default": 5
          },
          "skipBlurryFrames": {
            "title": "🌫️ Skip blurry frames",
            "type": "boolean",
            "description": "Drop frames whose sharpness score is very low (motion blur, out of focus). Every frame row carries sharpness and isBlurry either way, so you can filter later instead.",
            "default": false
          },
          "imageFormat": {
            "title": "🖼️ Image format",
            "enum": [
              "jpg",
              "png",
              "webp"
            ],
            "type": "string",
            "description": "File format of the saved frames.",
            "default": "jpg"
          },
          "maxWidth": {
            "title": "📐 Max frame width (px)",
            "minimum": 0,
            "maximum": 7680,
            "type": "integer",
            "description": "Frames are scaled down to at most this width, keeping the aspect ratio, never scaled up. For platform links the smallest copy that reaches this width is fetched, which keeps runs fast. 0 = original resolution.",
            "default": 1280
          },
          "imageQuality": {
            "title": "🎛️ Image quality",
            "minimum": 30,
            "maximum": 100,
            "type": "integer",
            "description": "JPG and WebP quality from 30 to 100. 88 looks identical to the source at a fraction of the size; 95+ for print or training data.",
            "default": 88
          },
          "contactSheet": {
            "title": "🗂️ Contact sheet (free)",
            "type": "boolean",
            "description": "Also save one grid image per video with all its frames (up to 100), each stamped with its time. The link is in the video summary row (contactSheetUrl). One image is often enough to send a whole video to ChatGPT, Claude or Gemini.",
            "default": true
          },
          "contactSheetColumns": {
            "title": "🔲 Contact sheet columns",
            "minimum": 1,
            "maximum": 12,
            "type": "integer",
            "description": "Frames per row on the contact sheet.",
            "default": 4
          },
          "previewGif": {
            "title": "🎞️ Animated preview GIF (free)",
            "type": "boolean",
            "description": "Also save a small animated GIF that flips through the frames (360 px wide). Link in the video summary row (previewGifUrl).",
            "default": false
          },
          "readTextOnFrames": {
            "title": "🔤 Read text on frames (OCR, paid add-on)",
            "type": "boolean",
            "description": "Read the text burned into each frame — captions, titles, slides, prices, product names — into ocrText (lines top to bottom). Latin and Cyrillic scripts. Charged per frame read (frame-ocr event).",
            "default": false
          },
          "includeColors": {
            "title": "🎨 Dominant colours",
            "type": "boolean",
            "description": "Add the 5 dominant colours of each frame (hex and share) — handy for thumbnail research and design. Free.",
            "default": true
          },
          "includeVideoRows": {
            "title": "🧾 Video summary rows",
            "type": "boolean",
            "description": "One free row per video (type \"video\") with duration, source resolution, frames returned and skipped, contact sheet and GIF links. Filter frames with type == \"frame\".",
            "default": true
          },
          "proxyMode": {
            "title": "🌐 Connection",
            "enum": [
              "auto",
              "direct",
              "residential"
            ],
            "type": "string",
            "description": "Auto tries a direct connection first and switches to a residential proxy only when the site blocks the request (YouTube often does). Residential traffic is charged per started MB (residential-mb event); every other route is free.",
            "default": "auto"
          },
          "maxDownloadMbPerVideo": {
            "title": "💾 Max download per video (MB)",
            "minimum": 0,
            "maximum": 4000,
            "type": "integer",
            "description": "Safety limit on video data fetched per video. Seek modes (count, interval, timestamps) read only a few MB even on long videos; scan modes read the whole video at its smallest size. A video over the limit is skipped free of charge. 0 = no limit.",
            "default": 300
          },
          "includeRunSummary": {
            "title": "🧮 Run summary row",
            "type": "boolean",
            "description": "Add one free row at the end with how many frames were delivered and the exact cost of the run by event.",
            "default": 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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}