PyTweet - Selenium
PyTweet Selenium is a simple Python package to extract tweet content from a given URL. Built on selenium.
Installation
To install PyTweet, use:
pip install pytweetselenium
Usage
Here's how you can use PyTweet to fetch tweet content:
import pytweetselenium
url = "https://x.com/AlexanderJiazx/status/1876874066319049004"
result = pytweetselenium.get(url)
print(result)
Output Example
The pytweetselenium.get() function returns a dictionary containing key information about the tweet:
{
'author': 'Alexander Jia',
'author_id': 'AlexanderJiazx',
'text': 'Got the access of AVM with vision!\nTell me how do you want to test it.',
'replies': '7',
'retweets': '3',
'likes': '57',
'bookmarks': '8',
'timestamp': '2024-12-12T23:26:11.000Z'
}
Functions
- Extracts tweet content, including author details, tweet text, engagement metrics (replies, retweets, likes, bookmarks), and timestamp.
- Extraction support text only, image support coming soon.
License
This project is licensed under the MIT License. See the LICENSE file for details.
Metadata
Release files for pytweet-selenium 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pytweet_selenium-1.0.0.tar.gz | 4.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pytweet_selenium-1.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 9.6 kB
Release files / pytweet_selenium-1.0.0.tar.gz
| Download URL | pytweet_selenium-1.0.0.tar.gz |
|---|---|
| Size | 4.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
de86462680360bb0359df2b2ef8d578fe0552083205f8039ccf607550f34171c
|
|
BLAKE2b-256 checksum How to use checksums |
45f7054cd4f13d4a6c57812e843514f60521a7e7291e6bdf3b439f9447dc3203
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.11.3
|
Release files / pytweet_selenium-1.0.0-py3-none-any.whl
| Download URL | pytweet_selenium-1.0.0-py3-none-any.whl |
|---|---|
| Size | 5.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
dea8b59ab3ba4ad99e265ace8c4158db05fa450d89d6e515ce555e37cbec2ed0
|
|
BLAKE2b-256 checksum How to use checksums |
4f0dcc712b844b284c9913d0a459a8c2891bb20163f640e772cd146acc79c9c2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.11.3
|