Skip to content

the-csm-builder/get-twitter-data

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Retrieve Twitter Data Programatically and save to CSV

I used twarc library to retrieve data, and save to csv. The library is easy to use, and sample code works.

This notebook is a proof of concept, only to be used for testing

Setup

  • Install VSCode ( I use a mac). https://code.visualstudio.com/
  • Download python (if needed)
  • Download the Notebook from github in VSCode. Or run git clone commmand to download and install on computer
  • Install libary (twarc) using pip command, preferred installer program for python language. Run pip from terminal in VSCode. e.g pip3 install twarc
  • Ensure the data-output folder is setup, the query csv results will get stored in this folder

Run get twitter api in notebook

  • Update bearer_token with your value saved in a safe place. Dont share your bearer_token
  • Enter query value, e.g. "Tesla"
  • Update start_time and end_time values. If testing with Tesla, use minutes. If testing the query on your brand switch minutes to hours

Setup AWS Account

Pricing

  • AWS offers a free tier, if you get the data small for testing purposes, the cost will be minimal. For now, we are justing using the AWS comprehend sentiment service. For detailed pricing follow this link - https://aws.amazon.com/comprehend/pricing/

Link to workbook

Get Twitter Notebook

About

Retrieve twitter data for brands, to build customer 360

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors