Bearer logo
Twitter API logo

Twitter API


API documentation

Developer website

Incorrect or missing information? Help us

What is the Twitter API?

Twitter is, well you probably know what Twitter is. Broadly used by journalists, tech peoples and much more, it lets you see "What's happening". The API was once restricted, but Twitter starts to open it much more (with rate limits see below). You can do very exciting things with the API, from automating your tweets posts to making some very powerful data analysis for your business. An enterprise account might be required at some point.

How to use the Twitter API?

// npm install @bearer/node
.auth('AUTH_ID') // Check the code example below on how to generate access tokens
.then(({ data }) => console.log(data))
.catch(e => console.log(e))
// npm install @bearer/node
.auth('AUTH_ID') // Check the code example below on how to generate access tokens
.get('users/show.json', { query: { screen_name: "bearersh"}})
.then(({ data }) => console.log(data))
.catch(e => console.log(e))
<script src=""></script>
<button class="btn btn-primary" onclick="myConnectButton()">
Connect to Twitter
const bearerClient = bearer('YOUR_BEARER_PUB_KEY')
function myConnectButton() {
.then(({ authId }) => {
// Use this authId like bearer.auth(authId).get(..
console.log('AUTH_ID for this user', authId)

Start using the Twitter API

Bearer provides a universal API client to call any Twitter endpoints. It takes care of API authentication, credentials management, and monitoring out-of-the-box.

Available in Node.js, Ruby, Python, and PHP

Sign up with Email

How to get a Twitter API Key?

  1. Sign in to your Twitter developer account
  2. In your account settings, open the "Apps" section
  3. Click on "Create an app"
  4. Fill the form with application details
  5. When asking for a "Callback URL", provide the following
  6. Your app is created. Let's review the permissions. By default, Twitter gives "Read and write" access. You might need to change that.
  7. That's it!

Twitter API Rate Limits

Open Twitter endpoints Twitter references all the rate limits on a dedicated page of the API reference. Most common endpoints have a 900 requests limits per 15 min time window. But some endpoints have much fewer credits.

X-Rate-Limit-Limite.g. 900
The rate limit ceiling for that given endpoint.
X-Rate-Limit-Remaininge.g. 817
The number of requests left for the 15-minute window.
X-Rate-Limit-Resete.g. 1571066040
The remaining window before the rate limit resets (in UTC epoch seconds).

Twitter API Versions

The current Twitter API version (v1.1) relies on OAuth 1.0a in its standard version. The enterprise or ads version use different authentication method.

Start integrating the Twitter API for free!

Universal API client

Query the Twitter API and hundreds more APIs using a single API client.

Identity Management

From API credentials to OAuth dance, token and refresh token, Bearer manages it all.

Real-time Monitoring

Get a complete overview of your API usage with metrics and in-depth logs, find errors anddebug in a snap.

Bearer - Integrations built in minutes, Monitored in real-time


Docs & Help


Bearer is on TwitterBearer is on GitHubBearer is on FacebookBearer is on LinkedIn
© Copyright Bearer 2019
Bearer uses cookies to make its website easier to use. Learn more about cookies.