{
  "openapi": "3.0.1",
  "info": {
    "title": "YouTube Channel Scraper — All Videos, Transcripts, Comments",
    "description": "Scrape every video from a YouTube channel, playlist or search — long videos, Shorts and live streams. Transcripts, comments and replies. Exact views and RFC-3339 dates. CSV export. No API key, no quota. Failed, filtered and cached rows are free.",
    "version": "1.1",
    "x-build-id": "mrgFUcn2NUihdLpVU"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/aquixlabs~youtube-channel-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-aquixlabs-youtube-channel-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/aquixlabs~youtube-channel-scraper/runs": {
      "post": {
        "operationId": "runs-sync-aquixlabs-youtube-channel-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/aquixlabs~youtube-channel-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-aquixlabs-youtube-channel-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",
        "required": [
          "inputs"
        ],
        "properties": {
          "inputs": {
            "title": "Channels, playlists, videos or search terms",
            "minItems": 1,
            "type": "array",
            "description": "One per line, mixed freely. Channel: youtube.com/@handle, @handle, or a /channel/UC... URL — returns that channel's videos, newest first. Playlist: a playlist URL or a bare list ID. Video: an 11-character video ID, a watch URL, youtu.be, /shorts/ or /embed/. Search: any words, e.g. drone review. Note: a bare 11-character word is read as a video ID (so is 'helicopters') — write search:helicopters to force a search.",
            "items": {
              "type": "string"
            }
          },
          "maxResultsPerSource": {
            "title": "Max videos per channel, playlist or search",
            "minimum": 1,
            "maximum": 4000,
            "type": "integer",
            "description": "How many videos to take from each channel, playlist or search term. Videos passed by ID ignore this. This is the main cost control: 10 channels at 100 each is 1,000 videos. Playlists return 100 IDs per request, so values that are multiples of 100 are the cheapest per video.",
            "default": 30
          },
          "channelTabs": {
            "title": "Which channel tabs to read",
            "type": "array",
            "description": "A channel keeps long videos, Shorts and live streams in three separate tabs that do not overlap — measured on one channel: 30 videos, 48 Shorts, 5 streams. All three are read by default so \"every video from the channel\" means every video. Each tab costs one extra listing request; drop the ones you do not want. Every row says which tab it came from in video_type.",
            "items": {
              "type": "string",
              "enum": [
                "videos",
                "shorts",
                "streams"
              ],
              "enumTitles": [
                "Videos",
                "Shorts",
                "Live streams"
              ]
            },
            "default": [
              "videos",
              "shorts",
              "streams"
            ]
          },
          "publishedAfter": {
            "title": "Published on or after (YYYY-MM-DD)",
            "type": "string",
            "description": "Keep only videos published on or after this date. Leave empty for no limit. Filtering happens after each video is read, so videos that are filtered out are never charged to you."
          },
          "publishedBefore": {
            "title": "Published on or before (YYYY-MM-DD)",
            "type": "string",
            "description": "Keep only videos published on or before this date. Leave empty for no limit."
          },
          "durationMinSeconds": {
            "title": "Minimum duration (seconds)",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only videos at least this long. 0 means no minimum. Use 61 to exclude Shorts.",
            "default": 0
          },
          "durationMaxSeconds": {
            "title": "Maximum duration (seconds)",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only videos no longer than this. 0 means no maximum.",
            "default": 0
          },
          "includeLikes": {
            "title": "Include like counts",
            "type": "boolean",
            "description": "Off by default. Adds a like count to every row from a small extra request (about 1,392 bytes). Not charged separately.",
            "default": false
          },
          "includeTranscript": {
            "title": "Include transcripts / subtitles (billed separately)",
            "type": "boolean",
            "description": "Off by default. Adds the full transcript text, its language, whether it was auto-generated, and the number of timed cues. Getting subtitles needs a different and larger request per video, so it is charged as its own event and only when a transcript is actually returned. Videos with subtitles disabled come back with transcript_status = NO_CAPTIONS and cost you nothing.",
            "default": false
          },
          "transcriptLanguages": {
            "title": "Preferred transcript languages",
            "type": "array",
            "description": "In order of preference, e.g. en, es, de. The first available match wins. If none match, the video's own first track is used — human-written subtitles before auto-generated ones. Only used when transcripts are on.",
            "default": [
              "en"
            ],
            "items": {
              "type": "string"
            }
          },
          "includeTranscriptSegments": {
            "title": "Add timed transcript segments (no extra charge)",
            "type": "boolean",
            "description": "Off by default, and only used when transcripts are on. Adds transcript_segments: one entry per subtitle cue with start_s, duration_s and text — the same words as transcript, split by timestamp. Turn it on when you need to cite a moment in the video. Leave it off for text: a single video can carry 1,000 cues, every export format flattens them into transcript_segments/0/text … /999/text, and a spreadsheet of a few videos becomes thousands of columns. It costs nothing extra either way — the cues arrive in the same request as the text — and transcript_cue_count tells you how many there would be.",
            "default": false
          },
          "includeComments": {
            "title": "Include comments (billed separately)",
            "type": "boolean",
            "description": "Off by default. Adds comments as EXTRA ROWS, not extra columns — each comment is its own row with _row_type = comment, which is what you want in a CSV. Video rows are unchanged and keep _row_type = video. Charged per comment returned. Videos with comments turned off cost you nothing.",
            "default": false
          },
          "maxCommentsPerVideo": {
            "title": "Max comments per video",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Top-level comments come 20 per request, so 20, 40 or 100 are natural stopping points. Only used when comments are on.",
            "default": 20
          },
          "maxRepliesPerComment": {
            "title": "Replies to fetch per comment",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "0 = top-level comments only. Replies need one extra request per comment that has any, so this is capped per comment rather than priced per reply — it stops 100 comments quietly becoming 100 extra requests. Replies arrive as their own rows with comment_is_reply = true.",
            "default": 0
          },
          "maxAgeHours": {
            "title": "Serve from cache if fetched within (hours)",
            "minimum": 0,
            "maximum": 720,
            "type": "integer",
            "description": "Videos this actor already fetched within this many hours are returned from stored state instead of being fetched again, and are not charged. Cached rows are marked _cached = true with _cached_at, so row age is always visible. Set 0 to force a fresh fetch. View counts move constantly — use 0 when sorting on views or computing growth.",
            "default": 24
          },
          "resetFingerprintBaseline": {
            "title": "Reset the drift baseline on this run",
            "type": "boolean",
            "description": "Advanced. Every run compares its column shape against a stored baseline and warns when fields start coming back empty. After an intended change to the output columns the old baseline is permanently wrong and warns forever. Turn this on for one run to replace it. Leave off otherwise — a baseline that resets itself cannot detect anything.",
            "default": false
          },
          "concurrency": {
            "title": "Parallel requests",
            "minimum": 1,
            "maximum": 16,
            "type": "integer",
            "description": "How many requests are in flight at once. Each worker makes at most one request per second, so this also sets the request rate. Lower it if you see failures; raising it finishes sooner but does not cost less.",
            "default": 8
          },
          "language": {
            "title": "Language (hl)",
            "type": "string",
            "description": "Language for text YouTube generates — category names, \"N subscribers\", relative dates. e.g. en, de, es, ja. Titles and descriptions are whatever the creator wrote and do not change.",
            "default": "en"
          },
          "region": {
            "title": "Region (gl)",
            "type": "string",
            "description": "Two-letter country the results are ranked and filtered for, e.g. US, DE, GB, IN. Mostly affects search ordering and availability.",
            "default": "US"
          },
          "maxItems": {
            "title": "Max videos in total (0 = no limit)",
            "minimum": 0,
            "type": "integer",
            "description": "Hard cap across the whole run, applied after channels and playlists are expanded. 0 processes everything.",
            "default": 0
          },
          "proxyConfiguration": {
            "title": "Proxy — RESIDENTIAL required",
            "type": "object",
            "description": "RESIDENTIAL is required and is the default. Measured on this actor: channel and playlist listings work on datacenter IPs, but the per-video request was refused on 20 of 20 with \"Sign in to confirm you're not a bot\". Responses are small — about 4.4 KB per video plus one listing request per channel or playlist — so bandwidth is roughly $0.0001 per video at $8/GB.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": [
                "RESIDENTIAL"
              ]
            }
          },
          "site": {
            "title": "Site",
            "enum": [
              "youtube"
            ],
            "type": "string",
            "description": "Which site config to use. Only 'youtube' today.",
            "default": "youtube"
          }
        }
      },
      "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}