Skip to main content

Download videos from toutiao.com

Installation

python3 -m pip install toutiao-video

Usage

Use in CMD

toutiao --help

# download videos from user feed
toutiao feed -u xxxxx -t xxxxx
toutiao feed -u xxxxx -t xxxxx -O output
toutiao feed -u xxxxx -t xxxxx -l 5
toutiao feed -u xxxxx -t xxxxx -l 1 -d 1080p
toutiao feed -u xxxxx -t xxxxx -l 10 --dryrun

# download video from video url
toutiao video -t xxxxx <video_url>
toutiao video -t xxxxx <video_url> -d 1080p
toutiao video -t xxxxx <video_url> -d 1080p -O output
toutiao video -t xxxxx <video_url> -d 1080p -O output --dryrun

Use in Python

# download videos from user feed
from toutiao.core import TouTiao

toutiao = TouTiao(user_id='user_id', tt_webid='tt_webid')

for n, item in enumerate(toutiao.list_user_feed(), 1):
    if n > 5:
        break()
    print(item)       

# download video from video url
from toutiao.video import ToutiaoVideo
video = ToutiaoVideo(url='<your_video_url>', ttwid='<your_ttwid>')
initial_video = video.get_initial_video()
print(initial_video)
# video.download()

Help

  • tt-webid and ttwid you can get the value from Network > Request Headers > Cookie or Application > Cookies on your browser.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

toutiao-video-1.0.1.tar.gz (5.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

toutiao_video-1.0.1-py3-none-any.whl (6.1 kB view details)

Uploaded Python 3

File details

Details for the file toutiao-video-1.0.1.tar.gz.

File metadata

  • Download URL: toutiao-video-1.0.1.tar.gz
  • Upload date:
  • Size: 5.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.8

File hashes

Hashes for toutiao-video-1.0.1.tar.gz
Algorithm Hash digest
SHA256 9c6ef144af8425c28f3983c321e52e542a1f874ec65f51fd73d22d1301ef1d76
MD5 7a449b36d9b6c2a24c5a7301d6d6cebf
BLAKE2b-256 fd7200ad1444cb491b89e999f1b042bdeff3edb32882dc07947e69f2137ee552

See more details on using hashes here.

File details

Details for the file toutiao_video-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: toutiao_video-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 6.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.8

File hashes

Hashes for toutiao_video-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 fff3a3f53837278a8e5c1d0f4407191953f2d68cd8087c2c2dabcfdf394dc44a
MD5 2be3252e62e45f7f3d1932a67538a851
BLAKE2b-256 2457d066250f9c99d61b0aa450d3a93310d2ebaf306fdf95e141d1950e5f0be2

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 files

1.0.0

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page