Skip to content

Please add Cookies-Support for ytdlp-nodejs #33

@nerzlakai96

Description

@nerzlakai96

Dear developer,
due to YouTube limiting or blocking, i encountered to following errors now when trying to use ytdlp-nodejs with yt-dlp:

Error code: Error: Command failed: /[...]/yt-dlp https://www.youtube.com/watch?v=dQw4w9WgXcQ --dump-json
ERROR: [youtube] dQw4w9WgXcQ: Sign in to confirm you’re not a bot. Use --cookies-from-browser or --cookies for the authentication. See https://github.com/yt-dlp/yt-dlp/wiki/FAQ#how-do-i-pass-cookies-to-yt-dlp for how to manually pass cookies. Also see https://github.com/yt-dlp/yt-dlp/wiki/Extractors#exporting-youtube-cookies for tips on effectively exporting YouTube cookies

This can be fixed by adding the possibility inside ytdlp-nodejs to add a configurable parameter "--cookies ./cookies.txt" to all functions like e.g ytdlp.stream / ytDlp.getInfoAsync so it sends a command to yt-dlp like this:
/[...]/yt-dlp https://www.youtube.com/watch?v=dQw4w9WgXcQ --cookies ./cookies.txt --dump-json

Thanks in advance and kind regards,
nerzlakai96

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions