An open API service indexing awesome lists of open source software.

https://github.com/matthazinski/snapfeed

Generate RSS feeds of Snapchat stories (unmaintained)
https://github.com/matthazinski/snapfeed

Last synced: about 2 months ago
JSON representation

Generate RSS feeds of Snapchat stories (unmaintained)

Awesome Lists containing this project

README

        

Snapfeed
========

A utility to generate static RSS feeds from Snapchat stories. Also creates
HTML pages containing all content from a story in a given day.

Installation
------------

You must have the following `python2` packages installed:

* requests
* [snapy](https://github.com/tatosaurus/snapy)
* feedgen
* docopt
* jinja2

Additionally, a web server is required, which is outside the scope of this
document. Nginx is recommended.

Usage
-----

Syntax is subject to change. Run `python2 ./snapfeed.py -h` for the latest
syntax.

```
Usage:
snapfeed.py [-d ] -u [-p | -a ] --gmail= --gpasswd= -U [...]
snapfeed.py -r -U [...]

Options:
-d --delay= Delay in minutes to wait before re-downloading
-h --help Show usage
-u --username= Snapchat username
-p --password= Snapchat password
--gmail= Gmail address
--gpasswd= Gmail password
-U --base-url= Base url, e.g. http://localhost/snaps/
-a --auth-token= Auth token from Snapchat
-r --regenerate-html Regenerate HTML
```

Note that you must provide a webserver where `path` is available at
`base-url`. This information is used to generate RSS feeds. The feed file
itself will be written within `path`.

The `whitelist` parameter is used to specify zero or more usernames to filter
on. If none are specified, the feed will not be filtered at all. If one or
more are specified, then each media file corresponding to a story will be
added to the feed `username.xml` if the username is in the whitelist.
Regardless, the media will be saved in the `path` directory.

By default (top syntax), only the HTML for the current day is generated. Use
the bottom syntax to regenerate pages for every day since the earliest snapchat
story for each user in the `whitelist`. The bottom syntax does not do anything
other than generate HTML for existing media.

TODO
----

The following features have not yet been implemented:

* PNG overlays for videos containing them (only the video is placed in the
feed).
* Consistent image/video dimensions in HTML pages
* Reduced traffic feeds - generate a single item per username during each
update linking to an HTML page with all relevant media filess.
* Daemonizing
* Place items in separate directories based on username
* Options to generate directory index to allow easy mass-downloading

Warning
-------

This is mentioned in the [snapy readme](https://github.com/tatosaurus/snapy/blob/master/README.md)
but bears repeating: your Snapchat credentials are sent to a third party,
[Casper's API](https://api.casper.io).

Also it should be noted that this currently downloads ALL friend stories you
have access to, irrespective of the username whitelist in the command line
options. Snap IDs are saved by the username and Unix timestamp, which are
probably easily guessable by an adversary. This behavior will likely change in
the future when I get around to implementing a separate config file.