Skip to main content

A PornHub client.

Project description

This is a simple library that scrapes PornHub for content, and provides a simple, elegant API for interacting with the website.

Only Python 3 is supported.

Example Usage

>>> from phlib import PornHub
>>> ph = PornHub()

>>> ph.categories
...

>>> ph['example category']
<Category title='example category'>

>>> cat = _
>>> cat.videos(max=25)
...

>>> ph.search('some search term')
...

Videos have a download() method, which will download the video to your current directory.

A CLI utility is provided, ph:

Ph — empowering porn users everywhere.

Usage:
  ph <search>... [--max=<n>] [--meta] [--download]
  ph (-h | --help)
  ph --version

Options:
  -h --help     Show this screen.
  --version     Show version.
  --max=<n>     Maximum number of videos to list [default: 25].
  --meta        Display video meta-data.
  --list        List categories.
  --download    Downloads videos.

Enjoy!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

phlib-0.1.0.tar.gz (2.8 kB view details)

Uploaded Source

Built Distribution

phlib-0.1.0-py2.py3-none-any.whl (3.4 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file phlib-0.1.0.tar.gz.

File metadata

  • Download URL: phlib-0.1.0.tar.gz
  • Upload date:
  • Size: 2.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for phlib-0.1.0.tar.gz
Algorithm Hash digest
SHA256 fc99989b95697993af55c17bca4cfaa17b65017cfddab22747df0b81178c3773
MD5 27dfd8df0cf88f9ce2e495a95b55847d
BLAKE2b-256 3552f001fd49c8ce1cdca41f2047b350ddd6935ce3937524a5a7f5012b08a806

See more details on using hashes here.

File details

Details for the file phlib-0.1.0-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for phlib-0.1.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 49ac40c6f7201f0747be634d3b1d4b5ed0a5a072a3983d8021a3793ec11cba73
MD5 4c4b27f8687adf938ca6774044a8c920
BLAKE2b-256 ea3391c3a3ca18ae1bd9b4f43fa296e82f54d4be7fa2ed88cbc2b190d744588c

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page