not really known
You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
Go to file
J. Fernando Sánchez b212a46ab7 Added CI and tests 8 years ago
bitter Added CI and tests 8 years ago
tests Improved tweet downloader (CLI and API) 8 years ago
.gitignore Added CI and tests 8 years ago
Dockerfile Drone tests, fixed get_credentials 8 years ago
Dockerfile-2.7 Added CI and tests 8 years ago
Dockerfile-3.4 Added CI and tests 8 years ago
Dockerfile.template Added CI and tests 8 years ago
MANIFEST.in Added CI and tests 8 years ago
Makefile Added CI and tests 8 years ago
README.md Drone tests, fixed get_credentials 8 years ago
requirements-py2.txt Changed versioning, added locks 8 years ago
requirements.txt Added stream to CLI 8 years ago
setup.cfg Added CI and tests 8 years ago
setup.py Added CI and tests 8 years ago
test-requirements.txt Drone tests, fixed get_credentials 8 years ago

README.md

#Description There are two parts to bitter. First of all, it is a wrapper over Python twitter that adds support for several Twitter API credentials (e.g. authorizing the same app with different user accounts). Secondly, it is a command line tool to automate several actions (e.g. downloading user networks) using the wrapper.

Instructions

In the command line:

python -m bitter --help

or

bitter --help

Programmatically:

from bitter.crawlers import TwitterQueue
wq = TwitterQueue.from_credentials()
print(wq.users.show(user_name='balkian'))

Credentials format

{"user": "balkian", "consumer_secret": "xxx", "consumer_key": "xxx", "token_key": "xxx", "token_secret": "xxx"}

By default, bitter uses '~/.bitter-credentials.json', but you may choose a different file:

python -m bitter -c <credentials_file> ...

Server

To add more users to the credentials file, you may run the builtin server, with the consumer key and secret of your app:

python -m bitter server <consumer_key> <consumer_secret>

If you get an error about missing dependencies, install the extra dependencies for the server. e.g.:

pip install bitter[web]

Make sure the callback url of your app is set to http://127.0.0.1:5000/callback_url/

Notice

Please, use according to Twitter's Terms of Service

TODO

  • Tests
  • Docs