A powerful Python library to scrape xvideos.com
Project description
xvideos-py
A powerful Python library to scrape xvideos.com.
💻 Installation
$ pip install xvideos-py
🍑 Usage
🍒 Importing the Library
from xvideos import XVideos
🍒 Retrieve Fresh Videos
xvideos = XVideos()
# Retrieve fresh videos from the first page
fresh = xvideos.fresh(page=1)
# Log details of the retrieved videos
print(fresh['videos']) # List of video objects with properties like url, path, title, duration, profile, views
print(fresh['pagination']['pages']) # List of available page numbers
🍒 Retrieve Verified Videos
# Retrieve verified videos from the first page
verified = xvideos.get_verified(page=1)
# Log details of the retrieved videos
print(verified['videos']) # List of verified video objects with properties like url, path, title, duration, profile, views
print(verified['pagination']) # List of available page numbers
🍒 Search Videos
# Search for videos with a specific keyword
search_results = xvideos.search(page=1, k="example", sort="relevance")
# Log details of the search results
print(search_results['videos']) # List of video objects with properties based on the search parameters
print(search_results['pagination']) # List of available page numbers
🍐 Params explanation
Parameter | Default | Options |
---|---|---|
page |
1 |
(any positive integer) |
k |
"" |
(any search keyword) |
sort |
"relevance" |
"uploaddate" , "rating" , "length" , "views" , "random" |
datef |
"all" |
"today" , "week" , "month" , "3month" , "6month" , "all" |
durf |
"allduration" |
"1-3min" , "3-10min" , "10min_more" , "10-20min" , "20min_more" , "allduration" |
quality |
"all" |
"hd" , "1080P" , "all" |
pewmium |
False |
False, True |
🍑 Development
🍒 Running Tests
To run tests, you can use pytest
. Ensure you have it installed in your development environment.
$ pytest
🐼 @me
You can find me on twitter as 🐤 @osinthappyemo or on instagram as 🍢 @osintxv
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
xvideos_py-0.1.0.tar.gz
(7.5 kB
view details)
Built Distributions
File details
Details for the file xvideos_py-0.1.0.tar.gz
.
File metadata
- Download URL: xvideos_py-0.1.0.tar.gz
- Upload date:
- Size: 7.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.12.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3ea4ef87c2a8354a93aa8a90c891cf609105d269836cc983d83e525da3a956bf |
|
MD5 | 3132a5dabd2c0f0cfa4f432ffcdb48fc |
|
BLAKE2b-256 | 0943e9cf9440e84dcede79ced61c657a6af6b80db376efec51c75e807aff161f |
File details
Details for the file xvideos_py-0.1.0-py3-none-any.whl
.
File metadata
- Download URL: xvideos_py-0.1.0-py3-none-any.whl
- Upload date:
- Size: 7.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.12.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 23b0599555922a663db55fd8db8544401d47e46e1950d390fc37435462015d36 |
|
MD5 | 7d8846d10435d57014885bd14b5b8d59 |
|
BLAKE2b-256 | 0cc20e3b62ad4cad1c16cdde1564c7237384fe7cfaebc6adf92bda80f07601e4 |
File details
Details for the file xvideos.py-0.1.0-py3-none-any.whl
.
File metadata
- Download URL: xvideos.py-0.1.0-py3-none-any.whl
- Upload date:
- Size: 7.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.10.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 09e0a1a6608a549d363fdbfb513775613f5d57576331a58ed50cb4709d10fda9 |
|
MD5 | 4d22e3a11f97ad4bfc1bb178f91edb55 |
|
BLAKE2b-256 | 243522b7b02553e9bb3f15db03417b1504b3769d041d28e120628ec294f9df60 |