generate a rss feed from Twitter or Mastodon search
Project description
python-twootfeed
a Python script to generate a rss feed from parsed Twitter or Mastodon search and Mastodon favorites, using Flask.
The RSS feed displays only the original tweets (not the retweets) and :
- links to :
- the original tweet on Twitter or toot on Mastodon
- hashtags
- usernames
- URLs
- images
- source
- location (only for Twitter)
- numbers of retweets (or boosts for Mastodon) and favorites
(see examples below).
Requirements
- Python 3.6+
- API keys Twitter and/or Mastodon
Installation and configuration
- Install from pip
$ pip install twootfeed
- Initialize the configuration file
$ twootfeed_init
-
Fill in fields for the client(s) you will use in '~/.config/twootfeed/config.yml' :
- for Twitter : see https://apps.twitter.com
copy/paste the Twitter API key values in config.yml file ('consumerKey' and 'consumerSecret') - for Mastodon : see Python wrapper for the Mastodon API
use the included script which will register your app and prompt you to log in, creating the credential files for you.
$ twootfeed_create_mastodon_cli
- for Twitter : see https://apps.twitter.com
-
Start the app
$ twootfeed
Usage
The RSS feeds are available on these urls:
- for Twitter: http://localhost:8080/_keywords_ or http://localhost:8080/tweets/_keywords_
- for Mastodon:
- search: http://localhost:8080/toots/_keywords_
- connected user favorites: http://localhost:8080/toot_favorites
Examples
Search on Twitter
Results in RSS Feed:
Display on FreshRSS, a great free self-hosted aggregator (https://github.com/FreshRSS/FreshRSS):
Search on Mastodon
Results in RSS Feed:
Display on FreshRSS:
Contribute
see Quick start for developers
Contributors
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
twootfeed-0.6.0.tar.gz
(9.8 kB
view hashes)
Built Distribution
twootfeed-0.6.0-py3-none-any.whl
(12.2 kB
view hashes)
Close
Hashes for twootfeed-0.6.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 54a608fa2df4846f44ddcbd1f19f7c9e4a698b1f6637a9dc42d13096867fa5fc |
|
MD5 | 06e412634844509f69ae3f16427daf0c |
|
BLAKE2b-256 | cf46278c0c1d2e866372ecf43d890a619417c4ab29d2519512b7a2e6a3a0b015 |