Year in review: Academic Research with the Twitter API v2
Tags: api, twitter
Published: 2021-12-03 18:58:39

In 2021, we launched product improvements and various community initiatives to help the academic research community succeed in their research studies with Twitter data. In this post, I present a recap of all the API launches and programs - from Twitter as well as the academic research community - that has made it easier for researchers to do research with Twitter data.

## Improvements for academics & students with the Twitter API v2

### Academic Research Product Track

[Launched in January 2021](https://twittercommunity.com/t/introducing-the-new-academic-research-product-track/148632), the [academic research product track](https://twitter.com/TwitterDev/status/1376612438313852930) is one of the biggest updates to the Twitter API v2 for the academic research community. It provides qualified academic researchers free access to the full-archive of public Tweets (previously, academics had to use the paid premium API to get Tweets older than 7 days). In addition to access to the full-archive search functionality, academics get 10 million Tweets per month. This is higher than the other access levels - the essential access provides 500K Tweets per month and the Elevated access provides 2 Million Tweets per month. The academic research track also lets academics further refine their search queries by supporting search operators for geo-filtering.

![Academic Product Track](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/o9p4spaoinzdrh2deqjw.png)

### Tweet counts endpoints

In June 2021, we [launched the Tweet counts endpoints](https://twitter.com/suhemparack/status/1408139121118175232) that give the volume of Tweets over a period of time for any search query. The Full-archive Tweet counts endpoint is currently available only for academics, so you can get the Tweet counts from the entire archive of public Tweets. This is particularly helpful for visualization use-cases and to identify trends and pattterns for topics over a period of time.
![Tweet Counts](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/um9ip9r9z0lbrhdwgf9k.gif)

### Batch compliance endpoints

In August 2021, we launched the [batch compliance endpoints](https://twitter.com/TwitterDev/status/1430587523919536129) that let developers and researchers upload large number of Tweet or User IDs and get the current status of those Tweets or Users (whether they are deleted, suspended etc). This lets developers and researchers keep their datasets compliant with [Twitter's developer policy](https://developer.twitter.com/en/developer-terms/policy). In the past, developers had to use the Tweet lookup endpoints to do this, which was quite slow and supported maximum 100 IDs per request, so this new solution is very helpful for researchers.

### Essential access

In November 2021, the [essential access was added to the Twitter API v2](https://twittercommunity.com/t/ushering-in-a-new-era-for-the-twitter-developer-platform-with-the-twitter-api-v2/162087). With essential access, anyone can get access to basic functionality in the Twitter API just by signing up - without applying for a developer use-case review. This gives you instant access to the Twitter API v2 and is thus a good option for teaching use-cases. Professors can just ask their students to sign up for essential access ahead of class, if they want to use Twitter data in their classes.

![Essential Access](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/iqq19y4xuz7pnyk4kcw0.jpg)

## Livestreams and virtual events for academic research with the Twitter API

We hosted livestreams and virtual events with various guests from the academic community to showcase how researchers can use the Twitter API v2 to get data for their research studies. Below is a list of livestreams and virtual events we did in 2021:

* February 25th 2021 - [Introduction to the academic research product track](https://twitter.com/TwitterDev/status/1364275610764201984)
* March 18th 2021 - [Deep-dive into the full-archive search with the Twitter API v2](https://twitter.com/TwitterDev/status/1371363033352638467)
* April 22nd 2021 - [Getting started with the Twitter API v2 in Python using Twarc2](https://twitter.com/TwitterDev/status/1382745061910138880)
* May 20th 2021 - [Getting started with the Twitter API v2 in R using academictwitteR](https://twitter.com/TwitterDev/status/1392887366507970561)
* June 23rd 2021 - [Exploratory data analysis in R with the Twitter API v2 with Dr. Maria Rodriguez](https://twitter.com/TwitterDev/status/1405586027088007170)
* July 9th 2021 - [Building visualizations with the Tweet counts endpoints in the Twitter API v2](https://twitter.com/TwitterDev/status/1411028983366361088)
* August 7th 2021 - [Postman Student Summit](https://twitter.com/getpostman/status/1419326709837533186)

![Postman Student Summit](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/g3bv5y9uyfmo3dputs3e.jpeg)

* August 26th 2021 - [Back to school event - how PhD & Postdocs use the Twitter API in their research studies](https://twitter.com/TwitterDev/status/1427691817600884737)
* September 3rd 2021 - [Getting started with the Twitter API v2 in Python using OSoMeTweet package](https://twitter.com/TwitterDev/status/1432380245806497792)
* September 30th 2021 - [Academic Research with the Twitter API v2 with Dr. Ernesto Calvo](https://twitter.com/TwitterDev/status/1441432845902221335)
* October 5th 2021 - [Academic Research with the Twitter API v2 with CSMaP NYU](https://twitter.com/TwitterDev/status/1445436032485244929)
* Octover 29th 2021 - [Academic Research with the Twitter API v2 with Dr. Deen Freelon](https://twitter.com/TwitterDev/status/1451609611455242241)
* November 12th 2021 - [Twitter API in the classroom](https://twitter.com/suhemparack/status/1458857902559547393)

## Office hours

In March 2021, we [announced monthly office hours](https://twitter.com/TwitterDev/status/1372627771717869568) for academics that need help with their usage of the Twitter API v2 and the academic research product track. During these office hours, researchers can get 1:1 technical help and get their questions about the Twitter API v2 answered.

## Getting started with the Twitter API v2 course

In June, we [launched a comprehensive course](https://twitter.com/TwitterDev/status/1409931481552543749) on getting started with the Twitter API v2 for academic research. [This course](https://github.com/twitterdev/getting-started-with-the-twitter-api-v2-for-academic-research) is available for free and contains content, cheatsheets and code samples in Python and R to help academics learn how to get the Twitter data for research studies using the Twitter API. Since its launch, this course has been adopted as a prerequisite model by various professors who teach courses on computational social sciences, text mining etc.

## Academic advisory board

In August 2021, we announced our [inaugural Academic Research Advisory Board](https://twitter.com/TwitterDev/status/1431360374155010049) aimed at creating regular and frequent dialogue between members of the academic community and our Developer Platform.

## Sharing your research with Twitter

In August 2021, we also provided researchers with a way to [share their research](https://twitter.com/TwitterDev/status/1422952458393776131) (done with the Twitter API) with us so that we can better learn how researchers use the Twitter API and how we can better serve their needs.

## Sample apps, videos, blogs and code samples

In 2021, we shared various code samples, videos, blogs and sample apps for researchers to learn how to work with the Twitter API v2. Below is a list of these.

### Tutorials and guides

* [Getting historical Tweets using the full-archive search endpoint](https://dev.to/twitterdev/getting-historical-tweets-using-the-full-archive-search-endpoint-1agp)
* [Building high-quality filters for getting Twitter data](https://developer.twitter.com/en/docs/tutorials/building-high-quality-filters)
* [Building visualizations with Tweet counts from the Twitter API v2 in Python](https://dev.to/twitterdev/building-visualizations-with-tweet-counts-from-the-twitter-api-v2-in-python-1nb0)
* [Translating Tweets from the Twitter API v2 using AWS Amazon Translate in Python](https://dev.to/twitterdev/translating-tweets-from-the-twitter-api-v2-using-aws-amazon-translate-in-python-1nj0)
* [A comprehensive guide for using the Twitter API v2 with Tweepy in Python](https://dev.to/twitterdev/a-comprehensive-guide-for-using-the-twitter-api-v2-using-tweepy-in-python-15d9)

### Videos

* [Understanding the Tweet Payload in the Twitter API v2](https://twitter.com/TwitterDev/status/1366832168333234177)
* [Introduction to the academic research product track](https://twitter.com/TwitterDev/status/1376612438313852930)
* [Introducing the getting started with Twitter API v2 for academic research course](https://twitter.com/TwitterDev/status/1409931481552543749)

### Sample apps

Below are some some sample apps, for educational purposes that we built in 2021 to showcase different use-cases pertaining to research with the Twitter API v2.

* [Twitter Timeline Explorer](https://v2-timeline-explorer.glitch.me/) - a sample app that shows the common topics that an account Tweets about
![Timeline Explorer](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ujmnrvq5gno6ng5v3cww.gif)

* [What's in this image](https://whats-in-this-image.glitch.me/) - a demo app to show how you can use AWS Rekognition to extract text from images
![Image analyzer](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/rbucdpceh8lsne06n4z0.gif)

* [Tweet tone analyzer](https://tweet-tone-analyzer.glitch.me/) - a sample app that uses IBM Tone Analyzer and Perpective APIs toxicity measurement functionality
![Tone Analyzer](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/yglx82y14pojdby60i9z.gif)

* [Tweet entity extractor](https://tweet-entity-extractor.glitch.me/) - a sample app that shows how to use the Twitter API v2's Tweet annotations
![Entity Extractor](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/sluss1msozusua91l7s5.gif)

## From the community

In 2021, we saw some amazing updates and resources from the academic community that make it easy for researchers to work with the Twitter API for their research studies. Below is a list of some of these:

* The Document The Now project launched the [twarc2 library](https://twitter.com/documentnow/status/1380119640567844865) in Python (with command line option) that supports the Twitter API v2 and the academic research product track
* [academictwitteR](https://twitter.com/cbarrie/status/1387744422729748486) - a new package in R from Chris Barrie and Justin Ho was launched that supports the Twitter API v2 and the academic product track in R.
* [focalevents](https://twitter.com/ryanjgallag/status/1442478038806003717) - open source codebase from Ryan Gallagher with tools to work with Twitter data for research
* [OSoMeTweets](https://github.com/osome-iu/osometweet) - a package in Python to work with the Twitter API
* A course on [cultural analytics in Python](https://twitter.com/mellymeldubs/status/1346050153237663744) from Melanie Walsh that uses the Twitter API v2

This was a great year for academics that work with the Twitter API for research. If you want to share with the community how you work with the Twitter API for academic research use-cases or have any feedback on our community programs, please feel free to reach out to me [@suhemparack](https://twitter.com/suhemparack)