{
  "openapi": "3.0.1",
  "info": {
    "title": "Video Keyframe Extractor API: Scene Cuts, No Login",
    "description": "Find every scene change in a video file and save one keyframe per scene, or a frame every N seconds. Rows give scene start and end timecodes, frame image links, a contact sheet, video metadata and optional on-screen text. $0.01 per video minute, $0.003 per frame.",
    "version": "0.0",
    "x-build-id": "FBE4HuHykXuV4vhhh"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/conserving_celerytop~video-scene-keyframes/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-conserving_celerytop-video-scene-keyframes",
        "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/conserving_celerytop~video-scene-keyframes/runs": {
      "post": {
        "operationId": "runs-sync-conserving_celerytop-video-scene-keyframes",
        "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/conserving_celerytop~video-scene-keyframes/run-sync": {
      "post": {
        "operationId": "run-sync-conserving_celerytop-video-scene-keyframes",
        "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": "Direct links to video files (MP4, MOV, WebM, MKV, AVI and other formats ffmpeg reads). Use files you own or have the right to process. Links to video platform pages (YouTube, TikTok, Instagram and similar) are refused.",
            "items": {
              "type": "string"
            }
          },
          "listDatasetId": {
            "title": "Dataset with the list",
            "type": "string",
            "description": "Pick an Apify Dataset that holds your video links, one entry per item. They are added to the entries typed above."
          },
          "listDatasetField": {
            "title": "Field in the dataset",
            "type": "string",
            "description": "Name of the dataset field that holds the entry. Leave empty to use the first text field it finds."
          },
          "listFileUrl": {
            "title": "List file URL",
            "type": "string",
            "description": "Web address of a .txt, .csv or .json file with your video links, one entry per line. A header row is skipped. Up to 10 MB."
          },
          "mode": {
            "title": "Frame selection",
            "enum": [
              "scenes",
              "interval"
            ],
            "type": "string",
            "description": "Scenes: find every cut or scene change and save the middle frame of each scene, with scene start and end timecodes. Interval: save one frame every N seconds.",
            "default": "scenes"
          },
          "intervalSeconds": {
            "title": "Seconds between frames",
            "minimum": 0.5,
            "maximum": 3600,
            "type": "number",
            "description": "Interval mode: time between saved frames. The first frame is at 0:00.",
            "default": 10
          },
          "maxFramesPerVideo": {
            "title": "Maximum frames per video",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Upper limit of frames saved from one video. In scene mode, keyframes are saved for the first scenes up to this number; the total scene count is still reported.",
            "default": 50
          },
          "readOnScreenText": {
            "title": "Read on-screen text",
            "type": "boolean",
            "description": "Read titles, captions and slide text in each saved frame with OCR. Adds the text to the row. Charged only for frames where text is found.",
            "default": false
          },
          "ocrLanguage": {
            "title": "On-screen text language",
            "enum": [
              "eng",
              "deu",
              "fra",
              "spa",
              "ita",
              "por",
              "nld"
            ],
            "type": "string",
            "description": "Language of the on-screen text.",
            "default": "eng"
          },
          "contactSheet": {
            "title": "Contact sheet",
            "type": "boolean",
            "description": "Save one overview image per video with all saved frames and their timecodes (up to 60 thumbnails).",
            "default": true
          },
          "sceneThreshold": {
            "title": "Scene change sensitivity",
            "minimum": 5,
            "maximum": 100,
            "type": "integer",
            "description": "Lower values find more, subtler scene changes; higher values keep only hard cuts. 27 suits most edited video.",
            "default": 27
          },
          "minSceneSeconds": {
            "title": "Minimum scene length (seconds)",
            "minimum": 0.1,
            "maximum": 600,
            "type": "number",
            "description": "Scenes shorter than this are merged with the next one. Raise it for fast-cut video such as ads or music videos.",
            "default": 1
          },
          "maxMinutesPerVideo": {
            "title": "Maximum minutes per video",
            "minimum": 1,
            "maximum": 180,
            "type": "integer",
            "description": "Only this many minutes from the start of each video are analysed.",
            "default": 30
          },
          "frameFormat": {
            "title": "Frame image format",
            "enum": [
              "jpeg",
              "png",
              "webp"
            ],
            "type": "string",
            "description": "Image format of saved frames and the contact sheet.",
            "default": "jpeg"
          },
          "frameWidth": {
            "title": "Frame width (pixels)",
            "minimum": 0,
            "maximum": 3840,
            "type": "integer",
            "description": "Frames wider than this are scaled down, keeping the aspect ratio. 0 keeps the original size.",
            "default": 1280
          },
          "imageQuality": {
            "title": "Image quality",
            "minimum": 30,
            "maximum": 100,
            "type": "integer",
            "description": "JPEG and WebP quality (PNG is lossless).",
            "default": 85
          },
          "maxFileMb": {
            "title": "Maximum file size (MB)",
            "minimum": 1,
            "maximum": 4096,
            "type": "integer",
            "description": "Larger files are not downloaded. Large files need more memory and disk; use 4 GB or more for files over 1 GB.",
            "default": 1024
          },
          "maxVideos": {
            "title": "Maximum videos",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Upper limit of videos processed in one run.",
            "default": 100
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}