Skip to content
Implementation of the Snapchat protocol in Python
Python
Branch: master
Clone or download

Latest commit

Latest commit 6277e03 Oct 3, 2014

Files

Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src Merge remote-tracking branch 'origin/master' Oct 3, 2014
.gitignore Update gitignore for PyCharm Nov 26, 2013
LICENSE Initial commit Nov 26, 2013
README.md Modified code to be more inline with the project. Oct 3, 2014
requirements.txt Add requirements.txt Nov 26, 2013

README.md

Snapchat for Python

Implementation of the Snapchat protocol in Python. Heavily based on php-snapchat.

Install

pip install requests
easy_install pycrypto
git clone https://github.com/niothiel/snapchat-python.git
cd snapchat-python/src
python example.py

Example

To get started, download snapchat.py and in another file enter the following:

from snapchat import Snapchat

s = Snapchat()
s.login('USERNAME', 'PASSWORD')

# Send a snapchat
media_id = s.upload(Snapchat.MEDIA_IMAGE, 'filename.jpg')
s.send(media_id, 'recipient')

# Get all snaps
snaps = s.get_snaps()

# Download a snap
s.get_media(snap['id'])

# Clear snapchat history
s.clear_feed()
You can’t perform that action at this time.