Package: nndownload
nndownloadEN |JAnndownload allows you to download videos, images, manga, and process other links fromNiconico, formerly known as Nico Nico Douga. Unlike other existing downloaders, this program communicates wth DMC (Dwango Media Cluster) servers to ensure access to high quality videos.DisclaimersIf you do not have apremium account, you may download low quality videos during economy mode hours (typically 12 PM - 2 AM JST) or during other periods of high traffic.When downloading without a login (using -g/--no-login), some videos may not be available for download or may only be available in a lower quality.Running multiple download sessions on the same connection may lead to temporary blocks or throttling.These functions are not currently supported:Downloading Niconama timeshiftsDownloading Seiga thumbnails and commentsDownloading channel blog commentsFeaturesDownload videos with comments, thumbnails, and metadataDownload Seiga images and manga with metadataDownload channel videos or blogs with metadataDownload mylistsDownload a user's videos, mylists, illustrations, or mangaGenerate stream URLs for Niconama broadcastsDownload videos faster using multiple threadsProcess lists of URLs from text filesRequirementsPython versionPython >=3.5.3Dependenciesaiohttpaiohttp-socksbeautifulsoup4requestsmutagensetuptoolsurllib3InstallationpipinstallnndownloadBinaries for Windows are available on thereleases page.UsageCLIusage: nndownload.py [options] input

positional arguments:
  input                 URLs or files

options:
  -h, --help            show this help message and exit
  -u EMAIL/TEL, --username EMAIL/TEL
                        account email address or telephone number
  -p PASSWORD, --password PASSWORD
                        account password
  --session-cookie COOKIE
                        user_session cookie value (string or filepath)
  -n, --netrc           use .netrc authentication
  -q, --quiet           suppress output to console
  -l, --log             log output to file
  -v, --version         show program's version number and exit

download options:
  -y PROXY, --proxy PROXY
                        http or socks proxy
  -o TEMPLATE, --output-path TEMPLATE
                        custom output path (see template options)
  -r N, --threads N     download videos using a specified number of threads
  -g, --no-login        create a download session without logging in
  -f, --force-high-quality
                        only download if the high quality video source is available
  -a, --add-metadata    add metadata to video file (MP4 only)
  -m, --dump-metadata   dump metadata to file
  -t, --download-thumbnail
                        download video thumbnail
  -c, --download-comments
                        download video comments
  -e, --english         request video on english site
  --chinese             request video on traditional chinese (taiwan) site
  -aq AUDIO_QUALITY, --audio-quality AUDIO_QUALITY
                        specify audio quality
  -vq VIDEO_QUALITY, --video-quality VIDEO_QUALITY
                        specify video quality
  -Q, --list-qualities  list video and audio qualities with availability status
  -s, --skip-media      skip downloading media
  --break-on-existing   break after encountering an existing download
  --playlist-start N    specify the index to start a list of items from (begins at 0)Moduleimportnndownloadurl="https://www.nicovideo.jp/watch/sm35249846"output_path="/tmp/{id}.{ext}"nndownload.execute("-g","-o",output_path,url)Custom Output PathsCustom filepaths are constructed like standard Python template strings, e.g.{uploader} - {title}.{ext}. For Seiga manga, the output path should be the template for a chapter directory, e.g.{manga_id}\{id} - {title}. The available options are:comment_count (videos, images, manga, articles)description (videos, images, manga)document_url (videos, images, manga, articles)ext (videos, images, articles)id (videos, images, manga, articles)published (videos, images, manga, articles)tags (videos, images, manga, articles)title (videos, images, manga, articles)uploader (videos, images, manga, articles)uploader_id (videos, images, manga, articles)url (videos, images)view_count (videos, images, manga)audio_quality (videos)video_quality (videos)article (articles)blog_title (articles)clip_count (images)duration (videos)manga_id (manga)manga_title (manga)mylist_count (videos)page_count (manga)size_high (videos)size_low (videos)thread_id (videos)thread_key (videos)thread_params (videos)thumbnail_url (videos)Using Stream LinksAfter generating a stream URL, the program must be kept running to keep the stream active.mpvandstreamlinkare the best options for playing generated stream URLs. Other programs that use aggressive HLS caching and threading may also work.mpv https://...streamlink https://... bestKnown BugsCheck open issues.LicenseThis project is licensed under the MIT License.