Search code examples
pythonyoutube-dl

youtube-dl python library documentation


is there any documentation for use youtube-dl as a python library in a project?

I know that I can use the main class, but I can't find any documentation or example...

import youtube_dl

ydl = youtube_dl.YoutubeDL(params)

... ?

Solution

  • If you download a version from github you can generate sphinx-docs which is useful for developement. Then using pythons help function usually gives some idea what the purpose of a function is

    >>> import youtube_dl as yt
    >>> help(yt)
    

    Furthermore I find ipython a useful tool to explore code using the %edit magic.

    %edit yt.main 
    

    would bring you directly to the source of the main function.