FREE-BUFF 1.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1055) hide show
  1. free_buff-1.0.dist-info/METADATA +2576 -0
  2. free_buff-1.0.dist-info/RECORD +1055 -0
  3. free_buff-1.0.dist-info/WHEEL +4 -0
  4. free_buff-1.0.dist-info/entry_points.txt +5 -0
  5. free_buff-1.0.dist-info/licenses/LICENSE +24 -0
  6. freestuff/YoutubeDL.py +4557 -0
  7. freestuff/__init__.py +1114 -0
  8. freestuff/__main__.py +17 -0
  9. freestuff/__pyinstaller/__init__.py +5 -0
  10. freestuff/__pyinstaller/hook-freestuff.py +37 -0
  11. freestuff/aes.py +552 -0
  12. freestuff/cache.py +91 -0
  13. freestuff/compat/__init__.py +64 -0
  14. freestuff/compat/_deprecated.py +21 -0
  15. freestuff/compat/_legacy.py +115 -0
  16. freestuff/compat/compat_utils.py +83 -0
  17. freestuff/compat/imghdr.py +22 -0
  18. freestuff/compat/shutil.py +30 -0
  19. freestuff/compat/urllib/__init__.py +10 -0
  20. freestuff/compat/urllib/request.py +36 -0
  21. freestuff/cookies.py +1420 -0
  22. freestuff/dependencies/Cryptodome.py +38 -0
  23. freestuff/dependencies/__init__.py +102 -0
  24. freestuff/downloader/__init__.py +130 -0
  25. freestuff/downloader/bunnycdn.py +50 -0
  26. freestuff/downloader/common.py +520 -0
  27. freestuff/downloader/dash.py +95 -0
  28. freestuff/downloader/external.py +595 -0
  29. freestuff/downloader/f4m.py +427 -0
  30. freestuff/downloader/fc2.py +46 -0
  31. freestuff/downloader/fragment.py +526 -0
  32. freestuff/downloader/hls.py +409 -0
  33. freestuff/downloader/http.py +376 -0
  34. freestuff/downloader/ism.py +283 -0
  35. freestuff/downloader/mhtml.py +174 -0
  36. freestuff/downloader/niconico.py +90 -0
  37. freestuff/downloader/rtmp.py +212 -0
  38. freestuff/downloader/soop.py +61 -0
  39. freestuff/downloader/websocket.py +53 -0
  40. freestuff/downloader/youtube_live_chat.py +228 -0
  41. freestuff/extractor/__init__.py +54 -0
  42. freestuff/extractor/_extractors.py +2472 -0
  43. freestuff/extractor/abc.py +443 -0
  44. freestuff/extractor/abcnews.py +153 -0
  45. freestuff/extractor/abcotvs.py +129 -0
  46. freestuff/extractor/abematv.py +496 -0
  47. freestuff/extractor/academicearth.py +39 -0
  48. freestuff/extractor/acast.py +149 -0
  49. freestuff/extractor/acfun.py +200 -0
  50. freestuff/extractor/adn.py +329 -0
  51. freestuff/extractor/adobeconnect.py +33 -0
  52. freestuff/extractor/adobepass.py +1878 -0
  53. freestuff/extractor/adobetv.py +100 -0
  54. freestuff/extractor/adultswim.py +200 -0
  55. freestuff/extractor/aenetworks.py +455 -0
  56. freestuff/extractor/aeonco.py +74 -0
  57. freestuff/extractor/afreecatv.py +475 -0
  58. freestuff/extractor/agalega.py +91 -0
  59. freestuff/extractor/agora.py +248 -0
  60. freestuff/extractor/aitube.py +60 -0
  61. freestuff/extractor/alibaba.py +42 -0
  62. freestuff/extractor/aliexpress.py +49 -0
  63. freestuff/extractor/aljazeera.py +83 -0
  64. freestuff/extractor/allocine.py +124 -0
  65. freestuff/extractor/allstar.py +252 -0
  66. freestuff/extractor/alphaporno.py +75 -0
  67. freestuff/extractor/altcensored.py +104 -0
  68. freestuff/extractor/alura.py +163 -0
  69. freestuff/extractor/amadeustv.py +77 -0
  70. freestuff/extractor/amara.py +100 -0
  71. freestuff/extractor/amazon.py +170 -0
  72. freestuff/extractor/amazonminitv.py +294 -0
  73. freestuff/extractor/amcnetworks.py +61 -0
  74. freestuff/extractor/americastestkitchen.py +215 -0
  75. freestuff/extractor/amp.py +101 -0
  76. freestuff/extractor/angel.py +56 -0
  77. freestuff/extractor/antenna.py +143 -0
  78. freestuff/extractor/anvato.py +357 -0
  79. freestuff/extractor/aol.py +133 -0
  80. freestuff/extractor/apa.py +90 -0
  81. freestuff/extractor/aparat.py +88 -0
  82. freestuff/extractor/appleconnect.py +125 -0
  83. freestuff/extractor/applepodcasts.py +79 -0
  84. freestuff/extractor/archiveorg.py +1134 -0
  85. freestuff/extractor/arcpublishing.py +179 -0
  86. freestuff/extractor/ard.py +765 -0
  87. freestuff/extractor/arnes.py +96 -0
  88. freestuff/extractor/art19.py +303 -0
  89. freestuff/extractor/arte.py +406 -0
  90. freestuff/extractor/asobichannel.py +168 -0
  91. freestuff/extractor/asobistage.py +155 -0
  92. freestuff/extractor/atresplayer.py +152 -0
  93. freestuff/extractor/atscaleconf.py +34 -0
  94. freestuff/extractor/audimedia.py +89 -0
  95. freestuff/extractor/audioboom.py +57 -0
  96. freestuff/extractor/audiodraft.py +94 -0
  97. freestuff/extractor/audiomack.py +146 -0
  98. freestuff/extractor/audius.py +273 -0
  99. freestuff/extractor/aws.py +75 -0
  100. freestuff/extractor/azmedien.py +63 -0
  101. freestuff/extractor/baidu.py +52 -0
  102. freestuff/extractor/banbye.py +226 -0
  103. freestuff/extractor/bandcamp.py +544 -0
  104. freestuff/extractor/bandlab.py +437 -0
  105. freestuff/extractor/bannedvideo.py +155 -0
  106. freestuff/extractor/bbc.py +1841 -0
  107. freestuff/extractor/beacon.py +68 -0
  108. freestuff/extractor/beatport.py +96 -0
  109. freestuff/extractor/beeg.py +89 -0
  110. freestuff/extractor/behindkink.py +42 -0
  111. freestuff/extractor/berufetv.py +70 -0
  112. freestuff/extractor/bet.py +47 -0
  113. freestuff/extractor/bfi.py +35 -0
  114. freestuff/extractor/bfmtv.py +143 -0
  115. freestuff/extractor/bibeltv.py +196 -0
  116. freestuff/extractor/bigo.py +57 -0
  117. freestuff/extractor/bild.py +63 -0
  118. freestuff/extractor/bilibili.py +2670 -0
  119. freestuff/extractor/biobiochiletv.py +83 -0
  120. freestuff/extractor/bitchute.py +315 -0
  121. freestuff/extractor/bitmovin.py +74 -0
  122. freestuff/extractor/blackboardcollaborate.py +179 -0
  123. freestuff/extractor/bleacherreport.py +110 -0
  124. freestuff/extractor/blerp.py +166 -0
  125. freestuff/extractor/blogger.py +56 -0
  126. freestuff/extractor/bloomberg.py +77 -0
  127. freestuff/extractor/bluesky.py +393 -0
  128. freestuff/extractor/bongacams.py +69 -0
  129. freestuff/extractor/boosty.py +254 -0
  130. freestuff/extractor/bostonglobe.py +67 -0
  131. freestuff/extractor/box.py +118 -0
  132. freestuff/extractor/boxcast.py +98 -0
  133. freestuff/extractor/bpb.py +157 -0
  134. freestuff/extractor/br.py +166 -0
  135. freestuff/extractor/brainpop.py +318 -0
  136. freestuff/extractor/breitbart.py +34 -0
  137. freestuff/extractor/brightcove.py +948 -0
  138. freestuff/extractor/brilliantpala.py +136 -0
  139. freestuff/extractor/btvplus.py +73 -0
  140. freestuff/extractor/bundesliga.py +34 -0
  141. freestuff/extractor/bundestag.py +124 -0
  142. freestuff/extractor/bunnycdn.py +195 -0
  143. freestuff/extractor/businessinsider.py +45 -0
  144. freestuff/extractor/buzzfeed.py +95 -0
  145. freestuff/extractor/byutv.py +104 -0
  146. freestuff/extractor/c56.py +59 -0
  147. freestuff/extractor/caltrans.py +37 -0
  148. freestuff/extractor/cam4.py +31 -0
  149. freestuff/extractor/camfm.py +85 -0
  150. freestuff/extractor/cammodels.py +77 -0
  151. freestuff/extractor/camsoda.py +57 -0
  152. freestuff/extractor/camtasia.py +71 -0
  153. freestuff/extractor/canal1.py +39 -0
  154. freestuff/extractor/canalalpha.py +107 -0
  155. freestuff/extractor/canalc2.py +68 -0
  156. freestuff/extractor/canalplus.py +109 -0
  157. freestuff/extractor/canalsurmas.py +84 -0
  158. freestuff/extractor/caracoltv.py +136 -0
  159. freestuff/extractor/cbc.py +1105 -0
  160. freestuff/extractor/cbs.py +280 -0
  161. freestuff/extractor/cbsnews.py +434 -0
  162. freestuff/extractor/cbssports.py +111 -0
  163. freestuff/extractor/ccc.py +133 -0
  164. freestuff/extractor/ccma.py +180 -0
  165. freestuff/extractor/cctv.py +200 -0
  166. freestuff/extractor/cda.py +418 -0
  167. freestuff/extractor/cellebrite.py +38 -0
  168. freestuff/extractor/ceskatelevize.py +289 -0
  169. freestuff/extractor/cgtn.py +65 -0
  170. freestuff/extractor/charlierose.py +54 -0
  171. freestuff/extractor/chaturbate.py +153 -0
  172. freestuff/extractor/chilloutzone.py +123 -0
  173. freestuff/extractor/chzzk.py +205 -0
  174. freestuff/extractor/cinemax.py +25 -0
  175. freestuff/extractor/cinetecamilano.py +62 -0
  176. freestuff/extractor/cineverse.py +140 -0
  177. freestuff/extractor/ciscolive.py +145 -0
  178. freestuff/extractor/ciscowebex.py +106 -0
  179. freestuff/extractor/cjsw.py +67 -0
  180. freestuff/extractor/clipchamp.py +61 -0
  181. freestuff/extractor/cliprs.py +31 -0
  182. freestuff/extractor/closertotruth.py +89 -0
  183. freestuff/extractor/cloudflarestream.py +96 -0
  184. freestuff/extractor/cloudycdn.py +110 -0
  185. freestuff/extractor/clubic.py +53 -0
  186. freestuff/extractor/clyp.py +99 -0
  187. freestuff/extractor/cnbc.py +97 -0
  188. freestuff/extractor/cnn.py +278 -0
  189. freestuff/extractor/comedycentral.py +27 -0
  190. freestuff/extractor/common.py +4176 -0
  191. freestuff/extractor/commonmistakes.py +58 -0
  192. freestuff/extractor/commonprotocols.py +42 -0
  193. freestuff/extractor/condenast.py +265 -0
  194. freestuff/extractor/corus.py +154 -0
  195. freestuff/extractor/coub.py +136 -0
  196. freestuff/extractor/cozytv.py +37 -0
  197. freestuff/extractor/cpac.py +134 -0
  198. freestuff/extractor/cracked.py +88 -0
  199. freestuff/extractor/craftsy.py +75 -0
  200. freestuff/extractor/croatianfilm.py +79 -0
  201. freestuff/extractor/crooksandliars.py +69 -0
  202. freestuff/extractor/crowdbunker.py +112 -0
  203. freestuff/extractor/crtvg.py +53 -0
  204. freestuff/extractor/cspan.py +286 -0
  205. freestuff/extractor/ctsnews.py +84 -0
  206. freestuff/extractor/ctvnews.py +182 -0
  207. freestuff/extractor/cultureunplugged.py +72 -0
  208. freestuff/extractor/curiositystream.py +202 -0
  209. freestuff/extractor/cybrary.py +144 -0
  210. freestuff/extractor/dacast.py +182 -0
  211. freestuff/extractor/dailymail.py +84 -0
  212. freestuff/extractor/dailymotion.py +664 -0
  213. freestuff/extractor/dailywire.py +113 -0
  214. freestuff/extractor/damtomo.py +107 -0
  215. freestuff/extractor/dangalplay.py +210 -0
  216. freestuff/extractor/daum.py +256 -0
  217. freestuff/extractor/daystar.py +47 -0
  218. freestuff/extractor/dbtv.py +61 -0
  219. freestuff/extractor/dctp.py +101 -0
  220. freestuff/extractor/democracynow.py +91 -0
  221. freestuff/extractor/detik.py +159 -0
  222. freestuff/extractor/deuxm.py +76 -0
  223. freestuff/extractor/dfb.py +52 -0
  224. freestuff/extractor/dhm.py +58 -0
  225. freestuff/extractor/digitalconcerthall.py +285 -0
  226. freestuff/extractor/digiteka.py +81 -0
  227. freestuff/extractor/digiview.py +130 -0
  228. freestuff/extractor/discogs.py +35 -0
  229. freestuff/extractor/disney.py +160 -0
  230. freestuff/extractor/dispeak.py +128 -0
  231. freestuff/extractor/dlf.py +192 -0
  232. freestuff/extractor/dlive.py +92 -0
  233. freestuff/extractor/douyutv.py +308 -0
  234. freestuff/extractor/dplay.py +1306 -0
  235. freestuff/extractor/drbonanza.py +54 -0
  236. freestuff/extractor/dreisat.py +124 -0
  237. freestuff/extractor/dropbox.py +111 -0
  238. freestuff/extractor/dropout.py +224 -0
  239. freestuff/extractor/drtalks.py +51 -0
  240. freestuff/extractor/drtuber.py +104 -0
  241. freestuff/extractor/drtv.py +400 -0
  242. freestuff/extractor/dtube.py +79 -0
  243. freestuff/extractor/dumpert.py +114 -0
  244. freestuff/extractor/duoplay.py +138 -0
  245. freestuff/extractor/dvtv.py +177 -0
  246. freestuff/extractor/dw.py +111 -0
  247. freestuff/extractor/ebaumsworld.py +31 -0
  248. freestuff/extractor/ebay.py +36 -0
  249. freestuff/extractor/egghead.py +133 -0
  250. freestuff/extractor/eggs.py +155 -0
  251. freestuff/extractor/elementorembed.py +72 -0
  252. freestuff/extractor/elonet.py +64 -0
  253. freestuff/extractor/elpais.py +92 -0
  254. freestuff/extractor/eltrecetv.py +62 -0
  255. freestuff/extractor/embedly.py +109 -0
  256. freestuff/extractor/epicon.py +116 -0
  257. freestuff/extractor/epidemicsound.py +124 -0
  258. freestuff/extractor/eplus.py +205 -0
  259. freestuff/extractor/epoch.py +55 -0
  260. freestuff/extractor/eporner.py +134 -0
  261. freestuff/extractor/erocast.py +63 -0
  262. freestuff/extractor/eroprofile.py +122 -0
  263. freestuff/extractor/err.py +292 -0
  264. freestuff/extractor/ertgr.py +310 -0
  265. freestuff/extractor/espn.py +427 -0
  266. freestuff/extractor/ettutv.py +60 -0
  267. freestuff/extractor/europa.py +190 -0
  268. freestuff/extractor/europeantour.py +34 -0
  269. freestuff/extractor/eurosport.py +165 -0
  270. freestuff/extractor/euscreen.py +59 -0
  271. freestuff/extractor/expressen.py +96 -0
  272. freestuff/extractor/extractors.py +43 -0
  273. freestuff/extractor/facebook.py +1189 -0
  274. freestuff/extractor/fancode.py +174 -0
  275. freestuff/extractor/fathom.py +54 -0
  276. freestuff/extractor/faulio.py +237 -0
  277. freestuff/extractor/faz.py +89 -0
  278. freestuff/extractor/fc2.py +299 -0
  279. freestuff/extractor/fczenit.py +51 -0
  280. freestuff/extractor/fifa.py +82 -0
  281. freestuff/extractor/filmarchiv.py +52 -0
  282. freestuff/extractor/filmon.py +170 -0
  283. freestuff/extractor/filmweb.py +38 -0
  284. freestuff/extractor/firsttv.py +171 -0
  285. freestuff/extractor/fivetv.py +85 -0
  286. freestuff/extractor/flextv.py +77 -0
  287. freestuff/extractor/flickr.py +112 -0
  288. freestuff/extractor/floatplane.py +387 -0
  289. freestuff/extractor/folketinget.py +75 -0
  290. freestuff/extractor/footyroom.py +38 -0
  291. freestuff/extractor/formula1.py +24 -0
  292. freestuff/extractor/fourtube.py +301 -0
  293. freestuff/extractor/fox.py +174 -0
  294. freestuff/extractor/fox9.py +38 -0
  295. freestuff/extractor/foxnews.py +185 -0
  296. freestuff/extractor/foxsports.py +52 -0
  297. freestuff/extractor/fptplay.py +117 -0
  298. freestuff/extractor/francaisfacile.py +76 -0
  299. freestuff/extractor/francetv.py +489 -0
  300. freestuff/extractor/freesound.py +77 -0
  301. freestuff/extractor/freespeech.py +29 -0
  302. freestuff/extractor/freetv.py +139 -0
  303. freestuff/extractor/frontendmasters.py +249 -0
  304. freestuff/extractor/frontro.py +101 -0
  305. freestuff/extractor/funk.py +43 -0
  306. freestuff/extractor/funker530.py +80 -0
  307. freestuff/extractor/fuyintv.py +30 -0
  308. freestuff/extractor/gab.py +83 -0
  309. freestuff/extractor/gaia.py +120 -0
  310. freestuff/extractor/gamedevtv.py +141 -0
  311. freestuff/extractor/gamejolt.py +537 -0
  312. freestuff/extractor/gamespot.py +76 -0
  313. freestuff/extractor/gamestar.py +60 -0
  314. freestuff/extractor/gaskrank.py +97 -0
  315. freestuff/extractor/gazeta.py +44 -0
  316. freestuff/extractor/gbnews.py +113 -0
  317. freestuff/extractor/gdcvault.py +214 -0
  318. freestuff/extractor/gedidigital.py +198 -0
  319. freestuff/extractor/generic.py +1303 -0
  320. freestuff/extractor/genericembeds.py +114 -0
  321. freestuff/extractor/genius.py +145 -0
  322. freestuff/extractor/germanupa.py +91 -0
  323. freestuff/extractor/getcourseru.py +188 -0
  324. freestuff/extractor/gettr.py +206 -0
  325. freestuff/extractor/giantbomb.py +85 -0
  326. freestuff/extractor/glide.py +38 -0
  327. freestuff/extractor/globalplayer.py +254 -0
  328. freestuff/extractor/globo.py +239 -0
  329. freestuff/extractor/glomex.py +233 -0
  330. freestuff/extractor/gmanetwork.py +83 -0
  331. freestuff/extractor/go.py +305 -0
  332. freestuff/extractor/godresource.py +79 -0
  333. freestuff/extractor/godtube.py +55 -0
  334. freestuff/extractor/golem.py +66 -0
  335. freestuff/extractor/goodgame.py +69 -0
  336. freestuff/extractor/googledrive.py +290 -0
  337. freestuff/extractor/googlesearch.py +38 -0
  338. freestuff/extractor/goplay.py +441 -0
  339. freestuff/extractor/gopro.py +105 -0
  340. freestuff/extractor/gotostage.py +66 -0
  341. freestuff/extractor/graspop.py +32 -0
  342. freestuff/extractor/gronkh.py +120 -0
  343. freestuff/extractor/groupon.py +63 -0
  344. freestuff/extractor/harpodeon.py +70 -0
  345. freestuff/extractor/hbo.py +172 -0
  346. freestuff/extractor/hearthisat.py +130 -0
  347. freestuff/extractor/heise.py +207 -0
  348. freestuff/extractor/hellporno.py +72 -0
  349. freestuff/extractor/hgtv.py +37 -0
  350. freestuff/extractor/hidive.py +119 -0
  351. freestuff/extractor/historicfilms.py +45 -0
  352. freestuff/extractor/hitrecord.py +65 -0
  353. freestuff/extractor/hollywoodreporter.py +72 -0
  354. freestuff/extractor/holodex.py +100 -0
  355. freestuff/extractor/hotnewhiphop.py +62 -0
  356. freestuff/extractor/hotstar.py +482 -0
  357. freestuff/extractor/hrefli.py +15 -0
  358. freestuff/extractor/hrfensehen.py +88 -0
  359. freestuff/extractor/hrti.py +200 -0
  360. freestuff/extractor/hse.py +93 -0
  361. freestuff/extractor/huajiao.py +53 -0
  362. freestuff/extractor/huffpost.py +90 -0
  363. freestuff/extractor/hungama.py +201 -0
  364. freestuff/extractor/huya.py +243 -0
  365. freestuff/extractor/hypem.py +47 -0
  366. freestuff/extractor/hypergryph.py +66 -0
  367. freestuff/extractor/hytale.py +59 -0
  368. freestuff/extractor/icareus.py +179 -0
  369. freestuff/extractor/ichinanalive.py +215 -0
  370. freestuff/extractor/idagio.py +262 -0
  371. freestuff/extractor/ign.py +396 -0
  372. freestuff/extractor/iheart.py +94 -0
  373. freestuff/extractor/ilpost.py +68 -0
  374. freestuff/extractor/iltalehti.py +51 -0
  375. freestuff/extractor/imdb.py +144 -0
  376. freestuff/extractor/imggaming.py +126 -0
  377. freestuff/extractor/imgur.py +428 -0
  378. freestuff/extractor/ina.py +84 -0
  379. freestuff/extractor/inc.py +57 -0
  380. freestuff/extractor/indavideo.py +130 -0
  381. freestuff/extractor/infoq.py +130 -0
  382. freestuff/extractor/instagram.py +761 -0
  383. freestuff/extractor/internazionale.py +75 -0
  384. freestuff/extractor/iprima.py +269 -0
  385. freestuff/extractor/iqiyi.py +579 -0
  386. freestuff/extractor/islamchannel.py +81 -0
  387. freestuff/extractor/israelnationalnews.py +50 -0
  388. freestuff/extractor/itprotv.py +138 -0
  389. freestuff/extractor/itv.py +267 -0
  390. freestuff/extractor/ivi.py +253 -0
  391. freestuff/extractor/ivideon.py +75 -0
  392. freestuff/extractor/ivoox.py +78 -0
  393. freestuff/extractor/iwara.py +305 -0
  394. freestuff/extractor/ixigua.py +83 -0
  395. freestuff/extractor/jamendo.py +216 -0
  396. freestuff/extractor/japandiet.py +277 -0
  397. freestuff/extractor/jeuxvideo.py +52 -0
  398. freestuff/extractor/jiosaavn.py +412 -0
  399. freestuff/extractor/jixie.py +47 -0
  400. freestuff/extractor/joj.py +115 -0
  401. freestuff/extractor/jove.py +73 -0
  402. freestuff/extractor/jstream.py +73 -0
  403. freestuff/extractor/jtbc.py +156 -0
  404. freestuff/extractor/jwplatform.py +102 -0
  405. freestuff/extractor/kakao.py +152 -0
  406. freestuff/extractor/kaltura.py +579 -0
  407. freestuff/extractor/kankanews.py +49 -0
  408. freestuff/extractor/karaoketv.py +62 -0
  409. freestuff/extractor/kelbyone.py +81 -0
  410. freestuff/extractor/kenh14.py +160 -0
  411. freestuff/extractor/khanacademy.py +153 -0
  412. freestuff/extractor/kick.py +258 -0
  413. freestuff/extractor/kicker.py +55 -0
  414. freestuff/extractor/kickstarter.py +68 -0
  415. freestuff/extractor/kika.py +174 -0
  416. freestuff/extractor/kinopoisk.py +63 -0
  417. freestuff/extractor/kommunetv.py +31 -0
  418. freestuff/extractor/kompas.py +26 -0
  419. freestuff/extractor/krasview.py +58 -0
  420. freestuff/extractor/kth.py +27 -0
  421. freestuff/extractor/ku6.py +30 -0
  422. freestuff/extractor/kukululive.py +140 -0
  423. freestuff/extractor/kuwo.py +352 -0
  424. freestuff/extractor/la7.py +234 -0
  425. freestuff/extractor/laracasts.py +114 -0
  426. freestuff/extractor/lastfm.py +129 -0
  427. freestuff/extractor/laxarxames.py +73 -0
  428. freestuff/extractor/lbry.py +443 -0
  429. freestuff/extractor/lci.py +49 -0
  430. freestuff/extractor/lcp.py +72 -0
  431. freestuff/extractor/learningonscreen.py +72 -0
  432. freestuff/extractor/lecture2go.py +67 -0
  433. freestuff/extractor/lecturio.py +234 -0
  434. freestuff/extractor/leeco.py +245 -0
  435. freestuff/extractor/lefigaro.py +136 -0
  436. freestuff/extractor/lego.py +141 -0
  437. freestuff/extractor/lemonde.py +56 -0
  438. freestuff/extractor/lenta.py +51 -0
  439. freestuff/extractor/libraryofcongress.py +147 -0
  440. freestuff/extractor/libsyn.py +111 -0
  441. freestuff/extractor/lifenews.py +231 -0
  442. freestuff/extractor/likee.py +182 -0
  443. freestuff/extractor/linkedin.py +353 -0
  444. freestuff/extractor/liputan6.py +64 -0
  445. freestuff/extractor/listennotes.py +84 -0
  446. freestuff/extractor/litv.py +117 -0
  447. freestuff/extractor/livejournal.py +39 -0
  448. freestuff/extractor/livestreamfails.py +37 -0
  449. freestuff/extractor/lnk.py +87 -0
  450. freestuff/extractor/locipo.py +209 -0
  451. freestuff/extractor/loco.py +159 -0
  452. freestuff/extractor/loom.py +484 -0
  453. freestuff/extractor/lovehomeporn.py +33 -0
  454. freestuff/extractor/lrt.py +167 -0
  455. freestuff/extractor/lsm.py +299 -0
  456. freestuff/extractor/lumni.py +23 -0
  457. freestuff/extractor/maariv.py +62 -0
  458. freestuff/extractor/magellantv.py +72 -0
  459. freestuff/extractor/magentamusik.py +62 -0
  460. freestuff/extractor/mailru.py +337 -0
  461. freestuff/extractor/mainstreaming.py +221 -0
  462. freestuff/extractor/mangomolo.py +81 -0
  463. freestuff/extractor/manyvids.py +108 -0
  464. freestuff/extractor/maoritv.py +28 -0
  465. freestuff/extractor/markiza.py +123 -0
  466. freestuff/extractor/massengeschmacktv.py +72 -0
  467. freestuff/extractor/masters.py +37 -0
  468. freestuff/extractor/matchitv.py +38 -0
  469. freestuff/extractor/matchtv.py +35 -0
  470. freestuff/extractor/mave.py +190 -0
  471. freestuff/extractor/mbn.py +89 -0
  472. freestuff/extractor/mdr.py +140 -0
  473. freestuff/extractor/medaltv.py +124 -0
  474. freestuff/extractor/mediaite.py +104 -0
  475. freestuff/extractor/mediaklikk.py +113 -0
  476. freestuff/extractor/medialaan.py +224 -0
  477. freestuff/extractor/mediaset.py +320 -0
  478. freestuff/extractor/mediasite.py +414 -0
  479. freestuff/extractor/mediastream.py +226 -0
  480. freestuff/extractor/mediaworksnz.py +103 -0
  481. freestuff/extractor/medici.py +153 -0
  482. freestuff/extractor/megaphone.py +46 -0
  483. freestuff/extractor/megatvcom.py +172 -0
  484. freestuff/extractor/meipai.py +99 -0
  485. freestuff/extractor/melonvod.py +68 -0
  486. freestuff/extractor/metacritic.py +62 -0
  487. freestuff/extractor/mgtv.py +173 -0
  488. freestuff/extractor/microsoftembed.py +358 -0
  489. freestuff/extractor/minds.py +192 -0
  490. freestuff/extractor/mir24tv.py +37 -0
  491. freestuff/extractor/mirrativ.py +118 -0
  492. freestuff/extractor/mirrorcouk.py +98 -0
  493. freestuff/extractor/mit.py +130 -0
  494. freestuff/extractor/mixch.py +171 -0
  495. freestuff/extractor/mixcloud.py +369 -0
  496. freestuff/extractor/mixlr.py +134 -0
  497. freestuff/extractor/mlb.py +526 -0
  498. freestuff/extractor/mlssoccer.py +115 -0
  499. freestuff/extractor/mocha.py +64 -0
  500. freestuff/extractor/mojevideo.py +121 -0
  501. freestuff/extractor/monstercat.py +96 -0
  502. freestuff/extractor/motorsport.py +51 -0
  503. freestuff/extractor/moviepilot.py +97 -0
  504. freestuff/extractor/movingimage.py +50 -0
  505. freestuff/extractor/msn.py +215 -0
  506. freestuff/extractor/mtv.py +268 -0
  507. freestuff/extractor/muenchentv.py +72 -0
  508. freestuff/extractor/murrtube.py +161 -0
  509. freestuff/extractor/museai.py +112 -0
  510. freestuff/extractor/musescore.py +72 -0
  511. freestuff/extractor/mux.py +92 -0
  512. freestuff/extractor/mx3.py +171 -0
  513. freestuff/extractor/mxplayer.py +450 -0
  514. freestuff/extractor/myspace.py +195 -0
  515. freestuff/extractor/myspass.py +91 -0
  516. freestuff/extractor/myvideoge.py +81 -0
  517. freestuff/extractor/myvidster.py +27 -0
  518. freestuff/extractor/mzaalo.py +95 -0
  519. freestuff/extractor/n1.py +202 -0
  520. freestuff/extractor/nascar.py +60 -0
  521. freestuff/extractor/nate.py +120 -0
  522. freestuff/extractor/nationalgeographic.py +23 -0
  523. freestuff/extractor/naver.py +284 -0
  524. freestuff/extractor/nba.py +423 -0
  525. freestuff/extractor/nbc.py +1108 -0
  526. freestuff/extractor/ndr.py +471 -0
  527. freestuff/extractor/ndtv.py +107 -0
  528. freestuff/extractor/nebula.py +541 -0
  529. freestuff/extractor/nekohacker.py +214 -0
  530. freestuff/extractor/nest.py +117 -0
  531. freestuff/extractor/netapp.py +79 -0
  532. freestuff/extractor/neteasemusic.py +671 -0
  533. freestuff/extractor/netzkino.py +60 -0
  534. freestuff/extractor/newgrounds.py +311 -0
  535. freestuff/extractor/newspicks.py +77 -0
  536. freestuff/extractor/newsy.py +47 -0
  537. freestuff/extractor/nexx.py +519 -0
  538. freestuff/extractor/nfb.py +293 -0
  539. freestuff/extractor/nfhsnetwork.py +135 -0
  540. freestuff/extractor/nfl.py +396 -0
  541. freestuff/extractor/nhk.py +920 -0
  542. freestuff/extractor/nhl.py +123 -0
  543. freestuff/extractor/nick.py +48 -0
  544. freestuff/extractor/niconico.py +1082 -0
  545. freestuff/extractor/niconicochannelplus.py +426 -0
  546. freestuff/extractor/ninaprotocol.py +225 -0
  547. freestuff/extractor/ninecninemedia.py +130 -0
  548. freestuff/extractor/ninegag.py +147 -0
  549. freestuff/extractor/ninenews.py +72 -0
  550. freestuff/extractor/ninenow.py +141 -0
  551. freestuff/extractor/nintendo.py +131 -0
  552. freestuff/extractor/nitter.py +361 -0
  553. freestuff/extractor/nobelprize.py +57 -0
  554. freestuff/extractor/noice.py +116 -0
  555. freestuff/extractor/nonktube.py +36 -0
  556. freestuff/extractor/noodlemagazine.py +74 -0
  557. freestuff/extractor/nosnl.py +115 -0
  558. freestuff/extractor/nova.py +307 -0
  559. freestuff/extractor/novaplay.py +67 -0
  560. freestuff/extractor/nowcanal.py +37 -0
  561. freestuff/extractor/nowness.py +141 -0
  562. freestuff/extractor/noz.py +84 -0
  563. freestuff/extractor/npo.py +612 -0
  564. freestuff/extractor/npr.py +132 -0
  565. freestuff/extractor/nrk.py +901 -0
  566. freestuff/extractor/nrl.py +27 -0
  567. freestuff/extractor/nts.py +76 -0
  568. freestuff/extractor/ntvcojp.py +82 -0
  569. freestuff/extractor/ntvde.py +83 -0
  570. freestuff/extractor/ntvru.py +179 -0
  571. freestuff/extractor/nubilesporn.py +98 -0
  572. freestuff/extractor/nuevo.py +32 -0
  573. freestuff/extractor/nuvid.py +99 -0
  574. freestuff/extractor/nytimes.py +437 -0
  575. freestuff/extractor/nzherald.py +119 -0
  576. freestuff/extractor/nzonscreen.py +93 -0
  577. freestuff/extractor/nzz.py +32 -0
  578. freestuff/extractor/odkmedia.py +105 -0
  579. freestuff/extractor/odnoklassniki.py +451 -0
  580. freestuff/extractor/oftv.py +54 -0
  581. freestuff/extractor/oktoberfesttv.py +45 -0
  582. freestuff/extractor/olympics.py +151 -0
  583. freestuff/extractor/omnyfm.py +272 -0
  584. freestuff/extractor/on24.py +94 -0
  585. freestuff/extractor/ondemandkorea.py +169 -0
  586. freestuff/extractor/onefootball.py +51 -0
  587. freestuff/extractor/onenewsnz.py +107 -0
  588. freestuff/extractor/oneplace.py +43 -0
  589. freestuff/extractor/onet.py +259 -0
  590. freestuff/extractor/onsen.py +165 -0
  591. freestuff/extractor/opencast.py +188 -0
  592. freestuff/extractor/openload.py +243 -0
  593. freestuff/extractor/openrec.py +728 -0
  594. freestuff/extractor/orf.py +558 -0
  595. freestuff/extractor/outsidetv.py +25 -0
  596. freestuff/extractor/owncloud.py +80 -0
  597. freestuff/extractor/packtpub.py +153 -0
  598. freestuff/extractor/palcomp3.py +142 -0
  599. freestuff/extractor/pandatv.py +83 -0
  600. freestuff/extractor/panopto.py +598 -0
  601. freestuff/extractor/parler.py +89 -0
  602. freestuff/extractor/parlview.py +63 -0
  603. freestuff/extractor/parti.py +95 -0
  604. freestuff/extractor/patreon.py +748 -0
  605. freestuff/extractor/pbs.py +814 -0
  606. freestuff/extractor/pearvideo.py +68 -0
  607. freestuff/extractor/peekvids.py +188 -0
  608. freestuff/extractor/peertube.py +1772 -0
  609. freestuff/extractor/peertv.py +52 -0
  610. freestuff/extractor/peloton.py +215 -0
  611. freestuff/extractor/performgroup.py +74 -0
  612. freestuff/extractor/periscope.py +181 -0
  613. freestuff/extractor/pgatour.py +47 -0
  614. freestuff/extractor/philharmoniedeparis.py +96 -0
  615. freestuff/extractor/phoenix.py +98 -0
  616. freestuff/extractor/photobucket.py +43 -0
  617. freestuff/extractor/pialive.py +122 -0
  618. freestuff/extractor/piapro.py +112 -0
  619. freestuff/extractor/picarto.py +168 -0
  620. freestuff/extractor/piksel.py +177 -0
  621. freestuff/extractor/pinkbike.py +93 -0
  622. freestuff/extractor/pinterest.py +266 -0
  623. freestuff/extractor/platzi.py +211 -0
  624. freestuff/extractor/playerfm.py +70 -0
  625. freestuff/extractor/playsuisse.py +292 -0
  626. freestuff/extractor/playtvak.py +184 -0
  627. freestuff/extractor/pluralsight.py +484 -0
  628. freestuff/extractor/plutotv.py +192 -0
  629. freestuff/extractor/plyr.py +104 -0
  630. freestuff/extractor/podbayfm.py +88 -0
  631. freestuff/extractor/podchaser.py +114 -0
  632. freestuff/extractor/podomatic.py +73 -0
  633. freestuff/extractor/pokergo.py +109 -0
  634. freestuff/extractor/polsatgo.py +86 -0
  635. freestuff/extractor/polskieradio.py +609 -0
  636. freestuff/extractor/popcorntimes.py +92 -0
  637. freestuff/extractor/popcorntv.py +72 -0
  638. freestuff/extractor/pornbox.py +113 -0
  639. freestuff/extractor/pornflip.py +73 -0
  640. freestuff/extractor/pornhub.py +835 -0
  641. freestuff/extractor/pornotube.py +82 -0
  642. freestuff/extractor/pornovoisines.py +103 -0
  643. freestuff/extractor/pornoxo.py +55 -0
  644. freestuff/extractor/pr0gramm.py +203 -0
  645. freestuff/extractor/prankcast.py +168 -0
  646. freestuff/extractor/premiershiprugby.py +39 -0
  647. freestuff/extractor/presstv.py +69 -0
  648. freestuff/extractor/projectveritas.py +52 -0
  649. freestuff/extractor/prx.py +429 -0
  650. freestuff/extractor/puhutv.py +232 -0
  651. freestuff/extractor/pyvideo.py +69 -0
  652. freestuff/extractor/qdance.py +171 -0
  653. freestuff/extractor/qingting.py +46 -0
  654. freestuff/extractor/qqmusic.py +492 -0
  655. freestuff/extractor/r7.py +112 -0
  656. freestuff/extractor/radiko.py +263 -0
  657. freestuff/extractor/radiocanada.py +165 -0
  658. freestuff/extractor/radiode.py +50 -0
  659. freestuff/extractor/radiofrance.py +473 -0
  660. freestuff/extractor/radiojavan.py +81 -0
  661. freestuff/extractor/radiokapital.py +93 -0
  662. freestuff/extractor/radioradicale.py +105 -0
  663. freestuff/extractor/radiozet.py +50 -0
  664. freestuff/extractor/radlive.py +180 -0
  665. freestuff/extractor/rai.py +861 -0
  666. freestuff/extractor/raywenderlich.py +175 -0
  667. freestuff/extractor/rbgtum.py +142 -0
  668. freestuff/extractor/rcs.py +372 -0
  669. freestuff/extractor/rcti.py +379 -0
  670. freestuff/extractor/rds.py +67 -0
  671. freestuff/extractor/redbee.py +380 -0
  672. freestuff/extractor/redbulltv.py +223 -0
  673. freestuff/extractor/reddit.py +459 -0
  674. freestuff/extractor/redgifs.py +286 -0
  675. freestuff/extractor/redtube.py +144 -0
  676. freestuff/extractor/rentv.py +103 -0
  677. freestuff/extractor/restudy.py +41 -0
  678. freestuff/extractor/reuters.py +66 -0
  679. freestuff/extractor/reverbnation.py +51 -0
  680. freestuff/extractor/ridehome.py +96 -0
  681. freestuff/extractor/rinsefm.py +96 -0
  682. freestuff/extractor/rockstargames.py +65 -0
  683. freestuff/extractor/rokfin.py +455 -0
  684. freestuff/extractor/roosterteeth.py +352 -0
  685. freestuff/extractor/rottentomatoes.py +80 -0
  686. freestuff/extractor/roya.py +43 -0
  687. freestuff/extractor/rozhlas.py +363 -0
  688. freestuff/extractor/rte.py +162 -0
  689. freestuff/extractor/rtl2.py +96 -0
  690. freestuff/extractor/rtlnl.py +294 -0
  691. freestuff/extractor/rtnews.py +196 -0
  692. freestuff/extractor/rtp.py +332 -0
  693. freestuff/extractor/rtrfm.py +65 -0
  694. freestuff/extractor/rts.py +231 -0
  695. freestuff/extractor/rtvcplay.py +286 -0
  696. freestuff/extractor/rtve.py +434 -0
  697. freestuff/extractor/rtvs.py +89 -0
  698. freestuff/extractor/rtvslo.py +195 -0
  699. freestuff/extractor/rudovideo.py +135 -0
  700. freestuff/extractor/rule34video.py +123 -0
  701. freestuff/extractor/rumble.py +412 -0
  702. freestuff/extractor/rutube.py +468 -0
  703. freestuff/extractor/ruutu.py +262 -0
  704. freestuff/extractor/ruv.py +186 -0
  705. freestuff/extractor/s4c.py +134 -0
  706. freestuff/extractor/safari.py +255 -0
  707. freestuff/extractor/saitosan.py +75 -0
  708. freestuff/extractor/samplefocus.py +105 -0
  709. freestuff/extractor/sapo.py +114 -0
  710. freestuff/extractor/sauceplus.py +57 -0
  711. freestuff/extractor/sbs.py +165 -0
  712. freestuff/extractor/sbscokr.py +200 -0
  713. freestuff/extractor/screen9.py +62 -0
  714. freestuff/extractor/screencast.py +116 -0
  715. freestuff/extractor/screencastify.py +70 -0
  716. freestuff/extractor/screencastomatic.py +72 -0
  717. freestuff/extractor/screenrec.py +33 -0
  718. freestuff/extractor/scrippsnetworks.py +155 -0
  719. freestuff/extractor/scrolller.py +102 -0
  720. freestuff/extractor/sejmpl.py +218 -0
  721. freestuff/extractor/sen.py +36 -0
  722. freestuff/extractor/senalcolombia.py +32 -0
  723. freestuff/extractor/senategov.py +246 -0
  724. freestuff/extractor/servus.py +142 -0
  725. freestuff/extractor/sevenplus.py +131 -0
  726. freestuff/extractor/sexu.py +61 -0
  727. freestuff/extractor/seznamzpravy.py +155 -0
  728. freestuff/extractor/shahid.py +217 -0
  729. freestuff/extractor/sharepoint.py +112 -0
  730. freestuff/extractor/shemaroome.py +99 -0
  731. freestuff/extractor/shiey.py +34 -0
  732. freestuff/extractor/showroomlive.py +80 -0
  733. freestuff/extractor/sibnet.py +17 -0
  734. freestuff/extractor/simplecast.py +175 -0
  735. freestuff/extractor/sina.py +108 -0
  736. freestuff/extractor/skeb.py +132 -0
  737. freestuff/extractor/sky.py +135 -0
  738. freestuff/extractor/skyit.py +321 -0
  739. freestuff/extractor/skylinewebcams.py +40 -0
  740. freestuff/extractor/skynewsarabia.py +115 -0
  741. freestuff/extractor/skynewsau.py +43 -0
  742. freestuff/extractor/slideshare.py +51 -0
  743. freestuff/extractor/slideslive.py +536 -0
  744. freestuff/extractor/slutload.py +63 -0
  745. freestuff/extractor/smotrim.py +403 -0
  746. freestuff/extractor/snapchat.py +76 -0
  747. freestuff/extractor/softwhiteunderbelly.py +87 -0
  748. freestuff/extractor/sohu.py +289 -0
  749. freestuff/extractor/sonyliv.py +250 -0
  750. freestuff/extractor/soundcloud.py +1360 -0
  751. freestuff/extractor/soundgasm.py +74 -0
  752. freestuff/extractor/southpark.py +354 -0
  753. freestuff/extractor/sovietscloset.py +189 -0
  754. freestuff/extractor/spankbang.py +198 -0
  755. freestuff/extractor/spiegel.py +51 -0
  756. freestuff/extractor/sport5.py +86 -0
  757. freestuff/extractor/sportbox.py +98 -0
  758. freestuff/extractor/sportdeutschland.py +164 -0
  759. freestuff/extractor/spreaker.py +179 -0
  760. freestuff/extractor/sproutvideo.py +206 -0
  761. freestuff/extractor/srgssr.py +246 -0
  762. freestuff/extractor/srmediathek.py +102 -0
  763. freestuff/extractor/stacommu.py +251 -0
  764. freestuff/extractor/stageplus.py +515 -0
  765. freestuff/extractor/startrek.py +76 -0
  766. freestuff/extractor/startv.py +97 -0
  767. freestuff/extractor/steam.py +214 -0
  768. freestuff/extractor/storyfire.py +133 -0
  769. freestuff/extractor/streaks.py +265 -0
  770. freestuff/extractor/streamable.py +103 -0
  771. freestuff/extractor/streamcz.py +122 -0
  772. freestuff/extractor/streetvoice.py +97 -0
  773. freestuff/extractor/stripchat.py +63 -0
  774. freestuff/extractor/stv.py +88 -0
  775. freestuff/extractor/subsplash.py +199 -0
  776. freestuff/extractor/substack.py +158 -0
  777. freestuff/extractor/sunporno.py +75 -0
  778. freestuff/extractor/sverigesradio.py +149 -0
  779. freestuff/extractor/svt.py +463 -0
  780. freestuff/extractor/sztvhu.py +38 -0
  781. freestuff/extractor/tagesschau.py +164 -0
  782. freestuff/extractor/taptap.py +275 -0
  783. freestuff/extractor/tarangplus.py +244 -0
  784. freestuff/extractor/tass.py +59 -0
  785. freestuff/extractor/tbs.py +161 -0
  786. freestuff/extractor/tbsjp.py +153 -0
  787. freestuff/extractor/teachable.py +295 -0
  788. freestuff/extractor/teachertube.py +126 -0
  789. freestuff/extractor/teachingchannel.py +32 -0
  790. freestuff/extractor/teamcoco.py +281 -0
  791. freestuff/extractor/teamtreehouse.py +134 -0
  792. freestuff/extractor/ted.py +251 -0
  793. freestuff/extractor/tele13.py +84 -0
  794. freestuff/extractor/tele5.py +84 -0
  795. freestuff/extractor/telebruxelles.py +72 -0
  796. freestuff/extractor/telecaribe.py +91 -0
  797. freestuff/extractor/telecinco.py +182 -0
  798. freestuff/extractor/telegraaf.py +86 -0
  799. freestuff/extractor/telegram.py +136 -0
  800. freestuff/extractor/telemb.py +75 -0
  801. freestuff/extractor/telemundo.py +50 -0
  802. freestuff/extractor/telequebec.py +236 -0
  803. freestuff/extractor/teletask.py +52 -0
  804. freestuff/extractor/telewebion.py +133 -0
  805. freestuff/extractor/tencent.py +489 -0
  806. freestuff/extractor/tennistv.py +155 -0
  807. freestuff/extractor/tenplay.py +336 -0
  808. freestuff/extractor/testurl.py +50 -0
  809. freestuff/extractor/tf1.py +101 -0
  810. freestuff/extractor/tfo.py +49 -0
  811. freestuff/extractor/thechosen.py +118 -0
  812. freestuff/extractor/theguardian.py +134 -0
  813. freestuff/extractor/thehighwire.py +43 -0
  814. freestuff/extractor/theintercept.py +45 -0
  815. freestuff/extractor/theplatform.py +409 -0
  816. freestuff/extractor/thestar.py +33 -0
  817. freestuff/extractor/thesun.py +43 -0
  818. freestuff/extractor/theweatherchannel.py +99 -0
  819. freestuff/extractor/thisamericanlife.py +38 -0
  820. freestuff/extractor/thisoldhouse.py +153 -0
  821. freestuff/extractor/thisvid.py +226 -0
  822. freestuff/extractor/threeqsdn.py +156 -0
  823. freestuff/extractor/threespeak.py +93 -0
  824. freestuff/extractor/tiktok.py +1728 -0
  825. freestuff/extractor/tmz.py +191 -0
  826. freestuff/extractor/tnaflix.py +335 -0
  827. freestuff/extractor/toggle.py +204 -0
  828. freestuff/extractor/toggo.py +82 -0
  829. freestuff/extractor/tonline.py +53 -0
  830. freestuff/extractor/toongoggles.py +76 -0
  831. freestuff/extractor/toutiao.py +121 -0
  832. freestuff/extractor/toutv.py +87 -0
  833. freestuff/extractor/toypics.py +90 -0
  834. freestuff/extractor/trtcocuk.py +48 -0
  835. freestuff/extractor/trtworld.py +101 -0
  836. freestuff/extractor/trueid.py +136 -0
  837. freestuff/extractor/trunews.py +32 -0
  838. freestuff/extractor/truth.py +74 -0
  839. freestuff/extractor/tube8.py +170 -0
  840. freestuff/extractor/tubetugraz.py +263 -0
  841. freestuff/extractor/tubitv.py +206 -0
  842. freestuff/extractor/tumblr.py +574 -0
  843. freestuff/extractor/tunein.py +335 -0
  844. freestuff/extractor/turner.py +263 -0
  845. freestuff/extractor/tv2.py +324 -0
  846. freestuff/extractor/tv24ua.py +78 -0
  847. freestuff/extractor/tv2dk.py +166 -0
  848. freestuff/extractor/tv2hu.py +103 -0
  849. freestuff/extractor/tv4.py +149 -0
  850. freestuff/extractor/tv5mondeplus.py +178 -0
  851. freestuff/extractor/tv5unis.py +162 -0
  852. freestuff/extractor/tva.py +76 -0
  853. freestuff/extractor/tvanouvelles.py +62 -0
  854. freestuff/extractor/tvc.py +109 -0
  855. freestuff/extractor/tver.py +372 -0
  856. freestuff/extractor/tvigle.py +133 -0
  857. freestuff/extractor/tviplayer.py +72 -0
  858. freestuff/extractor/tvn24.py +100 -0
  859. freestuff/extractor/tvnoe.py +82 -0
  860. freestuff/extractor/tvo.py +152 -0
  861. freestuff/extractor/tvopengr.py +130 -0
  862. freestuff/extractor/tvp.py +644 -0
  863. freestuff/extractor/tvplay.py +306 -0
  864. freestuff/extractor/tvw.py +217 -0
  865. freestuff/extractor/tweakers.py +59 -0
  866. freestuff/extractor/twentymin.py +91 -0
  867. freestuff/extractor/twentythreevideo.py +76 -0
  868. freestuff/extractor/twitcasting.py +321 -0
  869. freestuff/extractor/twitch.py +1289 -0
  870. freestuff/extractor/twitter.py +1767 -0
  871. freestuff/extractor/txxx.py +422 -0
  872. freestuff/extractor/udemy.py +472 -0
  873. freestuff/extractor/udn.py +106 -0
  874. freestuff/extractor/ufctv.py +7 -0
  875. freestuff/extractor/ukcolumn.py +71 -0
  876. freestuff/extractor/uliza.py +113 -0
  877. freestuff/extractor/umg.py +53 -0
  878. freestuff/extractor/unistra.py +64 -0
  879. freestuff/extractor/unitednations.py +32 -0
  880. freestuff/extractor/unity.py +31 -0
  881. freestuff/extractor/unsupported.py +353 -0
  882. freestuff/extractor/uol.py +136 -0
  883. freestuff/extractor/uplynk.py +88 -0
  884. freestuff/extractor/urort.py +60 -0
  885. freestuff/extractor/urplay.py +179 -0
  886. freestuff/extractor/usanetwork.py +21 -0
  887. freestuff/extractor/usatoday.py +59 -0
  888. freestuff/extractor/ustream.py +272 -0
  889. freestuff/extractor/ustudio.py +119 -0
  890. freestuff/extractor/varzesh3.py +73 -0
  891. freestuff/extractor/vbox7.py +112 -0
  892. freestuff/extractor/veo.py +75 -0
  893. freestuff/extractor/vevo.py +352 -0
  894. freestuff/extractor/vgtv.py +310 -0
  895. freestuff/extractor/vh1.py +50 -0
  896. freestuff/extractor/vice.py +315 -0
  897. freestuff/extractor/viddler.py +147 -0
  898. freestuff/extractor/videa.py +208 -0
  899. freestuff/extractor/videocampus_sachsen.py +274 -0
  900. freestuff/extractor/videoken.py +46 -0
  901. freestuff/extractor/videopress.py +104 -0
  902. freestuff/extractor/vidflex.py +148 -0
  903. freestuff/extractor/vidio.py +309 -0
  904. freestuff/extractor/vidlii.py +154 -0
  905. freestuff/extractor/vidly.py +83 -0
  906. freestuff/extractor/vidyard.py +438 -0
  907. freestuff/extractor/viewlift.py +374 -0
  908. freestuff/extractor/viidea.py +196 -0
  909. freestuff/extractor/vimeo.py +2327 -0
  910. freestuff/extractor/viously.py +60 -0
  911. freestuff/extractor/viqeo.py +100 -0
  912. freestuff/extractor/visir.py +116 -0
  913. freestuff/extractor/viu.py +541 -0
  914. freestuff/extractor/vk.py +963 -0
  915. freestuff/extractor/vocaroo.py +63 -0
  916. freestuff/extractor/vodplatform.py +37 -0
  917. freestuff/extractor/voicy.py +145 -0
  918. freestuff/extractor/volejtv.py +167 -0
  919. freestuff/extractor/voxmedia.py +212 -0
  920. freestuff/extractor/vrsquare.py +185 -0
  921. freestuff/extractor/vrt.py +562 -0
  922. freestuff/extractor/vtm.py +42 -0
  923. freestuff/extractor/vtv.py +108 -0
  924. freestuff/extractor/walla.py +83 -0
  925. freestuff/extractor/washingtonpost.py +122 -0
  926. freestuff/extractor/wat.py +126 -0
  927. freestuff/extractor/wdr.py +349 -0
  928. freestuff/extractor/webcamerapl.py +44 -0
  929. freestuff/extractor/webcaster.py +92 -0
  930. freestuff/extractor/webofstories.py +151 -0
  931. freestuff/extractor/weibo.py +370 -0
  932. freestuff/extractor/weiqitv.py +50 -0
  933. freestuff/extractor/weverse.py +769 -0
  934. freestuff/extractor/wevidi.py +108 -0
  935. freestuff/extractor/whowatch.py +96 -0
  936. freestuff/extractor/whyp.py +60 -0
  937. freestuff/extractor/wikimedia.py +133 -0
  938. freestuff/extractor/wimbledon.py +61 -0
  939. freestuff/extractor/wimtv.py +157 -0
  940. freestuff/extractor/wistia.py +423 -0
  941. freestuff/extractor/wordpress.py +154 -0
  942. freestuff/extractor/worldstarhiphop.py +38 -0
  943. freestuff/extractor/wppilot.py +173 -0
  944. freestuff/extractor/wrestleuniverse.py +335 -0
  945. freestuff/extractor/wsj.py +130 -0
  946. freestuff/extractor/wwe.py +137 -0
  947. freestuff/extractor/wykop.py +268 -0
  948. freestuff/extractor/xboxclips.py +62 -0
  949. freestuff/extractor/xhamster.py +638 -0
  950. freestuff/extractor/xiaohongshu.py +109 -0
  951. freestuff/extractor/ximalaya.py +246 -0
  952. freestuff/extractor/xinpianchang.py +90 -0
  953. freestuff/extractor/xminus.py +77 -0
  954. freestuff/extractor/xnxx.py +83 -0
  955. freestuff/extractor/xvideos.py +225 -0
  956. freestuff/extractor/xxxymovies.py +77 -0
  957. freestuff/extractor/yahoo.py +369 -0
  958. freestuff/extractor/yandexdisk.py +143 -0
  959. freestuff/extractor/yandexmusic.py +453 -0
  960. freestuff/extractor/yandexvideo.py +413 -0
  961. freestuff/extractor/yapfiles.py +99 -0
  962. freestuff/extractor/yappy.py +128 -0
  963. freestuff/extractor/yfanefa.py +67 -0
  964. freestuff/extractor/yle_areena.py +182 -0
  965. freestuff/extractor/youjizz.py +90 -0
  966. freestuff/extractor/youku.py +290 -0
  967. freestuff/extractor/younow.py +194 -0
  968. freestuff/extractor/youporn.py +567 -0
  969. freestuff/extractor/youtube/__init__.py +49 -0
  970. freestuff/extractor/youtube/_base.py +1314 -0
  971. freestuff/extractor/youtube/_clip.py +68 -0
  972. freestuff/extractor/youtube/_mistakes.py +69 -0
  973. freestuff/extractor/youtube/_notifications.py +98 -0
  974. freestuff/extractor/youtube/_redirect.py +248 -0
  975. freestuff/extractor/youtube/_search.py +152 -0
  976. freestuff/extractor/youtube/_tab.py +2511 -0
  977. freestuff/extractor/youtube/_video.py +4576 -0
  978. freestuff/extractor/youtube/jsc/README.md +132 -0
  979. freestuff/extractor/youtube/jsc/__init__.py +5 -0
  980. freestuff/extractor/youtube/jsc/_builtin/__init__.py +0 -0
  981. freestuff/extractor/youtube/jsc/_builtin/bun.py +165 -0
  982. freestuff/extractor/youtube/jsc/_builtin/deno.py +131 -0
  983. freestuff/extractor/youtube/jsc/_builtin/ejs.py +328 -0
  984. freestuff/extractor/youtube/jsc/_builtin/node.py +70 -0
  985. freestuff/extractor/youtube/jsc/_builtin/quickjs.py +67 -0
  986. freestuff/extractor/youtube/jsc/_builtin/vendor/__init__.py +17 -0
  987. freestuff/extractor/youtube/jsc/_builtin/vendor/_info.py +11 -0
  988. freestuff/extractor/youtube/jsc/_builtin/vendor/yt.solver.bun.lib.js +9 -0
  989. freestuff/extractor/youtube/jsc/_builtin/vendor/yt.solver.core.js +368 -0
  990. freestuff/extractor/youtube/jsc/_builtin/vendor/yt.solver.deno.lib.js +9 -0
  991. freestuff/extractor/youtube/jsc/_director.py +287 -0
  992. freestuff/extractor/youtube/jsc/_registry.py +4 -0
  993. freestuff/extractor/youtube/jsc/provider.py +161 -0
  994. freestuff/extractor/youtube/pot/README.md +309 -0
  995. freestuff/extractor/youtube/pot/__init__.py +3 -0
  996. freestuff/extractor/youtube/pot/_builtin/__init__.py +0 -0
  997. freestuff/extractor/youtube/pot/_builtin/memory_cache.py +78 -0
  998. freestuff/extractor/youtube/pot/_builtin/webpo_cachespec.py +48 -0
  999. freestuff/extractor/youtube/pot/_director.py +478 -0
  1000. freestuff/extractor/youtube/pot/_provider.py +167 -0
  1001. freestuff/extractor/youtube/pot/_registry.py +8 -0
  1002. freestuff/extractor/youtube/pot/cache.py +97 -0
  1003. freestuff/extractor/youtube/pot/provider.py +283 -0
  1004. freestuff/extractor/youtube/pot/utils.py +77 -0
  1005. freestuff/extractor/zaiko.py +145 -0
  1006. freestuff/extractor/zan.py +238 -0
  1007. freestuff/extractor/zapiks.py +205 -0
  1008. freestuff/extractor/zattoo.py +862 -0
  1009. freestuff/extractor/zdf.py +794 -0
  1010. freestuff/extractor/zeenews.py +59 -0
  1011. freestuff/extractor/zenporn.py +118 -0
  1012. freestuff/extractor/zetland.py +71 -0
  1013. freestuff/extractor/zhihu.py +65 -0
  1014. freestuff/extractor/zingmp3.py +628 -0
  1015. freestuff/extractor/zoom.py +211 -0
  1016. freestuff/extractor/zype.py +135 -0
  1017. freestuff/globals.py +41 -0
  1018. freestuff/jsinterp.py +971 -0
  1019. freestuff/minicurses.py +182 -0
  1020. freestuff/networking/__init__.py +38 -0
  1021. freestuff/networking/_curlcffi.py +346 -0
  1022. freestuff/networking/_helper.py +273 -0
  1023. freestuff/networking/_requests.py +418 -0
  1024. freestuff/networking/_urllib.py +445 -0
  1025. freestuff/networking/_websockets.py +189 -0
  1026. freestuff/networking/common.py +608 -0
  1027. freestuff/networking/exceptions.py +103 -0
  1028. freestuff/networking/impersonate.py +155 -0
  1029. freestuff/networking/websocket.py +23 -0
  1030. freestuff/options.py +2012 -0
  1031. freestuff/plugins.py +247 -0
  1032. freestuff/postprocessor/__init__.py +69 -0
  1033. freestuff/postprocessor/common.py +215 -0
  1034. freestuff/postprocessor/embedthumbnail.py +233 -0
  1035. freestuff/postprocessor/exec.py +49 -0
  1036. freestuff/postprocessor/ffmpeg.py +1182 -0
  1037. freestuff/postprocessor/metadataparser.py +128 -0
  1038. freestuff/postprocessor/modify_chapters.py +336 -0
  1039. freestuff/postprocessor/movefilesafterdownload.py +53 -0
  1040. freestuff/postprocessor/sponsorblock.py +105 -0
  1041. freestuff/postprocessor/xattrpp.py +79 -0
  1042. freestuff/socks.py +274 -0
  1043. freestuff/update.py +630 -0
  1044. freestuff/utils/__init__.py +10 -0
  1045. freestuff/utils/_deprecated.py +61 -0
  1046. freestuff/utils/_jsruntime.py +153 -0
  1047. freestuff/utils/_legacy.py +269 -0
  1048. freestuff/utils/_utils.py +5754 -0
  1049. freestuff/utils/jslib/__init__.py +1 -0
  1050. freestuff/utils/jslib/devalue.py +167 -0
  1051. freestuff/utils/networking.py +256 -0
  1052. freestuff/utils/progress.py +109 -0
  1053. freestuff/utils/traversal.py +477 -0
  1054. freestuff/version.py +13 -0
  1055. freestuff/webvtt.py +398 -0
@@ -0,0 +1,2576 @@
1
+ Metadata-Version: 2.4
2
+ Name: FREE--BUFF
3
+ Version: 1.0
4
+ Summary: A feature-rich command-line audio/video downloader
5
+ Project-URL: Documentation, https://github.com/rahulae1616-rgb/FREE-STUFF#readme
6
+ Project-URL: Repository, https://github.com/rahulae1616-rgb/FREE-STUFF
7
+ Project-URL: Tracker, https://github.com/rahulae1616-rgb/FREE-STUFF/issues
8
+ Author: RAHUL CHANDRA
9
+ Maintainer: RAHUL CHANDRA
10
+ License-Expression: Unlicense
11
+ License-File: LICENSE
12
+ Keywords: cli,downloader,free-stuff,video-downloader
13
+ Classifier: Development Status :: 5 - Production/Stable
14
+ Classifier: Environment :: Console
15
+ Classifier: Operating System :: OS Independent
16
+ Classifier: Programming Language :: Python
17
+ Classifier: Programming Language :: Python :: 3 :: Only
18
+ Classifier: Programming Language :: Python :: 3.10
19
+ Classifier: Programming Language :: Python :: 3.11
20
+ Classifier: Programming Language :: Python :: 3.12
21
+ Classifier: Programming Language :: Python :: 3.13
22
+ Classifier: Programming Language :: Python :: 3.14
23
+ Classifier: Programming Language :: Python :: Implementation
24
+ Classifier: Programming Language :: Python :: Implementation :: CPython
25
+ Classifier: Programming Language :: Python :: Implementation :: PyPy
26
+ Classifier: Topic :: Multimedia :: Video
27
+ Requires-Python: >=3.10
28
+ Provides-Extra: curl-cffi
29
+ Requires-Dist: curl-cffi!=0.6.*,!=0.7.*,!=0.8.*,!=0.9.*,<0.16,>=0.5.10; (implementation_name == 'cpython') and extra == 'curl-cffi'
30
+ Provides-Extra: default
31
+ Requires-Dist: brotli; (implementation_name == 'cpython' and sys_platform != 'ios') and extra == 'default'
32
+ Requires-Dist: brotlicffi; (implementation_name != 'cpython') and extra == 'default'
33
+ Requires-Dist: certifi; extra == 'default'
34
+ Requires-Dist: freestuff-ejs==0.8.0; extra == 'default'
35
+ Requires-Dist: mutagen; extra == 'default'
36
+ Requires-Dist: pycryptodomex; extra == 'default'
37
+ Requires-Dist: requests<3,>=2.32.2; extra == 'default'
38
+ Requires-Dist: urllib3<3,>=2.0.2; extra == 'default'
39
+ Requires-Dist: websockets>=13.0; extra == 'default'
40
+ Provides-Extra: deno
41
+ Requires-Dist: deno>=2.6.6; extra == 'deno'
42
+ Provides-Extra: pin
43
+ Requires-Dist: brotli==1.2.0; (implementation_name == 'cpython' and sys_platform != 'ios') and extra == 'pin'
44
+ Requires-Dist: brotlicffi==1.2.0.1; (implementation_name != 'cpython') and extra == 'pin'
45
+ Requires-Dist: certifi==2026.6.17; extra == 'pin'
46
+ Requires-Dist: charset-normalizer==3.4.7; extra == 'pin'
47
+ Requires-Dist: freestuff-ejs==0.8.0; extra == 'pin'
48
+ Requires-Dist: idna==3.18; extra == 'pin'
49
+ Requires-Dist: mutagen==1.48.1; extra == 'pin'
50
+ Requires-Dist: pycryptodomex==3.23.0; extra == 'pin'
51
+ Requires-Dist: requests==2.34.2; extra == 'pin'
52
+ Requires-Dist: urllib3==2.7.0; extra == 'pin'
53
+ Requires-Dist: websockets==16.0; extra == 'pin'
54
+ Provides-Extra: pin-curl-cffi
55
+ Requires-Dist: certifi==2026.6.17; (implementation_name == 'cpython') and extra == 'pin-curl-cffi'
56
+ Requires-Dist: cffi==2.0.0; (implementation_name == 'cpython') and extra == 'pin-curl-cffi'
57
+ Requires-Dist: curl-cffi==0.15.0; (implementation_name == 'cpython') and extra == 'pin-curl-cffi'
58
+ Requires-Dist: markdown-it-py==4.2.0; (implementation_name == 'cpython') and extra == 'pin-curl-cffi'
59
+ Requires-Dist: mdurl==0.1.2; (implementation_name == 'cpython') and extra == 'pin-curl-cffi'
60
+ Requires-Dist: pycparser==3.0; (implementation_name == 'cpython') and extra == 'pin-curl-cffi'
61
+ Requires-Dist: pygments==2.20.0; (implementation_name == 'cpython') and extra == 'pin-curl-cffi'
62
+ Requires-Dist: rich==15.0.0; (implementation_name == 'cpython') and extra == 'pin-curl-cffi'
63
+ Provides-Extra: pin-deno
64
+ Requires-Dist: deno==2.8.3; extra == 'pin-deno'
65
+ Provides-Extra: pin-secretstorage
66
+ Requires-Dist: cffi==2.0.0; (platform_python_implementation != 'PyPy') and extra == 'pin-secretstorage'
67
+ Requires-Dist: cryptography==49.0.0; extra == 'pin-secretstorage'
68
+ Requires-Dist: jeepney==0.9.0; extra == 'pin-secretstorage'
69
+ Requires-Dist: pycparser==3.0; (implementation_name != 'PyPy' and platform_python_implementation != 'PyPy') and extra == 'pin-secretstorage'
70
+ Requires-Dist: secretstorage==3.5.0; extra == 'pin-secretstorage'
71
+ Requires-Dist: typing-extensions==4.15.0; (python_full_version < '3.11') and extra == 'pin-secretstorage'
72
+ Provides-Extra: secretstorage
73
+ Requires-Dist: secretstorage; extra == 'secretstorage'
74
+ Description-Content-Type: text/markdown
75
+
76
+ <!-- MANPAGE: BEGIN EXCLUDED SECTION -->
77
+ <div align="center">
78
+
79
+ [![freestuff](https://raw.githubusercontent.com/freestuff/freestuff/master/.github/banner.svg)](#readme)
80
+
81
+ [![Release version](https://img.shields.io/github/v/release/freestuff/freestuff?color=brightgreen&label=Latest&style=for-the-badge)](#installation "Installation")
82
+ [![Python Version](https://img.shields.io/python/required-version-toml?tomlFilePath=https%3A%2F%2Fraw.githubusercontent.com%2Ffreestuff%2Ffreestuff%2Frefs%2Fheads%2Fmaster%2Fpyproject.toml&style=for-the-badge)](https://github.com/freestuff/freestuff/blob/master/pyproject.toml "Python Version")
83
+ [![PyPI](https://img.shields.io/badge/-PyPI-blue.svg?logo=pypi&labelColor=555555&style=for-the-badge)](https://pypi.org/project/freestuff "PyPI")
84
+ [![Discord](https://img.shields.io/badge/Discord-%235865F2.svg?&logo=discord&logoColor=white&style=for-the-badge)]([#](https://discord.gg/H5MNcFW63r "Discord")
85
+ [![License: Unlicense](https://img.shields.io/badge/-Unlicense-red.svg?style=for-the-badge)](LICENSE "License")
86
+ [![Commits](https://img.shields.io/github/commit-activity/m/freestuff/freestuff?label=commits&style=for-the-badge)](https://github.com/freestuff/freestuff/commits "Commit History")
87
+
88
+ </div>
89
+ <!-- MANPAGE: END EXCLUDED SECTION -->
90
+
91
+ freestuff is a feature-rich command-line audio/video downloader with support for [thousands of sites](supportedsites.md). The project is a fork of [youtube-dl](https://github.com/ytdl-org/youtube-dl) based on the now inactive [youtube-dlc](https://github.com/blackjack4494/yt-dlc).
92
+
93
+ <!-- MANPAGE: MOVE "USAGE AND OPTIONS" SECTION HERE -->
94
+
95
+ <!-- MANPAGE: BEGIN EXCLUDED SECTION -->
96
+ * [INSTALLATION](#installation)
97
+ * [Detailed instructions](https://github.com/freestuff/freestuff/wiki/Installation)
98
+ * [Release Files](#release-files)
99
+ * [Update](#update)
100
+ * [Dependencies](#dependencies)
101
+ * [Compile](#compile)
102
+ * [USAGE AND OPTIONS](#usage-and-options)
103
+ * [General Options](#general-options)
104
+ * [Network Options](#network-options)
105
+ * [Geo-restriction](#geo-restriction)
106
+ * [Video Selection](#video-selection)
107
+ * [Download Options](#download-options)
108
+ * [Filesystem Options](#filesystem-options)
109
+ * [Thumbnail Options](#thumbnail-options)
110
+ * [Internet Shortcut Options](#internet-shortcut-options)
111
+ * [Verbosity and Simulation Options](#verbosity-and-simulation-options)
112
+ * [Workarounds](#workarounds)
113
+ * [Video Format Options](#video-format-options)
114
+ * [Subtitle Options](#subtitle-options)
115
+ * [Authentication Options](#authentication-options)
116
+ * [Post-processing Options](#post-processing-options)
117
+ * [SponsorBlock Options](#sponsorblock-options)
118
+ * [Extractor Options](#extractor-options)
119
+ * [Preset Aliases](#preset-aliases)
120
+ * [CONFIGURATION](#configuration)
121
+ * [Configuration file encoding](#configuration-file-encoding)
122
+ * [Authentication with netrc](#authentication-with-netrc)
123
+ * [Notes about environment variables](#notes-about-environment-variables)
124
+ * [OUTPUT TEMPLATE](#output-template)
125
+ * [Output template examples](#output-template-examples)
126
+ * [FORMAT SELECTION](#format-selection)
127
+ * [Filtering Formats](#filtering-formats)
128
+ * [Sorting Formats](#sorting-formats)
129
+ * [Format Selection examples](#format-selection-examples)
130
+ * [MODIFYING METADATA](#modifying-metadata)
131
+ * [Modifying metadata examples](#modifying-metadata-examples)
132
+ * [EXTRACTOR ARGUMENTS](#extractor-arguments)
133
+ * [PLUGINS](#plugins)
134
+ * [Installing Plugins](#installing-plugins)
135
+ * [Developing Plugins](#developing-plugins)
136
+ * [EMBEDDING freestuff](#embedding-freestuff)
137
+ * [Embedding examples](#embedding-examples)
138
+ * [CHANGES FROM YOUTUBE-DL](#changes-from-youtube-dl)
139
+ * [New features](#new-features)
140
+ * [Differences in default behavior](#differences-in-default-behavior)
141
+ * [Deprecated options](#deprecated-options)
142
+ * [CONTRIBUTING](CONTRIBUTING.md#contributing-to-freestuff)
143
+ * [Opening an Issue](CONTRIBUTING.md#opening-an-issue)
144
+ * [Developer Instructions](CONTRIBUTING.md#developer-instructions)
145
+ * [WIKI](https://github.com/freestuff/freestuff/wiki)
146
+ * [FAQ](https://github.com/freestuff/freestuff/wiki/FAQ)
147
+ <!-- MANPAGE: END EXCLUDED SECTION -->
148
+
149
+
150
+ # INSTALLATION
151
+
152
+ <!-- MANPAGE: BEGIN EXCLUDED SECTION -->
153
+ [![Windows](https://img.shields.io/badge/-Windows_x64-blue.svg?style=for-the-badge&logo=windows)](https://github.com/freestuff/freestuff/releases/latest/download/freestuff.exe)
154
+ [![Unix](https://img.shields.io/badge/-Linux/BSD-red.svg?style=for-the-badge&logo=linux)](https://github.com/freestuff/freestuff/releases/latest/download/freestuff)
155
+ [![MacOS](https://img.shields.io/badge/-MacOS-lightblue.svg?style=for-the-badge&logo=apple)](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_macos)
156
+ [![PyPI](https://img.shields.io/badge/-PyPI-blue.svg?logo=pypi&labelColor=555555&style=for-the-badge)](https://pypi.org/project/freestuff)
157
+ [![Source Tarball](https://img.shields.io/badge/-Source_tar-green.svg?style=for-the-badge)](https://github.com/freestuff/freestuff/releases/latest/download/freestuff.tar.gz)
158
+ [![Other variants](https://img.shields.io/badge/-Other-grey.svg?style=for-the-badge)](#release-files)
159
+ [![All versions](https://img.shields.io/badge/-All_Versions-lightgrey.svg?style=for-the-badge)](https://github.com/freestuff/freestuff/releases)
160
+ <!-- MANPAGE: END EXCLUDED SECTION -->
161
+
162
+ You can install freestuff using [the binaries](#release-files), [pip](https://pypi.org/project/freestuff) or one using a third-party package manager. See [the wiki](https://github.com/freestuff/freestuff/wiki/Installation) for detailed instructions
163
+
164
+
165
+ <!-- MANPAGE: BEGIN EXCLUDED SECTION -->
166
+ ## RELEASE FILES
167
+
168
+ #### Recommended
169
+
170
+ File|Description
171
+ :---|:---
172
+ [freestuff](https://github.com/freestuff/freestuff/releases/latest/download/freestuff)|Platform-independent [zipimport](https://docs.python.org/3/library/zipimport.html) binary. Needs Python (recommended for **Linux/BSD**)
173
+ [freestuff.exe](https://github.com/freestuff/freestuff/releases/latest/download/freestuff.exe)|Windows (Win8+) standalone x64 binary (recommended for **Windows**)
174
+ [freestuff_macos](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_macos)|Universal MacOS (10.15+) standalone executable (recommended for **MacOS**)
175
+
176
+ #### Alternatives
177
+
178
+ File|Description
179
+ :---|:---
180
+ [freestuff_linux](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_linux)|Linux (glibc 2.17+) standalone x86_64 binary
181
+ [freestuff_linux.zip](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_linux.zip)|Unpackaged Linux (glibc 2.17+) x86_64 executable (no auto-update)
182
+ [freestuff_linux_aarch64](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_linux_aarch64)|Linux (glibc 2.17+) standalone aarch64 binary
183
+ [freestuff_linux_aarch64.zip](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_linux_aarch64.zip)|Unpackaged Linux (glibc 2.17+) aarch64 executable (no auto-update)
184
+ [freestuff_linux_armv7l.zip](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_linux_armv7l.zip)|Unpackaged Linux (glibc 2.31+) armv7l executable (no auto-update)
185
+ [freestuff_musllinux](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_musllinux)|Linux (musl 1.2+) standalone x86_64 binary
186
+ [freestuff_musllinux.zip](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_musllinux.zip)|Unpackaged Linux (musl 1.2+) x86_64 executable (no auto-update)
187
+ [freestuff_musllinux_aarch64](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_musllinux_aarch64)|Linux (musl 1.2+) standalone aarch64 binary
188
+ [freestuff_musllinux_aarch64.zip](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_musllinux_aarch64.zip)|Unpackaged Linux (musl 1.2+) aarch64 executable (no auto-update)
189
+ [freestuff_x86.exe](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_x86.exe)|Windows (Win8+) standalone x86 (32-bit) binary
190
+ [freestuff_win_x86.zip](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_win_x86.zip)|Unpackaged Windows (Win8+) x86 (32-bit) executable (no auto-update)
191
+ [freestuff_arm64.exe](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_arm64.exe)|Windows (Win10+) standalone ARM64 binary
192
+ [freestuff_win_arm64.zip](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_win_arm64.zip)|Unpackaged Windows (Win10+) ARM64 executable (no auto-update)
193
+ [freestuff_win.zip](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_win.zip)|Unpackaged Windows (Win8+) x64 executable (no auto-update)
194
+ [freestuff_macos.zip](https://github.com/freestuff/freestuff/releases/latest/download/freestuff_macos.zip)|Unpackaged MacOS (10.15+) executable (no auto-update)
195
+
196
+ #### Misc
197
+
198
+ File|Description
199
+ :---|:---
200
+ [freestuff.tar.gz](https://github.com/freestuff/freestuff/releases/latest/download/freestuff.tar.gz)|Source tarball
201
+ [SHA2-512SUMS](https://github.com/freestuff/freestuff/releases/latest/download/SHA2-512SUMS)|GNU-style SHA512 sums
202
+ [SHA2-512SUMS.sig](https://github.com/freestuff/freestuff/releases/latest/download/SHA2-512SUMS.sig)|GPG signature file for SHA512 sums
203
+ [SHA2-256SUMS](https://github.com/freestuff/freestuff/releases/latest/download/SHA2-256SUMS)|GNU-style SHA256 sums
204
+ [SHA2-256SUMS.sig](https://github.com/freestuff/freestuff/releases/latest/download/SHA2-256SUMS.sig)|GPG signature file for SHA256 sums
205
+
206
+ The public key that can be used to verify the GPG signatures is [available here](https://github.com/freestuff/freestuff/blob/master/public.key)
207
+ Example usage:
208
+ ```
209
+ curl -L https://github.com/freestuff/freestuff/raw/master/public.key | gpg --import
210
+ gpg --verify SHA2-256SUMS.sig SHA2-256SUMS
211
+ gpg --verify SHA2-512SUMS.sig SHA2-512SUMS
212
+ ```
213
+
214
+ #### Licensing
215
+
216
+ While freestuff is licensed under the [Unlicense](LICENSE), many of the release files contain code from other projects with different licenses.
217
+
218
+ Most notably, the PyInstaller-bundled executables include GPLv3+ licensed code, and as such the combined work is licensed under [GPLv3+](https://www.gnu.org/licenses/gpl-3.0.html).
219
+
220
+ The zipimport Unix executable (`freestuff`) contains [ISC](https://github.com/meriyah/meriyah/blob/main/LICENSE.md) licensed code from [`meriyah`](https://github.com/meriyah/meriyah) and [MIT](https://github.com/davidbonnet/astring/blob/main/LICENSE) licensed code from [`astring`](https://github.com/davidbonnet/astring).
221
+
222
+ See [THIRD_PARTY_LICENSES.txt](THIRD_PARTY_LICENSES.txt) for more details.
223
+
224
+ The git repository, the source tarball (`freestuff.tar.gz`), the PyPI source distribution and the PyPI built distribution (wheel) only contain code licensed under the [Unlicense](LICENSE).
225
+
226
+ <!-- MANPAGE: END EXCLUDED SECTION -->
227
+
228
+ **Note**: The manpages, shell completion (autocomplete) files etc. are available inside the [source tarball](https://github.com/freestuff/freestuff/releases/latest/download/freestuff.tar.gz)
229
+
230
+
231
+ ## UPDATE
232
+ You can use `freestuff -U` to update if you are using the [release binaries](#release-files)
233
+
234
+ If you [installed with pip](https://github.com/freestuff/freestuff/wiki/Installation#with-pip), simply re-run the same command that was used to install the program
235
+
236
+ For other third-party package managers, see [the wiki](https://github.com/freestuff/freestuff/wiki/Installation#third-party-package-managers) or refer to their documentation
237
+
238
+ <a id="update-channels"></a>
239
+
240
+ There are currently three release channels for binaries: `stable`, `nightly` and `master`.
241
+
242
+ * `stable` is the default channel, which offers releases published on a (mostly) monthly schedule. While it is named `stable` due to many of its changes having been tested by users of the `nightly` or `master` release channels, the latest `stable` release is often "stale" and prone to external breakage (i.e. sites changing things on their end and breaking freestuff).
243
+ * The `nightly` channel offers releases that publish shortly before midnight UTC on any day that sees changes to the codebase. This channel serves as a snapshot of the project's development, and it is the **recommended channel for regular users** of freestuff. The `nightly` releases are available from [freestuff/freestuff-nightly-builds](https://github.com/freestuff/freestuff-nightly-builds/releases) or as development releases of the `freestuff` PyPI package (which can be installed with pip's `--pre` flag).
244
+ * The `master` channel offers "canary" releases that publish after each push to the master branch. This channel will always provide the very latest fixes and features, but may be prone to bugs or regressions. The `master` releases are available from [freestuff/freestuff-master-builds](https://github.com/freestuff/freestuff-master-builds/releases).
245
+
246
+ When using `--update`/`-U`, a release binary will only update to its current channel.
247
+ `--update-to CHANNEL` can be used to switch to a different channel when a newer version is available. `--update-to [CHANNEL@]TAG` can also be used to upgrade or downgrade to specific tags from a channel.
248
+
249
+ You may also use `--update-to <repository>` (`<owner>/<repository>`) to update to a channel on a completely different repository. Be careful with what repository you are updating to though, there is no verification done for binaries from different repositories.
250
+
251
+ Example usage:
252
+
253
+ * `freestuff --update-to master` switch to the `master` channel and update to its latest release
254
+ * `freestuff --update-to stable@2023.07.06` upgrade/downgrade to release to `stable` channel tag `2023.07.06`
255
+ * `freestuff --update-to 2023.10.07` upgrade/downgrade to tag `2023.10.07` if it exists on the current channel
256
+ * `freestuff --update-to example/freestuff@2023.09.24` upgrade/downgrade to the release from the `example/freestuff` repository, tag `2023.09.24`
257
+
258
+ **Important**: Any user experiencing an issue with the `stable` release should install or update to the `nightly` release before submitting a bug report:
259
+ ```
260
+ # To update to nightly from stable executable/binary:
261
+ freestuff --update-to nightly
262
+
263
+ # To install nightly with pip:
264
+ python -m pip install -U --pre "freestuff[default]"
265
+ ```
266
+
267
+ When running a freestuff version that is older than 90 days, you will see a warning message suggesting to update to the latest version.
268
+ You can suppress this warning by adding `--no-update` to your command or configuration file.
269
+
270
+ ## DEPENDENCIES
271
+ Python versions 3.10+ (CPython) and 3.11+ (PyPy) are supported. Other versions and implementations may or may not work correctly.
272
+
273
+ <!-- Python 3.5+ uses VC++14 and it is already embedded in the binary created
274
+ <!x-- https://www.microsoft.com/en-us/download/details.aspx?id=26999 --x>
275
+ On Windows, [Microsoft Visual C++ 2010 SP1 Redistributable Package (x86)](https://download.microsoft.com/download/1/6/5/165255E7-1014-4D0A-B094-B6A430A6BFFC/vcredist_x86.exe) is also necessary to run freestuff. You probably already have this, but if the executable throws an error due to missing `MSVCR100.dll` you need to install it manually.
276
+ -->
277
+
278
+ While all the other dependencies are optional, `ffmpeg`, `ffprobe`, `freestuff-ejs` and a supported JavaScript runtime/engine are highly recommended
279
+
280
+ ### Strongly recommended
281
+
282
+ * [**ffmpeg** and **ffprobe**](https://www.ffmpeg.org) - Required for [merging separate video and audio files](#format-selection), as well as for various [post-processing](#post-processing-options) tasks. License [depends on the build](https://www.ffmpeg.org/legal.html)
283
+
284
+ Since ffmpeg is such an important dependency, we provide our own builds at [freestuff/FFmpeg-Builds](https://github.com/freestuff/FFmpeg-Builds). In the past, patches were applied to these builds in order to fix common issues for freestuff users, but currently our builds are equivalent to upstream ffmpeg. See [the readme](https://github.com/freestuff/FFmpeg-Builds#patches-applied) for details
285
+
286
+ **Important**: What you need is ffmpeg *binary*, **NOT** [the Python package of the same name](https://pypi.org/project/ffmpeg)
287
+
288
+ * [**freestuff-ejs**](https://github.com/freestuff/ejs) - Required for full YouTube support. Licensed under [Unlicense](https://github.com/freestuff/ejs/blob/main/LICENSE), bundles [MIT](https://github.com/davidbonnet/astring/blob/main/LICENSE) and [ISC](https://github.com/meriyah/meriyah/blob/main/LICENSE.md) components.
289
+
290
+ A JavaScript runtime/engine like [**deno**](https://deno.land) (recommended), [**node.js**](https://nodejs.org), [**bun**](https://bun.sh), or [**QuickJS**](https://bellard.org/quickjs/) is also required to run freestuff-ejs. See [the wiki](https://github.com/freestuff/freestuff/wiki/EJS).
291
+
292
+ ### Networking
293
+ * [**certifi**](https://github.com/certifi/python-certifi)\* - Provides Mozilla's root certificate bundle. Licensed under [MPLv2](https://github.com/certifi/python-certifi/blob/master/LICENSE)
294
+ * [**brotli**](https://github.com/google/brotli)\* or [**brotlicffi**](https://github.com/python-hyper/brotlicffi) - [Brotli](https://en.wikipedia.org/wiki/Brotli) content encoding support. Both licensed under MIT <sup>[1](https://github.com/google/brotli/blob/master/LICENSE) [2](https://github.com/python-hyper/brotlicffi/blob/master/LICENSE) </sup>
295
+ * [**websockets**](https://github.com/aaugustin/websockets)\* - For downloading over websocket. Licensed under [BSD-3-Clause](https://github.com/aaugustin/websockets/blob/main/LICENSE)
296
+ * [**requests**](https://github.com/psf/requests)\* - HTTP library. For HTTPS proxy and persistent connections support. Licensed under [Apache-2.0](https://github.com/psf/requests/blob/main/LICENSE)
297
+
298
+ #### Impersonation
299
+
300
+ The following provide support for impersonating browser requests. This may be required for some sites that employ TLS fingerprinting.
301
+
302
+ * [**curl_cffi**](https://github.com/lexiforest/curl_cffi) (recommended) - Python binding for [curl-impersonate](https://github.com/lexiforest/curl-impersonate). Provides impersonation targets for Chrome, Edge and Safari. Licensed under [MIT](https://github.com/lexiforest/curl_cffi/blob/main/LICENSE)
303
+ * Can be installed with the `curl-cffi` extra, e.g. `pip install "freestuff[default,curl-cffi]"`
304
+ * Currently included in most builds *except* `freestuff` (Unix zipimport binary) and `freestuff_x86` (Windows 32-bit)
305
+
306
+
307
+ ### Metadata
308
+
309
+ * [**mutagen**](https://github.com/quodlibet/mutagen)\* - For `--embed-thumbnail` in certain formats. Licensed under [GPLv2+](https://github.com/quodlibet/mutagen/blob/master/COPYING)
310
+ * [**AtomicParsley**](https://github.com/wez/atomicparsley) - For `--embed-thumbnail` in `mp4`/`m4a` files when `mutagen`/`ffmpeg` cannot. Licensed under [GPLv2+](https://github.com/wez/atomicparsley/blob/master/COPYING)
311
+ * [**xattr**](https://github.com/xattr/xattr), [**pyxattr**](https://github.com/iustin/pyxattr) or [**setfattr**](http://savannah.nongnu.org/projects/attr) - For writing xattr metadata (`--xattrs`) on **Mac** and **BSD**. Licensed under [MIT](https://github.com/xattr/xattr/blob/master/LICENSE.txt), [LGPL2.1](https://github.com/iustin/pyxattr/blob/master/COPYING) and [GPLv2+](http://git.savannah.nongnu.org/cgit/attr.git/tree/doc/COPYING) respectively
312
+
313
+ ### Misc
314
+
315
+ * [**pycryptodomex**](https://github.com/Legrandin/pycryptodome)\* - For decrypting AES-128 HLS streams and various other data. Licensed under [BSD-2-Clause](https://github.com/Legrandin/pycryptodome/blob/master/LICENSE.rst)
316
+ * [**phantomjs**](https://github.com/ariya/phantomjs) - Used in some extractors where JavaScript needs to be run. No longer used for YouTube. To be deprecated in the near future. Licensed under [BSD-3-Clause](https://github.com/ariya/phantomjs/blob/master/LICENSE.BSD)
317
+ * [**secretstorage**](https://github.com/mitya57/secretstorage)\* - For `--cookies-from-browser` to access the **Gnome** keyring while decrypting cookies of **Chromium**-based browsers on **Linux**. Licensed under [BSD-3-Clause](https://github.com/mitya57/secretstorage/blob/master/LICENSE)
318
+ * Any external downloader that you want to use with `--downloader`
319
+
320
+ ### Deprecated
321
+
322
+ * [**rtmpdump**](http://rtmpdump.mplayerhq.hu) - For downloading `rtmp` streams. ffmpeg can be used instead with `--downloader ffmpeg`. Licensed under [GPLv2+](http://rtmpdump.mplayerhq.hu)
323
+
324
+ To use or redistribute the dependencies, you must agree to their respective licensing terms.
325
+
326
+ The standalone release binaries are built with the Python interpreter and the packages marked with **\*** included.
327
+
328
+ If you do not have the necessary dependencies for a task you are attempting, freestuff will warn you. All the currently available dependencies are visible at the top of the `--verbose` output
329
+
330
+
331
+ ## COMPILE
332
+
333
+ ### Standalone PyInstaller Builds
334
+ To build the standalone executable, you must have Python and `pyinstaller` (plus any of freestuff's [optional dependencies](#dependencies) if needed). The executable will be built for the same CPU architecture as the Python used.
335
+
336
+ You can run the following commands:
337
+
338
+ ```
339
+ python devscripts/install_deps.py --include-group pyinstaller
340
+ python devscripts/make_lazy_extractors.py
341
+ python -m bundle.pyinstaller
342
+ ```
343
+
344
+ On some systems, you may need to use `py` or `python3` instead of `python`.
345
+
346
+ `python -m bundle.pyinstaller` accepts any arguments that can be passed to `pyinstaller`, such as `--onefile/-F` or `--onedir/-D`, which is further [documented here](https://pyinstaller.org/en/stable/usage.html#what-to-generate).
347
+
348
+ **Note**: Pyinstaller versions below 4.4 [do not support](https://github.com/pyinstaller/pyinstaller#requirements-and-tested-platforms) Python installed from the Windows store without using a virtual environment.
349
+
350
+ **Important**: Running `pyinstaller` directly **instead of** using `python -m bundle.pyinstaller` is **not** officially supported. This may or may not work correctly.
351
+
352
+ ### Platform-independent Binary (UNIX)
353
+ You will need the build tools `python` (3.10+), `zip`, `make` (GNU), `pandoc`\* and `pytest`\*.
354
+
355
+ After installing these, simply run `make`.
356
+
357
+ You can also run `make freestuff` instead to compile only the binary without updating any of the additional files. (The build tools marked with **\*** are not needed for this)
358
+
359
+ ### Related scripts
360
+
361
+ * **`devscripts/install_deps.py`** - Install dependencies for freestuff.
362
+ * **`devscripts/update-version.py`** - Update the version number based on the current date.
363
+ * **`devscripts/set-variant.py`** - Set the build variant of the executable.
364
+ * **`devscripts/make_changelog.py`** - Create a markdown changelog using short commit messages and update `CONTRIBUTORS` file.
365
+ * **`devscripts/make_lazy_extractors.py`** - Create lazy extractors. Running this before building the binaries (any variant) will improve their startup performance. Set the environment variable `YTDLP_NO_LAZY_EXTRACTORS` to something nonempty to forcefully disable lazy extractor loading.
366
+
367
+ Note: See their `--help` for more info.
368
+
369
+ ### Forking the project
370
+ If you fork the project on GitHub, you can run your fork's [build workflow](.github/workflows/build.yml) to automatically build the selected version(s) as artifacts. Alternatively, you can run the [release workflow](.github/workflows/release.yml) or enable the [nightly workflow](.github/workflows/release-nightly.yml) to create full (pre-)releases.
371
+
372
+ # USAGE AND OPTIONS
373
+
374
+ <!-- MANPAGE: BEGIN EXCLUDED SECTION -->
375
+ freestuff [OPTIONS] [--] URL [URL...]
376
+
377
+ Tip: Use `CTRL`+`F` (or `Command`+`F`) to search by keywords
378
+ <!-- MANPAGE: END EXCLUDED SECTION -->
379
+
380
+ <!-- Auto generated -->
381
+ ## General Options:
382
+ -h, --help Print this help text and exit
383
+ --version Print program version and exit
384
+ -U, --update Update this program to the latest version
385
+ --no-update Do not check for updates (default)
386
+ --update-to [CHANNEL]@[TAG] Upgrade/downgrade to a specific version.
387
+ CHANNEL can be a repository as well. CHANNEL
388
+ and TAG default to "stable" and "latest"
389
+ respectively if omitted; See "UPDATE" for
390
+ details. Supported channels: stable,
391
+ nightly, master
392
+ -i, --ignore-errors Ignore download and postprocessing errors.
393
+ The download will be considered successful
394
+ even if the postprocessing fails
395
+ --no-abort-on-error Continue with next video on download errors;
396
+ e.g. to skip unavailable videos in a
397
+ playlist (default)
398
+ --abort-on-error Abort downloading of further videos if an
399
+ error occurs (Alias: --no-ignore-errors)
400
+ --list-extractors List all supported extractors and exit
401
+ --extractor-descriptions Output descriptions of all supported
402
+ extractors and exit
403
+ --use-extractors NAMES Extractor names to use separated by commas.
404
+ You can also use regexes, "all", "default"
405
+ and "end" (end URL matching); e.g. --ies
406
+ "holodex.*,end,youtube". Prefix the name
407
+ with a "-" to exclude it, e.g. --ies
408
+ default,-generic. Use --list-extractors for
409
+ a list of extractor names. (Alias: --ies)
410
+ --default-search PREFIX Use this prefix for unqualified URLs. E.g.
411
+ "gvsearch2:python" downloads two videos from
412
+ google videos for the search term "python".
413
+ Use the value "auto" to let freestuff guess
414
+ ("auto_warning" to emit a warning when
415
+ guessing). "error" just throws an error. The
416
+ default value "fixup_error" repairs broken
417
+ URLs, but emits an error if this is not
418
+ possible instead of searching
419
+ --ignore-config Don't load any more configuration files
420
+ except those given to --config-locations.
421
+ For backward compatibility, if this option
422
+ is found inside the system configuration
423
+ file, the user configuration is not loaded.
424
+ (Alias: --no-config)
425
+ --no-config-locations Do not load any custom configuration files
426
+ (default). When given inside a configuration
427
+ file, ignore all previous --config-locations
428
+ defined in the current file
429
+ --config-locations PATH Location of the main configuration file;
430
+ either the path to the config or its
431
+ containing directory ("-" for stdin). Can be
432
+ used multiple times and inside other
433
+ configuration files
434
+ --plugin-dirs DIR Path to an additional directory to search
435
+ for plugins. This option can be used
436
+ multiple times to add multiple directories.
437
+ Use "default" to search the default plugin
438
+ directories (default)
439
+ --no-plugin-dirs Clear plugin directories to search,
440
+ including defaults and those provided by
441
+ previous --plugin-dirs
442
+ --js-runtimes RUNTIME[:PATH] Additional JavaScript runtime to enable,
443
+ with an optional location for the runtime
444
+ (either the path to the binary or its
445
+ containing directory). This option can be
446
+ used multiple times to enable multiple
447
+ runtimes. Supported runtimes are (in order
448
+ of priority, from highest to lowest): deno,
449
+ node, quickjs, bun. Only "deno" is enabled
450
+ by default. The highest priority runtime
451
+ that is both enabled and available will be
452
+ used. In order to use a lower priority
453
+ runtime when "deno" is available, --no-js-
454
+ runtimes needs to be passed before enabling
455
+ other runtimes
456
+ --no-js-runtimes Clear JavaScript runtimes to enable,
457
+ including defaults and those provided by
458
+ previous --js-runtimes
459
+ --remote-components COMPONENT Remote components to allow freestuff to fetch
460
+ when required. This option is currently not
461
+ needed if you are using an official
462
+ executable or have the requisite version of
463
+ the freestuff-ejs package installed. You can
464
+ use this option multiple times to allow
465
+ multiple components. Supported values:
466
+ ejs:npm (external JavaScript components from
467
+ npm), ejs:github (external JavaScript
468
+ components from freestuff-ejs GitHub). By
469
+ default, no remote components are allowed
470
+ --no-remote-components Disallow fetching of all remote components,
471
+ including any previously allowed by
472
+ --remote-components or defaults.
473
+ --flat-playlist Do not extract a playlist's URL result
474
+ entries; some entry metadata may be missing
475
+ and downloading may be bypassed
476
+ --no-flat-playlist Fully extract the videos of a playlist
477
+ (default)
478
+ --live-from-start Download livestreams from the start.
479
+ Currently experimental and only supported
480
+ for YouTube, Twitch, TVer, and mellow-fan
481
+ --no-live-from-start Download livestreams from the current time
482
+ (default)
483
+ --wait-for-video MIN[-MAX] Wait for scheduled streams to become
484
+ available. Pass the minimum number of
485
+ seconds (or range) to wait between retries
486
+ --no-wait-for-video Do not wait for scheduled streams (default)
487
+ --mark-watched Mark videos watched (even with --simulate)
488
+ --no-mark-watched Do not mark videos watched (default)
489
+ --color [STREAM:]POLICY Whether to emit color codes in output,
490
+ optionally prefixed by the STREAM (stdout or
491
+ stderr) to apply the setting to. Can be one
492
+ of "always", "auto" (default), "never", or
493
+ "no_color" (use non color terminal
494
+ sequences). Use "auto-tty" or "no_color-tty"
495
+ to decide based on terminal support only.
496
+ Can be used multiple times
497
+ --compat-options OPTS Options that can help keep compatibility
498
+ with youtube-dl or youtube-dlc
499
+ configurations by reverting some of the
500
+ changes made in freestuff. See "Differences in
501
+ default behavior" for details
502
+ --alias ALIASES OPTIONS Create aliases for an option string. Unless
503
+ an alias starts with a dash "-", it is
504
+ prefixed with "--". Arguments are parsed
505
+ according to the Python string formatting
506
+ mini-language. E.g. --alias get-audio,-X "-S
507
+ aext:{0},abr -x --audio-format {0}" creates
508
+ options "--get-audio" and "-X" that takes an
509
+ argument (ARG0) and expands to "-S
510
+ aext:ARG0,abr -x --audio-format ARG0". All
511
+ defined aliases are listed in the --help
512
+ output. Alias options can trigger more
513
+ aliases; so be careful to avoid defining
514
+ recursive options. As a safety measure, each
515
+ alias may be triggered a maximum of 100
516
+ times. This option can be used multiple times
517
+ -t, --preset-alias PRESET Applies a predefined set of options. e.g.
518
+ --preset-alias mp3. The following presets
519
+ are available: mp3, aac, mp4, mkv, sleep.
520
+ See the "Preset Aliases" section at the end
521
+ for more info. This option can be used
522
+ multiple times
523
+
524
+ ## Network Options:
525
+ --proxy URL Use the specified HTTP/HTTPS/SOCKS proxy. To
526
+ enable SOCKS proxy, specify a proper scheme,
527
+ e.g. socks5://user:pass@127.0.0.1:1080/.
528
+ Pass in an empty string (--proxy "") for
529
+ direct connection
530
+ --socket-timeout SECONDS Time to wait before giving up, in seconds
531
+ --source-address IP Client-side IP address to bind to
532
+ --impersonate CLIENT[:OS] Client to impersonate for requests. E.g.
533
+ chrome, chrome-110, chrome:windows-10. Pass
534
+ --impersonate="" to impersonate any client.
535
+ Note that forcing impersonation for all
536
+ requests may have a detrimental impact on
537
+ download speed and stability
538
+ --list-impersonate-targets List available clients to impersonate.
539
+ -4, --force-ipv4 Make all connections via IPv4
540
+ -6, --force-ipv6 Make all connections via IPv6
541
+ --enable-file-urls Enable file:// URLs. This is disabled by
542
+ default for security reasons.
543
+
544
+ ## Geo-restriction:
545
+ --geo-verification-proxy URL Use this proxy to verify the IP address for
546
+ some geo-restricted sites. The default proxy
547
+ specified by --proxy (or none, if the option
548
+ is not present) is used for the actual
549
+ downloading
550
+ --xff VALUE How to fake X-Forwarded-For HTTP header to
551
+ try bypassing geographic restriction. One of
552
+ "default" (only when known to be useful),
553
+ "never", an IP block in CIDR notation, or a
554
+ two-letter ISO 3166-2 country code
555
+
556
+ ## Video Selection:
557
+ -I, --playlist-items ITEM_SPEC Comma-separated playlist_index of the items
558
+ to download. You can specify a range using
559
+ "[START]:[STOP][:STEP]". For backward
560
+ compatibility, START-STOP is also supported.
561
+ Use negative indices to count from the right
562
+ and negative STEP to download in reverse
563
+ order. E.g. "-I 1:3,7,-5::2" used on a
564
+ playlist of size 15 will download the items
565
+ at index 1,2,3,7,11,13,15
566
+ --min-filesize SIZE Abort download if filesize is smaller than
567
+ SIZE, e.g. 50k or 44.6M
568
+ --max-filesize SIZE Abort download if filesize is larger than
569
+ SIZE, e.g. 50k or 44.6M
570
+ --date DATE Download only videos uploaded on this date.
571
+ The date can be "YYYYMMDD" or in the format
572
+ [now|today|yesterday][-N[day|week|month|year]].
573
+ E.g. "--date today-2weeks" downloads only
574
+ videos uploaded on the same day two weeks ago
575
+ --datebefore DATE Download only videos uploaded on or before
576
+ this date. The date formats accepted are the
577
+ same as --date
578
+ --dateafter DATE Download only videos uploaded on or after
579
+ this date. The date formats accepted are the
580
+ same as --date
581
+ --match-filters FILTER Generic video filter. Any "OUTPUT TEMPLATE"
582
+ field can be compared with a number or a
583
+ string using the operators defined in
584
+ "Filtering Formats". You can also simply
585
+ specify a field to match if the field is
586
+ present, use "!field" to check if the field
587
+ is not present, and "&" to check multiple
588
+ conditions. Use a "\" to escape "&" or
589
+ quotes if needed. If used multiple times,
590
+ the filter matches if at least one of the
591
+ conditions is met. E.g. --match-filters
592
+ !is_live --match-filters "like_count>?100 &
593
+ description~='(?i)\bcats \& dogs\b'" matches
594
+ only videos that are not live OR those that
595
+ have a like count more than 100 (or the like
596
+ field is not available) and also has a
597
+ description that contains the phrase "cats &
598
+ dogs" (caseless). Use "--match-filters -" to
599
+ interactively ask whether to download each
600
+ video
601
+ --no-match-filters Do not use any --match-filters (default)
602
+ --break-match-filters FILTER Same as "--match-filters" but stops the
603
+ download process when a video is rejected
604
+ --no-break-match-filters Do not use any --break-match-filters (default)
605
+ --no-playlist Download only the video, if the URL refers
606
+ to a video and a playlist
607
+ --yes-playlist Download the playlist, if the URL refers to
608
+ a video and a playlist
609
+ --age-limit YEARS Download only videos suitable for the given
610
+ age
611
+ --download-archive FILE Download only videos not listed in the
612
+ archive file. Record the IDs of all
613
+ downloaded videos in it
614
+ --no-download-archive Do not use archive file (default)
615
+ --max-downloads NUMBER Abort after downloading NUMBER files
616
+ --break-on-existing Stop the download process when encountering
617
+ a file that is in the archive supplied with
618
+ the --download-archive option
619
+ --no-break-on-existing Do not stop the download process when
620
+ encountering a file that is in the archive
621
+ (default)
622
+ --break-per-input Alters --max-downloads, --break-on-existing,
623
+ --break-match-filters, and autonumber to
624
+ reset per input URL
625
+ --no-break-per-input --break-on-existing and similar options
626
+ terminates the entire download queue
627
+ --skip-playlist-after-errors N Number of allowed failures until the rest of
628
+ the playlist is skipped
629
+
630
+ ## Download Options:
631
+ -N, --concurrent-fragments N Number of fragments of a dash/hlsnative
632
+ video that should be downloaded concurrently
633
+ (default is 1)
634
+ -r, --limit-rate RATE Maximum download rate in bytes per second,
635
+ e.g. 50K or 4.2M
636
+ --throttled-rate RATE Minimum download rate in bytes per second
637
+ below which throttling is assumed and the
638
+ video data is re-extracted, e.g. 100K
639
+ -R, --retries RETRIES Number of retries (default is 10), or
640
+ "infinite"
641
+ --file-access-retries RETRIES Number of times to retry on file access
642
+ error (default is 3), or "infinite"
643
+ --fragment-retries RETRIES Number of retries for a fragment (default is
644
+ 10), or "infinite" (DASH, hlsnative and ISM)
645
+ --retry-sleep [TYPE:]EXPR Time to sleep between retries in seconds
646
+ (optionally) prefixed by the type of retry
647
+ (http (default), fragment, file_access,
648
+ extractor) to apply the sleep to. EXPR can
649
+ be a number, linear=START[:END[:STEP=1]] or
650
+ exp=START[:END[:BASE=2]]. This option can be
651
+ used multiple times to set the sleep for the
652
+ different retry types, e.g. --retry-sleep
653
+ linear=1::2 --retry-sleep fragment:exp=1:20
654
+ --skip-unavailable-fragments Skip unavailable fragments for DASH,
655
+ hlsnative and ISM downloads (default)
656
+ (Alias: --no-abort-on-unavailable-fragments)
657
+ --abort-on-unavailable-fragments
658
+ Abort download if a fragment is unavailable
659
+ (Alias: --no-skip-unavailable-fragments)
660
+ --keep-fragments Keep downloaded fragments on disk after
661
+ downloading is finished
662
+ --no-keep-fragments Delete downloaded fragments after
663
+ downloading is finished (default)
664
+ --buffer-size SIZE Size of download buffer, e.g. 1024 or 16K
665
+ (default is 1024)
666
+ --resize-buffer The buffer size is automatically resized
667
+ from an initial value of --buffer-size
668
+ (default)
669
+ --no-resize-buffer Do not automatically adjust the buffer size
670
+ --http-chunk-size SIZE Size of a chunk for chunk-based HTTP
671
+ downloading, e.g. 10485760 or 10M (default
672
+ is disabled). May be useful for bypassing
673
+ bandwidth throttling imposed by a webserver
674
+ (experimental)
675
+ --playlist-random Download playlist videos in random order
676
+ --lazy-playlist Process entries in the playlist as they are
677
+ received. This disables n_entries,
678
+ --playlist-random and --playlist-reverse
679
+ --no-lazy-playlist Process videos in the playlist only after
680
+ the entire playlist is parsed (default)
681
+ --hls-use-mpegts Use the mpegts container for HLS videos;
682
+ allowing some players to play the video
683
+ while downloading, and reducing the chance
684
+ of file corruption if download is
685
+ interrupted. This is enabled by default for
686
+ live streams
687
+ --no-hls-use-mpegts Do not use the mpegts container for HLS
688
+ videos. This is default when not downloading
689
+ live streams
690
+ --download-sections REGEX Download only chapters that match the
691
+ regular expression. A "*" prefix denotes
692
+ time-range instead of chapter. Negative
693
+ timestamps are calculated from the end.
694
+ "*from-url" can be used to download between
695
+ the "start_time" and "end_time" extracted
696
+ from the URL. Needs ffmpeg. This option can
697
+ be used multiple times to download multiple
698
+ sections, e.g. --download-sections
699
+ "*10:15-inf" --download-sections "intro"
700
+ --downloader [PROTO:]NAME Name or path of the external downloader to
701
+ use (optionally) prefixed by the protocols
702
+ (http, ftp, m3u8, dash, rtmp) to use it for.
703
+ Currently supports native, aria2c, axel,
704
+ curl, ffmpeg, httpie, wget. You can use this
705
+ option multiple times to set different
706
+ downloaders for different protocols. E.g.
707
+ --downloader aria2c --downloader
708
+ "dash,m3u8:native" will use aria2c for
709
+ http/ftp downloads, and the native
710
+ downloader for dash/m3u8 downloads (Alias:
711
+ --external-downloader)
712
+ --downloader-args NAME:ARGS Give these arguments to the external
713
+ downloader. Specify the downloader name and
714
+ the arguments separated by a colon ":". For
715
+ ffmpeg, arguments can be passed to different
716
+ positions using the same syntax as
717
+ --postprocessor-args. You can use this
718
+ option multiple times to give different
719
+ arguments to different downloaders (Alias:
720
+ --external-downloader-args)
721
+
722
+ ## Filesystem Options:
723
+ -a, --batch-file FILE File containing URLs to download ("-" for
724
+ stdin), one URL per line. Lines starting
725
+ with "#", ";" or "]" are considered as
726
+ comments and ignored
727
+ --no-batch-file Do not read URLs from batch file (default)
728
+ -P, --paths [TYPES:]PATH The paths where the files should be
729
+ downloaded. Specify the type of file and the
730
+ path separated by a colon ":". All the same
731
+ TYPES as --output are supported.
732
+ Additionally, you can also provide "home"
733
+ (default) and "temp" paths. All intermediary
734
+ files are first downloaded to the temp path
735
+ and then the final files are moved over to
736
+ the home path after download is finished.
737
+ This option is ignored if --output is an
738
+ absolute path
739
+ -o, --output [TYPES:]TEMPLATE Output filename template; see "OUTPUT
740
+ TEMPLATE" for details
741
+ --output-na-placeholder TEXT Placeholder for unavailable fields in
742
+ --output (default: "NA")
743
+ --restrict-filenames Restrict filenames to only ASCII characters,
744
+ and avoid "&" and spaces in filenames
745
+ --no-restrict-filenames Allow Unicode characters, "&" and spaces in
746
+ filenames (default)
747
+ --windows-filenames Force filenames to be Windows-compatible
748
+ --no-windows-filenames Sanitize filenames only minimally
749
+ --trim-filenames LENGTH Limit the filename length (excluding
750
+ extension) to the specified number of
751
+ characters
752
+ -w, --no-overwrites Do not overwrite any files
753
+ --force-overwrites Overwrite all video and metadata files. This
754
+ option includes --no-continue
755
+ --no-force-overwrites Do not overwrite the video, but overwrite
756
+ related files (default)
757
+ -c, --continue Resume partially downloaded files/fragments
758
+ (default)
759
+ --no-continue Do not resume partially downloaded
760
+ fragments. If the file is not fragmented,
761
+ restart download of the entire file
762
+ --part Use .part files instead of writing directly
763
+ into output file (default)
764
+ --no-part Do not use .part files - write directly into
765
+ output file
766
+ --mtime Use the Last-modified header to set the file
767
+ modification time
768
+ --no-mtime Do not use the Last-modified header to set
769
+ the file modification time (default)
770
+ --write-description Write video description to a .description file
771
+ --no-write-description Do not write video description (default)
772
+ --write-info-json Write video metadata to a .info.json file
773
+ (this may contain personal information)
774
+ --no-write-info-json Do not write video metadata (default)
775
+ --write-playlist-metafiles Write playlist metadata in addition to the
776
+ video metadata when using --write-info-json,
777
+ --write-description etc. (default)
778
+ --no-write-playlist-metafiles Do not write playlist metadata when using
779
+ --write-info-json, --write-description etc.
780
+ --clean-info-json Remove some internal metadata such as
781
+ filenames from the infojson (default)
782
+ --no-clean-info-json Write all fields to the infojson
783
+ --write-comments Retrieve video comments to be placed in the
784
+ infojson. The comments are fetched even
785
+ without this option if the extraction is
786
+ known to be quick (Alias: --get-comments)
787
+ --no-write-comments Do not retrieve video comments unless the
788
+ extraction is known to be quick (Alias:
789
+ --no-get-comments)
790
+ --load-info-json FILE JSON file containing the video information
791
+ (created with the "--write-info-json" option)
792
+ --cookies FILE Netscape formatted file to read cookies from
793
+ and dump cookie jar in
794
+ --no-cookies Do not read/dump cookies from/to file
795
+ (default)
796
+ --cookies-from-browser BROWSER[+KEYRING][:PROFILE][::CONTAINER]
797
+ The name of the browser to load cookies
798
+ from. Currently supported browsers are:
799
+ brave, chrome, chromium, edge, firefox,
800
+ opera, safari, vivaldi, whale. Optionally,
801
+ the KEYRING used for decrypting Chromium
802
+ cookies on Linux, the name/path of the
803
+ PROFILE to load cookies from, and the
804
+ CONTAINER name (if Firefox) ("none" for no
805
+ container) can be given with their
806
+ respective separators. By default, all
807
+ containers of the most recently accessed
808
+ profile are used. Currently supported
809
+ keyrings are: basictext, gnomekeyring,
810
+ kwallet, kwallet5, kwallet6
811
+ --no-cookies-from-browser Do not load cookies from browser (default)
812
+ --cache-dir DIR Location in the filesystem where freestuff can
813
+ store some downloaded information (such as
814
+ client ids and signatures) permanently. By
815
+ default ${XDG_CACHE_HOME}/freestuff
816
+ --no-cache-dir Disable filesystem caching
817
+ --rm-cache-dir Delete all filesystem cache files
818
+
819
+ ## Thumbnail Options:
820
+ --write-thumbnail Write thumbnail image to disk
821
+ --no-write-thumbnail Do not write thumbnail image to disk (default)
822
+ --write-all-thumbnails Write all thumbnail image formats to disk
823
+ --list-thumbnails List available thumbnails of each video.
824
+ Simulate unless --no-simulate is used
825
+
826
+ ## Internet Shortcut Options:
827
+ --write-link Write an internet shortcut file, depending
828
+ on the current platform (.url, .webloc or
829
+ .desktop). The URL may be cached by the OS
830
+ --write-url-link Write a .url Windows internet shortcut. The
831
+ OS caches the URL based on the file path
832
+ --write-webloc-link Write a .webloc macOS internet shortcut
833
+ --write-desktop-link Write a .desktop Linux internet shortcut
834
+
835
+ ## Verbosity and Simulation Options:
836
+ -q, --quiet Activate quiet mode. If used with --verbose,
837
+ print the log to stderr
838
+ --no-quiet Deactivate quiet mode. (Default)
839
+ --no-warnings Ignore warnings
840
+ -s, --simulate Do not download the video and do not write
841
+ anything to disk
842
+ --no-simulate Download the video even if printing/listing
843
+ options are used
844
+ --ignore-no-formats-error Ignore "No video formats" error. Useful for
845
+ extracting metadata even if the videos are
846
+ not actually available for download
847
+ (experimental)
848
+ --no-ignore-no-formats-error Throw error when no downloadable video
849
+ formats are found (default)
850
+ --skip-download Do not download the video but write all
851
+ related files (Alias: --no-download)
852
+ -O, --print [WHEN:]TEMPLATE Field name or output template to print to
853
+ screen, optionally prefixed with when to
854
+ print it, separated by a ":". Supported
855
+ values of "WHEN" are the same as that of
856
+ --use-postprocessor (default: video).
857
+ Implies --quiet. Implies --simulate unless
858
+ --no-simulate or later stages of WHEN are
859
+ used. This option can be used multiple times
860
+ --print-to-file [WHEN:]TEMPLATE FILE
861
+ Append given template to the file. The
862
+ values of WHEN and TEMPLATE are the same as
863
+ that of --print. FILE uses the same syntax
864
+ as the output template. This option can be
865
+ used multiple times
866
+ -j, --dump-json Quiet, but print JSON information for each
867
+ video. Simulate unless --no-simulate is
868
+ used. See "OUTPUT TEMPLATE" for a
869
+ description of available keys
870
+ -J, --dump-single-json Quiet, but print JSON information for each
871
+ URL or infojson passed. Simulate unless
872
+ --no-simulate is used. If the URL refers to
873
+ a playlist, the whole playlist information
874
+ is dumped in a single line
875
+ --force-write-archive Force download archive entries to be written
876
+ as far as no errors occur, even if -s or
877
+ another simulation option is used (Alias:
878
+ --force-download-archive)
879
+ --newline Output progress bar as new lines
880
+ --no-progress Do not print progress bar
881
+ --progress Show progress bar, even if in quiet mode
882
+ --console-title Display progress in console titlebar
883
+ --progress-template [TYPES:]TEMPLATE
884
+ Template for progress outputs, optionally
885
+ prefixed with one of "download:" (default),
886
+ "download-title:" (the console title),
887
+ "postprocess:", or "postprocess-title:".
888
+ The video's fields are accessible under the
889
+ "info" key and the progress attributes are
890
+ accessible under "progress" key. E.g.
891
+ --console-title --progress-template
892
+ "download-title:%(info.id)s-%(progress.eta)s"
893
+ --progress-delta SECONDS Time between progress output (default: 0)
894
+ -v, --verbose Print various debugging information
895
+ --dump-pages Print downloaded pages encoded using base64
896
+ to debug problems (very verbose)
897
+ --write-pages Write downloaded intermediary pages to files
898
+ in the current directory to debug problems
899
+ --print-traffic Display sent and read HTTP traffic
900
+
901
+ ## Workarounds:
902
+ --encoding ENCODING Force the specified encoding (experimental)
903
+ --legacy-server-connect Explicitly allow HTTPS connection to servers
904
+ that do not support RFC 5746 secure
905
+ renegotiation
906
+ --no-check-certificates Suppress HTTPS certificate validation
907
+ --prefer-insecure Use an unencrypted connection to retrieve
908
+ information about the video
909
+ --add-headers FIELD:VALUE Specify a custom HTTP header and its value,
910
+ separated by a colon ":". You can use this
911
+ option multiple times
912
+ --bidi-workaround Work around terminals that lack
913
+ bidirectional text support. Requires bidiv
914
+ or fribidi executable in PATH
915
+ --sleep-requests SECONDS Number of seconds to sleep between requests
916
+ during data extraction
917
+ --sleep-interval SECONDS Number of seconds to sleep before each
918
+ download. This is the minimum time to sleep
919
+ when used along with --max-sleep-interval
920
+ (Alias: --min-sleep-interval)
921
+ --max-sleep-interval SECONDS Maximum number of seconds to sleep. Can only
922
+ be used along with --min-sleep-interval
923
+ --sleep-subtitles SECONDS Number of seconds to sleep before each
924
+ subtitle download
925
+
926
+ ## Video Format Options:
927
+ -f, --format FORMAT Video format code, see "FORMAT SELECTION"
928
+ for more details
929
+ -S, --format-sort SORTORDER Sort the formats by the fields given, see
930
+ "Sorting Formats" for more details
931
+ --format-sort-reset Disregard previous user specified sort order
932
+ and reset to the default
933
+ --format-sort-force Force user specified sort order to have
934
+ precedence over all fields, see "Sorting
935
+ Formats" for more details (Alias: --S-force)
936
+ --no-format-sort-force Some fields have precedence over the user
937
+ specified sort order (default)
938
+ --video-multistreams Allow multiple video streams to be merged
939
+ into a single file
940
+ --no-video-multistreams Only one video stream is downloaded for each
941
+ output file (default)
942
+ --audio-multistreams Allow multiple audio streams to be merged
943
+ into a single file
944
+ --no-audio-multistreams Only one audio stream is downloaded for each
945
+ output file (default)
946
+ --prefer-free-formats Prefer video formats with free containers
947
+ over non-free ones of the same quality. Use
948
+ with "-S ext" to strictly prefer free
949
+ containers irrespective of quality
950
+ --no-prefer-free-formats Don't give any special preference to free
951
+ containers (default)
952
+ --check-formats Make sure formats are selected only from
953
+ those that are actually downloadable
954
+ --check-all-formats Check all formats for whether they are
955
+ actually downloadable
956
+ --no-check-formats Do not check that the formats are actually
957
+ downloadable
958
+ -F, --list-formats List available formats of each video.
959
+ Simulate unless --no-simulate is used
960
+ --merge-output-format FORMAT Containers that may be used when merging
961
+ formats, separated by "/", e.g. "mp4/mkv".
962
+ Ignored if no merge is required. (currently
963
+ supported: avi, flv, mkv, mov, mp4, webm)
964
+
965
+ ## Subtitle Options:
966
+ --write-subs Write subtitle file
967
+ --no-write-subs Do not write subtitle file (default)
968
+ --write-auto-subs Write automatically generated subtitle file
969
+ (Alias: --write-automatic-subs)
970
+ --no-write-auto-subs Do not write auto-generated subtitles
971
+ (default) (Alias: --no-write-automatic-subs)
972
+ --list-subs List available subtitles of each video.
973
+ Simulate unless --no-simulate is used
974
+ --sub-format FORMAT Subtitle format; accepts formats preference
975
+ separated by "/", e.g. "srt" or "ass/srt/best"
976
+ --sub-langs LANGS Languages of the subtitles to download (can
977
+ be regex) or "all" separated by commas, e.g.
978
+ --sub-langs "en.*,ja" (where "en.*" is a
979
+ regex pattern that matches "en" followed by
980
+ 0 or more of any character). You can prefix
981
+ the language code with a "-" to exclude it
982
+ from the requested languages, e.g. --sub-
983
+ langs all,-live_chat. Use --list-subs for a
984
+ list of available language tags
985
+
986
+ ## Authentication Options:
987
+ -u, --username USERNAME Login with this account ID
988
+ -p, --password PASSWORD Account password. If this option is left
989
+ out, freestuff will ask interactively
990
+ -2, --twofactor TWOFACTOR Two-factor authentication code
991
+ -n, --netrc Use .netrc authentication data
992
+ --netrc-location PATH Location of .netrc authentication data;
993
+ either the path or its containing directory.
994
+ Defaults to ~/.netrc
995
+ --netrc-cmd NETRC_CMD Command to execute to get the credentials
996
+ for an extractor.
997
+ --video-password PASSWORD Video-specific password
998
+ --ap-mso MSO Adobe Pass multiple-system operator (TV
999
+ provider) identifier, use --ap-list-mso for
1000
+ a list of available MSOs
1001
+ --ap-username USERNAME Multiple-system operator account login
1002
+ --ap-password PASSWORD Multiple-system operator account password.
1003
+ If this option is left out, freestuff will ask
1004
+ interactively
1005
+ --ap-list-mso List all supported multiple-system operators
1006
+ --client-certificate CERTFILE Path to client certificate file in PEM
1007
+ format. May include the private key
1008
+ --client-certificate-key KEYFILE
1009
+ Path to private key file for client
1010
+ certificate
1011
+ --client-certificate-password PASSWORD
1012
+ Password for client certificate private key,
1013
+ if encrypted. If not provided, and the key
1014
+ is encrypted, freestuff will ask interactively
1015
+
1016
+ ## Post-Processing Options:
1017
+ -x, --extract-audio Convert video files to audio-only files
1018
+ (requires ffmpeg and ffprobe)
1019
+ --audio-format FORMAT Format to convert the audio to when -x is
1020
+ used. (currently supported: best (default),
1021
+ aac, alac, flac, m4a, mp3, opus, vorbis,
1022
+ wav). You can specify multiple rules using
1023
+ similar syntax as --remux-video
1024
+ --audio-quality QUALITY Specify ffmpeg audio quality to use when
1025
+ converting the audio with -x. Insert a value
1026
+ between 0 (best) and 10 (worst) for VBR or a
1027
+ specific bitrate like 128K (default 5)
1028
+ --remux-video FORMAT Remux the video into another container if
1029
+ necessary (currently supported: avi, flv,
1030
+ gif, mkv, mov, mp4, webm, aac, aiff, alac,
1031
+ flac, m4a, mka, mp3, ogg, opus, vorbis,
1032
+ wav). If the target container does not
1033
+ support the video/audio codec, remuxing will
1034
+ fail. You can specify multiple rules; e.g.
1035
+ "aac>m4a/mov>mp4/mkv" will remux aac to m4a,
1036
+ mov to mp4 and anything else to mkv
1037
+ --recode-video FORMAT Re-encode the video into another format if
1038
+ necessary. The syntax and supported formats
1039
+ are the same as --remux-video
1040
+ --postprocessor-args NAME:ARGS Give these arguments to the postprocessors.
1041
+ Specify the postprocessor/executable name
1042
+ and the arguments separated by a colon ":"
1043
+ to give the argument to the specified
1044
+ postprocessor/executable. Supported PP are:
1045
+ Merger, ModifyChapters, SplitChapters,
1046
+ ExtractAudio, VideoRemuxer, VideoConvertor,
1047
+ Metadata, EmbedSubtitle, EmbedThumbnail,
1048
+ SubtitlesConvertor, ThumbnailsConvertor,
1049
+ FixupStretched, FixupM4a, FixupM3u8,
1050
+ FixupTimestamp and FixupDuration. The
1051
+ supported executables are: AtomicParsley,
1052
+ FFmpeg and FFprobe. You can also specify
1053
+ "PP+EXE:ARGS" to give the arguments to the
1054
+ specified executable only when being used by
1055
+ the specified postprocessor. Additionally,
1056
+ for ffmpeg/ffprobe, "_i"/"_o" can be
1057
+ appended to the prefix optionally followed
1058
+ by a number to pass the argument before the
1059
+ specified input/output file, e.g. --ppa
1060
+ "Merger+ffmpeg_i1:-v quiet". You can use
1061
+ this option multiple times to give different
1062
+ arguments to different postprocessors.
1063
+ (Alias: --ppa)
1064
+ -k, --keep-video Keep the intermediate video file on disk
1065
+ after post-processing
1066
+ --no-keep-video Delete the intermediate video file after
1067
+ post-processing (default)
1068
+ --post-overwrites Overwrite post-processed files (default)
1069
+ --no-post-overwrites Do not overwrite post-processed files
1070
+ --embed-subs Embed subtitles in the video (only for mp4,
1071
+ webm and mkv videos)
1072
+ --no-embed-subs Do not embed subtitles (default)
1073
+ --embed-thumbnail Embed thumbnail in the video as cover art
1074
+ --no-embed-thumbnail Do not embed thumbnail (default)
1075
+ --embed-metadata Embed metadata to the video file. Also
1076
+ embeds chapters/infojson if present unless
1077
+ --no-embed-chapters/--no-embed-info-json are
1078
+ used (Alias: --add-metadata)
1079
+ --no-embed-metadata Do not add metadata to file (default)
1080
+ (Alias: --no-add-metadata)
1081
+ --embed-chapters Add chapter markers to the video file
1082
+ (Alias: --add-chapters)
1083
+ --no-embed-chapters Do not add chapter markers (default) (Alias:
1084
+ --no-add-chapters)
1085
+ --embed-info-json Embed the infojson as an attachment to
1086
+ mkv/mka video files
1087
+ --no-embed-info-json Do not embed the infojson as an attachment
1088
+ to the video file
1089
+ --parse-metadata [WHEN:]FROM:TO
1090
+ Parse additional metadata like title/artist
1091
+ from other fields; see "MODIFYING METADATA"
1092
+ for details. Supported values of "WHEN" are
1093
+ the same as that of --use-postprocessor
1094
+ (default: pre_process)
1095
+ --replace-in-metadata [WHEN:]FIELDS REGEX REPLACE
1096
+ Replace text in a metadata field using the
1097
+ given regex. This option can be used
1098
+ multiple times. Supported values of "WHEN"
1099
+ are the same as that of --use-postprocessor
1100
+ (default: pre_process)
1101
+ --xattrs Write metadata to the video file's xattrs
1102
+ (using Dublin Core and XDG standards)
1103
+ --concat-playlist POLICY Concatenate videos in a playlist. One of
1104
+ "never", "always", or "multi_video"
1105
+ (default; only when the videos form a single
1106
+ show). All the video files must have the
1107
+ same codecs and number of streams to be
1108
+ concatenable. The "pl_video:" prefix can be
1109
+ used with "--paths" and "--output" to set
1110
+ the output filename for the concatenated
1111
+ files. See "OUTPUT TEMPLATE" for details
1112
+ --fixup POLICY Automatically correct known faults of the
1113
+ file. One of never (do nothing), warn (only
1114
+ emit a warning), detect_or_warn (the
1115
+ default; fix the file if we can, warn
1116
+ otherwise), force (try fixing even if the
1117
+ file already exists)
1118
+ --ffmpeg-location PATH Location of the ffmpeg binary; either the
1119
+ path to the binary or its containing directory
1120
+ --exec [WHEN:]CMD Execute a command, optionally prefixed with
1121
+ when to execute it, separated by a ":".
1122
+ Supported values of "WHEN" are the same as
1123
+ that of --use-postprocessor (default:
1124
+ after_move). The same syntax as the output
1125
+ template can be used to pass any field as
1126
+ arguments to the command; however, for
1127
+ security reasons the only allowed
1128
+ conversions are: "i"/"d" (signed integer
1129
+ decimal), "f" (floating-point decimal) and
1130
+ "q" (shell-quoted). If no fields are passed,
1131
+ %(filepath,_filename|)q is appended to the
1132
+ end of the command. This option can be used
1133
+ multiple times
1134
+ --no-exec Remove any previously defined --exec
1135
+ --convert-subs FORMAT Convert the subtitles to another format
1136
+ (currently supported: ass, lrc, srt, vtt).
1137
+ Use "--convert-subs none" to disable
1138
+ conversion (default) (Alias: --convert-
1139
+ subtitles)
1140
+ --convert-thumbnails FORMAT Convert the thumbnails to another format
1141
+ (currently supported: jpg, png, webp). You
1142
+ can specify multiple rules using similar
1143
+ syntax as "--remux-video". Use "--convert-
1144
+ thumbnails none" to disable conversion
1145
+ (default)
1146
+ --split-chapters Split video into multiple files based on
1147
+ internal chapters. The "chapter:" prefix can
1148
+ be used with "--paths" and "--output" to set
1149
+ the output filename for the split files. See
1150
+ "OUTPUT TEMPLATE" for details
1151
+ --no-split-chapters Do not split video based on chapters (default)
1152
+ --remove-chapters REGEX Remove chapters whose title matches the
1153
+ given regular expression. The syntax is the
1154
+ same as --download-sections. This option can
1155
+ be used multiple times
1156
+ --no-remove-chapters Do not remove any chapters from the file
1157
+ (default)
1158
+ --force-keyframes-at-cuts Force keyframes at cuts when
1159
+ downloading/splitting/removing sections.
1160
+ This is slow due to needing a re-encode, but
1161
+ the resulting video may have fewer artifacts
1162
+ around the cuts
1163
+ --no-force-keyframes-at-cuts Do not force keyframes around the chapters
1164
+ when cutting/splitting (default)
1165
+ --use-postprocessor NAME[:ARGS]
1166
+ The (case-sensitive) name of plugin
1167
+ postprocessors to be enabled, and
1168
+ (optionally) arguments to be passed to it,
1169
+ separated by a colon ":". ARGS are a
1170
+ semicolon ";" delimited list of NAME=VALUE.
1171
+ The "when" argument determines when the
1172
+ postprocessor is invoked. It can be one of
1173
+ "pre_process" (after video extraction),
1174
+ "after_filter" (after video passes filter),
1175
+ "video" (after --format; before
1176
+ --print/--output), "before_dl" (before each
1177
+ video download), "post_process" (after each
1178
+ video download; default), "after_move"
1179
+ (after moving the video file to its final
1180
+ location), "after_video" (after downloading
1181
+ and processing all formats of a video), or
1182
+ "playlist" (at end of playlist). This option
1183
+ can be used multiple times to add different
1184
+ postprocessors
1185
+
1186
+ ## SponsorBlock Options:
1187
+ Make chapter entries for, or remove various segments (sponsor,
1188
+ introductions, etc.) from downloaded YouTube videos using the
1189
+ [SponsorBlock API](https://sponsor.ajay.app)
1190
+
1191
+ --sponsorblock-mark CATS SponsorBlock categories to create chapters
1192
+ for, separated by commas. Available
1193
+ categories are sponsor, intro, outro,
1194
+ selfpromo, preview, filler, interaction,
1195
+ music_offtopic, hook, poi_highlight,
1196
+ chapter, all and default (=all). You can
1197
+ prefix the category with a "-" to exclude
1198
+ it. See [1] for descriptions of the
1199
+ categories. E.g. --sponsorblock-mark
1200
+ all,-preview
1201
+ [1] https://wiki.sponsor.ajay.app/w/Segment_Categories
1202
+ --sponsorblock-remove CATS SponsorBlock categories to be removed from
1203
+ the video file, separated by commas. If a
1204
+ category is present in both mark and remove,
1205
+ remove takes precedence. The syntax and
1206
+ available categories are the same as for
1207
+ --sponsorblock-mark except that "default"
1208
+ refers to "all,-filler" and poi_highlight,
1209
+ chapter are not available
1210
+ --sponsorblock-chapter-title TEMPLATE
1211
+ An output template for the title of the
1212
+ SponsorBlock chapters created by
1213
+ --sponsorblock-mark. The only available
1214
+ fields are start_time, end_time, category,
1215
+ categories, name, category_names. Defaults
1216
+ to "[SponsorBlock]: %(category_names)l"
1217
+ --no-sponsorblock Disable both --sponsorblock-mark and
1218
+ --sponsorblock-remove
1219
+ --sponsorblock-api URL SponsorBlock API location, defaults to
1220
+ https://sponsor.ajay.app
1221
+
1222
+ ## Extractor Options:
1223
+ --extractor-retries RETRIES Number of retries for known extractor errors
1224
+ (default is 3), or "infinite"
1225
+ --allow-dynamic-mpd Process dynamic DASH manifests (default)
1226
+ (Alias: --no-ignore-dynamic-mpd)
1227
+ --ignore-dynamic-mpd Do not process dynamic DASH manifests
1228
+ (Alias: --no-allow-dynamic-mpd)
1229
+ --hls-split-discontinuity Split HLS playlists to different formats at
1230
+ discontinuities such as ad breaks
1231
+ --no-hls-split-discontinuity Do not split HLS playlists into different
1232
+ formats at discontinuities such as ad breaks
1233
+ (default)
1234
+ --extractor-args IE_KEY:ARGS Pass ARGS arguments to the IE_KEY extractor.
1235
+ See "EXTRACTOR ARGUMENTS" for details. You
1236
+ can use this option multiple times to give
1237
+ arguments for different extractors
1238
+
1239
+ ## Preset Aliases:
1240
+ Predefined aliases for convenience and ease of use. Note that future
1241
+ versions of freestuff may add or adjust presets, but the existing preset
1242
+ names will not be changed or removed
1243
+
1244
+ -t mp3 -f 'ba[acodec^=mp3]/ba/b' -x --audio-format
1245
+ mp3
1246
+
1247
+ -t aac -f
1248
+ 'ba[acodec^=aac]/ba[acodec^=mp4a.40.]/ba/b'
1249
+ -x --audio-format aac
1250
+
1251
+ -t mp4 --merge-output-format mp4 --remux-video mp4
1252
+ -S vcodec:h264,lang,quality,res,fps,hdr:12,a
1253
+ codec:aac
1254
+
1255
+ -t mkv --merge-output-format mkv --remux-video mkv
1256
+
1257
+ -t sleep --sleep-subtitles 5 --sleep-requests 0.75
1258
+ --sleep-interval 10 --max-sleep-interval 20
1259
+
1260
+ # CONFIGURATION
1261
+
1262
+ You can configure freestuff by placing any supported command line option in a configuration file. The configuration is loaded from the following locations:
1263
+
1264
+ 1. **Main Configuration**:
1265
+ * The file given to `--config-locations`
1266
+ 1. **Portable Configuration**: (Recommended for portable installations)
1267
+ * If using a binary, `freestuff.conf` in the same directory as the binary
1268
+ * If running from source-code, `freestuff.conf` in the parent directory of `yt_dlp`
1269
+ 1. **Home Configuration**:
1270
+ * `freestuff.conf` in the home path given to `-P`
1271
+ * If `-P` is not given, the current directory is searched
1272
+ 1. **User Configuration**:
1273
+ * `${XDG_CONFIG_HOME}/freestuff.conf`
1274
+ * `${XDG_CONFIG_HOME}/freestuff/config` (recommended on Linux/macOS)
1275
+ * `${XDG_CONFIG_HOME}/freestuff/config.txt`
1276
+ * `${APPDATA}/freestuff.conf`
1277
+ * `${APPDATA}/freestuff/config` (recommended on Windows)
1278
+ * `${APPDATA}/freestuff/config.txt`
1279
+ * `~/freestuff.conf`
1280
+ * `~/freestuff.conf.txt`
1281
+ * `~/.freestuff/config`
1282
+ * `~/.freestuff/config.txt`
1283
+
1284
+ See also: [Notes about environment variables](#notes-about-environment-variables)
1285
+ 1. **System Configuration**:
1286
+ * `/etc/freestuff.conf`
1287
+ * `/etc/freestuff/config`
1288
+ * `/etc/freestuff/config.txt`
1289
+
1290
+ E.g. with the following configuration file, freestuff will always extract the audio, copy the mtime, use a proxy and save all videos under `YouTube` directory in your home directory:
1291
+ ```
1292
+ # Lines starting with # are comments
1293
+
1294
+ # Always extract audio
1295
+ -x
1296
+
1297
+ # Copy the mtime
1298
+ --mtime
1299
+
1300
+ # Use this proxy
1301
+ --proxy 127.0.0.1:3128
1302
+
1303
+ # Save all videos under YouTube directory in your home directory
1304
+ -o ~/YouTube/%(title)s.%(ext)s
1305
+ ```
1306
+
1307
+ **Note**: Options in a configuration file are just the same options aka switches used in regular command line calls; thus there **must be no whitespace** after `-` or `--`, e.g. `-o` or `--proxy` but not `- o` or `-- proxy`. They must also be quoted when necessary, as if it were a UNIX shell.
1308
+
1309
+ You can use `--ignore-config` if you want to disable all configuration files for a particular freestuff run. If `--ignore-config` is found inside any configuration file, no further configuration will be loaded. For example, having the option in the portable configuration file prevents loading of home, user, and system configurations. Additionally, (for backward compatibility) if `--ignore-config` is found inside the system configuration file, the user configuration is not loaded.
1310
+
1311
+ ### Configuration file encoding
1312
+
1313
+ The configuration files are decoded according to the UTF BOM if present, and in the encoding from system locale otherwise.
1314
+
1315
+ If you want your file to be decoded differently, add `# coding: ENCODING` to the beginning of the file (e.g. `# coding: shift-jis`). There must be no characters before that, even spaces or BOM.
1316
+
1317
+ ### Authentication with netrc
1318
+
1319
+ You may also want to configure automatic credentials storage for extractors that support authentication (by providing login and password with `--username` and `--password`) in order not to pass credentials as command line arguments on every freestuff execution and prevent tracking plain text passwords in the shell command history. You can achieve this using a [`.netrc` file](https://stackoverflow.com/tags/.netrc/info) on a per-extractor basis. For that, you will need to create a `.netrc` file in `--netrc-location` and restrict permissions to read/write by only you:
1320
+ ```
1321
+ touch ${HOME}/.netrc
1322
+ chmod a-rwx,u+rw ${HOME}/.netrc
1323
+ ```
1324
+ After that, you can add credentials for an extractor in the following format, where *extractor* is the name of the extractor in lowercase:
1325
+ ```
1326
+ machine <extractor> login <username> password <password>
1327
+ ```
1328
+ E.g.
1329
+ ```
1330
+ machine youtube login myaccount@gmail.com password my_youtube_password
1331
+ machine twitch login my_twitch_account_name password my_twitch_password
1332
+ ```
1333
+ To activate authentication with the `.netrc` file you should pass `--netrc` to freestuff or place it in the [configuration file](#configuration).
1334
+
1335
+ The default location of the .netrc file is `~` (see below).
1336
+
1337
+ As an alternative to using the `.netrc` file, which has the disadvantage of keeping your passwords in a plain text file, you can configure a custom shell command to provide the credentials for an extractor. This is done by providing the `--netrc-cmd` parameter, it shall output the credentials in the netrc format and return `0` on success, other values will be treated as an error. `{}` in the command will be replaced by the name of the extractor to make it possible to select the credentials for the right extractor.
1338
+
1339
+ E.g. To use an encrypted `.netrc` file stored as `.authinfo.gpg`
1340
+ ```
1341
+ freestuff --netrc-cmd 'gpg --decrypt ~/.authinfo.gpg' 'https://www.youtube.com/watch?v=YE7VzlLtp-4'
1342
+ ```
1343
+
1344
+
1345
+ ### Notes about environment variables
1346
+ * Environment variables are normally specified as `${VARIABLE}`/`$VARIABLE` on UNIX and `%VARIABLE%` on Windows; but is always shown as `${VARIABLE}` in this documentation
1347
+ * freestuff also allows using UNIX-style variables on Windows for path-like options; e.g. `--output`, `--config-locations`
1348
+ * If unset, `${XDG_CONFIG_HOME}` defaults to `~/.config` and `${XDG_CACHE_HOME}` to `~/.cache`
1349
+ * On Windows, `~` points to `${HOME}` if present; or, `${USERPROFILE}` or `${HOMEDRIVE}${HOMEPATH}` otherwise
1350
+ * On Windows, `${USERPROFILE}` generally points to `C:\Users\<user name>` and `${APPDATA}` to `${USERPROFILE}\AppData\Roaming`
1351
+
1352
+ # OUTPUT TEMPLATE
1353
+
1354
+ The `-o` option is used to indicate a template for the output file names while `-P` option is used to specify the path each type of file should be saved to.
1355
+
1356
+ <!-- MANPAGE: BEGIN EXCLUDED SECTION -->
1357
+ **tl;dr:** [navigate me to examples](#output-template-examples).
1358
+ <!-- MANPAGE: END EXCLUDED SECTION -->
1359
+
1360
+ The simplest usage of `-o` is not to set any template arguments when downloading a single file, like in `freestuff -o funny_video.flv "https://some/video"` (hard-coding file extension like this is _not_ recommended and could break some post-processing).
1361
+
1362
+ It may however also contain special sequences that will be replaced when downloading each video. The special sequences may be formatted according to [Python string formatting operations](https://docs.python.org/3/library/stdtypes.html#printf-style-string-formatting), e.g. `%(NAME)s` or `%(NAME)05d`. To clarify, that is a percent symbol followed by a name in parentheses, followed by formatting operations.
1363
+
1364
+ The field names themselves (the part inside the parenthesis) can also have some special formatting:
1365
+
1366
+ 1. **Object traversal**: The dictionaries and lists available in metadata can be traversed by using a dot `.` separator; e.g. `%(tags.0)s`, `%(subtitles.en.-1.ext)s`. You can do Python slicing with colon `:`; E.g. `%(id.3:7)s`, `%(id.6:2:-1)s`, `%(formats.:.format_id)s`. Curly braces `{}` can be used to build dictionaries with only specific keys; e.g. `%(formats.:.{format_id,height})#j`. An empty field name `%()s` refers to the entire infodict; e.g. `%(.{id,title})s`. Note that all the fields that become available using this method are not listed below. Use `-j` to see such fields
1367
+
1368
+ 1. **Arithmetic**: Simple arithmetic can be done on numeric fields using `+`, `-` and `*`. E.g. `%(playlist_index+10)03d`, `%(n_entries+1-playlist_index)d`
1369
+
1370
+ 1. **Date/time Formatting**: Date/time fields can be formatted according to [strftime formatting](https://docs.python.org/3/library/datetime.html#strftime-and-strptime-format-codes) by specifying it separated from the field name using a `>`. E.g. `%(duration>%H-%M-%S)s`, `%(upload_date>%Y-%m-%d)s`, `%(epoch-3600>%H-%M-%S)s`
1371
+
1372
+ 1. **Alternatives**: Alternate fields can be specified separated with a `,`. E.g. `%(release_date>%Y,upload_date>%Y|Unknown)s`
1373
+
1374
+ 1. **Replacement**: A replacement value can be specified using a `&` separator according to the [`str.format` mini-language](https://docs.python.org/3/library/string.html#format-specification-mini-language). If the field is *not* empty, this replacement value will be used instead of the actual field content. This is done after alternate fields are considered; thus the replacement is used if *any* of the alternative fields is *not* empty. E.g. `%(chapters&has chapters|no chapters)s`, `%(title&TITLE={:>20}|NO TITLE)s`
1375
+
1376
+ 1. **Default**: A literal default value can be specified for when the field is empty using a `|` separator. This overrides `--output-na-placeholder`. E.g. `%(uploader|Unknown)s`
1377
+
1378
+ 1. **More Conversions**: In addition to the normal format types `diouxXeEfFgGcrs`, freestuff additionally supports converting to `B` = **B**ytes, `j` = **j**son (flag `#` for pretty-printing, `+` for Unicode), `h` = HTML escaping, `l` = a comma-separated **l**ist (flag `#` for `\n` newline-separated), `q` = a string **q**uoted for the terminal (flag `#` to split a list into different arguments), `D` = add **D**ecimal suffixes (e.g. 10M) (flag `#` to use 1024 as factor), and `S` = **S**anitize as filename (flag `#` for restricted)
1379
+
1380
+ 1. **Unicode normalization**: The format type `U` can be used for NFC [Unicode normalization](https://docs.python.org/3/library/unicodedata.html#unicodedata.normalize). The alternate form flag (`#`) changes the normalization to NFD and the conversion flag `+` can be used for NFKC/NFKD compatibility equivalence normalization. E.g. `%(title)+.100U` is NFKC
1381
+
1382
+ To summarize, the general syntax for a field is:
1383
+ ```
1384
+ %(name[.keys][addition][>strf][,alternate][&replacement][|default])[flags][width][.precision][length]type
1385
+ ```
1386
+
1387
+ Additionally, you can set different output templates for the various metadata files separately from the general output template by specifying the type of file followed by the template separated by a colon `:`. The different file types supported are `subtitle`, `thumbnail`, `description`, `annotation` (deprecated), `infojson`, `link`, `pl_thumbnail`, `pl_description`, `pl_infojson`, `chapter`, `pl_video`. E.g. `-o "%(title)s.%(ext)s" -o "thumbnail:%(title)s\%(title)s.%(ext)s"` will put the thumbnails in a folder with the same name as the video. If any of the templates is empty, that type of file will not be written. E.g. `--write-thumbnail -o "thumbnail:"` will write thumbnails only for playlists and not for video.
1388
+
1389
+ <a id="outtmpl-postprocess-note"></a>
1390
+
1391
+ **Note**: Due to post-processing (i.e. merging etc.), the actual output filename might differ. Use `--print after_move:filepath` to get the name after all post-processing is complete.
1392
+
1393
+ The available fields are:
1394
+
1395
+ - `id` (string): Video identifier
1396
+ - `title` (string): Video title
1397
+ - `fulltitle` (string): Video title ignoring live timestamp and generic title
1398
+ - `ext` (string): Video filename extension
1399
+ - `alt_title` (string): A secondary title of the video
1400
+ - `description` (string): The description of the video
1401
+ - `display_id` (string): An alternative identifier for the video
1402
+ - `uploader` (string): Full name of the video uploader
1403
+ - `uploader_id` (string): Nickname or id of the video uploader
1404
+ - `uploader_url` (string): URL to the video uploader's profile
1405
+ - `license` (string): License name the video is licensed under
1406
+ - `creators` (list): The creators of the video
1407
+ - `creator` (string): The creators of the video; comma-separated
1408
+ - `timestamp` (numeric): UNIX timestamp of the moment the video became available
1409
+ - `upload_date` (string): Video upload date in UTC (YYYYMMDD)
1410
+ - `release_timestamp` (numeric): UNIX timestamp of the moment the video was released
1411
+ - `release_date` (string): The date (YYYYMMDD) when the video was released in UTC
1412
+ - `release_year` (numeric): Year (YYYY) when the video or album was released
1413
+ - `modified_timestamp` (numeric): UNIX timestamp of the moment the video was last modified
1414
+ - `modified_date` (string): The date (YYYYMMDD) when the video was last modified in UTC
1415
+ - `channel` (string): Full name of the channel the video is uploaded on
1416
+ - `channel_id` (string): Id of the channel
1417
+ - `channel_url` (string): URL of the channel
1418
+ - `channel_follower_count` (numeric): Number of followers of the channel
1419
+ - `channel_is_verified` (boolean): Whether the channel is verified on the platform
1420
+ - `location` (string): Physical location where the video was filmed
1421
+ - `duration` (numeric): Length of the video in seconds
1422
+ - `duration_string` (string): Length of the video (HH:mm:ss)
1423
+ - `view_count` (numeric): How many users have watched the video on the platform
1424
+ - `concurrent_view_count` (numeric): How many users are currently watching the video on the platform.
1425
+ - `like_count` (numeric): Number of positive ratings of the video
1426
+ - `dislike_count` (numeric): Number of negative ratings of the video
1427
+ - `repost_count` (numeric): Number of reposts of the video
1428
+ - `average_rating` (numeric): Average rating given by users, the scale used depends on the webpage
1429
+ - `comment_count` (numeric): Number of comments on the video (For some extractors, comments are only downloaded at the end, and so this field cannot be used)
1430
+ - `save_count` (numeric): Number of times the video has been saved or bookmarked
1431
+ - `age_limit` (numeric): Age restriction for the video (years)
1432
+ - `live_status` (string): One of "not_live", "is_live", "is_upcoming", "was_live", "post_live" (was live, but VOD is not yet processed)
1433
+ - `is_live` (boolean): Whether this video is a live stream or a fixed-length video
1434
+ - `was_live` (boolean): Whether this video was originally a live stream
1435
+ - `playable_in_embed` (string): Whether this video is allowed to play in embedded players on other sites
1436
+ - `availability` (string): Whether the video is "private", "premium_only", "subscriber_only", "needs_auth", "unlisted" or "public"
1437
+ - `media_type` (string): The type of media as classified by the site, e.g. "episode", "clip", "trailer"
1438
+ - `start_time` (numeric): Time in seconds where the reproduction should start, as specified in the URL
1439
+ - `end_time` (numeric): Time in seconds where the reproduction should end, as specified in the URL
1440
+ - `extractor` (string): Name of the extractor
1441
+ - `extractor_key` (string): Key name of the extractor
1442
+ - `epoch` (numeric): Unix epoch of when the information extraction was completed
1443
+ - `autonumber` (numeric): Number that will be increased with each download, starting at `--autonumber-start`, padded with leading zeros to 5 digits
1444
+ - `video_autonumber` (numeric): Number that will be increased with each video
1445
+ - `n_entries` (numeric): Total number of extracted items in the playlist
1446
+ - `playlist_id` (string): Identifier of the playlist that contains the video
1447
+ - `playlist_title` (string): Name of the playlist that contains the video
1448
+ - `playlist` (string): `playlist_title` if available or else `playlist_id`
1449
+ - `playlist_count` (numeric): Total number of items in the playlist. May not be known if entire playlist is not extracted
1450
+ - `playlist_index` (numeric): Index of the video in the playlist padded with leading zeros according the final index
1451
+ - `playlist_autonumber` (numeric): Position of the video in the playlist download queue padded with leading zeros according to the total length of the playlist
1452
+ - `playlist_uploader` (string): Full name of the playlist uploader
1453
+ - `playlist_uploader_id` (string): Nickname or id of the playlist uploader
1454
+ - `playlist_channel` (string): Display name of the channel that uploaded the playlist
1455
+ - `playlist_channel_id` (string): Identifier of the channel that uploaded the playlist
1456
+ - `playlist_webpage_url` (string): URL of the playlist webpage
1457
+ - `webpage_url` (string): A URL to the video webpage which, if given to freestuff, should yield the same result again
1458
+ - `webpage_url_basename` (string): The basename of the webpage URL
1459
+ - `webpage_url_domain` (string): The domain of the webpage URL
1460
+ - `original_url` (string): The URL given by the user (or the same as `webpage_url` for playlist entries)
1461
+ - `categories` (list): List of categories the video belongs to
1462
+ - `tags` (list): List of tags assigned to the video
1463
+ - `cast` (list): List of cast members
1464
+
1465
+ All the fields in [Filtering Formats](#filtering-formats) can also be used
1466
+
1467
+ Available for the video that belongs to some logical chapter or section:
1468
+
1469
+ - `chapter` (string): Name or title of the chapter the video belongs to
1470
+ - `chapter_number` (numeric): Number of the chapter the video belongs to
1471
+ - `chapter_id` (string): Id of the chapter the video belongs to
1472
+
1473
+ Available for the video that is an episode of some series or program:
1474
+
1475
+ - `series` (string): Title of the series or program the video episode belongs to
1476
+ - `series_id` (string): Id of the series or program the video episode belongs to
1477
+ - `season` (string): Title of the season the video episode belongs to
1478
+ - `season_number` (numeric): Number of the season the video episode belongs to
1479
+ - `season_id` (string): Id of the season the video episode belongs to
1480
+ - `episode` (string): Title of the video episode
1481
+ - `episode_number` (numeric): Number of the video episode within a season
1482
+ - `episode_id` (string): Id of the video episode
1483
+
1484
+ Available for the media that is a track or a part of a music album:
1485
+
1486
+ - `track` (string): Title of the track
1487
+ - `track_number` (numeric): Number of the track within an album or a disc
1488
+ - `track_id` (string): Id of the track
1489
+ - `artists` (list): Artist(s) of the track
1490
+ - `artist` (string): Artist(s) of the track; comma-separated
1491
+ - `genres` (list): Genre(s) of the track
1492
+ - `genre` (string): Genre(s) of the track; comma-separated
1493
+ - `composers` (list): Composer(s) of the piece
1494
+ - `composer` (string): Composer(s) of the piece; comma-separated
1495
+ - `album` (string): Title of the album the track belongs to
1496
+ - `album_type` (string): Type of the album
1497
+ - `album_artists` (list): All artists appeared on the album
1498
+ - `album_artist` (string): All artists appeared on the album; comma-separated
1499
+ - `disc_number` (numeric): Number of the disc or other physical medium the track belongs to
1500
+
1501
+ Available only when using `--download-sections` and for `chapter:` prefix when using `--split-chapters` for videos with internal chapters:
1502
+
1503
+ - `section_title` (string): Title of the chapter
1504
+ - `section_number` (numeric): Number of the chapter within the file
1505
+ - `section_start` (numeric): Start time of the chapter in seconds
1506
+ - `section_end` (numeric): End time of the chapter in seconds
1507
+
1508
+ Available only when used in `--print`:
1509
+
1510
+ - `urls` (string): The URLs of all requested formats, one in each line
1511
+ - `filename` (string): Name of the video file. Note that the [actual filename may differ](#outtmpl-postprocess-note)
1512
+ - `formats_table` (table): The video format table as printed by `--list-formats`
1513
+ - `thumbnails_table` (table): The thumbnail format table as printed by `--list-thumbnails`
1514
+ - `subtitles_table` (table): The subtitle format table as printed by `--list-subs`
1515
+ - `automatic_captions_table` (table): The automatic subtitle format table as printed by `--list-subs`
1516
+
1517
+ Available only after the video is downloaded (`post_process`/`after_move`):
1518
+
1519
+ - `filepath`: Actual path of downloaded video file
1520
+
1521
+ Available only in `--sponsorblock-chapter-title`:
1522
+
1523
+ - `start_time` (numeric): Start time of the chapter in seconds
1524
+ - `end_time` (numeric): End time of the chapter in seconds
1525
+ - `categories` (list): The [SponsorBlock categories](https://wiki.sponsor.ajay.app/w/Types#Category) the chapter belongs to
1526
+ - `category` (string): The smallest SponsorBlock category the chapter belongs to
1527
+ - `category_names` (list): Friendly names of the categories
1528
+ - `name` (string): Friendly name of the smallest category
1529
+ - `type` (string): The [SponsorBlock action type](https://wiki.sponsor.ajay.app/w/Types#Action_Type) of the chapter
1530
+
1531
+ Each aforementioned sequence when referenced in an output template will be replaced by the actual value corresponding to the sequence name. E.g. for `-o %(title)s-%(id)s.%(ext)s` and an mp4 video with title `freestuff test video` and id `YE7VzlLtp-4`, this will result in a `freestuff test video-YE7VzlLtp-4.mp4` file created in the current directory.
1532
+
1533
+ **Note**: Some of the sequences are not guaranteed to be present, since they depend on the metadata obtained by a particular extractor. Such sequences will be replaced with placeholder value provided with `--output-na-placeholder` (`NA` by default).
1534
+
1535
+ **Tip**: Look at the `-j` output to identify which fields are available for the particular URL
1536
+
1537
+ For numeric sequences, you can use [numeric related formatting](https://docs.python.org/3/library/stdtypes.html#printf-style-string-formatting); e.g. `%(view_count)05d` will result in a string with view count padded with zeros up to 5 characters, like in `00042`.
1538
+
1539
+ Output templates can also contain arbitrary hierarchical path, e.g. `-o "%(playlist)s/%(playlist_index)s - %(title)s.%(ext)s"` which will result in downloading each video in a directory corresponding to this path template. Any missing directory will be automatically created for you.
1540
+
1541
+ To use percent literals in an output template use `%%`. To output to stdout use `-o -`.
1542
+
1543
+ The current default template is `%(title)s [%(id)s].%(ext)s`.
1544
+
1545
+ In some cases, you don't want special characters such as 中, spaces, or &, such as when transferring the downloaded filename to a Windows system or the filename through an 8bit-unsafe channel. In these cases, add the `--restrict-filenames` flag to get a shorter title.
1546
+
1547
+ #### Output template examples
1548
+
1549
+ ```bash
1550
+ $ freestuff --print filename -o "test video.%(ext)s" ptd1NN40vMw
1551
+ test video.webm # Literal name with correct extension
1552
+
1553
+ $ freestuff --print filename -o "%(title)s.%(ext)s" ptd1NN40vMw
1554
+ To'y!🤯😂🤦🏻‍♂️.webm # All kinds of weird characters
1555
+
1556
+ $ freestuff --print filename -o "%(title)s.%(ext)s" ptd1NN40vMw --restrict-filenames
1557
+ To_y.webm # Restricted file name
1558
+
1559
+ # Download YouTube playlist videos in separate directory indexed by video order in a playlist
1560
+ $ freestuff -o "%(playlist)s/%(playlist_index)s - %(title)s.%(ext)s" "https://www.youtube.com/playlist?list=PLwiyx1dc3P2JR9N8gQaQN_BCvlSlap7re"
1561
+
1562
+ # Download YouTube playlist videos in separate directories according to their uploaded year
1563
+ $ freestuff -o "%(upload_date>%Y)s/%(title)s.%(ext)s" "https://www.youtube.com/playlist?list=PLwiyx1dc3P2JR9N8gQaQN_BCvlSlap7re"
1564
+
1565
+ # Prefix playlist index with " - " separator, but only if it is available
1566
+ $ freestuff -o "%(playlist_index&{} - |)s%(title)s.%(ext)s" YE7VzlLtp-4 "https://www.youtube.com/user/TheLinuxFoundation/playlists"
1567
+
1568
+ # Download all playlists of YouTube channel/user keeping each playlist in separate directory:
1569
+ $ freestuff -o "%(uploader)s/%(playlist)s/%(playlist_index)s - %(title)s.%(ext)s" "https://www.youtube.com/user/TheLinuxFoundation/playlists"
1570
+
1571
+ # Download Udemy course keeping each chapter in separate directory under MyVideos directory in your home
1572
+ $ freestuff -u user -p password -P "~/MyVideos" -o "%(playlist)s/%(chapter_number)s - %(chapter)s/%(title)s.%(ext)s" "https://www.udemy.com/java-tutorial"
1573
+
1574
+ # Download entire series season keeping each series and each season in separate directory under C:/MyVideos
1575
+ $ freestuff -P "C:/MyVideos" -o "%(series)s/%(season_number)s - %(season)s/%(episode_number)s - %(episode)s.%(ext)s" "https://videomore.ru/kino_v_detalayah/5_sezon/367617"
1576
+
1577
+ # Download video as "C:\MyVideos\uploader\title.ext", subtitles as "C:\MyVideos\subs\uploader\title.ext"
1578
+ # and put all temporary files in "C:\MyVideos\tmp"
1579
+ $ freestuff -P "C:/MyVideos" -P "temp:tmp" -P "subtitle:subs" -o "%(uploader)s/%(title)s.%(ext)s" YE7VzlLtp-4 --write-subs
1580
+
1581
+ # Download video as "C:\MyVideos\uploader\title.ext" and subtitles as "C:\MyVideos\uploader\subs\title.ext"
1582
+ $ freestuff -P "C:/MyVideos" -o "%(uploader)s/%(title)s.%(ext)s" -o "subtitle:%(uploader)s/subs/%(title)s.%(ext)s" YE7VzlLtp-4 --write-subs
1583
+
1584
+ # Stream the video being downloaded to stdout
1585
+ $ freestuff -o - YE7VzlLtp-4
1586
+ ```
1587
+
1588
+ # FORMAT SELECTION
1589
+
1590
+ By default, freestuff tries to download the best available quality if you **don't** pass any options.
1591
+ This is generally equivalent to using `-f bestvideo*+bestaudio/best`. However, if multiple audiostreams is enabled (`--audio-multistreams`), the default format changes to `-f bestvideo+bestaudio/best`. Similarly, if ffmpeg is unavailable, or if you use freestuff to stream to `stdout` (`-o -`), the default becomes `-f best/bestvideo+bestaudio`.
1592
+
1593
+ **Deprecation warning**: Latest versions of freestuff can stream multiple formats to the stdout simultaneously using ffmpeg. So, in future versions, the default for this will be set to `-f bv*+ba/b` similar to normal downloads. If you want to preserve the `-f b/bv+ba` setting, it is recommended to explicitly specify it in the configuration options.
1594
+
1595
+ The general syntax for format selection is `-f FORMAT` (or `--format FORMAT`) where `FORMAT` is a *selector expression*, i.e. an expression that describes format or formats you would like to download.
1596
+
1597
+ <!-- MANPAGE: BEGIN EXCLUDED SECTION -->
1598
+ **tl;dr:** [navigate me to examples](#format-selection-examples).
1599
+ <!-- MANPAGE: END EXCLUDED SECTION -->
1600
+
1601
+ The simplest case is requesting a specific format; e.g. with `-f 22` you can download the format with format code equal to 22. You can get the list of available format codes for particular video using `--list-formats` or `-F`. Note that these format codes are extractor specific.
1602
+
1603
+ You can also use a file extension (currently `3gp`, `aac`, `flv`, `m4a`, `mp3`, `mp4`, `ogg`, `wav`, `webm` are supported) to download the best quality format of a particular file extension served as a single file, e.g. `-f webm` will download the best quality format with the `webm` extension served as a single file.
1604
+
1605
+ You can use `-f -` to interactively provide the format selector *for each video*
1606
+
1607
+ You can also use special names to select particular edge case formats:
1608
+
1609
+ - `all`: Select **all formats** separately
1610
+ - `mergeall`: Select and **merge all formats** (Must be used with `--audio-multistreams`, `--video-multistreams` or both)
1611
+ - `b*`, `best*`: Select the best quality format that **contains either** a video or an audio or both (i.e.; `vcodec!=none or acodec!=none`)
1612
+ - `b`, `best`: Select the best quality format that **contains both** video and audio. Equivalent to `best*[vcodec!=none][acodec!=none]`
1613
+ - `bv`, `bestvideo`: Select the best quality **video-only** format. Equivalent to `best*[acodec=none]`
1614
+ - `bv*`, `bestvideo*`: Select the best quality format that **contains video**. It may also contain audio. Equivalent to `best*[vcodec!=none]`
1615
+ - `ba`, `bestaudio`: Select the best quality **audio-only** format. Equivalent to `best*[vcodec=none]`
1616
+ - `ba*`, `bestaudio*`: Select the best quality format that **contains audio**. It may also contain video. Equivalent to `best*[acodec!=none]` ([Do not use!](https://github.com/freestuff/freestuff/issues/979#issuecomment-919629354))
1617
+ - `w*`, `worst*`: Select the worst quality format that contains either a video or an audio
1618
+ - `w`, `worst`: Select the worst quality format that contains both video and audio. Equivalent to `worst*[vcodec!=none][acodec!=none]`
1619
+ - `wv`, `worstvideo`: Select the worst quality video-only format. Equivalent to `worst*[acodec=none]`
1620
+ - `wv*`, `worstvideo*`: Select the worst quality format that contains video. It may also contain audio. Equivalent to `worst*[vcodec!=none]`
1621
+ - `wa`, `worstaudio`: Select the worst quality audio-only format. Equivalent to `worst*[vcodec=none]`
1622
+ - `wa*`, `worstaudio*`: Select the worst quality format that contains audio. It may also contain video. Equivalent to `worst*[acodec!=none]`
1623
+
1624
+ For example, to download the worst quality video-only format you can use `-f worstvideo`. It is, however, recommended not to use `worst` and related options. When your format selector is `worst`, the format which is worst in all respects is selected. Most of the time, what you actually want is the video with the smallest filesize instead. So it is generally better to use `-S +size` or more rigorously, `-S +size,+br,+res,+fps` instead of `-f worst`. See [Sorting Formats](#sorting-formats) for more details.
1625
+
1626
+ You can select the n'th best format of a type by using `best<type>.<n>`. For example, `best.2` will select the 2nd best combined format. Similarly, `bv*.3` will select the 3rd best format that contains a video stream.
1627
+
1628
+ If you want to download multiple videos, and they don't have the same formats available, you can specify the order of preference using slashes. Note that formats on the left hand side are preferred; e.g. `-f 22/17/18` will download format 22 if it's available, otherwise it will download format 17 if it's available, otherwise it will download format 18 if it's available, otherwise it will complain that no suitable formats are available for download.
1629
+
1630
+ If you want to download several formats of the same video use a comma as a separator, e.g. `-f 22,17,18` will download all these three formats, of course if they are available. Or a more sophisticated example combined with the precedence feature: `-f 136/137/mp4/bestvideo,140/m4a/bestaudio`.
1631
+
1632
+ You can merge the video and audio of multiple formats into a single file using `-f <format1>+<format2>+...` (requires ffmpeg installed); e.g. `-f bestvideo+bestaudio` will download the best video-only format, the best audio-only format and mux them together with ffmpeg.
1633
+
1634
+ **Deprecation warning**: Since the *below* described behavior is complex and counter-intuitive, this will be removed and multistreams will be enabled by default in the future. A new operator will be instead added to limit formats to single audio/video
1635
+
1636
+ Unless `--video-multistreams` is used, all formats with a video stream except the first one are ignored. Similarly, unless `--audio-multistreams` is used, all formats with an audio stream except the first one are ignored. E.g. `-f bestvideo+best+bestaudio --video-multistreams --audio-multistreams` will download and merge all 3 given formats. The resulting file will have 2 video streams and 2 audio streams. But `-f bestvideo+best+bestaudio --no-video-multistreams` will download and merge only `bestvideo` and `bestaudio`. `best` is ignored since another format containing a video stream (`bestvideo`) has already been selected. The order of the formats is therefore important. `-f best+bestaudio --no-audio-multistreams` will download only `best` while `-f bestaudio+best --no-audio-multistreams` will ignore `best` and download only `bestaudio`.
1637
+
1638
+ ## Filtering Formats
1639
+
1640
+ You can also filter the video formats by putting a condition in brackets, as in `-f "best[height=720]"` (or `-f "[filesize>10M]"` since filters without a selector are interpreted as `best`).
1641
+
1642
+ The following numeric meta fields can be used with comparisons `<`, `<=`, `>`, `>=`, `=` (equals), `!=` (not equals):
1643
+
1644
+ - `filesize`: The number of bytes, if known in advance
1645
+ - `filesize_approx`: An estimate for the number of bytes
1646
+ - `width`: Width of the video, if known
1647
+ - `height`: Height of the video, if known
1648
+ - `aspect_ratio`: Aspect ratio of the video, if known
1649
+ - `tbr`: Average bitrate of audio and video in [kbps](## "1000 bits/sec")
1650
+ - `abr`: Average audio bitrate in [kbps](## "1000 bits/sec")
1651
+ - `vbr`: Average video bitrate in [kbps](## "1000 bits/sec")
1652
+ - `asr`: Audio sampling rate in Hertz
1653
+ - `fps`: Frame rate
1654
+ - `audio_channels`: The number of audio channels
1655
+ - `stretched_ratio`: `width:height` of the video's pixels, if not square
1656
+
1657
+ Also filtering work for comparisons `=` (equals), `^=` (starts with), `$=` (ends with), `*=` (contains), `~=` (matches regex) and following string meta fields:
1658
+
1659
+ - `url`: Video URL
1660
+ - `ext`: File extension
1661
+ - `acodec`: Name of the audio codec in use
1662
+ - `vcodec`: Name of the video codec in use
1663
+ - `container`: Name of the container format
1664
+ - `protocol`: The protocol that will be used for the actual download, lower-case (`http`, `https`, `rtmp`, `rtmpe`, `f4m`, `ism`, `http_dash_segments`, `m3u8`, or `m3u8_native`)
1665
+ - `language`: Language code
1666
+ - `dynamic_range`: The dynamic range of the video
1667
+ - `format_id`: A short description of the format
1668
+ - `format`: A human-readable description of the format
1669
+ - `format_note`: Additional info about the format
1670
+ - `resolution`: Textual description of width and height
1671
+
1672
+ Any string comparison may be prefixed with negation `!` in order to produce an opposite comparison, e.g. `!*=` (does not contain). The comparand of a string comparison needs to be quoted with either double or single quotes if it contains spaces or special characters other than `._-`.
1673
+
1674
+ **Note**: None of the aforementioned meta fields are guaranteed to be present since this solely depends on the metadata obtained by the particular extractor, i.e. the metadata offered by the website. Any other field made available by the extractor can also be used for filtering.
1675
+
1676
+ Formats for which the value is not known are excluded unless you put a question mark (`?`) after the operator. You can combine format filters, so `-f "bv[height<=?720][tbr>500]"` selects up to 720p videos (or videos where the height is not known) with a bitrate of at least 500 kbps. You can also use the filters with `all` to download all formats that satisfy the filter, e.g. `-f "all[vcodec=none]"` selects all audio-only formats.
1677
+
1678
+ Format selectors can also be grouped using parentheses; e.g. `-f "(mp4,webm)[height<480]"` will download the best pre-merged mp4 and webm formats with a height lower than 480.
1679
+
1680
+ ## Sorting Formats
1681
+
1682
+ You can change the criteria for being considered the `best` by using `-S` (`--format-sort`). The general format for this is `--format-sort field1,field2...`.
1683
+
1684
+ The available fields are:
1685
+
1686
+ - `hasvid`: Gives priority to formats that have a video stream
1687
+ - `hasaud`: Gives priority to formats that have an audio stream
1688
+ - `ie_pref`: The format preference
1689
+ - `lang`: The language preference as determined by the extractor (e.g. original language preferred over audio description)
1690
+ - `quality`: The quality of the format
1691
+ - `source`: The preference of the source
1692
+ - `proto`: Protocol used for download (`https`/`ftps` > `http`/`ftp` > `m3u8_native`/`m3u8` > `http_dash_segments`> `websocket_frag` > `f4f`/`f4m`)
1693
+ - `vcodec`: Video Codec (`av01` > `vp9.2` > `vp9` > `h265` > `h264` > `vp8` > `h263` > `theora` > other)
1694
+ - `acodec`: Audio Codec (`flac`/`alac` > `wav`/`aiff` > `opus` > `vorbis` > `aac` > `mp4a` > `mp3` > `ac4` > `eac3` > `ac3` > `dts` > other)
1695
+ - `codec`: Equivalent to `vcodec,acodec`
1696
+ - `vext`: Video Extension (`mp4` > `mov` > `webm` > `flv` > other). If `--prefer-free-formats` is used, `webm` is preferred.
1697
+ - `aext`: Audio Extension (`m4a` > `aac` > `mp3` > `ogg` > `opus` > `webm` > other). If `--prefer-free-formats` is used, the order changes to `ogg` > `opus` > `webm` > `mp3` > `m4a` > `aac`
1698
+ - `ext`: Equivalent to `vext,aext`
1699
+ - `filesize`: Exact filesize, if known in advance
1700
+ - `fs_approx`: Approximate filesize
1701
+ - `size`: Exact filesize if available, otherwise approximate filesize
1702
+ - `height`: Height of video
1703
+ - `width`: Width of video
1704
+ - `res`: Video resolution, calculated as the smallest dimension.
1705
+ - `fps`: Framerate of video
1706
+ - `hdr`: The dynamic range of the video (`DV` > `HDR12` > `HDR10+` > `HDR10` > `HLG` > `SDR`)
1707
+ - `channels`: The number of audio channels
1708
+ - `tbr`: Total average bitrate in [kbps](## "1000 bits/sec")
1709
+ - `vbr`: Average video bitrate in [kbps](## "1000 bits/sec")
1710
+ - `abr`: Average audio bitrate in [kbps](## "1000 bits/sec")
1711
+ - `br`: Average bitrate in [kbps](## "1000 bits/sec"), `tbr`/`vbr`/`abr`
1712
+ - `asr`: Audio sample rate in Hz
1713
+
1714
+ **Deprecation warning**: Many of these fields have (currently undocumented) aliases, that may be removed in a future version. It is recommended to use only the documented field names.
1715
+
1716
+ All fields, unless specified otherwise, are sorted in descending order. To reverse this, prefix the field with a `+`. E.g. `+res` prefers format with the smallest resolution. Additionally, you can suffix a preferred value for the fields, separated by a `:`. E.g. `res:720` prefers larger videos, but no larger than 720p and the smallest video if there are no videos less than 720p. For `codec` and `ext`, you can provide two preferred values, the first for video and the second for audio. E.g. `+codec:avc:m4a` (equivalent to `+vcodec:avc,+acodec:m4a`) sets the video codec preference to `h264` > `h265` > `vp9` > `vp9.2` > `av01` > `vp8` > `h263` > `theora` and audio codec preference to `mp4a` > `aac` > `vorbis` > `opus` > `mp3` > `ac3` > `dts`. You can also make the sorting prefer the nearest values to the provided by using `~` as the delimiter. E.g. `filesize~1G` prefers the format with filesize closest to 1 GiB.
1717
+
1718
+ The fields `hasvid` and `ie_pref` are always given highest priority in sorting, irrespective of the user-defined order. This behavior can be changed by using `--format-sort-force`. Apart from these, the default order used is: `lang,quality,res,fps,hdr:12,vcodec,channels,acodec,size,br,asr,proto,ext,hasaud,source,id`. The extractors may override this default order, but they cannot override the user-provided order.
1719
+
1720
+ Note that the default for hdr is `hdr:12`; i.e. Dolby Vision is not preferred. This choice was made since DV formats are not yet fully compatible with most devices. This may be changed in the future.
1721
+
1722
+ If your format selector is `worst`, the last item is selected after sorting. This means it will select the format that is worst in all respects. Most of the time, what you actually want is the video with the smallest filesize instead. So it is generally better to use `-f best -S +size,+br,+res,+fps`.
1723
+
1724
+ If you use the `-S`/`--format-sort` option multiple times, each subsequent sorting argument will be prepended to the previous one, and only the highest priority entry of any duplicated field will be preserved. E.g. `-S proto -S res` is equivalent to `-S res,proto`, and `-S res:720,fps -S vcodec,res:1080` is equivalent to `-S vcodec,res:1080,fps`. You can use `--format-sort-reset` to disregard any previously passed `-S`/`--format-sort` arguments and reset to the default order.
1725
+
1726
+ **Tip**: You can use the `-v -F` to see how the formats have been sorted (worst to best).
1727
+
1728
+ ## Format Selection examples
1729
+
1730
+ ```bash
1731
+ # Download and merge the best video-only format and the best audio-only format,
1732
+ # or download the best combined format if video-only format is not available
1733
+ $ freestuff -f "bv+ba/b"
1734
+
1735
+ # Download best format that contains video,
1736
+ # and if it doesn't already have an audio stream, merge it with best audio-only format
1737
+ $ freestuff -f "bv*+ba/b"
1738
+
1739
+ # Same as above
1740
+ $ freestuff
1741
+
1742
+ # Download the best video-only format and the best audio-only format without merging them
1743
+ # For this case, an output template should be used since
1744
+ # by default, bestvideo and bestaudio will have the same file name.
1745
+ $ freestuff -f "bv,ba" -o "%(title)s.f%(format_id)s.%(ext)s"
1746
+
1747
+ # Download and merge the best format that has a video stream,
1748
+ # and all audio-only formats into one file
1749
+ $ freestuff -f "bv*+mergeall[vcodec=none]" --audio-multistreams
1750
+
1751
+ # Download and merge the best format that has a video stream,
1752
+ # and the best 2 audio-only formats into one file
1753
+ $ freestuff -f "bv*+ba+ba.2" --audio-multistreams
1754
+
1755
+
1756
+ # The following examples show the old method (without -S) of format selection
1757
+ # and how to use -S to achieve a similar but (generally) better result
1758
+
1759
+ # Download the worst video available (old method)
1760
+ $ freestuff -f "wv*+wa/w"
1761
+
1762
+ # Download the best video available but with the smallest resolution
1763
+ $ freestuff -S "+res"
1764
+
1765
+ # Download the smallest video available
1766
+ $ freestuff -S "+size,+br"
1767
+
1768
+
1769
+
1770
+ # Download the best mp4 video available, or the best video if no mp4 available
1771
+ $ freestuff -f "bv*[ext=mp4]+ba[ext=m4a]/b[ext=mp4] / bv*+ba/b"
1772
+
1773
+ # Download the best video with the best extension
1774
+ # (For video, mp4 > mov > webm > flv. For audio, m4a > aac > mp3 ...)
1775
+ $ freestuff -S "ext"
1776
+
1777
+
1778
+
1779
+ # Download the best video available but no better than 480p,
1780
+ # or the worst video if there is no video under 480p
1781
+ $ freestuff -f "bv*[height<=480]+ba/b[height<=480] / wv*+ba/w"
1782
+
1783
+ # Download the best video available with the largest height but no better than 480p,
1784
+ # or the best video with the smallest resolution if there is no video under 480p
1785
+ $ freestuff -S "height:480"
1786
+
1787
+ # Download the best video available with the largest resolution but no better than 480p,
1788
+ # or the best video with the smallest resolution if there is no video under 480p
1789
+ # Resolution is determined by using the smallest dimension.
1790
+ # So this works correctly for vertical videos as well
1791
+ $ freestuff -S "res:480"
1792
+
1793
+
1794
+
1795
+ # Download the best video (that also has audio) but no bigger than 50 MB,
1796
+ # or the worst video (that also has audio) if there is no video under 50 MB
1797
+ $ freestuff -f "b[filesize<50M] / w"
1798
+
1799
+ # Download the largest video (that also has audio) but no bigger than 50 MB,
1800
+ # or the smallest video (that also has audio) if there is no video under 50 MB
1801
+ $ freestuff -f "b" -S "filesize:50M"
1802
+
1803
+ # Download the best video (that also has audio) that is closest in size to 50 MB
1804
+ $ freestuff -f "b" -S "filesize~50M"
1805
+
1806
+
1807
+
1808
+ # Download best video available via direct link over HTTP/HTTPS protocol,
1809
+ # or the best video available via any protocol if there is no such video
1810
+ $ freestuff -f "(bv*+ba/b)[protocol^=http][protocol!*=dash] / (bv*+ba/b)"
1811
+
1812
+ # Download best video available via the best protocol
1813
+ # (https/ftps > http/ftp > m3u8_native > m3u8 > http_dash_segments ...)
1814
+ $ freestuff -S "proto"
1815
+
1816
+
1817
+
1818
+ # Download the best video with either h264 or h265 codec,
1819
+ # or the best video if there is no such video
1820
+ $ freestuff -f "(bv*[vcodec~='^((he|a)vc|h26[45])']+ba) / (bv*+ba/b)"
1821
+
1822
+ # Download the best video with best codec no better than h264,
1823
+ # or the best video with worst codec if there is no such video
1824
+ $ freestuff -S "codec:h264"
1825
+
1826
+ # Download the best video with worst codec no worse than h264,
1827
+ # or the best video with best codec if there is no such video
1828
+ $ freestuff -S "+codec:h264"
1829
+
1830
+
1831
+
1832
+ # More complex examples
1833
+
1834
+ # Download the best video no better than 720p preferring framerate greater than 30,
1835
+ # or the worst video (still preferring framerate greater than 30) if there is no such video
1836
+ $ freestuff -f "((bv*[fps>30]/bv*)[height<=720]/(wv*[fps>30]/wv*)) + ba / (b[fps>30]/b)[height<=720]/(w[fps>30]/w)"
1837
+
1838
+ # Download the video with the largest resolution no better than 720p,
1839
+ # or the video with the smallest resolution available if there is no such video,
1840
+ # preferring larger framerate for formats with the same resolution
1841
+ $ freestuff -S "res:720,fps"
1842
+
1843
+
1844
+
1845
+ # Download the video with smallest resolution no worse than 480p,
1846
+ # or the video with the largest resolution available if there is no such video,
1847
+ # preferring better codec and then larger total bitrate for the same resolution
1848
+ $ freestuff -S "+res:480,codec,br"
1849
+ ```
1850
+
1851
+ # MODIFYING METADATA
1852
+
1853
+ The metadata obtained by the extractors can be modified by using `--parse-metadata` and `--replace-in-metadata`
1854
+
1855
+ `--replace-in-metadata FIELDS REGEX REPLACE` is used to replace text in any metadata field using [Python regular expression](https://docs.python.org/3/library/re.html#regular-expression-syntax). [Backreferences](https://docs.python.org/3/library/re.html?highlight=backreferences#re.sub) can be used in the replace string for advanced use.
1856
+
1857
+ The general syntax of `--parse-metadata FROM:TO` is to give the name of a field or an [output template](#output-template) to extract data from, and the format to interpret it as, separated by a colon `:`. Either a [Python regular expression](https://docs.python.org/3/library/re.html#regular-expression-syntax) with named capture groups, a single field name, or a similar syntax to the [output template](#output-template) (only `%(field)s` formatting is supported) can be used for `TO`. The option can be used multiple times to parse and modify various fields.
1858
+
1859
+ Note that these options preserve their relative order, allowing replacements to be made in parsed fields and vice versa. Also, any field thus created can be used in the [output template](#output-template) and will also affect the media file's metadata added when using `--embed-metadata`.
1860
+
1861
+ This option also has a few special uses:
1862
+
1863
+ * You can download an additional URL based on the metadata of the currently downloaded video. To do this, set the field `additional_urls` to the URL that you want to download. E.g. `--parse-metadata "description:(?P<additional_urls>https?://www\.vimeo\.com/\d+)"` will download the first vimeo video found in the description
1864
+
1865
+ * You can use this to change the metadata that is embedded in the media file. To do this, set the value of the corresponding field with a `meta_` prefix. For example, any value you set to `meta_description` field will be added to the `description` field in the file - you can use this to set a different "description" and "synopsis". To modify the metadata of individual streams, use the `meta<n>_` prefix (e.g. `meta1_language`). Any value set to the `meta_` field will overwrite all default values.
1866
+
1867
+ **Note**: Metadata modification happens before format selection, post-extraction and other post-processing operations. Some fields may be added or changed during these steps, overriding your changes.
1868
+
1869
+ For reference, these are the fields freestuff adds by default to the file metadata:
1870
+
1871
+ Metadata fields | From
1872
+ :--------------------------|:------------------------------------------------
1873
+ `title` | `track` or `title`
1874
+ `date` | `upload_date`
1875
+ `description`, `synopsis` | `description`
1876
+ `purl`, `comment` | `webpage_url`
1877
+ `track` | `track_number`
1878
+ `artist` | `artist`, `artists`, `creator`, `creators`, `uploader` or `uploader_id`
1879
+ `composer` | `composer` or `composers`
1880
+ `genre` | `genre`, `genres`, `categories` or `tags`
1881
+ `album` | `album` or `series`
1882
+ `album_artist` | `album_artist` or `album_artists`
1883
+ `disc` | `disc_number`
1884
+ `show` | `series`
1885
+ `season_number` | `season_number`
1886
+ `episode_id` | `episode` or `episode_id`
1887
+ `episode_sort` | `episode_number`
1888
+ `language` of each stream | the format's `language`
1889
+
1890
+ **Note**: The file format may not support some of these fields
1891
+
1892
+
1893
+ ## Modifying metadata examples
1894
+
1895
+ ```bash
1896
+ # Interpret the title as "Artist - Title"
1897
+ $ freestuff --parse-metadata "title:%(artist)s - %(title)s"
1898
+
1899
+ # Regex example
1900
+ $ freestuff --parse-metadata "description:Artist - (?P<artist>.+)"
1901
+
1902
+ # Copy the episode field to the title field (with FROM and TO as single fields)
1903
+ $ freestuff --parse-metadata "episode:title"
1904
+
1905
+ # Set title as "Series name S01E05"
1906
+ $ freestuff --parse-metadata "%(series)s S%(season_number)02dE%(episode_number)02d:%(title)s"
1907
+
1908
+ # Prioritize uploader as the "artist" field in video metadata
1909
+ $ freestuff --parse-metadata "%(uploader|)s:%(meta_artist)s" --embed-metadata
1910
+
1911
+ # Set "comment" field in video metadata using description instead of webpage_url,
1912
+ # handling multiple lines correctly
1913
+ $ freestuff --parse-metadata "description:(?s)(?P<meta_comment>.+)" --embed-metadata
1914
+
1915
+ # Do not set any "synopsis" in the video metadata
1916
+ $ freestuff --parse-metadata ":(?P<meta_synopsis>)"
1917
+
1918
+ # Remove "formats" field from the infojson by setting it to an empty string
1919
+ $ freestuff --parse-metadata "video::(?P<formats>)" --write-info-json
1920
+
1921
+ # Replace all spaces and "_" in title and uploader with a `-`
1922
+ $ freestuff --replace-in-metadata "title,uploader" "[ _]" "-"
1923
+
1924
+ ```
1925
+
1926
+ # EXTRACTOR ARGUMENTS
1927
+
1928
+ Some extractors accept additional arguments which can be passed using `--extractor-args KEY:ARGS`. `ARGS` is a `;` (semicolon) separated string of `ARG=VAL1,VAL2`. E.g. `--extractor-args "youtube:player-client=tv,mweb;formats=incomplete" --extractor-args "twitter:api=syndication"`
1929
+
1930
+ Note: In CLI, `ARG` can use `-` instead of `_`; e.g. `youtube:player-client"` becomes `youtube:player_client"`
1931
+
1932
+ The following extractors use this feature:
1933
+
1934
+ #### youtube
1935
+ * `lang`: Prefer translated metadata (`title`, `description` etc) of this language code (case-sensitive). By default, the video primary language metadata is preferred, with a fallback to `en` translated. See [youtube/_base.py](https://github.com/freestuff/freestuff/blob/415b4c9f955b1a0391204bd24a7132590e7b3bdb/yt_dlp/extractor/youtube/_base.py#L402-L409) for the list of supported content language codes
1936
+ * `skip`: One or more of `hls`, `dash` or `translated_subs` to skip extraction of the m3u8 manifests, dash manifests and [auto-translated subtitles](https://github.com/freestuff/freestuff/issues/4090#issuecomment-1158102032) respectively
1937
+ * `player_client`: Clients to extract video data from. The currently available clients are `web`, `web_safari`, `web_embedded`, `web_music`, `web_creator`, `mweb`, `ios`, `android`, `android_vr`, `tv`, `tv_downgraded`, and `tv_simply`. By default, `android_vr,web_safari` is used. If no JavaScript runtime/engine is available, then only `android_vr` is used. If logged-in cookies are passed to freestuff, then `tv_downgraded,web_safari` is used for free accounts and `tv_downgraded,web_creator` is used for premium accounts. The `web_music` client is added for `music.youtube.com` URLs when logged-in cookies are used. The `web_embedded` client is added for age-restricted videos but only successfully works around the age-restriction sometimes (e.g. if the video is embeddable), and may be added as a fallback if `android_vr` is unable to access a video. The `web_creator` client is added for age-restricted videos if account age-verification is required. Some clients, such as `web_creator` and `web_music`, require a `po_token` for their formats to be downloadable. Some clients, such as `web_creator`, will only work with authentication. Not all clients support authentication via cookies. You can use `default` for the default clients, or you can use `all` for all clients (not recommended). You can prefix a client with `-` to exclude it, e.g. `youtube:player_client=default,-web_safari`
1938
+ * `player_skip`: Skip some network requests that are generally needed for robust extraction. One or more of `configs` (skip client configs), `webpage` (skip initial webpage), `js` (skip js player), `initial_data` (skip initial data/next ep request). While these options can help reduce the number of requests needed or avoid some rate-limiting, they could cause issues such as missing formats or metadata. See [#860](https://github.com/freestuff/freestuff/pull/860) and [#12826](https://github.com/freestuff/freestuff/issues/12826) for more details
1939
+ * `webpage_skip`: Skip extraction of embedded webpage data. One or both of `player_response`, `initial_data`. These options are for testing purposes and don't skip any network requests. Neither is skipped by default; however, if a `player_js_version` value other than `actual` is used, then `webpage_skip=player_response` is implied
1940
+ * `webpage_client`: Client to use for the video webpage request. One of `web` or `web_safari` (default)
1941
+ * `player_params`: YouTube player parameters to use for player requests. Will overwrite any default ones set by freestuff.
1942
+ * `player_js_variant`: The player javascript variant to use for n/sig deciphering. The known variants are: `main`, `tcc`, `tce`, `es5`, `es6`, `es6_tcc`, `es6_tce`, `tv`, `tv_es6`, `phone`, `house`. The default is `main`, and the others are for debugging purposes. You can use `actual` to go with what is prescribed by the site
1943
+ * `player_js_version`: The player javascript version to use for n/sig deciphering, in the format of `signature_timestamp@hash` (e.g. `20348@0004de42`). The default is to use what is prescribed by the site, and can be selected with `actual`. Using any other value will imply `webpage_skip=player_response`
1944
+ * `comment_sort`: `top` or `new` (default) - choose comment sorting mode (on YouTube's side)
1945
+ * `max_comments`: Limit the amount of comments to gather. Comma-separated list of integers representing `max-comments,max-parents,max-replies,max-replies-per-thread,max-depth`. Default is `all,all,all,all,all`
1946
+ * A `max-depth` value of `1` will discard all replies, regardless of the `max-replies` or `max-replies-per-thread` values given
1947
+ * E.g. `all,all,1000,10,2` will get a maximum of 1000 replies total, with up to 10 replies per thread, and only 2 levels of depth (i.e. top-level comments plus their immediate replies). `1000,all,100` will get a maximum of 1000 comments, with a maximum of 100 replies total
1948
+ * `formats`: Change the types of formats to return. `dashy` (convert HTTP to DASH), `duplicate` (identical content but different URLs or protocol; includes `dashy`), `incomplete` (cannot be downloaded completely - live and post-live dash, post-live m3u8, and live adaptive https without --live-from-start), `missing_pot` (include formats that require a PO Token but are missing one)
1949
+ * `innertube_host`: Innertube API host to use for all API requests; e.g. `studio.youtube.com`, `youtubei.googleapis.com`. Note that cookies exported from one subdomain will not work on others
1950
+ * `innertube_key`: Innertube API key to use for all API requests. By default, no API key is used
1951
+ * `raise_incomplete_data`: `Incomplete Data Received` raises an error instead of reporting a warning
1952
+ * `data_sync_id`: Overrides the account Data Sync ID used in Innertube API requests. This may be needed if you are using an account with `youtube:player_skip=webpage,configs` or `youtubetab:skip=webpage`
1953
+ * `visitor_data`: Overrides the Visitor Data used in Innertube API requests. This should be used with `player_skip=webpage,configs` and without cookies. Note: this may have adverse effects if used improperly. If a session from a browser is wanted, you should pass cookies instead (which contain the Visitor ID)
1954
+ * `po_token`: Proof of Origin (PO) Token(s) to use. Comma-separated list of PO Tokens in the format `CLIENT.CONTEXT+PO_TOKEN`, e.g. `youtube:po_token=web.gvs+XXX,web.player=XXX,web_safari.gvs+YYY`. Context can be any of `gvs` (Google Video Server URLs), `player` (Innertube player request) or `subs` (Subtitles)
1955
+ * `pot_trace`: Enable debug logging for PO Token fetching. Either `true` or `false` (default)
1956
+ * `fetch_pot`: Policy to use for fetching a PO Token from providers. One of `always` (always try fetch a PO Token regardless if the client requires one for the given context), `never` (never fetch a PO Token), or `auto` (default; only fetch a PO Token if the client requires one for the given context)
1957
+ * `jsc_trace`: Enable debug logging for JS Challenge fetching. Either `true` or `false` (default)
1958
+ * `use_ad_playback_context`: Skip preroll ads to eliminate the mandatory wait period before download. Do NOT use this when passing premium account cookies to freestuff, as it will result in a loss of premium formats. Only effective with the `mweb` and `web_music` player clients. Either `true` or `false` (default)
1959
+
1960
+ #### youtube-ejs
1961
+ * `jitless`: Run supported Javascript engines in JIT-less mode. Supported runtimes are `deno`, `node` and `bun`. Provides better security at the cost of performance/speed. Do note that `node` and `bun` are still considered insecure. Either `true` or `false` (default)
1962
+
1963
+ #### youtubepot-webpo
1964
+ * `bind_to_visitor_id`: Whether to use the Visitor ID instead of Visitor Data for caching WebPO tokens. Either `true` (default) or `false`
1965
+
1966
+ #### youtubetab (YouTube playlists, channels, feeds, etc.)
1967
+ * `skip`: One or more of `webpage` (skip initial webpage download), `authcheck` (allow the download of playlists requiring authentication when no initial webpage is downloaded. This may cause unwanted behavior, see [#1122](https://github.com/freestuff/freestuff/pull/1122) for more details)
1968
+ * `approximate_date`: Extract approximate `upload_date` and `timestamp` in flat-playlist. This may cause date-based filters to be slightly off
1969
+
1970
+ #### generic
1971
+ * `fragment_query`: Passthrough any query in mpd/m3u8 manifest URLs to their fragments if no value is provided, or else apply the query string given as `fragment_query=VALUE`. Note that if the stream has an HLS AES-128 key, then the query parameters will be passed to the key URI as well, unless the `key_query` extractor-arg is passed, or unless an external key URI is provided via the `hls_key` extractor-arg. Does not apply to ffmpeg
1972
+ * `variant_query`: Passthrough the master m3u8 URL query to its variant playlist URLs if no value is provided, or else apply the query string given as `variant_query=VALUE`
1973
+ * `key_query`: Passthrough the master m3u8 URL query to its HLS AES-128 decryption key URI if no value is provided, or else apply the query string given as `key_query=VALUE`. Note that this will have no effect if the key URI is provided via the `hls_key` extractor-arg. Does not apply to ffmpeg
1974
+ * `hls_key`: An HLS AES-128 key URI *or* key (as hex), and optionally the IV (as hex), in the form of `(URI|KEY)[,IV]`; e.g. `generic:hls_key=ABCDEF1234567980,0xFEDCBA0987654321`. Passing any of these values will force usage of the native HLS downloader and override the corresponding values found in the m3u8 playlist
1975
+ * `is_live`: Bypass live HLS detection and manually set `live_status` - a value of `false` will set `not_live`, any other value (or no value) will set `is_live`
1976
+ * `impersonate`: Target(s) to try and impersonate with the initial webpage request; e.g. `generic:impersonate=safari,chrome-110`. Use `generic:impersonate` to impersonate any available target, and use `generic:impersonate=false` to disable impersonation (default)
1977
+
1978
+ #### vikichannel
1979
+ * `video_types`: Types of videos to download - one or more of `episodes`, `movies`, `clips`, `trailers`
1980
+
1981
+ #### youtubewebarchive
1982
+ * `check_all`: Try to check more at the cost of more requests. One or more of `thumbnails`, `captures`
1983
+
1984
+ #### gamejolt
1985
+ * `comment_sort`: `hot` (default), `you` (cookies needed), `top`, `new` - choose comment sorting mode (on GameJolt's side)
1986
+
1987
+ #### hotstar
1988
+ * `res`: resolution to ignore - one or more of `sd`, `hd`, `fhd`
1989
+ * `vcodec`: vcodec to ignore - one or more of `h264`, `h265`, `dvh265`
1990
+ * `dr`: dynamic range to ignore - one or more of `sdr`, `hdr10`, `dv`
1991
+
1992
+ #### instagram
1993
+ * `app_id`: The value of the `X-IG-App-ID` header used for API requests. Can be the actual ID number, `ios`, or `web` (default)
1994
+
1995
+ #### niconicochannelplus
1996
+ * `max_comments`: Maximum number of comments to extract - default is `120`
1997
+
1998
+ #### tiktok
1999
+ * `api_hostname`: Hostname to use for mobile API calls, e.g. `api22-normal-c-alisg.tiktokv.com`
2000
+ * `app_name`: Default app name to use with mobile API calls, e.g. `trill`
2001
+ * `app_version`: Default app version to use with mobile API calls - should be set along with `manifest_app_version`, e.g. `34.1.2`
2002
+ * `manifest_app_version`: Default numeric app version to use with mobile API calls, e.g. `2023401020`
2003
+ * `aid`: Default app ID to use with mobile API calls, e.g. `1180`
2004
+ * `app_info`: Enable mobile API extraction with one or more app info strings in the format of `<iid>/[app_name]/[app_version]/[manifest_app_version]/[aid]`, where `iid` is the unique app install ID. `iid` is the only required value; all other values and their `/` separators can be omitted, e.g. `tiktok:app_info=1234567890123456789` or `tiktok:app_info=123,456/trill///1180,789//34.0.1/340001`
2005
+ * `device_id`: Enable mobile API extraction with a genuine device ID to be used with mobile API calls. Default is a random 19-digit string
2006
+
2007
+ #### rokfinchannel
2008
+ * `tab`: Which tab to download - one of `new`, `top`, `videos`, `podcasts`, `streams`, `stacks`
2009
+
2010
+ #### twitter
2011
+ * `api`: Select one of `graphql` (default), `legacy` or `syndication` as the API for tweet extraction. Has no effect if logged in
2012
+
2013
+ #### stacommu, wrestleuniverse
2014
+ * `device_id`: UUID value assigned by the website and used to enforce device limits for paid livestream content. Can be found in browser local storage
2015
+
2016
+ #### twitch
2017
+ * `client_id`: Client ID value to be sent with GraphQL requests, e.g. `twitch:client_id=kimne78kx3ncx6brgo4mv6wki5h1ko`
2018
+
2019
+ #### nhkradirulive (NHK らじる★らじる LIVE)
2020
+ * `area`: Which regional variation to extract. Valid areas are: `sapporo`, `sendai`, `tokyo`, `nagoya`, `osaka`, `hiroshima`, `matsuyama`, `fukuoka`. Defaults to `tokyo`
2021
+
2022
+ #### nflplusreplay
2023
+ * `type`: Type(s) of game replays to extract. Valid types are: `full_game`, `full_game_spanish`, `condensed_game` and `all_22`. You can use `all` to extract all available replay types, which is the default
2024
+
2025
+ #### jiocinema
2026
+ * `refresh_token`: The `refreshToken` UUID from browser local storage can be passed to extend the life of your login session when logging in with `token` as username and the `accessToken` from browser local storage as password
2027
+
2028
+ #### jiosaavn
2029
+ * `bitrate`: Audio bitrates to request. One or more of `16`, `32`, `64`, `128`, `320`. Default is `128,320`
2030
+
2031
+ #### afreecatvlive
2032
+ * `cdn`: One or more CDN IDs to use with the API call for stream URLs, e.g. `gcp_cdn`, `gs_cdn_pc_app`, `gs_cdn_mobile_web`, `gs_cdn_pc_web`
2033
+
2034
+ #### soundcloud
2035
+ * `formats`: Formats to request from the API. Requested values should be in the format of `{protocol}_{codec}`, e.g. `hls_opus,http_aac`. The `*` character functions as a wildcard, e.g. `*_mp3`, and can be passed by itself to request all formats. Known protocols include `http`, `hls` and `hls-aes`; known codecs include `aac`, `opus` and `mp3`. Original `download` formats are always extracted. Default is `http_aac,hls_aac,http_opus,hls_opus,http_mp3,hls_mp3`
2036
+
2037
+ #### orfon (orf:on)
2038
+ * `prefer_segments_playlist`: Prefer a playlist of program segments instead of a single complete video when available. If individual segments are desired, use `--concat-playlist never --extractor-args "orfon:prefer_segments_playlist"`
2039
+
2040
+ #### bilibili
2041
+ * `prefer_multi_flv`: Prefer extracting flv formats over mp4 for older videos that still provide legacy formats
2042
+
2043
+ #### sonylivseries
2044
+ * `sort_order`: Episode sort order for series extraction - one of `asc` (ascending, oldest first) or `desc` (descending, newest first). Default is `asc`
2045
+
2046
+ #### streaks
2047
+ * `api_key`: API key for the `X-Streaks-Api-Key` header
2048
+
2049
+ #### tver
2050
+ * `backend`: Backend API to use for extraction - one of `streaks` (default) or `brightcove` (deprecated)
2051
+
2052
+ #### vimeo
2053
+ * `client`: Client to extract video data from. The currently available clients are `android`, `ios`, `macos` and `web`. Only one client can be used. The `macos` client is used by default, but the `web` client is used when logged-in. The `web` client only works with account cookies or login credentials. The `android` and `ios` clients only work with previously cached OAuth tokens
2054
+ * `original_format_policy`: Policy for when to try extracting original formats. One of `always`, `never`, or `auto`. The default `auto` policy tries to avoid exceeding the web client's API rate-limit by only making an extra request when Vimeo publicizes the video's downloadability
2055
+
2056
+ #### zan
2057
+ * `split_angles`: Split multi-angle streams into separate angle formats. Forces re-encoding of the video stream during download, and requires ffmpeg. Either `true` or `false` (default)
2058
+
2059
+ **Note**: These options may be changed/removed in the future without concern for backward compatibility
2060
+
2061
+ <!-- MANPAGE: MOVE "INSTALLATION" SECTION HERE -->
2062
+
2063
+
2064
+ # PLUGINS
2065
+
2066
+ Note that **all** plugins are imported even if not invoked, and that **there are no checks** performed on plugin code. **Use plugins at your own risk and only if you trust the code!**
2067
+
2068
+ Plugins can be of `<type>`s `extractor` or `postprocessor`.
2069
+ - Extractor plugins do not need to be enabled from the CLI and are automatically invoked when the input URL is suitable for it.
2070
+ - Extractor plugins take priority over built-in extractors.
2071
+ - Postprocessor plugins can be invoked using `--use-postprocessor NAME`.
2072
+
2073
+
2074
+ Plugins are loaded from the namespace packages `yt_dlp_plugins.extractor` and `yt_dlp_plugins.postprocessor`.
2075
+
2076
+ In other words, the file structure on the disk looks something like:
2077
+
2078
+ yt_dlp_plugins/
2079
+ extractor/
2080
+ myplugin.py
2081
+ postprocessor/
2082
+ myplugin.py
2083
+
2084
+ freestuff looks for these `yt_dlp_plugins` namespace folders in many locations (see below) and loads in plugins from **all** of them.
2085
+ Set the environment variable `YTDLP_NO_PLUGINS` to something nonempty to disable loading plugins entirely.
2086
+
2087
+ See the [wiki for some known plugins](https://github.com/freestuff/freestuff/wiki/Plugins)
2088
+
2089
+ ## Installing Plugins
2090
+
2091
+ Plugins can be installed using various methods and locations.
2092
+
2093
+ 1. **Configuration directories**:
2094
+ Plugin packages (containing a `yt_dlp_plugins` namespace folder) can be dropped into the following standard [configuration locations](#configuration):
2095
+ * **User Plugins**
2096
+ * `${XDG_CONFIG_HOME}/freestuff/plugins/<package name>/yt_dlp_plugins/` (recommended on Linux/macOS)
2097
+ * `${XDG_CONFIG_HOME}/freestuff-plugins/<package name>/yt_dlp_plugins/`
2098
+ * `${APPDATA}/freestuff/plugins/<package name>/yt_dlp_plugins/` (recommended on Windows)
2099
+ * `${APPDATA}/freestuff-plugins/<package name>/yt_dlp_plugins/`
2100
+ * `~/.freestuff/plugins/<package name>/yt_dlp_plugins/`
2101
+ * `~/freestuff-plugins/<package name>/yt_dlp_plugins/`
2102
+ * **System Plugins**
2103
+ * `/etc/freestuff/plugins/<package name>/yt_dlp_plugins/`
2104
+ * `/etc/freestuff-plugins/<package name>/yt_dlp_plugins/`
2105
+ 2. **Executable location**: Plugin packages can similarly be installed in a `freestuff-plugins` directory under the executable location (recommended for portable installations):
2106
+ * Binary: where `<root-dir>/freestuff.exe`, `<root-dir>/freestuff-plugins/<package name>/yt_dlp_plugins/`
2107
+ * Source: where `<root-dir>/yt_dlp/__main__.py`, `<root-dir>/freestuff-plugins/<package name>/yt_dlp_plugins/`
2108
+
2109
+ 3. **pip and other locations in `PYTHONPATH`**
2110
+ * Plugin packages can be installed and managed using `pip`. See [freestuff-sample-plugins](https://github.com/freestuff/freestuff-sample-plugins) for an example.
2111
+ * Note: plugin files between plugin packages installed with pip must have unique filenames.
2112
+ * Any path in `PYTHONPATH` is searched in for the `yt_dlp_plugins` namespace folder.
2113
+ * Note: This does not apply for Pyinstaller builds.
2114
+
2115
+
2116
+ `.zip`, `.egg` and `.whl` archives containing a `yt_dlp_plugins` namespace folder in their root are also supported as plugin packages.
2117
+
2118
+ * e.g. `${XDG_CONFIG_HOME}/freestuff/plugins/mypluginpkg.zip` where `mypluginpkg.zip` contains `yt_dlp_plugins/<type>/myplugin.py`
2119
+
2120
+ Run freestuff with `--verbose` to check if the plugin has been loaded.
2121
+
2122
+ ## Developing Plugins
2123
+
2124
+ See the [freestuff-sample-plugins](https://github.com/freestuff/freestuff-sample-plugins) repo for a template plugin package and the [Plugin Development](https://github.com/freestuff/freestuff/wiki/Plugin-Development) section of the wiki for a plugin development guide.
2125
+
2126
+ All public classes with a name ending in `IE`/`PP` are imported from each file for extractors and postprocessors respectively. This respects underscore prefix (e.g. `_MyBasePluginIE` is private) and `__all__`. Modules can similarly be excluded by prefixing the module name with an underscore (e.g. `_myplugin.py`).
2127
+
2128
+ To replace an existing extractor with a subclass of one, set the `plugin_name` class keyword argument (e.g. `class MyPluginIE(ABuiltInIE, plugin_name='myplugin')` will replace `ABuiltInIE` with `MyPluginIE`). Since the extractor replaces the parent, you should exclude the subclass extractor from being imported separately by making it private using one of the methods described above.
2129
+
2130
+ If you are a plugin author, add [freestuff-plugins](https://github.com/topics/freestuff-plugins) as a topic to your repository for discoverability.
2131
+
2132
+ See the [Developer Instructions](https://github.com/freestuff/freestuff/blob/master/CONTRIBUTING.md#developer-instructions) on how to write and test an extractor.
2133
+
2134
+ # EMBEDDING freestuff
2135
+
2136
+ freestuff makes the best effort to be a good command-line program, and thus should be callable from any programming language.
2137
+
2138
+ Your program should avoid parsing the normal stdout since they may change in future versions. Instead, they should use options such as `-J`, `--print`, `--progress-template`, `--exec` etc to create console output that you can reliably reproduce and parse.
2139
+
2140
+ From a Python program, you can embed freestuff in a more powerful fashion, like this:
2141
+
2142
+ ```python
2143
+ from yt_dlp import YoutubeDL
2144
+
2145
+ URLS = ['https://www.youtube.com/watch?v=YE7VzlLtp-4']
2146
+ with YoutubeDL() as ydl:
2147
+ ydl.download(URLS)
2148
+ ```
2149
+
2150
+ Most likely, you'll want to use various options. For a list of options available, have a look at [`yt_dlp/YoutubeDL.py`](yt_dlp/YoutubeDL.py#L183) or `help(yt_dlp.YoutubeDL)` in a Python shell. If you are already familiar with the CLI, you can use [`devscripts/cli_to_api.py`](https://github.com/freestuff/freestuff/blob/master/devscripts/cli_to_api.py) to translate any CLI switches to `YoutubeDL` params.
2151
+
2152
+ **Tip**: If you are porting your code from youtube-dl to freestuff, one important point to look out for is that we do not guarantee the return value of `YoutubeDL.extract_info` to be json serializable, or even be a dictionary. It will be dictionary-like, but if you want to ensure it is a serializable dictionary, pass it through `YoutubeDL.sanitize_info` as shown in the [example below](#extracting-information)
2153
+
2154
+ ## Embedding examples
2155
+
2156
+ #### Extracting information
2157
+
2158
+ ```python
2159
+ import json
2160
+ import yt_dlp
2161
+
2162
+ URL = 'https://www.youtube.com/watch?v=YE7VzlLtp-4'
2163
+
2164
+ # ℹ️ See help(yt_dlp.YoutubeDL) for a list of available options and public functions
2165
+ ydl_opts = {}
2166
+ with yt_dlp.YoutubeDL(ydl_opts) as ydl:
2167
+ info = ydl.extract_info(URL, download=False)
2168
+
2169
+ # ℹ️ ydl.sanitize_info makes the info json-serializable
2170
+ print(json.dumps(ydl.sanitize_info(info)))
2171
+ ```
2172
+ #### Download using an info-json
2173
+
2174
+ ```python
2175
+ import yt_dlp
2176
+
2177
+ INFO_FILE = 'path/to/video.info.json'
2178
+
2179
+ with yt_dlp.YoutubeDL() as ydl:
2180
+ error_code = ydl.download_with_info_file(INFO_FILE)
2181
+
2182
+ print('Some videos failed to download' if error_code
2183
+ else 'All videos successfully downloaded')
2184
+ ```
2185
+
2186
+ #### Extract audio
2187
+
2188
+ ```python
2189
+ import yt_dlp
2190
+
2191
+ URLS = ['https://www.youtube.com/watch?v=YE7VzlLtp-4']
2192
+
2193
+ ydl_opts = {
2194
+ 'format': 'm4a/bestaudio/best',
2195
+ # ℹ️ See help(yt_dlp.postprocessor) for a list of available Postprocessors and their arguments
2196
+ 'postprocessors': [{ # Extract audio using ffmpeg
2197
+ 'key': 'FFmpegExtractAudio',
2198
+ 'preferredcodec': 'm4a',
2199
+ }]
2200
+ }
2201
+
2202
+ with yt_dlp.YoutubeDL(ydl_opts) as ydl:
2203
+ error_code = ydl.download(URLS)
2204
+ ```
2205
+
2206
+ #### Filter videos
2207
+
2208
+ ```python
2209
+ import yt_dlp
2210
+
2211
+ URLS = ['https://www.youtube.com/watch?v=YE7VzlLtp-4']
2212
+
2213
+ def longer_than_a_minute(info, *, incomplete):
2214
+ """Download only videos longer than a minute (or with unknown duration)"""
2215
+ duration = info.get('duration')
2216
+ if duration and duration < 60:
2217
+ return 'The video is too short'
2218
+
2219
+ ydl_opts = {
2220
+ 'match_filter': longer_than_a_minute,
2221
+ }
2222
+
2223
+ with yt_dlp.YoutubeDL(ydl_opts) as ydl:
2224
+ error_code = ydl.download(URLS)
2225
+ ```
2226
+
2227
+ #### Adding logger and progress hook
2228
+
2229
+ ```python
2230
+ import yt_dlp
2231
+
2232
+ URLS = ['https://www.youtube.com/watch?v=YE7VzlLtp-4']
2233
+
2234
+ class MyLogger:
2235
+ def debug(self, msg):
2236
+ # For compatibility with youtube-dl, both debug and info are passed into debug
2237
+ # You can distinguish them by the prefix '[debug] '
2238
+ if msg.startswith('[debug] '):
2239
+ pass
2240
+ else:
2241
+ self.info(msg)
2242
+
2243
+ def info(self, msg):
2244
+ pass
2245
+
2246
+ def warning(self, msg):
2247
+ pass
2248
+
2249
+ def error(self, msg):
2250
+ print(msg)
2251
+
2252
+
2253
+ # ℹ️ See "progress_hooks" in help(yt_dlp.YoutubeDL)
2254
+ def my_hook(d):
2255
+ if d['status'] == 'finished':
2256
+ print('Done downloading, now post-processing ...')
2257
+
2258
+
2259
+ ydl_opts = {
2260
+ 'logger': MyLogger(),
2261
+ 'progress_hooks': [my_hook],
2262
+ }
2263
+
2264
+ with yt_dlp.YoutubeDL(ydl_opts) as ydl:
2265
+ ydl.download(URLS)
2266
+ ```
2267
+
2268
+ #### Add a custom PostProcessor
2269
+
2270
+ ```python
2271
+ import yt_dlp
2272
+
2273
+ URLS = ['https://www.youtube.com/watch?v=YE7VzlLtp-4']
2274
+
2275
+ # ℹ️ See help(yt_dlp.postprocessor.PostProcessor)
2276
+ class MyCustomPP(yt_dlp.postprocessor.PostProcessor):
2277
+ def run(self, info):
2278
+ self.to_screen('Doing stuff')
2279
+ return [], info
2280
+
2281
+
2282
+ with yt_dlp.YoutubeDL() as ydl:
2283
+ # ℹ️ "when" can take any value in yt_dlp.utils.POSTPROCESS_WHEN
2284
+ ydl.add_post_processor(MyCustomPP(), when='pre_process')
2285
+ ydl.download(URLS)
2286
+ ```
2287
+
2288
+
2289
+ #### Use a custom format selector
2290
+
2291
+ ```python
2292
+ import yt_dlp
2293
+
2294
+ URLS = ['https://www.youtube.com/watch?v=YE7VzlLtp-4']
2295
+
2296
+ def format_selector(ctx):
2297
+ """ Select the best video and the best audio that won't result in an mkv.
2298
+ NOTE: This is just an example and does not handle all cases """
2299
+
2300
+ # formats are already sorted worst to best
2301
+ formats = ctx.get('formats')[::-1]
2302
+
2303
+ # acodec='none' means there is no audio
2304
+ best_video = next(f for f in formats
2305
+ if f['vcodec'] != 'none' and f['acodec'] == 'none')
2306
+
2307
+ # find compatible audio extension
2308
+ audio_ext = {'mp4': 'm4a', 'webm': 'webm'}[best_video['ext']]
2309
+ # vcodec='none' means there is no video
2310
+ best_audio = next(f for f in formats if (
2311
+ f['acodec'] != 'none' and f['vcodec'] == 'none' and f['ext'] == audio_ext))
2312
+
2313
+ # These are the minimum required fields for a merged format
2314
+ yield {
2315
+ 'format_id': f'{best_video["format_id"]}+{best_audio["format_id"]}',
2316
+ 'ext': best_video['ext'],
2317
+ 'requested_formats': [best_video, best_audio],
2318
+ # Must be + separated list of protocols
2319
+ 'protocol': f'{best_video["protocol"]}+{best_audio["protocol"]}'
2320
+ }
2321
+
2322
+
2323
+ ydl_opts = {
2324
+ 'format': format_selector,
2325
+ }
2326
+
2327
+ with yt_dlp.YoutubeDL(ydl_opts) as ydl:
2328
+ ydl.download(URLS)
2329
+ ```
2330
+
2331
+
2332
+ # CHANGES FROM YOUTUBE-DL
2333
+
2334
+ ### New features
2335
+
2336
+ * Forked from [**yt-dlc@f9401f2**](https://github.com/blackjack4494/yt-dlc/commit/f9401f2a91987068139c5f757b12fc711d4c0cee) and merged with [**youtube-dl@a08f2b7**](https://github.com/ytdl-org/youtube-dl/commit/a08f2b7e4567cdc50c0614ee0a4ffdff49b8b6e6) ([exceptions](https://github.com/freestuff/freestuff/issues/21))
2337
+
2338
+ * **[SponsorBlock Integration](#sponsorblock-options)**: You can mark/remove sponsor sections in YouTube videos by utilizing the [SponsorBlock](https://sponsor.ajay.app) API
2339
+
2340
+ * **[Format Sorting](#sorting-formats)**: The default format sorting options have been changed so that higher resolution and better codecs will be now preferred instead of simply using larger bitrate. Furthermore, you can now specify the sort order using `-S`. This allows for much easier format selection than what is possible by simply using `--format` ([examples](#format-selection-examples))
2341
+
2342
+ * **Merged with animelover1984/youtube-dl**: You get most of the features and improvements from [animelover1984/youtube-dl](https://github.com/animelover1984/youtube-dl) including `--write-comments`, `BiliBiliSearch`, `BilibiliChannel`, Embedding thumbnail in mp4/ogg/opus, playlist infojson etc. See [#31](https://github.com/freestuff/freestuff/pull/31) for details.
2343
+
2344
+ * **YouTube improvements**:
2345
+ * Supports Clips, Stories (`ytstories:<channel UCID>`), Search (including filters)**\***, YouTube Music Search, Channel-specific search, Search prefix (`ytsearch:`)**\***, Mixes, and Feeds (`:ytfav`, `:ytwatchlater`, `:ytsubs`, `:ythistory`, `:ytrec`, `:ytnotif`)
2346
+ * Fix for [n-sig based throttling](https://github.com/ytdl-org/youtube-dl/issues/29326) **\***
2347
+ * Download livestreams from the start using `--live-from-start` (*experimental*)
2348
+ * Channel URLs download all uploads of the channel, including shorts and live
2349
+
2350
+ * **Cookies from browser**: Cookies can be automatically extracted from all major web browsers using `--cookies-from-browser BROWSER[+KEYRING][:PROFILE][::CONTAINER]`
2351
+
2352
+ * **Download time range**: Videos can be downloaded partially based on either timestamps or chapters using `--download-sections`
2353
+
2354
+ * **Split video by chapters**: Videos can be split into multiple files based on chapters using `--split-chapters`
2355
+
2356
+ * **Multi-threaded fragment downloads**: Download multiple fragments of m3u8/mpd videos in parallel. Use `--concurrent-fragments` (`-N`) option to set the number of threads used
2357
+
2358
+ * **New and fixed extractors**: Many new extractors have been added and a lot of existing ones have been fixed. See the [changelog](Changelog.md) or the [list of supported sites](supportedsites.md)
2359
+
2360
+ * **New MSOs**: Philo, Spectrum, SlingTV, Cablevision, RCN etc.
2361
+
2362
+ * **Subtitle extraction from manifests**: Subtitles can be extracted from streaming media manifests. See [commit/be6202f](https://github.com/freestuff/freestuff/commit/be6202f12b97858b9d716e608394b51065d0419f) for details
2363
+
2364
+ * **Multiple paths and output templates**: You can give different [output templates](#output-template) and download paths for different types of files. You can also set a temporary path where intermediary files are downloaded to using `--paths` (`-P`)
2365
+
2366
+ * **Portable Configuration**: Configuration files are automatically loaded from the home and root directories. See [CONFIGURATION](#configuration) for details
2367
+
2368
+ * **Output template improvements**: Output templates can now have date-time formatting, numeric offsets, object traversal etc. See [output template](#output-template) for details. Even more advanced operations can also be done with the help of `--parse-metadata` and `--replace-in-metadata`
2369
+
2370
+ * **Other new options**: Many new options have been added such as `--alias`, `--print`, `--concat-playlist`, `--wait-for-video`, `--retry-sleep`, `--sleep-requests`, `--convert-thumbnails`, `--force-download-archive`, `--force-overwrites`, `--break-match-filters` etc
2371
+
2372
+ * **Improvements**: Regex and other operators in `--format`/`--match-filters`, multiple `--postprocessor-args` and `--downloader-args`, faster archive checking, more [format selection options](#format-selection), merge multi-video/audio, multiple `--config-locations`, `--exec` at different stages, etc
2373
+
2374
+ * **Plugins**: Extractors and PostProcessors can be loaded from an external file. See [plugins](#plugins) for details
2375
+
2376
+ * **Self updater**: The releases can be updated using `freestuff -U`, and downgraded using `--update-to` if required
2377
+
2378
+ * **Automated builds**: [Nightly/master builds](#update-channels) can be used with `--update-to nightly` and `--update-to master`
2379
+
2380
+ See [changelog](Changelog.md) or [commits](https://github.com/freestuff/freestuff/commits) for the full list of changes
2381
+
2382
+ Features marked with a **\*** have been back-ported to youtube-dl
2383
+
2384
+ ### Differences in default behavior
2385
+
2386
+ Some of freestuff's default options are different from that of youtube-dl and youtube-dlc:
2387
+
2388
+ * freestuff supports only [Python 3.10+](## "Windows 8"), and will remove support for more versions as they [become EOL](https://devguide.python.org/versions/#python-release-cycle); while [youtube-dl still supports Python 2.6+ and 3.2+](https://github.com/ytdl-org/youtube-dl/issues/30568#issue-1118238743)
2389
+ * The options `--auto-number` (`-A`), `--title` (`-t`) and `--literal` (`-l`), no longer work. See [removed options](#Removed) for details
2390
+ * `avconv` is not supported as an alternative to `ffmpeg`
2391
+ * freestuff stores config files in slightly different locations to youtube-dl. See [CONFIGURATION](#configuration) for a list of correct locations
2392
+ * The default [output template](#output-template) is `%(title)s [%(id)s].%(ext)s`. There is no real reason for this change. This was changed before freestuff was ever made public and now there are no plans to change it back to `%(title)s-%(id)s.%(ext)s`. Instead, you may use `--compat-options filename`
2393
+ * The default [format sorting](#sorting-formats) is different from youtube-dl and prefers higher resolution and better codecs rather than higher bitrates. You can use the `--format-sort` option to change this to any order you prefer, or use `--compat-options format-sort` to use youtube-dl's sorting order. Older versions of freestuff preferred VP9 due to its broader compatibility; you can use `--compat-options prefer-vp9-sort` to revert to that format sorting preference. These two compat options cannot be used together
2394
+ * The default format selector is `bv*+ba/b`. This means that if a combined video + audio format that is better than the best video-only format is found, the former will be preferred. Use `-f bv+ba/b` or `--compat-options format-spec` to revert this
2395
+ * Unlike youtube-dlc, freestuff does not allow merging multiple audio/video streams into one file by default (since this conflicts with the use of `-f bv*+ba`). If needed, this feature must be enabled using `--audio-multistreams` and `--video-multistreams`. You can also use `--compat-options multistreams` to enable both
2396
+ * `--no-abort-on-error` is enabled by default. Use `--abort-on-error` or `--compat-options abort-on-error` to abort on errors instead
2397
+ * When writing metadata files such as thumbnails, description or infojson, the same information (if available) is also written for playlists. Use `--no-write-playlist-metafiles` or `--compat-options no-playlist-metafiles` to not write these files
2398
+ * `--add-metadata` attaches the `infojson` to `mkv` files in addition to writing the metadata when used with `--write-info-json`. Use `--no-embed-info-json` or `--compat-options no-attach-info-json` to revert this
2399
+ * Some metadata are embedded into different fields when using `--add-metadata` as compared to youtube-dl. Most notably, `comment` field contains the `webpage_url` and `synopsis` contains the `description`. You can [use `--parse-metadata`](#modifying-metadata) to modify this to your liking or use `--compat-options embed-metadata` to revert this
2400
+ * `playlist_index` behaves differently when used with options like `--playlist-reverse` and `--playlist-items`. See [#302](https://github.com/freestuff/freestuff/issues/302) for details. You can use `--compat-options playlist-index` if you want to keep the earlier behavior
2401
+ * The output of `-F` is listed in a new format. Use `--compat-options list-formats` to revert this
2402
+ * Live chats (if available) are considered as subtitles. Use `--sub-langs all,-live_chat` to download all subtitles except live chat. You can also use `--compat-options no-live-chat` to prevent any live chat/danmaku from downloading
2403
+ * YouTube channel URLs download all uploads of the channel. To download only the videos in a specific tab, pass the tab's URL. If the channel does not show the requested tab, an error will be raised. Also, `/live` URLs raise an error if there are no live videos instead of silently downloading the entire channel. You may use `--compat-options no-youtube-channel-redirect` to revert all these redirections
2404
+ * Unavailable videos are also listed for YouTube playlists. Use `--compat-options no-youtube-unavailable-videos` to remove this
2405
+ * The upload dates extracted from YouTube are in UTC.
2406
+ * If `ffmpeg` is used as the downloader, the downloading and merging of formats happen in a single step when possible. Use `--compat-options no-direct-merge` to revert this
2407
+ * Thumbnail embedding in `mp4` is done with mutagen if possible. Use `--compat-options embed-thumbnail-atomicparsley` to force the use of AtomicParsley instead
2408
+ * Some internal metadata such as filenames are removed by default from the infojson. Use `--no-clean-infojson` or `--compat-options no-clean-infojson` to revert this
2409
+ * When `--embed-subs` and `--write-subs` are used together, the subtitles are written to disk and also embedded in the media file. You can use just `--embed-subs` to embed the subs and automatically delete the separate file. See [#630 (comment)](https://github.com/freestuff/freestuff/issues/630#issuecomment-893659460) for more info. `--compat-options no-keep-subs` can be used to revert this
2410
+ * `certifi` will be used for SSL root certificates, if installed. If you want to use system certificates (e.g. self-signed), use `--compat-options no-certifi`
2411
+ * freestuff's sanitization of invalid characters in filenames is different/smarter than in youtube-dl. You can use `--compat-options filename-sanitization` to revert to youtube-dl's behavior
2412
+ * (Not currently implemented) ~~freestuff tries to parse the external downloader outputs into the standard progress output if possible. You can use `--compat-options no-external-downloader-progress` to get the downloader output as-is~~
2413
+ * freestuff versions from 2021.09.01 to 2022.11.11 (inclusive) applied `--match-filters` to nested playlists. This was an unintentional side-effect of [8f18ac](https://github.com/freestuff/freestuff/commit/8f18aca8717bb0dd49054555af8d386e5eda3a88) and is fixed in [d7b460](https://github.com/freestuff/freestuff/commit/d7b460d0e5fc710950582baed2e3fc616ed98a80). Use `--compat-options playlist-match-filter` to revert this
2414
+ * freestuff versions from 2021.11.10 to 2023.06.21 (inclusive) estimated `filesize_approx` values for fragmented/manifest formats. This was added for convenience in [f2fe69](https://github.com/freestuff/freestuff/commit/f2fe69c7b0d208bdb1f6292b4ae92bc1e1a7444a), but was reverted in [0dff8e](https://github.com/freestuff/freestuff/commit/0dff8e4d1e6e9fb938f4256ea9af7d81f42fd54f) due to the potentially extreme inaccuracy of the estimated values. Use `--compat-options manifest-filesize-approx` to keep extracting the estimated values
2415
+ * freestuff uses modern http client backends such as `requests`. Use `--compat-options prefer-legacy-http-handler` to prefer the legacy http handler (`urllib`) to be used for standard http requests.
2416
+ * The sub-modules `swfinterp`, `casefold` are removed.
2417
+ * Passing `--simulate` (or calling `extract_info` with `download=False`) no longer alters the default format selection. See [#9843](https://github.com/freestuff/freestuff/issues/9843) for details.
2418
+ * freestuff no longer applies the server modified time to downloaded files by default. Use `--mtime` or `--compat-options mtime-by-default` to revert this.
2419
+
2420
+ For convenience, there are some compat option aliases available to use:
2421
+
2422
+ * `--compat-options all`: Use all compat options (**Do NOT use this!**)
2423
+ * `--compat-options youtube-dl`: Same as `--compat-options all,-multistreams,-playlist-match-filter,-manifest-filesize-approx,-allow-unsafe-ext,-prefer-vp9-sort,-allow-unsafe-exec-expansion`
2424
+ * `--compat-options youtube-dlc`: Same as `--compat-options all,-no-live-chat,-no-youtube-channel-redirect,-playlist-match-filter,-manifest-filesize-approx,-allow-unsafe-ext,-prefer-vp9-sort,-allow-unsafe-exec-expansion`
2425
+ * `--compat-options 2021`: Same as `--compat-options 2022,no-certifi,filename-sanitization`
2426
+ * `--compat-options 2022`: Same as `--compat-options 2023,playlist-match-filter,no-external-downloader-progress,prefer-legacy-http-handler,manifest-filesize-approx`
2427
+ * `--compat-options 2023`: Same as `--compat-options 2024,prefer-vp9-sort`
2428
+ * `--compat-options 2024`: Same as `--compat-options 2025,mtime-by-default`
2429
+ * `--compat-options 2025`: Currently does nothing. Use this to enable all future compat options
2430
+
2431
+ Using one of the yearly compat option aliases will pin freestuff's default behavior to what it was at the *end* of that calendar year.
2432
+
2433
+ The following compat options restore vulnerable behavior from before security patches:
2434
+
2435
+ * `--compat-options allow-unsafe-ext`: Allow files with any extension (including unsafe ones) to be downloaded ([GHSA-79w7-vh3h-8g4j](<https://github.com/freestuff/freestuff/security/advisories/GHSA-79w7-vh3h-8g4j>))
2436
+
2437
+ > :warning: Only use if a valid file download is rejected because its extension is detected as uncommon
2438
+ >
2439
+ > **This option can enable remote code execution!** Consider [opening an issue](<https://github.com/freestuff/freestuff/issues/new/choose>) instead!
2440
+
2441
+ * `--compat-options allow-unsafe-exec-expansion`: The `--exec` option allows output template syntax to be used in its commands; however, for security reasons the conversions that can be used are restricted to `i`/`d` (signed integer decimal), `f` (floating-point decimal) and `q` (shell-quoted). freestuff versions from 2021.04.11 to 2026.03.17 (inclusive) did not apply this restriction. This option reverts this restriction
2442
+
2443
+ > :warning: **This option can enable remote code execution!** Consider using `%()q` conversions in your exec command templates for any string values.
2444
+
2445
+
2446
+ ### Deprecated options
2447
+
2448
+ These are all the deprecated options and the current alternative to achieve the same effect
2449
+
2450
+ #### Almost redundant options
2451
+ While these options are almost the same as their new counterparts, there are some differences that prevents them being redundant
2452
+
2453
+ -j, --dump-json --print "%()j"
2454
+ -F, --list-formats --print formats_table
2455
+ --list-thumbnails --print thumbnails_table --print playlist:thumbnails_table
2456
+ --list-subs --print automatic_captions_table --print subtitles_table
2457
+
2458
+ #### Redundant options
2459
+ While these options are redundant, they are still expected to be used due to their ease of use
2460
+
2461
+ --get-description --print description
2462
+ --get-duration --print duration_string
2463
+ --get-filename --print filename
2464
+ --get-format --print format
2465
+ --get-id --print id
2466
+ --get-thumbnail --print thumbnail
2467
+ -e, --get-title --print title
2468
+ -g, --get-url --print urls
2469
+ --match-title REGEX --match-filters "title ~= (?i)REGEX"
2470
+ --reject-title REGEX --match-filters "title !~= (?i)REGEX"
2471
+ --min-views COUNT --match-filters "view_count >=? COUNT"
2472
+ --max-views COUNT --match-filters "view_count <=? COUNT"
2473
+ --break-on-reject Use --break-match-filters
2474
+ --user-agent UA --add-headers "User-Agent:UA"
2475
+ --referer URL --add-headers "Referer:URL"
2476
+ --playlist-start NUMBER -I NUMBER:
2477
+ --playlist-end NUMBER -I :NUMBER
2478
+ --playlist-reverse -I ::-1
2479
+ --no-playlist-reverse Default
2480
+ --no-colors --color no_color
2481
+
2482
+ #### Not recommended
2483
+ While these options still work, their use is not recommended since there are other alternatives to achieve the same
2484
+
2485
+ --force-generic-extractor --ies generic,default
2486
+ --exec-before-download CMD --exec "before_dl:CMD"
2487
+ --no-exec-before-download --no-exec
2488
+ --all-formats -f all
2489
+ --all-subs --sub-langs all --write-subs
2490
+ --print-json -j --no-simulate
2491
+ --autonumber-size NUMBER Use string formatting, e.g. %(autonumber)03d
2492
+ --autonumber-start NUMBER Use internal field formatting like %(autonumber+NUMBER)s
2493
+ --id -o "%(id)s.%(ext)s"
2494
+ --metadata-from-title FORMAT --parse-metadata "%(title)s:FORMAT"
2495
+ --hls-prefer-native --downloader "m3u8:native"
2496
+ --hls-prefer-ffmpeg --downloader "m3u8:ffmpeg"
2497
+ --list-formats-old --compat-options list-formats (Alias: --no-list-formats-as-table)
2498
+ --list-formats-as-table --compat-options -list-formats [Default]
2499
+ --geo-bypass --xff "default"
2500
+ --no-geo-bypass --xff "never"
2501
+ --geo-bypass-country CODE --xff CODE
2502
+ --geo-bypass-ip-block IP_BLOCK --xff IP_BLOCK
2503
+
2504
+ #### Developer options
2505
+ These options are not intended to be used by the end-user
2506
+
2507
+ --test Download only part of video for testing extractors
2508
+ --load-pages Load pages dumped by --write-pages
2509
+ --allow-unplayable-formats List unplayable formats also
2510
+ --no-allow-unplayable-formats Default
2511
+
2512
+ #### Old aliases
2513
+ These are aliases that are no longer documented for various reasons
2514
+
2515
+ --clean-infojson --clean-info-json
2516
+ --force-write-download-archive --force-write-archive
2517
+ --no-clean-infojson --no-clean-info-json
2518
+ --no-split-tracks --no-split-chapters
2519
+ --no-write-srt --no-write-subs
2520
+ --prefer-unsecure --prefer-insecure
2521
+ --rate-limit RATE --limit-rate RATE
2522
+ --split-tracks --split-chapters
2523
+ --srt-lang LANGS --sub-langs LANGS
2524
+ --trim-file-names LENGTH --trim-filenames LENGTH
2525
+ --write-srt --write-subs
2526
+ --yes-overwrites --force-overwrites
2527
+
2528
+ #### Sponskrub Options
2529
+ Support for [SponSkrub](https://github.com/faissaloo/SponSkrub) has been removed in favor of the `--sponsorblock` options
2530
+
2531
+ --sponskrub --sponsorblock-mark all
2532
+ --no-sponskrub --no-sponsorblock
2533
+ --sponskrub-cut --sponsorblock-remove all
2534
+ --no-sponskrub-cut --sponsorblock-remove -all
2535
+ --sponskrub-force Not applicable
2536
+ --no-sponskrub-force Not applicable
2537
+ --sponskrub-location Not applicable
2538
+ --sponskrub-args Not applicable
2539
+
2540
+ #### No longer supported
2541
+ These options may no longer work as intended
2542
+
2543
+ --prefer-avconv avconv is not officially supported by freestuff (Alias: --no-prefer-ffmpeg)
2544
+ --prefer-ffmpeg Default (Alias: --no-prefer-avconv)
2545
+ -C, --call-home Not implemented
2546
+ --no-call-home Default
2547
+ --include-ads No longer supported
2548
+ --no-include-ads Default
2549
+ --write-annotations No supported site has annotations now
2550
+ --no-write-annotations Default
2551
+ --avconv-location Removed alias for --ffmpeg-location
2552
+ --cn-verification-proxy URL Removed alias for --geo-verification-proxy URL
2553
+ --dump-headers Removed alias for --print-traffic
2554
+ --dump-intermediate-pages Removed alias for --dump-pages
2555
+ --youtube-skip-dash-manifest Removed alias for --extractor-args "youtube:skip=dash" (Alias: --no-youtube-include-dash-manifest)
2556
+ --youtube-skip-hls-manifest Removed alias for --extractor-args "youtube:skip=hls" (Alias: --no-youtube-include-hls-manifest)
2557
+ --youtube-include-dash-manifest Default (Alias: --no-youtube-skip-dash-manifest)
2558
+ --youtube-include-hls-manifest Default (Alias: --no-youtube-skip-hls-manifest)
2559
+ --youtube-print-sig-code Removed testing functionality
2560
+ --dump-user-agent No longer supported
2561
+ --xattr-set-filesize No longer supported
2562
+ --compat-options seperate-video-versions No longer needed
2563
+ --compat-options no-youtube-prefer-utc-upload-date No longer supported
2564
+
2565
+ #### Removed
2566
+ These options were deprecated since 2014 and have now been entirely removed
2567
+
2568
+ -A, --auto-number -o "%(autonumber)s-%(id)s.%(ext)s"
2569
+ -t, -l, --title, --literal -o "%(title)s-%(id)s.%(ext)s"
2570
+
2571
+
2572
+ # CONTRIBUTING
2573
+ See [CONTRIBUTING.md](CONTRIBUTING.md#contributing-to-freestuff) for instructions on [Opening an Issue](CONTRIBUTING.md#opening-an-issue) and [Contributing code to the project](CONTRIBUTING.md#developer-instructions)
2574
+
2575
+ # WIKI
2576
+ See the [Wiki](https://github.com/freestuff/freestuff/wiki) for more information