Skip to main content
This guide walks you through obtaining OAuth 2.0 credentials for the Twitter plugin.

Authentication Method

The Twitter plugin uses OAuth 2.0 authentication.
  • oauth_2 - OAuth 2.0 user authentication

OAuth 2.0 Setup

Step 1: Create a Twitter Developer App

  1. Go to developer.twitter.com
  2. Click + Add app or Create Project
  3. Fill in the app name and description
  4. Select OAuth 2.0 as the authentication type

Step 2: Configure OAuth Settings

  1. In your app settings, go to User authentication settings
  2. Enable OAuth 2.0
  3. Set App permissions to Read and write
  4. Add your Callback URI (e.g., http://localhost:<port> for CLI flow)
  5. Add your Website URL
  6. Click Save

Step 3: Get Client Credentials

  1. Go to Keys and Tokens
  2. Copy the OAuth 2.0 Client ID and Client Secret
  3. Store these securely
Storing Credentials: Store your OAuth app credentials, then start the flow:
pnpm corsair setup --plugin=twitter client_id=your-client-id client_secret=your-client-secret
pnpm corsair auth --plugin=twitter
The CLI will print an authorization URL — open it in a browser. Once you approve, tokens are saved automatically.

Required Credentials Summary

CredentialRequired ForWhere to Find
Client IDOAuth 2.0Developer Portal → Keys and Tokens
Client SecretOAuth 2.0Developer Portal → Keys and Tokens
For general information about how Corsair handles authentication, see Authentication.