A proxy library for python 3
Project description
Python proxy manager. <br>
Please use diligently and respectfully. <br>
Always respect a website's ROBOTS.txt
## compatibility
This library is compatible with python 3
## dependancies
This library is dependant on:
- requests
- beautifulsoup4
## install
```bash
pip install py_proxy
```
## features
- Automatically fetches up to 80 proxies
- Cycle between proxies easily
- Test a proxy and get details about the proxy
- Format proxies for use with requests library
## examples
```python
from proxy import Proxy
proxy = Proxy()
# getting the current proxy
cur_proxy = proxy.proxy
# testing the current proxy
res = proxy.test_proxy(cur_proxy)
if res == 1:
print("success!")
else:
print("failure!")
# cycling the proxy to a new proxy from the pool
proxy.cycle()
# filtering proxies by a country code
proxy = Proxy("US") #gets US only proxies from the pool
#format a proxy for use with requests library
ip = "100.100.100.100" #example ip, not real
port = "1989" #example port, not real
addr = [ip, port]
proxies = proxy.format_proxy(addr) #returns the requests proxies dictionary
```
## license
You're free to use this package which is licensed under the [MIT-LICENSE](LICENSE)
## contributing
Contribution is always appreciated. <br>
If you are contributing please remember to update the README. <br>
If your contribution is accepted you will be credited for it.
## Author
[Dylan Randall aka HOWZ1T](https://github.com/howz1t)
Keywords: proxy proxies library helper
Platform: UNKNOWN
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Topic :: Software Development :: Library
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.4
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
Please use diligently and respectfully. <br>
Always respect a website's ROBOTS.txt
## compatibility
This library is compatible with python 3
## dependancies
This library is dependant on:
- requests
- beautifulsoup4
## install
```bash
pip install py_proxy
```
## features
- Automatically fetches up to 80 proxies
- Cycle between proxies easily
- Test a proxy and get details about the proxy
- Format proxies for use with requests library
## examples
```python
from proxy import Proxy
proxy = Proxy()
# getting the current proxy
cur_proxy = proxy.proxy
# testing the current proxy
res = proxy.test_proxy(cur_proxy)
if res == 1:
print("success!")
else:
print("failure!")
# cycling the proxy to a new proxy from the pool
proxy.cycle()
# filtering proxies by a country code
proxy = Proxy("US") #gets US only proxies from the pool
#format a proxy for use with requests library
ip = "100.100.100.100" #example ip, not real
port = "1989" #example port, not real
addr = [ip, port]
proxies = proxy.format_proxy(addr) #returns the requests proxies dictionary
```
## license
You're free to use this package which is licensed under the [MIT-LICENSE](LICENSE)
## contributing
Contribution is always appreciated. <br>
If you are contributing please remember to update the README. <br>
If your contribution is accepted you will be credited for it.
## Author
[Dylan Randall aka HOWZ1T](https://github.com/howz1t)
Keywords: proxy proxies library helper
Platform: UNKNOWN
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Topic :: Software Development :: Library
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.4
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
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
py_proxy-0.2.1.tar.gz
(6.7 kB
view details)
File details
Details for the file py_proxy-0.2.1.tar.gz
.
File metadata
- Download URL: py_proxy-0.2.1.tar.gz
- Upload date:
- Size: 6.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 998c66776ae0d1856597059eaef785be157c3baa143f450369ba1c49afd7b0ba |
|
MD5 | 0a7499b48b867b5d0c13c2756c9a303b |
|
BLAKE2b-256 | 739a08a2b593d54866ce283f771356f14aad805e271fbf62965177504d28cf21 |