Skip to main content

Getting started with Twitter API

Generate API tokens

To use the Twitter API, you must obtain your API keys from Twitter developper portal: https://developer.twitter.com/en

The API keys and tokens are on Application level. So you need to:

  1. Create a project (if it does not exists) from the Twitter developer portal https://developer.twitter.com/en/portal/dashboard
  2. Add an App into the project.
  3. Save keys and token from the screen (as it will not be visible after for security reasons):

Twitter API keys and tokens

tip

The bearer token is enough to get tweets details.

Authentication

The process for obtaining these keys is described on the Twitter Developer Portal: https://developer.twitter.com/en/docs/twitter-api/getting-started/getting-access-to-the-twitter-api

Restrictions and limitations

They depend on your subscription level. You can see the comparison on the Twitter dev portal: https://developer.twitter.com/en/docs/twitter-api/getting-started/about-twitter-api