Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Twitter auth

Easy Twitter API OAuth 2 Access

  1. Go to your applications. Create a new one, and find the values in the Consumer Key and Consumer Secret fields.

  2. Use OAuth client information to produce an OAuth 2 access token:

    curl -i --user <consumer_key>:<consumer_secret> -X POST -d "grant_type=client_credentials"
  3. Then use that access token for direct API access:

    curl -i -H "Authorization: Bearer <oauth2_token>"\=<screen_name>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.