Code Monkey home page Code Monkey logo

tiktok-rss-flat's Introduction

TikTok RSS Logo

TikTok RSS Using GitHub Actions

Generate usable RSS feeds from TikTok using GitHub Actions and GitHub Pages.

NOTE March 2024: This seems to work again due to improvements in the original TikTok library. It requires an on-the-fly patch to that underlying TikTok library, which is hopefully only temporary

Setup for GitHub Actions

  • To get your own instance running

    • Fork this repo
    • Make sure to enable Actions in the Actions tab
    • Enable GitHub Pages for your new repo
    • Get a value of ms_token from your TikTok account as follows:
      • Log into TikTok on Chrome desktop
      • View a user profile of someone you follow
      • Open Chrome DevTools with F12
      • Go to the Application Tab > Storage > Cookies > https://www.tiktok.com
      • Copy the cookie value of msToken
    • In the Settings Tab for your Repo, go to Secrets and Variables > Actions
    • Create a New Repository Secret:
      • Name = MS_TOKEN
      • Value = The value you got for msToken above
    • Edit config.py to change ghPagesURL from "https://conoro.github.io/tiktok-rss-flat/" to your URL
    • Add the TikTok usernames that you like to subscriptions.csv
  • It's set to run once every 4 hours and generates one RSS XML file per user in the rss output directory.

  • You may need to update the msToken whenever your get GH Actions erros about TikTok returning an empty response

Running locally as an alternative

  • You need Python installed
  • Then setup with:
pip install virtualenv
python -m venv venv
source venv\bin\activate
pip install -r requirements.txt
export MS_TOKEN="blah"
  • Then run each time with:
source venv\bin\activate
python postprocessing.py
git commit -a -m "latest RSS"
git push origin main

Feed Reading

Acknowledgements

This uses an unoffical TikTokPy library to extract information about user videos from TikTok as JSON and generate RSS feeds for each user you are interested in.

Logo was created using the TikTok and RSS Font Awesome icons via CC BY 4.0 License

Copyright Conor O'Neill, 2021-2024 ([email protected])

License Apache 2.0

tiktok-rss-flat's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

tiktok-rss-flat's Issues

post fetch phase uses wrong url and gives error 128 on /usr/bin/git push

The extraction from TikTok actually works well, data is being fetched and the xml files are prebuilt in memory, only during the post fetch data phase I get an error from get (128).

It tries to go to the github.com url instead of the subdomain.github.io one. The url configured in ghPagesURL / postprocessing.py doesn't seem to be used. Any advice?

/usr/bin/git push
remote: Permission to xxx/tiktok-rss.git denied to github-actions[bot].
fatal: unable to access 'https://github.com/xxx/tiktok-rss/': The requested URL returned error: 403
Error: Post script failed! The process '/usr/bin/git' failed with exit code 128

Is it possible to hire you to make a script?

Is it possible to hire you to make a script?

Daily I download the videos of a specific hashtag, let's say the hastag is #fortnite , I need to have a list of all the videos that have been uploaded with that hashtag in the last 24 hours.

Can you do it, how much would it cost?

Worked for a bit, stopped working

Hi! First, many thanks for creating this! I was able to get the RSS feeds I was interested in, which is great!

Sadly, though, about four days ago it seems to have stopped working? I don't have anything new since Sept 13th, even though I've verified that new videos have been posted.

It also looks like the problem is affecting your version of the repository as well?

Although I understand some of what is happening, I'm afraid I don't know enough to debug the issue. Do you have any suggestions?

Thanks,
Ricky

Can't get it work :(

2024-01-16 17:53:40,032 Using selector: EpollSelector
2024-01-16 17:55:42,363 Error: Data scraping unable to complete in 60.0s (retries: 3)

Get this error :(

must enable actions after forking

Hey thanks for this so much, I hate getting sucked into tiktok, but there are a few creators that I'd like to follow - this would be the perfect solution.

so I think I set it up right, but for someone that is used to getting around github, it's worth pointing out in the readme, that after forking and setting up all the variables, you mus explicitly enable actions in the actions tab after it is forked.

Again, thanks for this - I can't wait for the tiktok api to get fixed so I can properly test this out.

the xml site can't be reached

Hello, thank you very much for sharing the project.
I have edited the url with my github page url, and when I checked the rss folder, the xml file got updated, but when I opened the link using browser, it said "This site can’t be reached". any tips? thank you

How to get updates?

Hi! I'm apparently less useful at git than I thought. Now that I've modified my list of tiktoks, and removed the CNAME file, etc., your repository and mine have gone their separate ways for a bit. But I notice that you've made some changes that I should pull over (update to new version of OCTO). How do I tell GitHub to pull over that one commit? Is there something that I should be googling for? Did I set up my project incorrectly (should I have cloned yours, the made my changes in a branch, so I could just "rebase"(?) on yours)?

Thanks for any suggestions,
Ricky

Rss feed doesn't seem to be updating

I noticed that despite the flat workflow triggering it isn't populating my rss folder. When I tried out one of the rss feeds you already have set up I also noticed that the feed was a few tiktoks behind- including one iamtabithabrown had uploaded 2 hours ago

The RSS folder does not create new and returns an error.

The page build completed successfully, but returned the following warning for the main branch:

The CNAME tiktokrss.conoroneill.com is already taken. Check out https://docs.github.com/articles/troubleshooting-custom-domains#cname-errors for more information.

For information on troubleshooting Jekyll see:

https://docs.github.com/articles/troubleshooting-jekyll-builds

If you have any questions you can submit a request at https://support.github.com/contact?repo_id=398568195&page_build_id=274193942

I've used GitHub action a few times. Allow users to create and operate specific branches.
like gh-pages

Doubt about execution

Hello, thank you very much for sharing the project.
I don't understand how I can make it run every hour and be able to get the feeds? Could someone tell me how to install or run it?

Working?

Are you finding that, as of 25 Jan 2022, this is working for you? I haven't seen updates to the RSS feeds in several weeks, even though there are several new videos that have been released...

Thanks,
Ricky

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.