HTTP requests in Python

Before installing pip packages, be sure to enable a venv: Using Venvs.

Install prerequisites

pip install requests

If you are behind a proxy, you might need to configure pip to work with a proxy.

Get requests

Example scripts

import requests

headers = {'Content-Type': 'application/json; charset=utf-8', 'Authorization': 'Splunk eyJraWQiOiJzc.blablalba.tartradfpdnhfpl'}

response = requests.get("", headers=headers, verify=False)



HTTP Requests