{
  "openapi": "3.0.1",
  "info": {
    "title": "YouTube Channel Scraper: YouTube Channel Videos & Stats",
    "description": "Scrape every video of any YouTube channel: title, URL, views, duration, publish date and thumbnail, plus channel stats on every row (subscribers, total views, video count, country, joined date, links). Add Shorts and live streams, sort newest or popular. No API key, no login.",
    "version": "0.1",
    "x-build-id": "aLvic7JoMSRVzK9so"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/xmolodtsov~youtube-channel-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-xmolodtsov-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/xmolodtsov~youtube-channel-scraper/runs": {
      "post": {
        "operationId": "runs-sync-xmolodtsov-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/xmolodtsov~youtube-channel-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-xmolodtsov-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",
        "properties": {
          "startUrls": {
            "title": "YouTube channels",
            "type": "array",
            "description": "Channel URLs, one per line: youtube.com/@handle, /channel/UC…, /c/name or /user/name, with or without a tab such as /videos. Paste many at once with Bulk edit; links to remote URL lists are not read (they are reported as invalid). Have only @handles or channel IDs? Put them in <em>Channel handles or IDs</em> below. Duplicate channels are scraped once.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "channels": {
            "title": "Channel handles or IDs",
            "type": "array",
            "description": "Optional, alongside or instead of the URLs above: @handles (@MrBeast), handles without the @, or UC… channel IDs, one per line.",
            "items": {
              "type": "string"
            }
          },
          "maxResults": {
            "title": "Max videos per channel",
            "minimum": 0,
            "maximum": 999999,
            "type": "integer",
            "description": "How many regular videos to take from each channel's Videos tab (not Shorts, not live streams). 0 skips the Videos tab. <strong>Free Apify plan:</strong> a run returns at most 10 results in total, whatever this value (a limit set by the developer, not by Apify).",
            "default": 50
          },
          "maxResultsShorts": {
            "title": "Max Shorts per channel",
            "minimum": 0,
            "maximum": 999999,
            "type": "integer",
            "description": "How many Shorts to take from each channel's Shorts tab. 0 skips it. The Shorts tab lists title, views and thumbnail only; turn on <em>Add video details</em> for the date, likes, comment count and description.",
            "default": 0
          },
          "maxResultStreams": {
            "title": "Max live streams per channel",
            "minimum": 0,
            "maximum": 999999,
            "type": "integer",
            "description": "How many live streams (live now, upcoming and past) to take from each channel's Live tab. 0 skips it. Channels without a Live tab return none.",
            "default": 0
          },
          "sortVideosBy": {
            "title": "Sort by",
            "enum": [
              "NEWEST",
              "POPULAR",
              "OLDEST"
            ],
            "type": "string",
            "description": "The sort buttons at the top of the channel's Videos, Shorts and Live tabs: newest first, most popular first, or oldest first. With a date filter set, newest first is always used.",
            "default": "NEWEST"
          },
          "oldestPostDate": {
            "title": "Only videos published after",
            "pattern": "^(\\d{4})-(0[1-9]|1[0-2])-(0[1-9]|[12]\\d|3[01])(T[0-2]\\d:[0-5]\\d(:[0-5]\\d)?(\\.\\d+)?Z?)?$|^[+-]?\\s*(\\d+)\\s*(minute|hour|day|week|month|year)s?$",
            "type": "string",
            "description": "Optional. A date (2026-01-31) or an age such as <code>30 days</code>: <code>1 day</code> keeps today's videos, <code>2 days</code> yesterday's and today's. Works with newest-first order only (it is switched on automatically) and stops each tab at the first video that is certainly older. Without details the Actor only sees YouTube's relative labels (\"3 weeks ago\", \"1 year ago\"), so a video can be kept that is older by up to the label's unit — a week, a month or a year. <strong>For precise cut-offs turn on <em>Add video details</em></strong>: it uses the upload day (YouTube's US-Pacific date, one day of slack). The Shorts tab shows no dates, so Shorts are filtered only with details on."
          },
          "includeVideoDetails": {
            "title": "Add video details",
            "type": "boolean",
            "description": "Opens each video's watch page for the exact view count, likes, comment count, upload date (YYYY-MM-DD), full description and hashtags. One extra request per video, so runs are roughly 10× slower; the price per result stays the same.",
            "default": false
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Optional. Apify datacenter proxy by default, which works for YouTube channel pages. Change it only to use residential proxies or your own proxies.",
            "default": {
              "useApifyProxy": 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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}