Skip to content

Extract metadata and comments from a TikTok video.

Notifications You must be signed in to change notification settings

bud1mu/tt-dumper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 

Repository files navigation

TikTok Comment Dumper

A Python tool for extracting metadata and comments from TikTok videos.

Features

  • Extract video metadata (ID, author, description, statistics)
  • Download video comments
  • Multiple output formats supported (JSON, CSV, TXT)
  • Configurable comment limit
  • Command-line interface

Requirements

requests
urllib3

Installation

  1. Clone the repository:
git clone https://github.com/bud1mu/tt-dumper.git
cd tt-dumper
  1. Install dependencies:
pip install -r requirements.txt

Usage

python main.py -u <tiktok_url> [-o output_file] [-c comment_count] [-f file_type]

Arguments

  • -u, --url: TikTok video URL (required)
  • -o, --output: Output filename (default: output.json)
  • -c, --comment: Number of comments to retrieve (optional)
  • -f, --file-type: Output format (json/csv/txt, default: json)

Example

python tt-dumper.py -u https://www.tiktok.com/@user/video/1234567890 -o results.csv -c 100 -f csv

Output Format

JSON

{
    "metadata": {
        "idVideo": "1234567890",
        "uniqueId": "username",
        "nickname": "User Name",
        "description": "Video description",
        "totalLike": 1000,
        "totalComment": 50,
        "totalShare": 100,
        "createTime": "2024-01-02 12:34:56",
        "duration": "00:00:30"
    },
    "comments": [
        {
            "username": "commenter1",
            "comment": "Comment text"
        }
    ]
}

Disclaimer

This tool is for educational purposes only. Please respect TikTok's terms of service and API usage guidelines.

Author

@bud1mu

About

Extract metadata and comments from a TikTok video.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages