Skip to main content

Command-line app for collecting keyword-based Twitter data.

Project description


A Python command-line application for collecting keyword-based Twitter data.

Tested with Python 2.7 and 3.4.


Install from PyPI via pip :

pip install pytwcla


  • Tweepy >= 3.5 (It will be installed automatically)


Edit api.ini with your Twitter credentials .

pytwcla -h will point you to the location where api.ini has been installed.


If installation is successful, an executable script should be somewhere in your PATH. Open a command-line and try it out:


REST search (eg. keyword = ‘fintech’):

pytwcla fintech -r

Returns IDs and Dates of Tweets matching the specified keyword and saves them in a SQLite database file named fintech_rest.db.

Stream search (eg. keyword = ‘fintech’):

pytwcla fintech -s

Returns IDs and Dates of relevant Tweets and saves them in fintech_stream.db.

Join REST and Stream search results:

pytwcla fintech -j

Neither the REST nor the Stream search API is meant to be an exhaustive source of Tweets.

Create csv:

pytwcla fintech -c

Creates .csv files with daily keyword counts.

If fintech_rest.db exists it creates fintech_rest.csv.



Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for Pytwcla, version 0.1.5
Filename, size File type Python version Upload date Hashes
Filename, size (8.0 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page