Generates RSS feeds for Twitch accounts.
This acts as a proxy to Twitch, presenting video history as an RSS feed. The idea is that you can add specific accounts to your RSS reader as separate URLs/feeds.
You can run it in two modes:
In order to use this, you first need to create a Twitch App and get the Client ID and Client Secret.
Those credentials will then be used by
twitch-rss to query Twitch APIs.
cargo install twitch-rss.
CLIENT_SECRETenvvars containing the Twitch App credentials. You can optionally also specify
0.0.0.0:8080is the default:
$ CLIENT_ID=1234...abcd \ CLIENT_SECRET=5678...efgh \ LISTEN=127.0.0.1:8080 \ ./twitch-rss
twitch-rssis running, you can then add it to your RSS reader with
/rss?account=ACCOUNT_NAME_HEREadded to the end of the
LISTENaddress. You can test this manually with
$ curl -v 'http://127.0.0.1:8080/rss?account=ACCOUNT_NAME_HERE'
You can also run
twitch-rss via the command line with the account to query as an argument. The command will then write the RSS payload to stdout. This is mainly useful for testing, or for writing the RSS payload to a static file.
$ CLIENT_ID=1234...abcd \ CLIENT_SECRET=5678...efgh \ ./twitch-rss ACCOUNT_NAME_HERE
twitch-rss mainly exposes options via environment variables. The one exception is specifying an account name to fetch as an argument, as shown in the CLI/stdout example above.
CLIENT_SECRET: Your Twitch App credentials for querying the Twitch API. Required.
LOG_LEVEL: Amount of logging you'd like to have. Defaults to
info, can be set to
traceto get more logs or
offto get fewer logs.
LISTEN: The listen address when running in HTTP mode. Defaults to
8080on all interfaces).
USER_CACHE_SECS: The duration in seconds to cache information about Twitch accounts. Default is
86400or 1 day.
VIDEO_CACHE_SECS: The duration in seconds to cache the recent videos for a given Twitch account. Default is
600= 10 minutes)