twitterer


Nametwitterer JSON
Version 0.0.1 PyPI version JSON
download
home_page
SummaryPython's package to scrape Twitter with selenium.
upload_time2024-03-17 13:31:21
maintainer
docs_urlNone
author
requires_python
licenseMIT License Copyright (c) 2024 CatBraaain Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
keywords twitter selenium scrape scraping scraper twitterer bot
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # twitterer

Python's package to scrape Twitter with selenium.
Get, like, retweet tweets with automatically.

## Usage
1. Install python package
```cmd
pip install twitterer
```
2. Create `.env` file at project root.
```properties
TWITTER_USERNAME = ReplaceThisToYourOwns
TWITTER_PASSWORD = ReplaceThisToYourOwns
```

### Get tweets and save it
```python
from twitterer import Twitterer

twitterer = Twitterer()
twitterer.authenticate()
tweets = list(
    twitterer.get_tweets(
        url="https://twitter.com/search?q=funny%20filter:videos",
        max_tweets=20,
    )
)

twitterer.save_to_file(tweets)
```

### Like and retweet tweets
`.get_tweets()` method returns generator.
This is real-time processing, so when you use `.like()` or `.retweet()` method on tweets, i must be handled by a generator.
```python
from twitterer import Twitterer

twitterer = Twitterer()
twitterer.authenticate()
for tweet in twitterer.get_tweets(
    url="https://twitter.com/home",
    max_tweets=20,
):
    tweet.like()
    tweet.retweet()
```


            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "twitterer",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "twitter,selenium,scrape,scraping,scraper,twitterer,bot",
    "author": "",
    "author_email": "",
    "download_url": "https://files.pythonhosted.org/packages/89/da/292221fbb7faf6d7e27b808b3a7b096fdeb7bfd28f4312546f0146050c7a/twitterer-0.0.1.tar.gz",
    "platform": null,
    "description": "\ufeff# twitterer\r\n\r\nPython's package to scrape Twitter with selenium.\r\nGet, like, retweet tweets with automatically.\r\n\r\n## Usage\r\n1. Install python package\r\n```cmd\r\npip install twitterer\r\n```\r\n2. Create `.env` file at project root.\r\n```properties\r\nTWITTER_USERNAME = ReplaceThisToYourOwns\r\nTWITTER_PASSWORD = ReplaceThisToYourOwns\r\n```\r\n\r\n### Get tweets and save it\r\n```python\r\nfrom twitterer import Twitterer\r\n\r\ntwitterer = Twitterer()\r\ntwitterer.authenticate()\r\ntweets = list(\r\n    twitterer.get_tweets(\r\n        url=\"https://twitter.com/search?q=funny%20filter:videos\",\r\n        max_tweets=20,\r\n    )\r\n)\r\n\r\ntwitterer.save_to_file(tweets)\r\n```\r\n\r\n### Like and retweet tweets\r\n`.get_tweets()` method returns generator.\r\nThis is real-time processing, so when you use `.like()` or `.retweet()` method on tweets, i must be handled by a generator.\r\n```python\r\nfrom twitterer import Twitterer\r\n\r\ntwitterer = Twitterer()\r\ntwitterer.authenticate()\r\nfor tweet in twitterer.get_tweets(\r\n    url=\"https://twitter.com/home\",\r\n    max_tweets=20,\r\n):\r\n    tweet.like()\r\n    tweet.retweet()\r\n```\r\n\r\n",
    "bugtrack_url": null,
    "license": "MIT License  Copyright (c) 2024 CatBraaain  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.  THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ",
    "summary": "Python's package to scrape Twitter with selenium.",
    "version": "0.0.1",
    "project_urls": {
        "Homepage": "https://github.com/CatBraaain/twitterer"
    },
    "split_keywords": [
        "twitter",
        "selenium",
        "scrape",
        "scraping",
        "scraper",
        "twitterer",
        "bot"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "dc48488d2c1991dced6176e6fce11c5afe3cf35b1cdcf10270e64cc6d8b1c74b",
                "md5": "dd578993caa07d5d5c238e5394b0dac0",
                "sha256": "85fafccf97cb991c1c88bf645741be1bb2de37bdbe08e61ad49152d173f978c0"
            },
            "downloads": -1,
            "filename": "twitterer-0.0.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "dd578993caa07d5d5c238e5394b0dac0",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 8478,
            "upload_time": "2024-03-17T13:31:19",
            "upload_time_iso_8601": "2024-03-17T13:31:19.243439Z",
            "url": "https://files.pythonhosted.org/packages/dc/48/488d2c1991dced6176e6fce11c5afe3cf35b1cdcf10270e64cc6d8b1c74b/twitterer-0.0.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "89da292221fbb7faf6d7e27b808b3a7b096fdeb7bfd28f4312546f0146050c7a",
                "md5": "dfc0135831ce640f4b28fc91b35c5585",
                "sha256": "6294630b432856bd9ab3b8c1eb8cf09e050900792037eef9527736f4fce18a21"
            },
            "downloads": -1,
            "filename": "twitterer-0.0.1.tar.gz",
            "has_sig": false,
            "md5_digest": "dfc0135831ce640f4b28fc91b35c5585",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 7664,
            "upload_time": "2024-03-17T13:31:21",
            "upload_time_iso_8601": "2024-03-17T13:31:21.142486Z",
            "url": "https://files.pythonhosted.org/packages/89/da/292221fbb7faf6d7e27b808b3a7b096fdeb7bfd28f4312546f0146050c7a/twitterer-0.0.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-03-17 13:31:21",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "CatBraaain",
    "github_project": "twitterer",
    "github_not_found": true,
    "lcname": "twitterer"
}
        
Elapsed time: 0.28958s