Skip to content

osscameroon/twitter-auth

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

twitter-auth

twitter oauth1 authenticator cli

Dependencies

The cli may require to have the following dependencies installed:

  • Python3
  • make

How to run

Set your twitter application credentials

The application may require you to set your twitter app consumer_key and consumer_secret in a config.ini file.

  • To do so, create a config.ini using mv example.config.ini config.ini
  • Then replace the file [AUTH] fields with the corresponding values
[AUTH]
consumer_key=<a_consumer_key
consumer_secret=<a_consumer_secret>

Run the application

To run the application execute make run, this command will ask you for a verifier PIN. To get this PIN

1 - Open on your browser the auth url.

2 - Click on Authorize App

Screenshot 2021-12-27 at 14 23 52

3 - then copy and paste the pin on your terminal.

Screenshot 2021-12-27 at 14 24 03

The CLI should spit out the twitter user api key and secret you can use to perform tasks on their behalf.

Example:

venv/bin/python3 main.py
auth url:  https://api.twitter.com/oauth/authorize?oauth_token=<token>
Verifier:3553107
api_key: <USER_API_KEY>
api_secret: <USER_API_SECRET>

Note: please make sure the OAuth 1.0a is turned on for your application

About

twitter oauth1 authenticator cli

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published