Skip to content

letsmakecakes/twitter-automation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

Twitter Automation Project

This is a Python script that uses Selenium to automate tweeting on Twitter. It opens a Chrome browser, logs in to a Twitter account, and sends a tweet with a predefined message.

Prerequisites

Before running the script, make sure you have the following installed:

  • Python (version 3.6 or higher)
  • Selenium library (install using pip install selenium)
  • Chrome browser
  • ChromeDriver (compatible with your Chrome browser version)

Setup

  1. Clone the repository:

    git clone https://github.com/your-username/twitter-automation.git
    cd twitter-automation
  2. Install the required dependencies:

    pip install selenium
  3. Download ChromeDriver and place it in the project directory. Make sure it matches your Chrome browser version. You can download ChromeDriver from the official website.

Usage

  1. Open the twitter_automation.py file in a text editor.

  2. Replace the placeholders 'username' and 'password' with your Twitter account credentials:

    username.send_keys("your-username")
    password.send_keys("your-password")
  3. Modify the tweet variable to customize the message you want to tweet:

    tweet = "Hello Everyone! This is a tweet..."
  4. Save the file.

  5. Run the script:

    python twitter_automation.py

    The script will open a Chrome browser, log in to your Twitter account, and send the tweet with the specified message.

Note: For security reasons, it's recommended to store your Twitter credentials in a separate configuration file and import them into the script instead of hardcoding them directly.

License

This project is licensed under the MIT License. Feel free to use and modify it according to your needs.

Contributing

Contributions are welcome! If you have any improvements or bug fixes, please submit a pull request.

About

Twitter Automation with Selenium in Python.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages