Skip to content

Latest commit

 

History

History
10 lines (8 loc) · 331 Bytes

proxy-usage-with-requests-in-python.md

File metadata and controls

10 lines (8 loc) · 331 Bytes

How to use proxies with Requests in Python

import requests
proxy = 'proxy:goes:here'
proxyDict = {"http"  : proxy, "https"  : proxy}
response = requests.get('https://www.url.com', proxies=proxyDict)

You can send the POST requests using a similar format. Headers can be added to the request using headers={}