You can use twarc
to give an example if you want to archive Nassim Nicholas Taleb's tweets you use.
twarc timeline nntaleb --format csv> taleb.csv
You can use other formats too: --format {json,csv,csv-excel}
How to configure twarc
:
The only way to get the complete tweets is using the API
unfortunately even if the app is transparent you need to have an initial setup and configuration, you also need to apply for the API
(
As of July 2018, you must apply for a Twitter developer account and be
approved before you may create new apps.
)
Once you've got your application keys you can tell twarc
what they are with the configure command.
twarc configure
This will store your credentials in a file called .twarc
in your home directory so you don't have to keep entering them in. If you would rather supply them directly you can set them in the environment (CONSUMER_KEY
, CONSUMER_SECRET
, ACCESS_TOKEN
, ACCESS_TOKEN_SECRET
) or using command line options (--consumer_key
, --consumer_secret
, --access_token
, --access_token_secret
).