Skip to content

NV4RE/tiktok-scraper-chrome-headless-go

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

tiktok-scraper-chrome-headless-go

TikTok's user profile scraper, if Captcha is detected, you have to resolve it manually, and press enter in terminal to continue.

Basic use

./tiktok-scraper-linux-amd64 -profile-url https://www.tiktok.com/@username_here

With video duration

./tiktok-scraper-linux-amd64 -profile-url https://www.tiktok.com/@username_here -video-duration

If you have problem starting the scraper

./tiktok-scraper-linux-amd64 -profile-url https://www.tiktok.com/@username_here -disable-gpu

All arguments

Usage of ./main:
  -debug-log
        Enable debug logging
  -disable-gpu
        Disable GPU
  -exec-path string
        Path to Chrome/Chromium or Brave executable
  -headless
        Run browser in headless mode
  -max-page-wait-sec int
        Maximum time to wait for page to load (default 20)
  -output string
        Output file (default "output.json")
  -profile-url string
        URL to the profile to scrape, e.g. https://www.tiktok.com/@username
  -video-duration
        Get video duration

Example Result

{
  "ProfileUrl": "https://www.tiktok.com/@xxxx",
  "StartedAt": "0001-01-01T00:00:00Z",
  "VideoStats": [
    {
      "Url": "https://www.tiktok.com/@xxxx/video/123412312?is_copy_url=1\u0026is_from_webapp=v1",
      "Description": "Foo bar",
      "Likes": "6.9K",
      "Comments": "699",
      "UploadAt": "11h ago",
      "DurationSeconds": 194.466667,
      "Date": "0001-01-01T00:00:00Z"
    },
    {
      "Url": "https://www.tiktok.com/@xxxx/video/123412312?is_copy_url=1\u0026is_from_webapp=v1",
      "Description": "Foo bar 2",
      "Likes": "96K",
      "Comments": "699",
      "UploadAt": "11h ago",
      "DurationSeconds": 69.69,
      "Date": "0001-01-01T00:00:00Z"
    }
  ]
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages