{
  "openapi": "3.0.1",
  "info": {
    "title": "YouTube Scraper: Videos by Search or Channel, No Login",
    "description": "YouTube scraper for videos from search terms, channel tabs (Videos, Shorts, Live) and video links: title, views, length, upload date, channel, hashtags, plus likes, comments and full description when you want them. $1 per 1,000 results, platform usage included.",
    "version": "0.1",
    "x-build-id": "aiOM2PGVD73wbbebX"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/one_dollar_store~youtube-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-one_dollar_store-youtube-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/one_dollar_store~youtube-scraper/runs": {
      "post": {
        "operationId": "runs-sync-one_dollar_store-youtube-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/one_dollar_store~youtube-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-one_dollar_store-youtube-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": {
          "searchQueries": {
            "title": "Search terms",
            "maxItems": 100,
            "type": "array",
            "description": "Words or phrases to search on YouTube, one per line. Each term is searched on its own, with the filters below. Leave empty if you only want channel or video links.",
            "items": {
              "type": "string"
            }
          },
          "channelUrls": {
            "title": "Channels",
            "maxItems": 500,
            "type": "array",
            "description": "Channel links, handles or channel ids, one per line, for example https://www.youtube.com/@mkbhd, @mkbhd or UCBJycsmduvYEL83R_U4JriQ. Returns the videos the channel lists on the tab chosen below, newest first.",
            "items": {
              "type": "string"
            }
          },
          "videoUrls": {
            "title": "Video links",
            "maxItems": 5000,
            "type": "array",
            "description": "Video links or 11 character video ids, one per line (watch, Shorts and youtu.be links all work). Each video comes back with its watch page details: exact views, likes, comment count, upload date and full description.",
            "items": {
              "type": "string"
            }
          },
          "channelContent": {
            "title": "Channel tab",
            "enum": [
              "videos",
              "shorts",
              "streams",
              "videosAndShorts",
              "all"
            ],
            "type": "string",
            "description": "Which channel tab to read for the channels above.",
            "default": "videos"
          },
          "uploadDate": {
            "title": "Upload date (search only)",
            "enum": [
              "any",
              "hour",
              "today",
              "week",
              "month",
              "year"
            ],
            "type": "string",
            "description": "Only search results uploaded within this time.",
            "default": "any"
          },
          "duration": {
            "title": "Length (search only)",
            "enum": [
              "any",
              "short",
              "medium",
              "long"
            ],
            "type": "string",
            "description": "Only search results of this length.",
            "default": "any"
          },
          "sortBy": {
            "title": "Sort by (search only)",
            "enum": [
              "relevance",
              "date",
              "views",
              "rating"
            ],
            "type": "string",
            "description": "Order of the search results.",
            "default": "relevance"
          },
          "contentType": {
            "title": "Type (search only)",
            "enum": [
              "video",
              "shorts",
              "live",
              "movie",
              "all"
            ],
            "type": "string",
            "description": "Kind of search result. Videos returns regular videos (Shorts may still appear); Live returns streams that are live now; Movies returns films. All keeps every video YouTube mixes into the results.",
            "default": "video"
          },
          "includeDetails": {
            "title": "Add watch page details",
            "type": "boolean",
            "description": "Reads each video's watch page data too: exact view count, like count, comment count, exact upload date and the full description. It adds one request per video, so runs take about one extra second per video. The price per result stays the same.",
            "default": false
          },
          "maxItems": {
            "title": "Maximum results",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "The run stops after this many videos in total. Each video is returned once, even when several search terms find it.",
            "default": 100
          },
          "maxPerSource": {
            "title": "Maximum results per search term or channel",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Caps the videos taken from each search term and each channel tab, so one source cannot fill the whole run. 0 means no cap per source.",
            "default": 0
          },
          "country": {
            "title": "Country",
            "pattern": "^[A-Za-z]{2}$",
            "type": "string",
            "description": "Two letter country code that YouTube uses to rank search results, for example US, GB, IN or DE.",
            "default": "US"
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Requests go out from Apify directly first and move to Apify datacenter proxy when YouTube refuses one. Residential proxy is used only as a small capped fallback. You can pick your own proxies instead.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}