Skip to content

Unofficial API for PornHub.com in Python

License

Notifications You must be signed in to change notification settings

classicvalues/pornhub-api

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PornHub Unofficial API

Unofficial API for pornhub.com in Python

Install

pip3 install pornhubapi

How to use

Create client

import pornhub
client = pornhub.PornHub()

Create client with proxy

import pornhub
client = pornhub.PornHub("5.135.164.72", 3128)
#With proxy, given a Proxy IP and Port. For the countries with restricted access like Turkey, etc.

Grab stars

for star in client.getStars(10):
    print(star)
    print(star["name"])

Create client with search keywords

keywords = ["word1", "word2"]
client = pornhub.PornHub(keywords)

# if using a proxy
client = pornhub.PornHub("5.135.164.72", 3128, keywords)
# or
client = pornhub.PornHub(ProxyIP="5.135.164.72", ProxyPort=3128, keywords=["word1", "word2"])

for video in client.getVideos(10,page=2):
    print(video)
    print(video["url"])

Contributors


Ibrahim Ipek


Kittinan


Елизаров Роман Русланович


IThinkImOKAY

License

MIT license

About

Unofficial API for PornHub.com in Python

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%